public class RecordArray extends RecordCollection
Parser
tree component for parsing an array of bean objects, where
a bean object is mapped to a Record
.
A RecordArray supports a single Record
child.
lazy, value
AGGREGATION_ARRAY, AGGREGATION_COLLECTION, AGGREGATION_MAP, COLLECTION, COMPLEX, MAP, SIMPLE
Constructor and Description |
---|
RecordArray()
Constructs a new RecordArray.
|
Modifier and Type | Method and Description |
---|---|
protected Collection<Object> |
createAggregationType() |
Class<?> |
getArrayType()
Returns the class type of the array.
|
Object |
getValue(ParsingContext context)
Returns the unmarshalled property value.
|
void |
setArrayType(Class<?> arrayType)
Sets the class type of the array (e.g.
|
void |
setValue(ParsingContext context,
Object value)
Sets the property value for marshaling.
|
int |
type()
Returns the property type.
|
getCollection, hasContent, marshal, unmarshal
clearValue, close, createValue, defines, getAccessor, getCount, getMaxOccurs, getMinOccurs, getNullValue, getOrder, getProperty, getSelector, getType, isIdentifier, isLazy, isMaxOccursReached, isRecordGroup, isSupportedChild, matchAny, matchNext, matchNext, registerLocals, reset, restoreState, setAccessor, setCount, setIdentifier, setLazy, setType, skip, toParamString, updateState
getParser, getSize, isOptional, matches
add, clone, find, getChildren, getFirst, getName, isDescendant, iterator, print, print, setName, size, sort, toString, updateReferences
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getName, getSize, isOptional, matches
forEach, spliterator
public int type()
Property
type
in interface Property
type
in class RecordCollection
Property.SIMPLE
, Property.COMPLEX
, Property.AGGREGATION_ARRAY
, Property.COLLECTION
,
Property.AGGREGATION_COLLECTION
, or Property.MAP
public Object getValue(ParsingContext context)
Parser
getValue
in interface Parser
getValue
in interface Property
getValue
in class RecordAggregation
context
- the ParsingContext
public void setValue(ParsingContext context, Object value)
Parser
setValue
in interface Parser
setValue
in interface Property
setValue
in class RecordCollection
context
- the ParsingContext
value
- the property valueprotected Collection<Object> createAggregationType()
createAggregationType
in class RecordAggregation
public Class<?> getArrayType()
public void setArrayType(Class<?> arrayType)
arrayType
- the array class type