/MEng/Int4

ClassPath:MEng.Int4
Parent ClassPath:MEng.Formattable
Copyable:Yes
Final:Yes

MEng.Int4 represents a signed (integral) value from -2147483648 to 2147483647. This class provides a full set of mathematical operations on Int4 values.

 

Literals:

Int4 kMinValue(-2147483648);
Int4 kMaxValue(2147483647);

 

Constructors:

Constructor();
Constructor([In] MEng.Int4 InitVal);

There is one default constructor, which will set the initial value to zero, and a constructor that takes an initial value.

 

Final, Const Methods:

Add([In] MEng.Int4 ToAdd) Returns MEng.Int4;
operator+([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Int4;

Adds the two objects and returns the result, leaving both objects unaffected. They do the same thing, and are only syntactically different. 

Div([In] MEng.Int4 DivBy) Returns MEng.Int4;
operator/([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Int4;

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.Int4 ToComp) Returns MEng.Boolean;
operator=([In] MEng.Int4 Src1, [In] MEng.Int4 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.

GetNegated() Returns MEng.Int4;

Returns a negated version of this object's value.

GtThan([In] MEng.Int4 ToComp) Returns MEng.Boolean;
operator>([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Boolean;
GtThanEq([In] MEng.Int4 ToComp) Returns MEng.Boolean;
operator>=([In] MEng.Int4 Src1, [In] MEng.Int4 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.Int4 ToComp) Returns MEng.Boolean;
operator<([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Boolean;
LsThanEq([In] MEng.Int4 ToComp) Returns MEng.Boolean;
operator<=([In] MEng.Int4 Src1, [In] MEng.Int4 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.Int4 Test) Returns MEng.Int4;
MinVal([In] MEng.Int4 Test) Returns MEng.Int4;

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.Int4 DivBy) Returns MEng.Int4;
operator%([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Int4;

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.Int4 MulBy) Returns MEng.Int4;
operator*([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Int4;

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. 

Sub([In] MEng.Int4 MulBy) Returns MEng.Int4;
operator-([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Int4;

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. 

 

Final, Non-Const Methods:

Dec() Returns MEng.Int4;
operator--() Returns MEng.Int4;

If the value of this object is greater than the minimum value, 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.Int4 DivBy);
operator/=([In] MEng.Int4 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.Int4;
operator++() Returns MEng.Int4;

If the value of this object is less than the maximum 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.Int4 DivBy) Returns MEng.Int4;
operator%=([In] MEng.Int4 Src1, [In] MEng.Int4 Src2) Returns MEng.Int4;

Performs a modulo division and set this object ot the the remainder of the operation. These both do the same thing, they are just syntactically different.

MinusEq([In] MEng.Int4 SrcVal);
operator-=([In] MEng.Int4 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.Int4 SrcVal);
operator*=([In] MEng.Int4 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.

PlusEq([In] MEng.Int4 SrcVal);
operator+=([In] MEng.Int4 SrcVal);

Adds the passed object to this object, updating this object with the resulting value. They do the same thing, and are only syntactically different.