public class ResourceGroup extends AbstractNamedAFPObject
AbstractAFPObject.Category, AbstractAFPObject.Type
name
triplets
log, SF_CLASS, SF_HEADER
Constructor and Description |
---|
ResourceGroup(java.lang.String name)
Constructor for the ResourceGroup, this takes a
name parameter which must be 8 characters long.
|
Modifier and Type | Method and Description |
---|---|
void |
addObject(AbstractNamedAFPObject namedObject)
Add this named object to this resource group
|
int |
getResourceCount()
Returns the number of resources contained in this resource group
|
boolean |
resourceExists(java.lang.String uri)
Returns true if the resource exists within this resource group,
false otherwise.
|
java.lang.String |
toString() |
void |
writeContent(java.io.OutputStream os)
Helper method to write the contents of the Object.
|
void |
writeEnd(java.io.OutputStream os)
Helper method to write the end of the Object.
|
void |
writeStart(java.io.OutputStream os)
Helper method to write the start of the Object.
|
copySF, getName, getNameBytes, getNameLength, setName
addTriplet, addTriplets, getFullyQualifiedName, getTripletDataLength, getTriplets, hasTriplet, hasTriplets, setComment, setFullyQualifiedName, setObjectClassification, writeTriplets
writeToStream
copyChunks, copySF, truncate, writeChunksToStream, writeObjects
public ResourceGroup(java.lang.String name)
name
- the resource group namepublic void addObject(AbstractNamedAFPObject namedObject) throws java.io.IOException
namedObject
- a named objectjava.io.IOException
- thrown if an I/O exception of some sort has occurred.public int getResourceCount()
public boolean resourceExists(java.lang.String uri)
uri
- the uri of the resourcepublic void writeStart(java.io.OutputStream os) throws java.io.IOException
writeStart
in class AbstractStructuredObject
os
- The stream to write tojava.io.IOException
- throws an I/O exception if one occurredpublic void writeContent(java.io.OutputStream os) throws java.io.IOException
writeContent
in class AbstractStructuredObject
os
- The stream to write tojava.io.IOException
- throws an I/O exception if one occurredpublic void writeEnd(java.io.OutputStream os) throws java.io.IOException
writeEnd
in class AbstractStructuredObject
os
- The stream to write tojava.io.IOException
- an I/O exception if one occurredpublic java.lang.String toString()
toString
in class AbstractNamedAFPObject
Copyright 1999-2010 The Apache Software Foundation. All Rights Reserved.