org.openfast.template.operator
Class CopyOperatorCodec
java.lang.Object
org.openfast.template.operator.OperatorCodec
org.openfast.template.operator.OptionallyPresentOperatorCodec
org.openfast.template.operator.CopyOperatorCodec
- All Implemented Interfaces:
- java.io.Serializable
public class CopyOperatorCodec
- extends OptionallyPresentOperatorCodec
- See Also:
- Serialized Form
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
CopyOperatorCodec
protected CopyOperatorCodec()
getValueToEncode
protected ScalarValue getValueToEncode(ScalarValue value,
ScalarValue priorValue,
ScalarValue defaultValue)
- Determine which values to encode from the passed ScalarValue objects
- Specified by:
getValueToEncode in class OptionallyPresentOperatorCodec
- Parameters:
value - The ScalarValue object to be encodedpriorValue - The priorValue object to be encodeddefaultValue - The defaultValue object to be encoded
- Returns:
- Returns null if the priorValue is undefined and if the
ScalarValue object equals the defaultValue object or priorValue
object, otherwise returns the ScalarValue object
getInitialValue
protected ScalarValue getInitialValue(Scalar field)
- Get the initial value of the passed Scalar object as long as the object
is defined
- Specified by:
getInitialValue in class OptionallyPresentOperatorCodec
- Parameters:
field - The Scalar object that the initial value is trying to return
- Returns:
- Returns the default value of the passed Scalar object if the
object is defined, otherwise returns null
getEmptyValue
protected ScalarValue getEmptyValue(ScalarValue priorValue)
- Specified by:
getEmptyValue in class OptionallyPresentOperatorCodec
- Returns:
- Returns the variable priorValue
decodeValue
public ScalarValue decodeValue(ScalarValue newValue,
ScalarValue priorValue,
Scalar field)
- Specified by:
decodeValue in class OperatorCodec
- Returns:
- newValue
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals in class OperatorCodec
Copyright © 2006-2008 The LaSalle Technology Group, LLC. All Rights Reserved.