Class NumericalField
-
- All Implemented Interfaces:
-
nl.basjes.modbus.schema.expression.Expression,nl.basjes.modbus.schema.expression.numbers.NumericalExpression
public final class NumericalField implements NumericalExpression
-
-
Field Summary
Fields Modifier and Type Field Description private final List<Expression>subExpressionsprivate final List<Address>requiredAddressesprivate final List<String>requiredFieldsprivate BooleanisImmutableprivate final ReturnTypereturnTypeprivate final List<Expression.Problem>problemsprivate final StringfieldNameprivate final List<Address>requiredMutableAddresses
-
Constructor Summary
Constructors Constructor Description NumericalField(String fieldName)
-
Method Summary
Modifier and Type Method Description List<Expression>getSubExpressions()List<Address>getRequiredAddresses()List<String>getRequiredFields()BooleanisImmutable()UnitsetImmutable(Boolean isImmutable)ReturnTypegetReturnType()List<Expression.Problem>getProblems()final StringgetFieldName()StringtoString()Booleaninitialize(Field containingField)Initialize the expression. NumericalExpression.ValueGuaranteegetGuarantee()DoublegetValueAsDouble(SchemaDevice schemaDevice)LonggetValueAsLong(SchemaDevice schemaDevice)-
-
Constructor Detail
-
NumericalField
NumericalField(String fieldName)
-
-
Method Detail
-
getSubExpressions
List<Expression> getSubExpressions()
-
getRequiredAddresses
List<Address> getRequiredAddresses()
-
getRequiredFields
List<String> getRequiredFields()
-
isImmutable
Boolean isImmutable()
-
setImmutable
Unit setImmutable(Boolean isImmutable)
-
getReturnType
ReturnType getReturnType()
-
getProblems
List<Expression.Problem> getProblems()
-
getFieldName
final String getFieldName()
-
initialize
Boolean initialize(Field containingField)
Initialize the expression.
- Parameters:
containingField- The field of which this expression is a part- Returns:
true if success, false means it must be retried.
-
getGuarantee
NumericalExpression.ValueGuarantee getGuarantee()
- Returns:
Can we guarantee anything about the return value?
-
getValueAsDouble
Double getValueAsDouble(SchemaDevice schemaDevice)
- Returns:
The Double value or null if it was not implemented
-
getValueAsLong
Long getValueAsLong(SchemaDevice schemaDevice)
- Returns:
The Long value or null if it was not implemented
-
-
-
-