The IRange class represents a range of IPair::Coord values between a specified lower and upper bound (inclusive).
Constructors & DestructorYou can construct, copy, and assign objects of this class. This class uses the compiler-generated copy constructor and assignment operator to copy and assign IRange objects.
![]() |
public:
IRange()
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
public:
IRange(const IPair& aPair)
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
public:
IRange(Coord lower, Coord upper)
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
CoordinatesUse these members to query and change the ordered pair of integers in an IRange object.
![]() |
public:
Coord lowerBound() const
Returns the lower bound of the range.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
IRange& setLowerBound(Coord lower)
Sets the lower bound of the range.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
IRange& setUpperBound(Coord upper)
Sets the upper bound of the range.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
Coord upperBound() const
Returns the upper bound of the range.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
TestingUse these members to test coordinate values.
![]() |
public:
bool includes(Coord aValue) const
Returns true if the range contains the specified coordinate value.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
IString asDebugInfo() const
IString asString() const
Coord coord1() const
Coord coord2() const
double distanceFrom(const IPair& aPair) const
long dotProduct(const IPair& aPair) const
IPair(Coord coord1, Coord coord2)
IPair(Coord init)
IPair()
IPair maximum(const IPair& aPair) const
IPair minimum(const IPair& aPair) const
bool operator !=(const IPair& aPair) const
IPair& operator %=(long divisor)
IPair& operator %=(const IPair& aPair)
IPair& operator *=(double multiplier)
IPair& operator *=(const IPair& aPair)
IPair& operator +=(const IPair& aPair)
IPair operator -() const
IPair& operator -=(const IPair& aPair)
IPair& operator /=(const IPair& aPair)
IPair& operator /=(double divisor)
bool operator <(const IPair& aPair) const
bool operator <=(const IPair& aPair) const
bool operator ==(const IPair& aPair) const
bool operator >(const IPair& aPair) const
bool operator >=(const IPair& aPair) const
IPair& scaleBy(double xFactor, double yFactor)
IPair scaledBy(double xFactor, double yFactor) const
IPair& setCoord1(Coord coord1)
IPair& setCoord2(Coord coord2)
IPair& transpose()