org.apache.fop.afp.modca

## Class AbstractResourceEnvironmentGroupContainer

- java.lang.Object
- - org.apache.fop.afp.modca.AbstractAFPObject
  - - org.apache.fop.afp.modca.AbstractStructuredObject
    - - org.apache.fop.afp.modca.AbstractTripletStructuredObject
      - - org.apache.fop.afp.modca.AbstractNamedAFPObject
        - - org.apache.fop.afp.modca.AbstractPageObject
          - - org.apache.fop.afp.modca.AbstractResourceGroupContainer
            - - org.apache.fop.afp.modca.AbstractResourceEnvironmentGroupContainer

All Implemented Interfaces:
  Completable, Streamable

Direct Known Subclasses:
  Document, PageGroup

    public abstract class AbstractResourceEnvironmentGroupContainer
    extends AbstractResourceGroupContainer

An abstract class which encapsulates the common features of Document and PageGroup resource containers

### Nested Class Summary

### Nested classes/interfaces inherited from class org.apache.fop.afp.modca.AbstractAFPObject

`AbstractAFPObject.Category, AbstractAFPObject.Type`

### Field Summary

Fields
`protected ResourceEnvironmentGroup` `resourceEnvironmentGroup` The resource environment group used to store complex resources

### Fields inherited from class org.apache.fop.afp.modca.AbstractResourceGroupContainer

`resourceGroup, started`

### Fields inherited from class org.apache.fop.afp.modca.AbstractPageObject

`activeEnvironmentGroup, complete, factory, invokeMediumMaps, objects, rotation`

### 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 and Description
`AbstractResourceEnvironmentGroupContainer(Factory factory, String name)` Main constructor

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `addPage(PageObject page)` Adds a page to the resource container.
`void` `addPageGroup(PageGroup pageGroup)` Adds a PageGroup to the resource container.
`void` `createInvokeMediumMap(String name)` Creates an InvokeMediaMap on the page.
`protected ResourceEnvironmentGroup` `getResourceEnvironmentGroup()` Returns the resource environment group
`protected void` `writeContent(OutputStream os)` Helper method to write the contents of the Object.

### Methods inherited from class org.apache.fop.afp.modca.AbstractResourceGroupContainer

`canWrite, getResourceCount, getResourceGroup, hasResources, writeObjects, writeObjects, writeToStream`

### Methods inherited from class org.apache.fop.afp.modca.AbstractPageObject

`addObject, createFont, createIncludePageSegment, createLine, createNoOperation, createTagLogicalElement, createText, endPage, endPresentationObject, getActiveEnvironmentGroup, getHeight, getPresentationTextObject, getRotation, getTagLogicalElements, getWidth, isComplete, setComplete`

### 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, writeStart`

### Methods inherited from class org.apache.fop.afp.modca.AbstractAFPObject

`copySF, truncate, writeChunksToStream`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Field Detail

#### resourceEnvironmentGroup

    protected ResourceEnvironmentGroup resourceEnvironmentGroup

The resource environment group used to store complex resources

### Constructor Detail

#### AbstractResourceEnvironmentGroupContainer

    public AbstractResourceEnvironmentGroupContainer(Factory factory,
                                                     String name)

Main constructor

Parameters:
  `factory` - the object factory
  `name` - the name of this resource container

### Method Detail

#### addPage

    public void addPage(PageObject page)

Adds a page to the resource container.

Parameters:
  `page` - - the Page object

#### addPageGroup

    public void addPageGroup(PageGroup pageGroup)

Adds a PageGroup to the resource container.

Parameters:
  `pageGroup` - the PageGroup object

#### createInvokeMediumMap

    public void createInvokeMediumMap(String name)

Creates an InvokeMediaMap on the page.

Overrides:
  `createInvokeMediumMap` in class `AbstractPageObject`
Parameters:
  `name` - the name of the media map

#### writeContent

    protected void writeContent(OutputStream os)
                         throws IOException

Helper method to write the contents of the Object.

Overrides:
  `writeContent` in class `AbstractPageObject`
Parameters:
  `os` - The stream to write to
Throws:
  `IOException` - throws an I/O exception if one occurred

#### getResourceEnvironmentGroup

    protected ResourceEnvironmentGroup getResourceEnvironmentGroup()

Returns the resource environment group

Returns:
  the resource environment group