public interface DataType
Data types are used to extend text-based Content Fragments with structured, typed data. Fragments with structured data are called Structured Content Fragments.
In general, the set of available data types is implementation-specific, but there's a minimum of data types an implementation must provide. An implementation can provide additional data types on top of these required types.
Required types:
BooleanLongDoubleStringCalendarThe defining type strings (@see getTypeString()} for the required types
are defined by BasicDataType.
Additionally, arrays (or collections) of data types need to be supported.
As the type system is pretty generic, values of a given type - represented by an
Object wrapped by FragmentData - need to be convertible to the needs
of the client. Therefore each implementation needs to be able to convert each provided
datatype to a String the least (see FragmentData.getValue(Class)).
For the conversion to a String the following rules need to be followed:
Xxxx.toString()/Xxx.parseXxx rather than NumberFormat
Calendar must be based on ISO-8601.
Additional conversions may be supported (Double from/to Long), but are
not guaranteed.
| Modifier and Type | Method and Description |
|---|---|
String |
getTypeString()
Gets the string representation of the data type.
|
boolean |
isMultiValue()
Determines if the data type represents a collection (or array) of values.
|
@Nonnull String getTypeString()
The string representation must be unique and is used to identify the type (and some releated data like mappings, etc.) within the repository.
boolean isMultiValue()
true if the data type represents a collection of values;
false if the data type represents a single valueCopyright © 2006-2017 Adobe Systems Incorporated. All Rights Reserved.