#include <size_2d.h>
Public メソッド | |
Size2D () | |
default constructor. | |
Size2D (const double &length, const double &width) | |
constructor with variables | |
const Size2D & | assign (const double &length, const double &width) |
assign new range directly. | |
const Size2D & | setLength (const double &length) |
set new X range | |
const Size2D & | setWidth (const double &width) |
set new Y range | |
const double & | length () const |
get the value of X range | |
const double & | width () const |
get the value of Y range | |
double | diagonal () const |
get the length of diagonal line | |
std::ostream & | print (std::ostream &os) const |
output values to stream. |
rcsc::Size2D::Size2D | ( | const double & | length, | |
const double & | width | |||
) | [inline] |
constructor with variables
length | x range | |
width | y range |
const Size2D& rcsc::Size2D::assign | ( | const double & | length, | |
const double & | width | |||
) | [inline] |
assign new range directly.
length | new X range | |
width | new Y range |
const Size2D& rcsc::Size2D::setLength | ( | const double & | length | ) | [inline] |
set new X range
length | new X range |
const Size2D& rcsc::Size2D::setWidth | ( | const double & | width | ) | [inline] |
set new Y range
width | new Y range |
const double& rcsc::Size2D::length | ( | ) | const [inline] |
get the value of X range
const double& rcsc::Size2D::width | ( | ) | const [inline] |
get the value of Y range
double rcsc::Size2D::diagonal | ( | ) | const [inline] |
get the length of diagonal line
std::ostream& rcsc::Size2D::print | ( | std::ostream & | os | ) | const [inline] |
output values to stream.
os | reference to the output stream |