pandore::Dimension2d Class Reference
#include <dimension.h>
Inheritance diagram for pandore::Dimension2d:
List of all members.
Detailed Description
A 2D dimension.
The Dimension2d
class encapsulates the width and the height of a component (in Long precision) in a single object.
Use of Dimension2d:
For the use of Dimension2d see The Dimensions.
Constructor & Destructor Documentation
pandore::Dimension2d::Dimension2d |
( |
|
) |
[inline] |
|
|
Creates a 2D dimension with a width of zero and a height of zero. |
pandore::Dimension2d::Dimension2d |
( |
Long |
height, |
|
|
Long |
width |
|
) |
[inline] |
|
|
Creates a 2D dimension with the specified width and height values. - Parameters:
-
| height | the specified width. |
| width | the specified height. |
|
pandore::Dimension2d::Dimension2d |
( |
const Dimension2d & |
d |
) |
[inline] |
|
|
Creates a 2D dimension with the specified dimension. - Parameters:
-
| d | the specified dimension for the width and the height values. |
|
Member Function Documentation
Pobject* pandore::Dimension2d::Clone |
( |
|
) |
const [inline] |
|
|
Creates and returns a distinct copy of this object. |
Errc pandore::Dimension2d::LoadData |
( |
FILE * |
df |
) |
[inline] |
|
|
Loads data from the given file. - Parameters:
-
| df | the file where to read data. |
- Returns:
- SUCCESS or FAILURE in case of IO errors.
|
std::string pandore::Dimension2d::Name |
( |
|
) |
const [inline] |
|
|
Returns the type name (for instance "Dimension2d"). - Returns:
- the name in a string.
|
Dimension2d pandore::Dimension2d::operator * |
( |
int |
x |
) |
const [inline] |
|
|
Creates a new 2D dimension from the multiplication of each dimension values by the specified value. - Parameters:
-
- Returns:
- a new dimension.
|
bool pandore::Dimension2d::operator!= |
( |
const Dimension2d & |
d |
) |
const [inline] |
|
|
Checks if the dimension is different from a reference dimension. - Parameters:
-
| d | the reference dimension. |
- Returns:
- true if dimensions are different.
|
Dimension2d pandore::Dimension2d::operator+ |
( |
int |
x |
) |
const [inline] |
|
|
Creates a new 2D dimension from the addition of each dimension values by the specified value. - Parameters:
-
- Returns:
- a new dimension.
|
Dimension2d pandore::Dimension2d::operator- |
( |
int |
x |
) |
const [inline] |
|
|
Creates a new 2D dimension from the subtraction of the each dimension values by the specified value. - Parameters:
-
- Returns:
- a new dimension.
|
Dimension2d pandore::Dimension2d::operator/ |
( |
int |
x |
) |
const [inline] |
|
|
Creates a new 2D dimension from the division of the each dimension values by the specified value. - Parameters:
-
- Returns:
- a new dimension.
|
|
Sets the new dimension values with the specified dimension values. - Parameters:
-
| d | the specified dimension. |
- Returns:
- the specified dimension.
|
bool pandore::Dimension2d::operator== |
( |
const Dimension2d & |
d |
) |
const [inline] |
|
|
Checks if the dimension is equal to a reference dimension. - Parameters:
-
| d | the reference dimension. |
- Returns:
- true if dimensions are equal.
|
Errc pandore::Dimension2d::SaveData |
( |
FILE * |
df |
) |
const [inline] |
|
|
Saves data in the given file. - Parameters:
-
| df | the file where to save data. |
- Returns:
- SUCCESS or FAILURE in case of IO errors.
|
Typobj pandore::Dimension2d::Type |
( |
|
) |
const [inline] |
|
|
Returns the magic number of the object (for instance Po_Dimension2d). - Returns:
- the magic number.
|
Member Data Documentation
|
The height dimension; negative values can be used. |
|
The width dimension; negative values can be used. |
The documentation for this class was generated from the following file: