Package lepl :: Package support :: Module graph :: Class ArgAsAttributeMixin
[hide private]
[frames] | no frames]

Class ArgAsAttributeMixin

source code


Constructor arguments are stored as attributes; their names are also stored in order so that the arguments can be constructed. This assumes that all names are unique. '*args' are named "without the *".
Instance Methods [hide private]
 
__init__(self)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
__set_attribute(self, name, value)
Add a single argument as a simple property.
source code
 
_arg(self, **kargs)
Set a single named argument as an attribute (the signature uses kargs so that the name does not need to be quoted).
source code
 
_karg(self, **kargs)
Set a single keyword argument (ie with default) as an attribute (the signature uses kargs so that the name does not need to be quoted).
source code
 
_args(self, **kargs)
Set a arg as an attribute (the signature uses kargs so that the attribute name does not need to be quoted). The name (without '') is added to self.__arg_names.
source code
 
_kargs(self, kargs)
Set **kargs as attributes.
source code
 
__args(self)
All (non-keyword) arguments.
source code
 
__kargs(self)
All keyword argmuents.
source code
 
_constructor_args(self)
Regenerate the constructor arguments.
source code
 
__iter__(self)
Return all children, in order.
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

source code 
x.__init__(...) initializes x; see help(type(x)) for signature
Overrides: object.__init__
(inherited documentation)

_arg(self, **kargs)

source code 
Set a single named argument as an attribute (the signature uses kargs so that the name does not need to be quoted). The attribute name is added to self.__arg_names.

_karg(self, **kargs)

source code 
Set a single keyword argument (ie with default) as an attribute (the signature uses kargs so that the name does not need to be quoted). The attribute name is added to self.__karg_names.

_kargs(self, kargs)

source code 
Set **kargs as attributes. The attribute names are added to self.__arg_names.

_constructor_args(self)

source code 
Regenerate the constructor arguments.
Overrides: ConstructorGraphNode._constructor_args