ariba.util.formatter
Class ListFormatter
java.lang.Object
ariba.util.formatter.Formatter
ariba.util.formatter.ListFormatter
- All Implemented Interfaces:
- Compare, StringParser
public class ListFormatter
- extends Formatter
ListFormatter
is a subclass of Formatter
which
is responsible for formatting, parsing, and comparing vectors.
Method Summary |
static java.lang.String |
formatList(java.util.List v,
java.util.Locale locale,
boolean useHTML)
Returns a string representation of the vector as a list. |
java.lang.Object |
getValue(java.lang.Object object,
java.util.Locale locale)
Returns a List from the given object . |
Methods inherited from class ariba.util.formatter.Formatter |
canFormatNulls, compare, compare, equal, equal, getFormat, getFormat, getFormatterClassForType, getFormatterForObject, getFormatterForType, getLocale, getStringValue, getStringValue, getValue, handlesNulls, isBidirectional, makeParseException, makeParseException, makeParseException, makeParseExceptionMessage, makeParseExceptionMessage, objectsAreEqual, objectsAreEqual, parse, parse, parseString, parseString, quickCompare, quickCompare, quickCompareValue, registerFormatter |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ListFormatter
public ListFormatter()
- Creates a new
ListFormatter
.
formatList
public static java.lang.String formatList(java.util.List v,
java.util.Locale locale,
boolean useHTML)
- Returns a string representation of the
vector
as a list.
- Parameters:
v
- List
to format.locale
- The Locale
to use for formatting.useHTML
- True if HTML tags should be inserted into the
string to create a list.
- Returns:
- Returns a string representation of the vector
getValue
public java.lang.Object getValue(java.lang.Object object,
java.util.Locale locale)
- Returns a
List
from the given object
.
We currently do not support converting other object types to
List
, so the method will either return the
List
that is passed in or, if the object
isn't a List
, it will return null.
- Specified by:
getValue
in class Formatter
- Parameters:
object
- the object to convert to a List
locale
- the Locale
to use for conversion (unused)
- Returns:
- a
List
derived from the given object
AribaWeb User Interface Development Framework
Copyright © 2000-2014 Ariba, Inc. All Rights Reserved.