|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.shibboleth.metadata.pipeline.AbstractComponent
net.shibboleth.metadata.pipeline.BaseStage<ItemType>
net.shibboleth.metadata.pipeline.SerializationStage<ItemType>
ItemType - type of items upon which this stage operatespublic class SerializationStage<ItemType extends Item<?>>
A stage which writes the given item collection out to a file.
This stage requires the following properties be set prior to initialization:
outputFileserializer
| Field Summary | |
|---|---|
private File |
outputFile
File to which the item will be written. |
private boolean |
overwritingExistingOutputFile
Whether an existing output file should be overwritten. |
private ItemSerializer<ItemType> |
serializer
Serializer used to write the item to the output stream. |
| Constructor Summary | |
|---|---|
SerializationStage()
|
|
| Method Summary | |
|---|---|
protected void |
doExecute(Collection<ItemType> itemCollection)
Performs the stage processing on the given Item collection. |
protected void |
doInitialize()
Do the initialization of the component. |
File |
getOutputFile()
Gets the file to which the item will be written. |
ItemSerializer<ItemType> |
getSerializer()
Gets the serializer used to write item to the output file. |
boolean |
isOverwritingExistingOutputFile()
Gets whether an existing output file should be overwritten. |
void |
setOutputFile(File file)
Sets the file to which the item will be written. |
void |
setOverwritingExistingOutputFile(boolean isOverwriting)
Sets whether an existing output file should be overwritten. |
void |
setSerializer(ItemSerializer<ItemType> itemSerializer)
Sets the serializer used to write item to the output file. |
| Methods inherited from class net.shibboleth.metadata.pipeline.BaseStage |
|---|
execute |
| Methods inherited from class net.shibboleth.metadata.pipeline.AbstractComponent |
|---|
equals, getId, getInitializationInstant, hashCode, initialize, isInitialized, setId |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.shibboleth.metadata.pipeline.Component |
|---|
getId, getInitializationInstant, initialize, isInitialized |
| Field Detail |
|---|
private File outputFile
private boolean overwritingExistingOutputFile
true
private ItemSerializer<ItemType extends Item<?>> serializer
| Constructor Detail |
|---|
public SerializationStage()
| Method Detail |
|---|
public File getOutputFile()
public void setOutputFile(File file)
file - file to which the item will be writtenpublic boolean isOverwritingExistingOutputFile()
public void setOverwritingExistingOutputFile(boolean isOverwriting)
isOverwriting - whether an existing output file should be overwrittenpublic ItemSerializer<ItemType> getSerializer()
public void setSerializer(ItemSerializer<ItemType> itemSerializer)
itemSerializer - serializer used to write item to the output file
protected void doExecute(Collection<ItemType> itemCollection)
throws StageProcessingException
doExecute in class BaseStage<ItemType extends Item<?>>itemCollection - collection to be processed
StageProcessingException - thrown if there is an unrecoverable problem when processing the stage
protected void doInitialize()
throws ComponentInitializationException
doInitialize in class AbstractComponentComponentInitializationException - throw if there is a problem initializing the component
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||