MEng.Card2 represents an unsigned (cardinal) value from 0 to 65535. This class provides a full set of mathematical and bitwise operations on Card2 values.
Add([In] MEng.Card2 ToAdd) Returns MEng.Card2;
operator+([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Adds the two objects and returns the result, leaving both objects unaffected. They do the same thing, and are only syntactically different. Overflow is ignored.
And([In] MEng.Card2 SrcVal) Returns MEng.Card2;
operator&([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Bitwise ANDs the two objects and return the result, leaving both objects unchanged. They do the same thing, and are only syntactically different.
Div([In] MEng.Card2 DivBy) Returns MEng.Card2;
operator/([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Divides the left hand object by the right hand object, and returns the result, leaving both objects unaffected. They do the same thing, and are only syntactically different.
Equal([In] MEng.Card2 ToComp) Returns MEng.Boolean;
operator=([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Boolean;
Compares the two objects and returns True if they are equal and False if they are unequal. Neither object is affected. They do the same thing, are only only syntactically different.
GetBit([In] Card4 BitIndex) Returns MEng.Boolean;
Returns the state of the bit at the indicated index, 0 to 15 for this Card2 class, where 0 is the low order bit and 15 is the high order. If the bit is on, then True is returned. Else False is returned.
GetHighByte() Returns MEng.Card1;
GetLowByte() Returns MEng.Card1;
Returns the high or low byte of this object. The high byte is the most significant byte and the low byte is the least significant byte.
GtThan([In] MEng.Card2 ToComp) Returns MEng.Boolean;
operator>([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Boolean;
GtThanEq([In] MEng.Card2 ToComp) Returns MEng.Boolean;
operator>=([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Boolean;
Compares the two objects and returns True if the left hand object is greater (or greater than or equal), else it returns False. Neither object is affected. The two sets do the same thing, and are just syntactically different.
LsThan([In] MEng.Card2 ToComp) Returns MEng.Boolean;
operator<([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Boolean;
LsThanEq([In] MEng.Card2 ToComp) Returns MEng.Boolean;
operator<=([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Boolean;
Compares the two objects and returns True if the left hand object is less than (or less than or equal) the right hand object, else it returns False. Neither object is affected. The two sets do the same thing, and are just syntactically different.
MaxVal([In] MEng.Card2 Test) Returns MEng.Card2;
MinVal([In] MEng.Card2 Test) Returns MEng.Card2;
Returns the larger or smaller of this value and the passed test value. So if this object's value is larger or smaller, it will be returned, else the passed value will be returned.
ModDiv([In] MEng.Card2 DivBy) Returns MEng.Card2;
operator%([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Performs a modulo division and returns the remainder of the operation. These both do the same thing, they are just syntactically different.
Mul([In] MEng.Card2 MulBy) Returns MEng.Card2;
operator*([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Multiplies the left hand object by the right hand object, and returns the result, leaving both objects unaffected. They do the same thing, and are only syntactically different. Overflow is ignored.
Or([In] MEng.Card2 SrcVal) Returns MEng.Card2;
operator|([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Bitwise ORs the two objects and return the result, leaving both objects unchanged. They do the same thing, and are only syntactically different.
ShiftLeft([In] MEng.Card4 ShiftBy);
ShiftRight([In] MEng.Card4 ShiftBy);
Shifts this object's value left or right by the indicated number of bits. The shift by is really turned into ShiftBy mod 16, so that un-required shifting isn't require, because any value greater than 16 is redundant.
Sub([In] MEng.Card2 MulBy) Returns MEng.Card2;
operator-([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Subtracts the right hand object from the left hand object, and returns the result, leaving both objects unaffected. They do the same thing, and are only syntactically different.
Xor([In] MEng.Card2 SrcVal) Returns MEng.Card2;
operator^([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Bitwise XORs the two objects and return the result, leaving both objects unchanged. They do the same thing, and are only syntactically different.
AndEq([In] MEng.Card2 SrcVal);
operator&=([In] MEng.Card2 SrcVal);
Bitwise ANDs this object with passed object, updating this object with the resulting value. They do the same thing, and are only syntactically different.
Copy([In] MEng.Card2 SrcVal);
operator=([In] MEng.Card2 SrcVal);
Copies the value of the passed object into this object. These both do the same thing, and are just syntactically different.
Dec() Returns MEng.Card2;
operator--() Returns MEng.Card2;
If the value of this object is greater than zero, it is decremented by one, else nothing happens. These both do the same thing, and are just syntactically different. This is a postfix decrement, so the value returned is the value before the decrement.
DivEq([In] MEng.Card2 DivBy);
operator/=([In] MEng.Card2 DivBy);
Divides this object by the passed object, updating this object with the resulting value. They do the same thing, and are only syntactically different.
Inc() Returns MEng.Card2;
operator++() Returns MEng.Card2;
If the value of this object is less than the maximum Card2 value, it is incremented by one, else nothing happens. These both do the same thing, and are just syntactically different. This is a postfix increment, so the value returned is the value before the increment.
ModDivEq([In] MEng.Card2 DivBy) Returns MEng.Card2;
operator%=([In] MEng.Card2 Src1, [In] MEng.Card2 Src2) Returns MEng.Card2;
Performs a modulo division and set this value to the remainder of the operation. The two versions do the same thing, they are just syntactically different.
MinusEq([In] MEng.Card2 SrcVal);
operator-=([In] MEng.Card2 SrcVal);
Subtracts the passed object from this object, updating this object with the resulting value. These both do the same thing, and are only syntactically different.
MulEq([In] MEng.Card2 SrcVal);
operator*=([In] MEng.Card2 SrcVal);
Multiplies this object by the passed object, updating this object with the resulting value. They do the same thing, and are only syntactically different.