Package buildbot :: Package schedulers :: Module forcesched :: Class AnyPropertyParameter
[frames] | no frames]

Class AnyPropertyParameter

source code

   object --+        
            |        
BaseParameter --+    
                |    
  NestedParameter --+
                    |
                   AnyPropertyParameter

A generic property parameter, where both the name and value of the property must be given.

Instance Methods
 
__init__(self, name, **kw)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
getFromKwargs(self, kwargs)
Simple customization point for child classes that do not need the other parameters supplied to updateFromKwargs.
source code
 
updateFromKwargs(self, master, properties, kwargs, **kw)
By default, the child values will be collapsed into a dictionary.
source code

Inherited from NestedParameter: collectChildProperties, setParent

Inherited from BaseParameter: parse_from_arg, parse_from_args

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

Class Variables
  type = ['nested', 'any']

Inherited from NestedParameter: fields

Inherited from BaseParameter: debug, default, hide, label, multiple, name, parentName, regex, required

Properties

Inherited from BaseParameter: fullName

Inherited from object: __class__

Method Details

__init__(self, name, **kw)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • name - the name of the field, used during posting values back to the scheduler. This is not necessarily a UI value, and there may be restrictions on the characters allowed for this value. For example, HTML would require this field to avoid spaces and other punctuation ('-', '.', and '_' allowed)
  • label - (optional) the name of the field, used for UI display.
  • regex - (optional) regex to validate the value with. Not used by all subclasses
Overrides: object.__init__
(inherited documentation)

getFromKwargs(self, kwargs)

source code 

Simple customization point for child classes that do not need the other parameters supplied to updateFromKwargs. Return the value for the property named 'self.name'.

The default implementation converts from a list of items, validates using the optional regex field and calls 'parse_from_args' for the final conversion.

Overrides: BaseParameter.getFromKwargs
(inherited documentation)

updateFromKwargs(self, master, properties, kwargs, **kw)

source code 

By default, the child values will be collapsed into a dictionary. If the parent is anonymous, this dictionary is the top-level properties.

Overrides: BaseParameter.updateFromKwargs
(inherited documentation)