org.bee.processor
Class Task
java.lang.Object
org.xml.sax.helpers.DefaultHandler
org.bee.processor.AbstractValue
org.bee.processor.AbstractBlock
org.bee.processor.Function
org.bee.processor.Task
- All Implemented Interfaces:
- Instruction, org.xml.sax.ContentHandler, org.xml.sax.DTDHandler, org.xml.sax.EntityResolver, org.xml.sax.ErrorHandler
public class Task
- extends Function
Fields inherited from interface org.bee.processor.Instruction |
ATTR_CODE, ATTR_COMMENT, ATTR_DIR, ATTR_ERROUT, ATTR_ERROUT_STREAM, ATTR_EXEC, ATTR_IN, ATTR_NAME, ATTR_OPTIONS, ATTR_PATH, ATTR_PROCESSONLY, ATTR_PROPERTY, ATTR_SEPARATOR, ATTR_STDIN, ATTR_STDOUT, ATTR_STDOUT_STREAM, ATTR_TARGET, ATTR_TYPE, ATTR_URL, ATTR_VALUE, ATTR_VARIABLE, RESERVE_BUILD_FILE, RESERVE_CLASS_LIB, RESERVE_NAME_ARGS, RESERVE_NAME_DIR, RESERVE_NAME_ERROR, RESERVE_NAME_EXCEPTION, RESERVE_OPTION_NOINPUT, TYPE_BOOL, TYPE_DATE, TYPE_DIRECTORY, TYPE_FILE, TYPE_NUMBER, TYPE_URL, TYPE_VARIABLE |
Constructor Summary |
Task(java.lang.String xpath)
|
Method Summary |
void |
childDone(Instruction child)
Child notifies a parent that evaluation done, and a parent can use it
for own evaluation |
InfoHolder |
eval()
Returns value of instruction |
protected void |
fillParameters(java.util.List<java.lang.String> result,
java.util.Map<java.lang.String,java.lang.String> environment)
|
java.lang.String[] |
getAllowedAttributeNames()
Funtions used only for diagnostic purpose to check if
not allowed attribute for instruction used. |
protected java.lang.reflect.Method |
getMethod(java.lang.Class codeClass)
|
java.lang.String |
getName()
returns instruction name |
void |
startElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName,
org.xml.sax.Attributes attributes)
|
Methods inherited from class org.bee.processor.AbstractValue |
characters, endElement, getHandler, getParent, getPath, ignorableWhitespace, lookupInChain, lookupNameSpace, lookupOnTop, lookupStringValue, makeFile, setDocumentLocator, setParent, traceInChain, updateInNameSpace, verifyAttributes |
Methods inherited from class org.xml.sax.helpers.DefaultHandler |
endDocument, endPrefixMapping, error, fatalError, notationDecl, processingInstruction, resolveEntity, skippedEntity, startDocument, startPrefixMapping, unparsedEntityDecl, warning |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RESULT_CODE_VAR_NAME
public static final java.lang.String RESULT_CODE_VAR_NAME
- See Also:
- Constant Field Values
PATH
public static final java.lang.String PATH
- See Also:
- Constant Field Values
CLASSPATH
public static final java.lang.String CLASSPATH
- See Also:
- Constant Field Values
exec
protected java.lang.String exec
code
protected java.lang.String code
path
protected java.lang.String path
stdErrVar
protected java.lang.String stdErrVar
stdOutVar
protected java.lang.String stdOutVar
stdInVar
protected java.lang.String stdInVar
onExitHandler
protected OnExit onExitHandler
onExceptionHandler
protected OnException onExceptionHandler
Task
public Task(java.lang.String xpath)
childDone
public void childDone(Instruction child)
- Description copied from interface:
Instruction
- Child notifies a parent that evaluation done, and a parent can use it
for own evaluation
- Specified by:
childDone
in interface Instruction
- Overrides:
childDone
in class Function
eval
public InfoHolder eval()
- Description copied from interface:
Instruction
- Returns value of instruction
- Specified by:
eval
in interface Instruction
- Overrides:
eval
in class Function
- Returns:
InfoHolder
getName
public java.lang.String getName()
- Description copied from interface:
Instruction
- returns instruction name
- Specified by:
getName
in interface Instruction
- Overrides:
getName
in class AbstractBlock
- Returns:
- name
getMethod
protected java.lang.reflect.Method getMethod(java.lang.Class codeClass)
throws java.lang.NoSuchMethodException
- Throws:
java.lang.NoSuchMethodException
fillParameters
protected void fillParameters(java.util.List<java.lang.String> result,
java.util.Map<java.lang.String,java.lang.String> environment)
startElement
public void startElement(java.lang.String uri,
java.lang.String localName,
java.lang.String qName,
org.xml.sax.Attributes attributes)
throws org.xml.sax.SAXException
- Specified by:
startElement
in interface org.xml.sax.ContentHandler
- Overrides:
startElement
in class AbstractBlock
- Throws:
org.xml.sax.SAXException
getAllowedAttributeNames
public java.lang.String[] getAllowedAttributeNames()
- Description copied from interface:
Instruction
- Funtions used only for diagnostic purpose to check if
not allowed attribute for instruction used.
- Specified by:
getAllowedAttributeNames
in interface Instruction
- Overrides:
getAllowedAttributeNames
in class AbstractBlock
- Returns:
- String[] names of allowed attribute, can return null
if any attribute is allowed