Transformer
The Transformer is the base class that provides the API to transform values to and from web interfaces
-
For a list of existing implementations see Web-Schnittstellen-Bibliothek
Methods
|
Function |
Parameters |
Return Value |
Description |
|---|---|---|---|
|
Transformer.__init_ |
web_attribute: A instance of weblink.metadata.WebAttribute pointing to the 593 record this transformer applies to |
Instance |
Initializes a new Transformer element. |
|
Transformer.transform_planta_value_to_web_value |
value: The value to transform |
The transformed value |
Transforms a value read from a PLANTA POJO attribute to the web appropriate value.
Overwrites this in a subclass to transform a PLANTA value into the value appropriate for your web interface. |
|
Transformer.transform_web_value_to_planta_value |
value: The value to transform |
The transformed value |
Transforms a value read from a web request into the PLANTA POJO attribute appropriate value.
Overwrites this in a subclass to transform a PLANTA value into the value appropriate for your web interface. |
|
Transformer.transform |
value: The value to transform |
The transformed value |
Method that is called by both planta→web and web→planta transform implementations by default. |
Classmethods
|
Function |
Parameters |
Return Value |
Description |
|---|---|---|---|
|
Transformer.register_parameter |
name: Name of the parameter default: The default value |
|
Registers a new parameter for this class |
|
Transformer.register_parameters |
|
|
A method that is called by the framework to register all parameters. By default it does nothing and must be overwritten in a subclass to call |
|
Transformer.unregister_parameter |
name: Name of the parameter |
|
Removes a registered parameter that is not required. Returns |
Properties
|
Property |
Getter |
Setter |
Description |
|---|---|---|---|
|
Transformer.parameters |
Returns a dictionary of the parameters of this transformer |