renderStatic()
This static method is optional, and only has to be provided for Control Types that support the "static" Render Mode. This method is invoked whenever the form needs to obtain a static rendering of the value bound to this control.
Note: This must be a static method on the ControlWrapper, as an instance of the ControlWrapper is not instantiated when the control is located in a static pane.
The value returned by the control is added as HTML to the form. Any user input values should be escaped appropriately to avoid them being interpreted as HTML.
Method Arguments:
- value: This is the value that needs to be formatted.
- label: (Type String) - The label to be rendered for the static control.
- hint: (Type String) - The hint to be rendered for the static control.
- labelId: (Type String) - Identifier of the label as rendered by the form. This is useful for accessibility.
- propertySet: (Type Associative Array) - Initial configuration of the control, including custom properties configured in the Form Designer. The key is the name of the property as defined in the Control Type.
- resource: (Type Object) - The same as retrieved from the Component.getResources() method.
- textOnly: (Type Boolean) - If true, then the pane this is being rendered in is expecting a text-only rendering of the value. That is, no rendering of a widget that displays the value.
- parentPaneType: (Type String) - This is the string that represents the type of pane. This is equal to the value returned from the Pane.getPaneType() method. A ControlWrapper identifies the rendering on a grid pane using the parentPaneType argument.
- logger: (Type logger Object) - This is the same logger object available in Form action scripts. The logger object helps to log messages to the form log. View the form log at preview time by using the appropriate logging level in the page. Enable logging at runtime by using the query parameter log_level with an appropriate value: TRACE, DEBUG, INFO, WARN, ERROR, FATAL. For example: http://<server>:<port>/openspace?log_level=INFO. See the table Logger Class for the list of available methods.
Method Return Value:
Copyright © Cloud Software Group, Inc. All rights reserved.