Package net.sf.basedb.util.listable
Class AbstractSourceItemTransformerFactory
- java.lang.Object
-
- net.sf.basedb.util.listable.AbstractSourceItemTransformerFactory
-
- All Implemented Interfaces:
SourceItemTransformerFactory
- Direct Known Subclasses:
ToBioSourceSourceItemTransformerFactory
,ToDerivedBioAssaySourceItemTransformerFactory
,ToExtractSourceItemTransformerFactory
,ToPhysicalBioAssaySourceItemTransformerFactory
,ToRawBioAssaySourceItemTransformerFactory
,ToSampleSourceItemTransformerFactory
public abstract class AbstractSourceItemTransformerFactory extends Object implements SourceItemTransformerFactory
Abstract base class for source item transformer factories that can be useful for implementing some common functionality.- Since:
- 3.5
- Author:
- Nicklas
-
-
Field Summary
Fields Modifier and Type Field Description private List<Item>
childToParent
private List<Item>
parentToChild
private Item
target
-
Constructor Summary
Constructors Modifier Constructor Description protected
AbstractSourceItemTransformerFactory(Item target, Item[] parentToChild, Item[] childToParent)
Create a new instance supports transformation between the given source items and target item.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<Item>
getSupportedSourceItems(SyncFilter.SourceItemTransform transform)
Get the supported source item types when transforming in the specified direction.Item
getTargetItem()
Get the target item type of this transformer factory.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.sf.basedb.util.listable.SourceItemTransformerFactory
create
-
-
-
-
Constructor Detail
-
AbstractSourceItemTransformerFactory
protected AbstractSourceItemTransformerFactory(Item target, Item[] parentToChild, Item[] childToParent)
Create a new instance supports transformation between the given source items and target item.- Parameters:
target
- The supported target item typeparentToChild
- The supported source item types forSyncFilter.SourceItemTransform.PARENT_TO_CHILD
transformchildToParent
- The supported source item types forSyncFilter.SourceItemTransform.CHILD_TO_PARENT
transform
-
-
Method Detail
-
getTargetItem
public Item getTargetItem()
Description copied from interface:SourceItemTransformerFactory
Get the target item type of this transformer factory. All transformers created by this factory are expected to have a matchingSourceItemTransformer.getTargetItemType()
.- Specified by:
getTargetItem
in interfaceSourceItemTransformerFactory
-
getSupportedSourceItems
public List<Item> getSupportedSourceItems(SyncFilter.SourceItemTransform transform)
Description copied from interface:SourceItemTransformerFactory
Get the supported source item types when transforming in the specified direction. TheSourceItemTransformerFactory.create(Item, SyncFilter.SourceItemTransform)
method should be able to create aSourceItemTransformer
for all of the item types returned by this method.- Specified by:
getSupportedSourceItems
in interfaceSourceItemTransformerFactory
-
-