|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Pipeline
The idea of a pipeline is being taken from Catalina in its entirety :-) I would like to take the idea further and implement Valves instead of hardcoding particular methods in a pipeline. It would be more flexible to specify Valves for a pipeline in an XML file (we can also rip off the digester rules from T4) and have invoke() as part of the interface. So a set of Valves would be added to the pipeline and the pipeline would 'invoke' each valve. In the case Turbine each Valve would produce some output to be sent out the pipe. I think with another days work this can be fully working. The first pipeline to be fully implemented will the ClassicPipeline will emulate the Turbine 2.1 way of doing things.
Method Summary | |
---|---|
void |
addValve(Valve valve)
Add a new Valve to the end of the pipeline. |
Valve[] |
getValves()
Return the set of all Valves in the pipeline. |
void |
initialize()
Initializes this instance. |
void |
invoke(PipelineData data)
Cause the specified request and response to be processed by the sequence of Valves associated with this pipeline, until one of these Valves decides to end the processing. |
void |
removeValve(Valve valve)
Remove the specified Valve from the pipeline, if it is found; otherwise, do nothing. |
Method Detail |
---|
void initialize() throws Exception
Exception
void addValve(Valve valve)
Add a new Valve to the end of the pipeline.
valve
- Valve to be added.
IllegalStateException
- If the pipeline has not been
initialized.Valve[] getValves()
void invoke(PipelineData data) throws TurbineException, IOException
Cause the specified request and response to be processed by the sequence of Valves associated with this pipeline, until one of these Valves decides to end the processing.
The implementation must ensure that multiple simultaneous requests (on different threads) can be processed through the same Pipeline without interfering with each other's control flow.
data
- The run-time information, including the servlet
request and response we are processing.
IOException
- an input/output error occurred.
TurbineException
void removeValve(Valve valve)
valve
- Valve to be removed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |