configuration_definitions

Full name: ase2sprkkr.common.configuration_definitions

Module class hierarchy

Inheritance diagram of ase2sprkkr.common.configuration_definitions.BaseDefinition, ase2sprkkr.common.configuration_definitions.ControlDefinition, ase2sprkkr.common.configuration_definitions.Gather, ase2sprkkr.common.configuration_definitions.Ignored, ase2sprkkr.common.configuration_definitions.NotAllowed, ase2sprkkr.common.configuration_definitions.RealItemDefinition, ase2sprkkr.common.configuration_definitions.SeparatorDefinition, ase2sprkkr.common.configuration_definitions.Stub, ase2sprkkr.common.configuration_definitions.Switch, ase2sprkkr.common.configuration_definitions.VirtualDefinition

Description

Configuration definitions are classes, that desribes the syntax of a configuration file, or its parts (sections or configuration options)

They are able both to parse a file, which results in an instance of (an instance of ase2sprkkr.common.Configuration, e.g. an Option or Section ), or write such object to a file.

Functions

gather(first, *members)

Modify the given option definitions, that they appears in the output file in the form.

if_defined(item, values[, not_values, name])

if_not_defined(item, values[, not_values, name])

switch(item, values[, condition, name])

Classes

BaseDefinition(name[, is_optional, condition])

This class is a member of definition of configuration, that can be both real (holds a value or values) or just virtual.

ControlDefinition([name, template, condition])

Control definitions has no grammar, they just modify the other items of the container

Gather(*items[, name_delimiter, ...])

Output definition for the element of grammar, that reads besides himself other grammar elements, such that their names goes first and then the values go.

Ignored()

Output definition for an ignored option.

NotAllowed(msg)

Object of this class can be returned as a result of a :func:ConfigurationDefinition.condition

RealItemDefinition(name[, written_name, ...])

A base class for a configuration definition, either of an option, or of a container.

SeparatorDefinition([separator_type, ...])

Basic class for separators

Stub(item[, name, condition])

Item that allows to reuse existing item on the other place e.g. in another branch of Switch.

Switch(item, values[, condition, name, template])

Items of this class can control, which elements of grammar will be active and which not

VirtualDefinition([name, template, condition])

Base class for a definition, that do not have value, just control the flow of the parsing