lisa.conf.TopLevelKeyDescBase#

class lisa.conf.TopLevelKeyDescBase(levels, *args, **kwargs)[source]#

Bases: LevelKeyDesc

Top-level key descriptor, which defines the top-level key to use in the configuration files.

Parameters:

levels (list(str)) – Levels of the top-level key, as a list of strings. Each item specifies a level in a mapping, so that multiple classes can share the same actual top-level without specific cooperation.

This top-level key is omitted in all interfaces except for the configuration file, since it only reflects the configuration class

Attributes

__reversed__ inherited

See collections.abc.Mapping.__reversed__

help inherited

Help description associated with the key.

name inherited

Name of that key.

parent inherited

Parent LevelKeyDesc.

Properties

key_desc inherited

Leaf KeyDescBase that this level will delegate to in case it is assigned a leaf value.

path inherited

Path in the config file from the root to that key.

qualname inherited

Qualified name of the configuration key used for error reporting.

Methods

get_help()

Get a help message describing the key.

__class_getitem__() inherited

See collections.abc.Iterable.__class_getitem__()

__contains__() inherited

See collections.abc.Mapping.__contains__()

__getattr__() inherited

__getitem__() inherited

__iter__() inherited

__len__() inherited

check_allowed_key() inherited

Checks that a given key is allowed under that levels.

get() inherited

See collections.abc.Mapping.get()

items() inherited

See collections.abc.Mapping.items()

keys() inherited

See collections.abc.Mapping.keys()

validate_val() inherited

Validate a mapping to be used as a configuration source.

values() inherited

See collections.abc.Mapping.values()

Attributes#

TopLevelKeyDescBase.__reversed__ = None#
TopLevelKeyDescBase.help#

Inherited attribute, see lisa.conf.KeyDescBase.help

Help description associated with the key.

TopLevelKeyDescBase.name#

Inherited attribute, see lisa.conf.KeyDescBase.name

Name of that key.

TopLevelKeyDescBase.parent#

Inherited attribute, see lisa.conf.KeyDescBase.parent

Parent LevelKeyDesc.

Properties#

property TopLevelKeyDescBase.key_desc#

Inherited property, see lisa.conf.LevelKeyDesc.key_desc

Leaf KeyDescBase that this level will delegate to in case it is assigned a leaf value.

property TopLevelKeyDescBase.path#

Inherited property, see lisa.conf.KeyDescBase.path

Path in the config file from the root to that key.

property TopLevelKeyDescBase.qualname#

Inherited property, see lisa.conf.KeyDescBase.qualname

Qualified name of the configuration key used for error reporting.

Methods#

TopLevelKeyDescBase.get_help(style=None, **kwargs)[source]#

Get a help message describing the key.

Parameters:
  • style – When “rst”, ResStructuredText formatting may be applied

  • style – str

  • last (bool) – True if this is the last item in a list.

  • children (bool) – If True, include the help of any children of the current level.

classmethod TopLevelKeyDescBase.__class_getitem__()#

Inherited method, see collections.abc.Iterable.__class_getitem__()

TopLevelKeyDescBase.__contains__()#

Inherited method, see collections.abc.Mapping.__contains__()

TopLevelKeyDescBase.__getattr__(attr)#

Inherited method, see lisa.conf.LevelKeyDesc.__getattr__()

TopLevelKeyDescBase.__getitem__(key)#

Inherited method, see lisa.conf.LevelKeyDesc.__getitem__()

TopLevelKeyDescBase.__iter__()#

Inherited method, see lisa.conf.LevelKeyDesc.__iter__()

TopLevelKeyDescBase.__len__()#

Inherited method, see lisa.conf.LevelKeyDesc.__len__()

TopLevelKeyDescBase.check_allowed_key(key)#

Inherited method, see lisa.conf.LevelKeyDesc.check_allowed_key()

Checks that a given key is allowed under that levels.

TopLevelKeyDescBase.get()#

Inherited method, see collections.abc.Mapping.get()

TopLevelKeyDescBase.items()#

Inherited method, see collections.abc.Mapping.items()

TopLevelKeyDescBase.keys()#

Inherited method, see collections.abc.Mapping.keys()

TopLevelKeyDescBase.validate_val(conf)#

Inherited method, see lisa.conf.LevelKeyDesc.validate_val()

Validate a mapping to be used as a configuration source.

TopLevelKeyDescBase.values()#

Inherited method, see collections.abc.Mapping.values()