public class OBasicCommandContext extends Object implements OCommandContext
OCommandContext.TIMEOUT_STRATEGY
Modifier and Type | Field and Description |
---|---|
protected Object[] |
args |
protected OCommandContext |
child |
protected ODatabase |
database |
protected Set<String> |
declaredScriptVariables |
static String |
EXECUTION_BEGUN |
protected Map<Object,Object> |
inputParameters |
static String |
INVALID_COMPARE_COUNT |
protected OCommandContext |
parent |
protected boolean |
recordMetrics |
protected AtomicLong |
resultsProcessed |
static String |
TIMEOUT_MS |
static String |
TIMEOUT_STRATEGY |
protected Set<Object> |
uniqueResult |
protected Map<String,Object> |
variables |
Constructor and Description |
---|
OBasicCommandContext() |
public static final String EXECUTION_BEGUN
public static final String TIMEOUT_MS
public static final String TIMEOUT_STRATEGY
public static final String INVALID_COMPARE_COUNT
protected ODatabase database
protected Object[] args
protected boolean recordMetrics
protected OCommandContext parent
protected OCommandContext child
protected AtomicLong resultsProcessed
public Object getVariable(String iName)
getVariable
in interface OCommandContext
public Object getVariable(String iName, Object iDefault)
getVariable
in interface OCommandContext
public OCommandContext setVariable(String iName, Object iValue)
setVariable
in interface OCommandContext
public OCommandContext incrementVariable(String iName)
incrementVariable
in interface OCommandContext
public long updateMetric(String iName, long iValue)
OCommandContext
updateMetric
in interface OCommandContext
iName
- Metric's nameiValue
- delta to add or subtractpublic Map<String,Object> getVariables()
getVariables
in interface OCommandContext
public OCommandContext setChild(OCommandContext iContext)
setChild
in interface OCommandContext
public OCommandContext getParent()
getParent
in interface OCommandContext
public OCommandContext setParent(OCommandContext iParentContext)
setParent
in interface OCommandContext
public OCommandContext setParentWithoutOverridingChild(OCommandContext iParentContext)
public boolean isRecordingMetrics()
isRecordingMetrics
in interface OCommandContext
public OCommandContext setRecordingMetrics(boolean recordMetrics)
setRecordingMetrics
in interface OCommandContext
public void beginExecution(long iTimeout, OCommandContext.TIMEOUT_STRATEGY iStrategy)
beginExecution
in interface OCommandContext
public boolean checkTimeout()
OCommandContext
checkTimeout
in interface OCommandContext
public OCommandContext copy()
OCommandContext
copy
in interface OCommandContext
public void merge(OCommandContext iContext)
OCommandContext
merge
in interface OCommandContext
public Map<Object,Object> getInputParameters()
getInputParameters
in interface OCommandContext
public void setInputParameters(Map<Object,Object> inputParameters)
setInputParameters
in interface OCommandContext
public AtomicLong getResultsProcessed()
public boolean addToUniqueResult(Object o)
o
- the result item to addpublic ODatabase getDatabase()
getDatabase
in interface OCommandContext
public void setDatabase(ODatabase database)
public void declareScriptVariable(String varName)
declareScriptVariable
in interface OCommandContext
public boolean isScriptVariableDeclared(String varName)
isScriptVariableDeclared
in interface OCommandContext
Copyright © 2009–2020 OrientDB. All rights reserved.