Package org.apache.fop.afp.modca
Class AbstractDataObject
- java.lang.Object
-
- All Implemented Interfaces:
Completable
,Startable
,Streamable
- Direct Known Subclasses:
GraphicsObject
,ImageObject
,ObjectContainer
public abstract class AbstractDataObject extends AbstractNamedAFPObject implements Startable, Completable
Abstract base class used by the ImageObject and GraphicsObject which both have define an ObjectEnvironmentGroup
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.fop.afp.modca.AbstractAFPObject
AbstractAFPObject.Category, AbstractAFPObject.Type
-
-
Field Summary
Fields Modifier and Type Field Description protected Factory
factory
the object factoryprotected ObjectEnvironmentGroup
objectEnvironmentGroup
the object environment group-
Fields inherited from class org.apache.fop.afp.modca.AbstractNamedAFPObject
name
-
Fields inherited from class org.apache.fop.afp.modca.AbstractTripletStructuredObject
triplets
-
Fields inherited from class org.apache.fop.afp.modca.AbstractAFPObject
LOG, SF_CLASS, SF_HEADER_LENGTH
-
-
Constructor Summary
Constructors Constructor Description AbstractDataObject(Factory factory, java.lang.String name)
Named constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ObjectEnvironmentGroup
getObjectEnvironmentGroup()
Gets the ObjectEnvironmentGroupboolean
isComplete()
Returns true if this object is completeboolean
isStarted()
Returns true if this object has startedvoid
setComplete(boolean complete)
Sets whether or not this object is complete or notvoid
setStarted(boolean started)
Sets whether or not this object has started or notvoid
setViewport(AFPDataObjectInfo dataObjectInfo)
Sets the object view port (area position and size).protected void
writeContent(java.io.OutputStream os)
Helper method to write the contents of the Object.protected void
writeStart(java.io.OutputStream os)
Helper method to write the start of the Object.-
Methods inherited from class org.apache.fop.afp.modca.AbstractNamedAFPObject
copySF, getName, getNameBytes, getNameLength, setName, toString
-
Methods inherited from class org.apache.fop.afp.modca.AbstractTripletStructuredObject
addTriplet, addTriplets, getFullyQualifiedName, getTripletDataLength, getTriplets, hasTriplet, hasTriplets, setComment, setFullyQualifiedName, setFullyQualifiedName, setObjectClassification, writeTriplets
-
Methods inherited from class org.apache.fop.afp.modca.AbstractStructuredObject
writeEnd, writeToStream
-
Methods inherited from class org.apache.fop.afp.modca.AbstractAFPObject
copySF, truncate, writeChunksToStream, writeObjects
-
-
-
-
Field Detail
-
objectEnvironmentGroup
protected ObjectEnvironmentGroup objectEnvironmentGroup
the object environment group
-
factory
protected final Factory factory
the object factory
-
-
Constructor Detail
-
AbstractDataObject
public AbstractDataObject(Factory factory, java.lang.String name)
Named constructor- Parameters:
factory
- the object factoryname
- data object name
-
-
Method Detail
-
setViewport
public void setViewport(AFPDataObjectInfo dataObjectInfo)
Sets the object view port (area position and size).- Parameters:
dataObjectInfo
- the object area info
-
getObjectEnvironmentGroup
public ObjectEnvironmentGroup getObjectEnvironmentGroup()
Gets the ObjectEnvironmentGroup- Returns:
- the object environment group
-
writeStart
protected void writeStart(java.io.OutputStream os) throws java.io.IOException
Helper method to write the start of the Object.- Overrides:
writeStart
in classAbstractStructuredObject
- Parameters:
os
- The stream to write to- Throws:
java.io.IOException
- throws an I/O exception if one occurred
-
writeContent
protected void writeContent(java.io.OutputStream os) throws java.io.IOException
Helper method to write the contents of the Object.- Overrides:
writeContent
in classAbstractStructuredObject
- Parameters:
os
- The stream to write to- Throws:
java.io.IOException
- throws an I/O exception if one occurred
-
setStarted
public void setStarted(boolean started)
Sets whether or not this object has started or not- Specified by:
setStarted
in interfaceStartable
- Parameters:
started
- true if this object has started
-
isStarted
public boolean isStarted()
Returns true if this object has started
-
setComplete
public void setComplete(boolean complete)
Sets whether or not this object is complete or not- Specified by:
setComplete
in interfaceCompletable
- Parameters:
complete
- true if this object is complete
-
isComplete
public boolean isComplete()
Returns true if this object is complete- Specified by:
isComplete
in interfaceCompletable
- Returns:
- true if this object is complete
-
-