public abstract class DfsBaseConditional extends DfsTask implements org.apache.tools.ant.taskdefs.condition.Condition
DfsTask
implements the
Ant >1.5
Condition
interface for HDFS tests. So one can test conditions like this:
<condition property="precond">
<and>
<hadoop:exists file="fileA" />
<hadoop:exists file="fileB" />
<hadoop:sizezero file="fileB" />
</and>
</condition>
This will define the property precond if fileA exists and fileB has zero
length.Modifier and Type | Field and Description |
---|---|
protected boolean |
result |
argv, cmd, confloader, err, errprop, failonerror, out, outprop
Constructor and Description |
---|
DfsBaseConditional() |
Modifier and Type | Method and Description |
---|---|
boolean |
eval() |
protected abstract char |
getFlag() |
protected int |
postCmd(int exit_code) |
void |
setFile(String file) |
execute, popContext, pushContext, setArgs, setCmd, setConf, setErr, setFailonerror, setOut
bindToOwner, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, log, log, maybeConfigure, perform, reconfigure, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
Copyright © 2018 Apache Software Foundation. All Rights Reserved.