org.apache.cocoon
Interface Processor

All Known Subinterfaces:
Block
All Known Implementing Classes:
BlockManager, BlockProcessor, Cocoon, ConcreteTreeProcessor, TreeProcessor

public interface Processor

Version:
CVS $Id: Processor.java 209567 2005-07-07 06:18:44Z cziegeler $
Author:
Pierpaolo Fumagalli (Apache Software Foundation), Carsten Ziegeler

Nested Class Summary
static class Processor.InternalPipelineDescription
           
 
Field Summary
static String ROLE
          The role of the root processor
 
Method Summary
 Processor.InternalPipelineDescription buildPipeline(Environment environment)
          Process the given Environment to assemble a ProcessingPipeline.
 Object getAttribute(String name)
          Gets an attribute
 Configuration[] getComponentConfigurations()
          Get the sitemap component configurations
 String getContext()
          Get the context URI for this processor
 Processor getRootProcessor()
          Get the root processor parent of this processor.
 SourceResolver getSourceResolver()
          Get the source resolver for this processor
 boolean process(Environment environment)
          Process the given Environment producing the output.
 Object removeAttribute(String name)
          Remove an attribute.
 void setAttribute(String name, Object value)
          Sets an attribute
 

Field Detail

ROLE

public static final String ROLE
The role of the root processor

Method Detail

process

public boolean process(Environment environment)
                throws Exception
Process the given Environment producing the output.

Returns:
If the processing is successfull true is returned. If no match is found in the sitemap false is returned.
Throws:
ResourceNotFoundException - If a sitemap component tries to access a resource which can not be found, e.g. the generator ConnectionResetException If the connection was reset
Exception

buildPipeline

public Processor.InternalPipelineDescription buildPipeline(Environment environment)
                                                    throws Exception
Process the given Environment to assemble a ProcessingPipeline. Don't forget to release the pipeline using Processor.InternalPipelineDescription.release().

Throws:
Exception
Since:
2.2

getComponentConfigurations

public Configuration[] getComponentConfigurations()
Get the sitemap component configurations

Since:
2.2

getRootProcessor

public Processor getRootProcessor()
Get the root processor parent of this processor.

Since:
2.1.1

getSourceResolver

public SourceResolver getSourceResolver()
Get the source resolver for this processor

Since:
2.2

getContext

public String getContext()
Get the context URI for this processor

Since:
2.2

setAttribute

public void setAttribute(String name,
                         Object value)
Sets an attribute

Since:
2.2

getAttribute

public Object getAttribute(String name)
Gets an attribute

Since:
2.2

removeAttribute

public Object removeAttribute(String name)
Remove an attribute.

Since:
2.2


Copyright ? 1999-2005 The Apache Software Foundation. All Rights Reserved.