public abstract class AbstractEntityToTupleTransformer<ENTITY,TUPLE> extends AbstractEntityTransformer<ENTITY,Object,TUPLE>
Must call init if not used via Spring
,
Serialized FormProcess.Event, Process.EventPoint
columnFieldMapping, idempotent, mode, modesSupported, nestedObjectInitMap, nonAssociatedMappers
listeners, processState
Constructor and Description |
---|
AbstractEntityToTupleTransformer() |
AbstractEntityToTupleTransformer(AbstractEntityToTupleTransformer t) |
Modifier and Type | Method and Description |
---|---|
List<String> |
getColumnNames()
Useful function to derive All Columns in the report
|
protected String |
identifyNode(Object node)
Identify a node/cell that is being processed.
|
protected abstract TUPLE |
init(ENTITY rawInput,
Map<String,Object> intermediateObjects)
Create the core Entity and also initialize intermediateObjects (nested objects) with core entities
|
protected abstract void |
setEntity(TUPLE tuple,
Mapper mapper,
Object value)
Reverse of SetEntity actually, setting the value to a given position in the Tuple for
Mapper.getFieldName() != null (I.e concrete Output fields) |
Object |
transform(Object input)
Work Horse method that does all the conversion using
Mapper s. |
consumeIntermediateObjects, getColumnFieldMapping, getEntityAccessTransformer, getMode, getModesSupported, getNestedObjectInitMap, getNonAssiciatedMappers, getNonAssociatedMappers, getValue, init, isIdempotent, nestedInit, processValue, setColumnFieldMapping, setEntityAccessTransformer, setIdempotent, setMode, setModesSupported, setNestedObjectInitMap, setNonAssociatedMappers
addListener, getListeners, onChangeHandler, setListeners
public AbstractEntityToTupleTransformer()
public AbstractEntityToTupleTransformer(AbstractEntityToTupleTransformer t)
protected String identifyNode(Object node)
AbstractEntityTransformer
identifyNode
in class AbstractEntityTransformer<ENTITY,Object,TUPLE>
public List<String> getColumnNames()
protected abstract TUPLE init(ENTITY rawInput, Map<String,Object> intermediateObjects)
init
in class AbstractEntityTransformer<ENTITY,Object,TUPLE>
intermediateObjects
- the Map into which we can pre-initialize stuffprotected abstract void setEntity(TUPLE tuple, Mapper mapper, Object value) throws Exception
Mapper.getFieldName()
!= null (I.e concrete Output fields)setEntity
in class AbstractEntityTransformer<ENTITY,Object,TUPLE>
mapper
- as Mapper
for MapperBehavior
s and Mapper.getFieldName()
Exception
- TODO: Add unit test case, for an Entity with Integer field type but passing Double field valueCopyright © 2018. All rights reserved.