public class FeatureFormat extends TabularFormat<Object>
City ┌────────────┬─────────┬─────────────┬───────────┐ │ Name │ Type │ Cardinality │ Value │ ├────────────┼─────────┼─────────────┼───────────┤ │ name │ String │ [1 … 1] │ Paderborn │ │ population │ Integer │ [1 … 1] │ 143,174 │ │ twin town │ City │ [0 … ∞] │ Le Mans │ └────────────┴─────────┴─────────────┴───────────┘
Defined in the sis-feature
module
Format.Field
beforeFill, columnSeparator, fillCharacter, lineSeparator, omitTrailingNulls
Constructor and Description |
---|
FeatureFormat()
Creates a new formatter for the default locale and timezone.
|
FeatureFormat(Locale locale,
TimeZone timezone)
Creates a new formatter for the given locale and timezone.
|
Modifier and Type | Method and Description |
---|---|
void |
format(Object object,
Appendable toAppendTo)
Formats the given object to the given stream of buffer.
|
Class<Object> |
getValueType()
Returns the type of objects formatted by this class.
|
Object |
parse(CharSequence text,
ParsePosition pos)
Not yet supported.
|
getColumnSeparatorMatcher, getColumnSeparatorPattern, getLineSeparator, setColumnSeparatorPattern, setLineSeparator
clone, createFormat, format, getFormat, getLocale, getTimeZone, parseObject, parseObject
format, formatToCharacterIterator
public FeatureFormat()
public final Class<Object> getValueType()
Object.class
since it is the only common parent to Feature
and FeatureType
.getValueType
in class CompoundFormat<Object>
Object.class
public void format(Object object, Appendable toAppendTo) throws IOException
Feature
FeatureType
format
in class CompoundFormat<Object>
object
- The object to format.toAppendTo
- Where to format the object.IOException
- If an error occurred while writing to the given appendable.public Object parse(CharSequence text, ParsePosition pos) throws ParseException
parse
in class CompoundFormat<Object>
text
- The character sequence for the object to parse.pos
- The position where to start the parsing.ParseException
- Currently always thrown.Copyright © 2010–2015 The Apache Software Foundation. All rights reserved.