org.x4juli.handlers.rolling.helper
Class CompositeAction
java.lang.Object
org.x4juli.global.components.AbstractComponent
org.x4juli.handlers.rolling.helper.AbstractAction
org.x4juli.handlers.rolling.helper.CompositeAction
- All Implemented Interfaces:
- Action, Component, java.lang.Runnable
- public class CompositeAction
- extends AbstractAction
A group of Actions to be executed in sequence.
Logging API as a whole was originally done for Apache log4j. Juli is a
port of main parts of that to complete the Java Logging
APIs. All credits for initial idea, design, implementation,
documentation belong to the log4j crew. This
file was originally published by Curt Arnold. Please use exclusively
the appropriate mailing lists for questions, remarks and
contribution.
- Since:
- 0.5
- Author:
- Boris Unckel
| Fields inherited from class org.x4juli.handlers.rolling.helper.AbstractAction |
|
|
Constructor Summary |
CompositeAction(java.util.List actions,
boolean stopOnError)
Construct a new composite action. |
|
Method Summary |
boolean |
execute()
Perform action. |
void |
run()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
actions
private final Action[] actions
- Actions to perform.
stopOnError
private final boolean stopOnError
- Stop on error.
CompositeAction
public CompositeAction(java.util.List actions,
boolean stopOnError)
- Construct a new composite action.
- Parameters:
actions - list of actions, may not be null.stopOnError - if true, stop on the first false return value or exception.
run
public void run()
-
- Specified by:
run in interface java.lang.Runnable- Overrides:
run in class AbstractAction
execute
public boolean execute()
throws java.io.IOException
- Perform action.
- Specified by:
execute in interface Action- Specified by:
execute in class AbstractAction
- Returns:
- true if successful.
- Throws:
java.io.IOException - if IO error.
${license_html}