Home | Trees | Indices | Help |
---|
|
object --+ | Extension
A class derived from 'Extension' is a QM extension.
A variety of different classes are derived from 'Extension'. All of these classes can be derived from by users to produce customized QM extensions.
'Extension' is an abstract class.
|
|||
Type | |||
__metaclass__ |
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from |
|
|||
arguments =
A list of the arguments to the extension class. |
|||
kind = None A string giving kind of extension is implemented by the class. |
|||
_argument_list =
A list of all the 'Field's in this class. |
|||
_argument_dictionary =
A map from argument names to 'Field' instances. |
|||
_allow_arg_names_matching_class_vars = None True if it is OK for fields to have the same name as class variables. |
|
|||
Inherited from |
|
Construct a new 'Extension'. 'args': Keyword arguments providing values for Extension parameters. The values should be appropriate for the corresponding fields. Derived classes must pass along any unrecognized keyword arguments to this method so that additional arguments can be added in the future without necessitating changes to derived classes. This method will place all of the arguments into this objects instance dictionary. Derived classes may override this method, but should call this method during their processing.
|
Return the name of the extension class. returns -- A string giving the name of this etension class. |
Return the arguments to this extension instance. returns -- A dictionary mapping argument names to their values. Computed arguments are ommitted from the dictionary. |
Create a DOM node for 'self'. 'document' -- The DOM document that will contain the new element. 'element' -- If not 'None' the extension element to which items will be added. Otherwise, a new element will be created by this function. returns -- A new DOM element corresponding to an instance of the extension class. The caller is responsible for attaching it to the 'document'. |
Create a DOM document for 'self'. 'extension_class' -- A class derived from 'Extension'. 'arguments' -- The arguments to the extension class. returns -- A new DOM document corresponding to an instance of the extension class. |
Write an XML description of 'self' to a file. 'file' -- A file object to which the data should be written. |
|
argumentsA list of the arguments to the extension class. Each element of this list should be an instance of 'Field'. The 'Field' instance describes the argument. Derived classes may redefine this class variable. However, derived classes should not explicitly include the arguments from base classes; QMTest will automatically combine all the arguments found throughout the class hierarchy.
|
kindA string giving kind of extension is implemented by the class. This field is used in an application-specific way; for example, QMTest has 'test' and 'target' extension classes.
|
_argument_listA list of all the 'Field's in this class. This list combines the complete list of 'arguments'. 'Field's appear in the order reached by a pre-order breadth-first traversal of the hierarchy, starting from the most derived class.
|
_argument_dictionaryA map from argument names to 'Field' instances. A map from the names of arguments for this class to the corresponding 'Field'.
|
_allow_arg_names_matching_class_varsTrue if it is OK for fields to have the same name as class variables. If this variable is set to true, it is OK for the 'arguments' to contain a field whose name is the same as a class variable. That makes the 'default_value' handling for fields fail, and is generally confusing. This module no longer allows such classes, unless this variable is set to true. That permits legacy extension classes to continue working, while preventing new extension classes from making the same mistake.
|
Home | Trees | Indices | Help |
---|
Generated by Epydoc 3.0.1 on Fri Dec 23 12:30:40 2011 | http://epydoc.sourceforge.net |