ERXStringWithLineBreaks Class Reference

Inherits er::extensions::components::ERXStatelessComponent.

Collaboration diagram for ERXStringWithLineBreaks:

Collaboration graph
[legend]

List of all members.

Public Member Functions

String br ()
 ERXStringWithLineBreaks (WOContext context)
void reset ()
void setValue (Object newValue)
String tabs ()
String value ()
Object valueWhenEmpty ()

Public Attributes

String _value

Protected Member Functions

String valueToString (Object value)


Detailed Description

Simple component that can convert a string that has line breaks and tabs in it into an html string that has
and &nbsp instead. Very useful for preserving line breaks that are typed into a WOTextBox.
Synopsis:
value=aString;[valueWhenEmpty=aString;]

value string to be converted valueWhenEmpty if null or length of zero what to display


Constructor & Destructor Documentation

ERXStringWithLineBreaks ( WOContext  context  ) 

Public constructor

Parameters:
context current context


Member Function Documentation

String br (  ) 

void reset (  ) 

Nulls out cached instance variable: _value

Reimplemented from ERXStatelessComponent.

void setValue ( Object  newValue  ) 

Set the value to be displayed.
This is useful when you want to return a string from a DirectAction for example for debugging purposes.

Parameters:
newValue Object to display

String tabs (  ) 

String value (  ) 

Converts '
', '
', '' into "<br />" and converts '' into five non-breaking spaces.

Returns:
converts string bound to binding: value into html-ified line breaks.

String valueToString ( Object  value  )  [protected]

Object valueWhenEmpty (  ) 

Returns binding valueWhenEmpty.

Returns:
value to display when the string is empty


Member Data Documentation

holds the html-ified string


The documentation for this class was generated from the following file:

Generated on Sat May 26 06:43:06 2012 for Project Wonder by  doxygen 1.5.8