Method summary
Methods
- __init__(self, factory, file_name, desc)
Initialise the object. factory is a callable that will create a new instance if there is no existing data. file_name is the name of the file in the ETSConfig.application_home directory (or the directory specified by the ETS_PERMS_DATA_DIR environment variable if set) to persist the data to. desc is a description of the data used in exceptions.
- lock(self)
Obtain a lock on the persisted data.
- read(self)
Read and return the persisted data.
- unlock(self)
Release the lock on the persisted data.
- write(self, data)
Write the persisted data.