class documentation
class FileManager(object):
Known subclasses: niryo_libraries.niryo_robot_poses_handlers.file_manager.PickleFileManager
Constructor: FileManager(base_dir, extension, protected_names)
Manages the creation, storage and loading of objects that implement the functions from_dict and to_dict.
!!! This class is an abstract class
Raises | |
NiryoRobotFileException |
Method | __init__ |
Undocumented |
Method | check |
Undocumented |
Method | exists |
Check if a file with a certain name exists |
Method | get |
Get all filenames available in storage |
Method | get |
Get all filenames available in storage + their descriptions |
Method | read |
Read file |
Method | read |
Undocumented |
Method | remove |
Remove file |
Class Variable | object |
Undocumented |
Method | _filename |
Undocumented |
Method | _name |
Undocumented |
Method | _path |
Undocumented |
Method | _write |
Undocumented |
Instance Variable | _base |
Undocumented |
Instance Variable | _extension |
Undocumented |
Instance Variable | _protected |
Undocumented |
Instance Variable | _suffix |
Undocumented |
Check if a file with a certain name exists
Parameters | |
name:str | file name |
Returns | |
bool | True if file exists, else False |
Get all filenames available in storage
Returns | |
list[str] | list of filenames |
Raises | |
Unknown exception | NiryoRobotFileException: if any error |
Read file
Parameters | |
name:str | file name |
Returns | |
object_type | An object corresponding to object_type |
Raises | |
Unknown exception | NiryoRobotFileException: if any error |
Remove file
Parameters | |
name:str | file name |
Returns | |
None | |
Raises | |
Unknown exception | NiryoRobotFileException: if any error |