b.c.IniFileStore(Store) : class documentation

Part of bzrlib.config View In Hierarchy

Known subclasses: bzrlib.config.BranchStore, bzrlib.config.LockableIniFileStore

A config Store using ConfigObj for storage.
Instance VariablestransportThe transport object where the config file is located.
file_nameThe config file basename in the transport directory.
_config_objPrivate member to hold the ConfigObj instance used to serialize/deserialize the config file.
Method __init__ A config Store using ConfigObj for storage.
Method is_loaded Returns True if the Store has been loaded.
Method unload Unloads the Store.
Method load Load the store from the associated file.
Method save Saves the Store to persistent storage.
Method external_url Undocumented
Method get_sections Get the configobj section in the file order.
Method get_mutable_section Returns the specified mutable section.
Method _load_from_string Create a config store from a string.

Inherited from Store:

Method __repr__ Undocumented
def __init__(self, transport, file_name):
A config Store using ConfigObj for storage.
ParameterstransportThe transport object where the config file is located.
file_nameThe config file basename in the transport directory.
def is_loaded(self):
Returns True if the Store has been loaded.

This is used to implement lazy loading and ensure the persistent storage is queried only when needed.

def unload(self):
Unloads the Store.

This should make is_loaded() return False. This is used when the caller knows that the persistent storage has changed or may have change since the last load.

def load(self):
Load the store from the associated file.
def _load_from_string(self, bytes):
Create a config store from a string.
ParametersbytesA string representing the file content.
def save(self):
Saves the Store to persistent storage.
def external_url(self):
Undocumented
def get_sections(self):
Get the configobj section in the file order.
ReturnsAn iterable of (name, dict).
def get_mutable_section(self, section_name=None):
Returns the specified mutable section.
Parameterssection_nameThe section identifier
API Documentation for Bazaar, generated by pydoctor at 2019-11-20 00:36:28.