b.c.OptionRegistry(registry.Registry) : class documentation

Part of bzrlib.config View In Hierarchy

Register config options by their name.

This overrides registry.Registry to simplify registration by acquiring some information from the option object itself.

Method register Register a new option to its name.
Method register_lazy Register a new option to be loaded on request.
Method get_help Get the help text associated with the given key

Inherited from Registry:

Method __init__ Create a new Registry.
Method get Return the object register()'ed to the given key.
Method get_prefix Return an object whose key is a prefix of the supplied value.
Method get_info Get the extra information associated with the given key
Method remove Remove a registered entry.
Method __contains__ Undocumented
Method keys Get a list of registered entries
Method iteritems Undocumented
Method items Undocumented
Method _add_help_and_info Add the help and information about this key
Method _get_module Return the module the object will be or was loaded from.
Method _get_key_or_default Return either 'key' or the default key if key is None
Method _set_default_key Undocumented
Method _get_default_key Undocumented
def register(self, option):
Register a new option to its name.
ParametersoptionThe option to register. Its name is used as the key.
def register_lazy(self, key, module_name, member_name):
Register a new option to be loaded on request.
Parameterskeythe key to request the option later. Since the registration is lazy, it should be provided and match the option name.
module_namethe python path to the module. Such as 'os.path'.
member_namethe member of the module to return. If empty or None, get() will return the module itself.
def get_help(self, key=None):
Get the help text associated with the given key
API Documentation for Bazaar, generated by pydoctor at 2019-02-24 00:18:01.