|
|
|
Description
Allows
for the insertion of text (with a specified format) into the HTML.
The text itself can be 'transformed' or not (where 'transform' in
this case means that various characters like < and > are
transformed into HTML safe representations such as < and
>). The
value for the text is bound, just like any other component.
|
See Also
Conditional,
Foreach,
RenderBlock,
InsertText,
RenderBody
|
Parameters
Name |
Type |
Direction |
Required |
Default |
Description |
value |
Object |
in |
no |
|
The value to be inserted. If the binding is null, then nothing is
inserted. Any object may be inserted, the toString() method is
used to convert it to a printable value.
|
format |
Format
|
in |
no |
|
An optional format object used to convert the value parameter for
insertion into the HTML response.
|
class |
String |
in |
no |
|
If specified, then the output is wrapped in an HTML <span> tag,
using the value specified as the CSS class.
|
raw |
boolean |
in |
no |
false |
If true, then the method
IMarkupWriter.printRaw(String) is used, rather than
IMarkupWriter.print(String).
This bypasses the normal safeguards
and is used when the value to insert contains HTML markup that
should be emitted as is.
|
Body: removed Informal parameters:
forbidden
Reserved
parameters: none
|
Examples
Inserts the pages dueDate and applies the specified DateFormat and HTML class.
The order was due on the 21 January 2002.
|
The order was due on the <span jwcid="insertDueDate"/>.
<component id="insertDueDate" type="Insert">
<binding name="value" property-path="dueDate"/>
<field-binding name="format" field-name="EnquiryPage.DATE_FORMAT"/>
<binding name="class" property-path="dueClass"/>
</component>
public class EnquiryPage extends BasePage {
public static final SimpleDateFormat DATE_FORMAT =
new SimpleDateFormat("dd MMM yyyy");
private Date dueDate;
private String dueClass;
public Date getDueDate() { return dueDate; }
public String getDueClass() { return dueClass; }
public void detach() {
dueDate = null;
dueClass = null;
super.detach();
}
}
|
|
|
|