LWordAssertions
Short summary
This class provides assert statements for long words
| Access | Abstract | Final | Extends | Implements |
|---|---|---|---|---|
| INTERNAL | No | No | AbstractAssertion | ILWordAssertions |
UML Diagram
Parameters
none
Properties
className
Type: CNM_AbstractObject.ClassName
This abstract property returns the class name of the concrete object, …
Methods
andMaskIsEqualTo
- Parameters:
currentValue(LWORD): current value to checkmask(LWORD): 2nd operand for bitwise operationexpectedValue(LWORD): expected result after maskingmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the result current value bitwise AND mask is equal to the expected value…
andMaskIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checkmask(LWORD): 2nd operand for bitwise operationunexpectedValue(LWORD): unexpected result after maskingmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the result current value bitwise AND mask…
bitXIsEqualTo
- Parameters:
currentValue(LWORD): current value to checknumber(BitNumberLWord): number of bit to checkexpectedValue(BOOL): expected value of bitmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the selected bit of current value…
bitXIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checknumber(BitNumberLWord): number of bit to checkunexpectedValue(BOOL): unexpected value of bitmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the selected bit of current value…
bitXIsSet
- Parameters:
currentValue(LWORD): current value to checknumber(BitNumberLWord): number of bit to checkmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the selected bit of current value…
bitXIsUnset
- Parameters:
currentValue(LWORD): current value to checknumber(BitNumberLWord): number of bit to checkmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the selected bit of current value…
lsbIsEqualTo
- Parameters:
currentValue(LWORD): current value to checkexpectedValue(BOOL): expected value of lsbmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the least significant bit of current value…
lsbIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checkunexpectedValue(BOOL): unexpected value of lsbmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the least significant bit of current value…
lsbIsSet
- Parameters:
currentValue(LWORD): current value to checkmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the least significant bit of current value…
lsbIsUnset
- Parameters:
currentValue(LWORD): current value to checkmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the least significant bit of current value…
msbIsEqualTo
- Parameters:
currentValue(LWORD): current value to checkexpectedValue(BOOL): expected value of msbmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the most significant bit of current value…
msbIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checkunexpectedValue(BOOL): unexpected value of msbmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the most significant bit of current value…
msbIsSet
- Parameters:
currentValue(LWORD): current value to checkmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the most significant bit of current value…
msbIsUnset
- Parameters:
currentValue(LWORD): current value to checkmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the most significant bit of current value…
orMaskIsEqualTo
- Parameters:
currentValue(LWORD): current value to checkmask(LWORD): 2nd operand for bitwise operationexpectedValue(LWORD): expected result after maskingmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the result current value bitwise OR mask is equal to the expected value…
orMaskIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checkmask(LWORD): 2nd operand for bitwise operationunexpectedValue(LWORD): unexpected result after maskingmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the result current value bitwise OR mask …
valueIsEqualTo
- Parameters:
currentValue(LWORD): current value to checkexpectedValue(LWORD): expected value to comparemessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is equal to the expected value…
valueIsGreaterThan
- Parameters:
currentValue(LWORD): current value to checklessValue(LWORD): less than lower limitmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is greater than the less value…
valueIsInRangeOf
- Parameters:
lowerLimit(LWORD): lower limit for the current valuecurrentValue(LWORD): current value to checkupperLimit(LWORD): upper limit for the current valuemessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is inside a limit…
valueIsLessThan
- Parameters:
currentValue(LWORD): current value to checkgreaterValue(LWORD): greater than upper limitmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is less than the greater value…
valueIsMax
- Parameters:
currentValue(LWORD): current value to checkmaximumValue(LWORD): upper limit for the current valuemessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is less than or equal to the maximum value…
valueIsMin
- Parameters:
currentValue(LWORD): current value to checkminimumValue(LWORD): lower limit for the current valuemessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is greater than or equal to the minimum value…
valueIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checkunexpectedValue(LWORD): unexpected value to comparemessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the current value is not equal to the unexpected value…
xorMaskIsEqualTo
- Parameters:
currentValue(LWORD): current value to checkmask(LWORD): 2nd operand for bitwise operationexpectedValue(LWORD): expected result after maskingmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the result current value bitwise XOR mask is equal to the expected value…
xorMaskIsNotEqualTo
- Parameters:
currentValue(LWORD): current value to checkmask(LWORD): 2nd operand for bitwise operationunexpectedValue(LWORD): unexpected result after maskingmessage(AssertMessage): message if the assertion is false
- Return type:
VOID
This assertion method checks if the result current value bitwise XOR mask …
Code
Declaration
{attribute 'reflection'}
FUNCTION_BLOCK INTERNAL LWordAssertions EXTENDS AbstractAssertion IMPLEMENTS ILWordAssertions
VAR
END_VAR
VAR CONSTANT
(* least significant bit *)
LSB :LWORD := 16#0000_0000_0000_0001;
(* most significant bit *)
MSB :LWORD := 16#8000_0000_0000_0000;
END_VAR