java.lang.Object
org.yamcs.mdb.ProcessingData
org.yamcs.mdb.TcProcessingContext
Keeps track of where we are when filling in the bits and bytes of a command
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsFields inherited from class org.yamcs.mdb.ProcessingData
cmdArgs, cmdParams, cmdParamsCache, tmParams, tmParamsCache -
Constructor Summary
ConstructorsConstructorDescriptionTcProcessingContext(org.yamcs.xtce.MetaCommand metaCmd, ProcessorData pdata, Map<org.yamcs.xtce.Parameter, Value> paramValues, BitBuffer bitbuf, int bitPosition) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddArgumentValue(org.yamcs.xtce.Argument a, Value argValue) getAggregateReference(String argName) Lookup the argument by name in the stack of aggregatesorg.yamcs.xtce.ArgumentgetArgument(String argName) getArgumentValue(String argName) Look up an argument by name only, for cases in which we do not have the full argument definition, such as arguments used for defining the length of other variable-length arguments.Map<org.yamcs.xtce.Argument,ArgumentValue> org.yamcs.xtce.MetaCommandreturns the size in bytes of the encoded commandgetRawParameterValue(org.yamcs.xtce.Parameter param) intgetSize()booleanhasArgumentValue(org.yamcs.xtce.Argument a) Pops the current aggregate from the stack and returns it.voidpushCurrentAggregate(TcProcessingContext.AggregateWithValue newAggregate) Pushes a new current aggregate onto the stack.voidsetSize(int size) sets the size in bytes of the encoded commandMethods inherited from class org.yamcs.mdb.ProcessingData
addCmdParam, addTmParam, addTmParams, cloneForCommanding, cloneForTm, containsUpdate, createForCmdProcessing, createForTestCmd, createForTestTm, createForTmProcessing, createInitial, getCmdArgs, getCmdArgument, getCmdParams, getParameterInstance, getTmParams, resolveDynamicIntegerValue, toString
-
Field Details
-
generationTime
public long generationTime
-
-
Constructor Details
-
TcProcessingContext
public TcProcessingContext(org.yamcs.xtce.MetaCommand metaCmd, ProcessorData pdata, Map<org.yamcs.xtce.Parameter, Value> paramValues, BitBuffer bitbuf, int bitPosition)
-
-
Method Details
-
getArgumentValue
Look up an argument by name only, for cases in which we do not have the full argument definition, such as arguments used for defining the length of other variable-length arguments.- Parameters:
argName- the name of the argument- Returns:
- the argument value, if found, or null
-
getAggregateReference
Lookup the argument by name in the stack of aggregatesThe returned AggregateWithValue may not have the value set
- Parameters:
argName- the name of the aggregate member to look up- Returns:
- the argument value, if found, or null
-
getRawParameterValue
-
getArgValues
-
hasArgumentValue
public boolean hasArgumentValue(org.yamcs.xtce.Argument a) -
pushCurrentAggregate
Pushes a new current aggregate onto the stack.- Parameters:
newAggregate- the aggregate to push
-
popCurrentAggregate
Pops the current aggregate from the stack and returns it.- Returns:
- the previous current aggregate, or null if the stack is empty
-
addArgumentValue
-
getArgument
-
getSize
public int getSize() -
setSize
public void setSize(int size) sets the size in bytes of the encoded command -
getCommand
public org.yamcs.xtce.MetaCommand getCommand()returns the size in bytes of the encoded command
-