Point Class Reference

Crea un punto 3D. More...

#include <Point.h>

List of all members.

Public Member Functions

 Point ()
 Point (int id, double x, double y, double z)
 Point (double x, double y, double z)
 Point (const Point &p)
void operator= (const Point &p)
bool operator== (const Point &p)
 ~Point ()
void setId (int id)
void setX (double x)
void setY (double y)
void setZ (double z)
int getId () const
double getX () const
double getY () const
double getZ () const
void setProcessed (bool processed)
bool isProcessed () const

Private Attributes

double x
double y
double z
int id
bool processed


Detailed Description

Crea un punto 3D.

Author:
Néstor Aguirre
Fecha de creación : 2007-03-18

Definition at line 33 of file Point.h.


Constructor & Destructor Documentation

Point::Point (  ) 

Definition at line 22 of file Point.cpp.

References processed, x, y, and z.

00023 {
00024         this->id = -1 ;
00025         this->x = 0.0 ;
00026         this->y = 0.0 ;
00027         this->z = 0.0 ;
00028         processed = false ;
00029 }

Point::Point ( int  id,
double  x,
double  y,
double  z 
)

Definition at line 31 of file Point.cpp.

References processed.

00032 {
00033         this->id = id ;
00034         this->x = x ;
00035         this->y = y ;
00036         this->z = z ;
00037         processed = false ;
00038 }

Point::Point ( double  x,
double  y,
double  z 
)

Definition at line 40 of file Point.cpp.

References processed.

00041 {
00042         this->id = -1 ;
00043         this->x = x ;
00044         this->y = y ;
00045         this->z = z ;
00046         processed = false ;
00047 }

Point::Point ( const Point p  ) 

Definition at line 49 of file Point.cpp.

References getId(), getX(), getY(), getZ(), isProcessed(), processed, x, y, and z.

00050 {
00051         this->id = p.getId() ;
00052         this->x = p.getX() ;
00053         this->y = p.getY() ;
00054         this->z = p.getZ() ;
00055         this->processed = p.isProcessed() ;
00056 }

Point::~Point (  ) 

Definition at line 77 of file Point.cpp.

00078 {
00079 }


Member Function Documentation

void Point::operator= ( const Point p  ) 

Definition at line 58 of file Point.cpp.

References getId(), getX(), getY(), getZ(), isProcessed(), processed, x, y, and z.

00059 {
00060         this->id = p.getId() ;
00061         this->x = p.getX() ;
00062         this->y = p.getY() ;
00063         this->z = p.getZ() ;
00064         this->processed = p.isProcessed() ;
00065 }

bool Point::operator== ( const Point p  ) 

Dos puntos son igules si y solo si sus ids son iguales

Parameters:
p Punto a ser comparado
Returns:
true si son iguales o de lo contrario false

Definition at line 72 of file Point.cpp.

References getId().

00073 {
00074         return ( this->id == p.getId() ) ? true : false ;
00075 }

void Point::setId ( int  id  ) 

Definition at line 86 of file Point.cpp.

00087 {
00088         this->id = id;
00089 }

void Point::setX ( double  x  ) 

Definition at line 96 of file Point.cpp.

00097 {
00098         this->x = x;
00099 }

void Point::setY ( double  y  ) 

Definition at line 106 of file Point.cpp.

00107 {
00108         this->y = y;
00109 }

void Point::setZ ( double  z  ) 

Definition at line 116 of file Point.cpp.

00117 {
00118         this->z = z;
00119 }

int Point::getId (  )  const

Definition at line 81 of file Point.cpp.

References id.

Referenced by Triangle::contains(), operator=(), operator==(), and Point().

00082 {
00083         return id;
00084 }

double Point::getX (  )  const

Definition at line 91 of file Point.cpp.

References x.

Referenced by operator=(), and Point().

00092 {
00093         return x;
00094 }

double Point::getY (  )  const

Definition at line 101 of file Point.cpp.

References y.

Referenced by operator=(), and Point().

00102 {
00103         return y;
00104 }

double Point::getZ (  )  const

Definition at line 111 of file Point.cpp.

References z.

Referenced by operator=(), and Point().

00112 {
00113         return z;
00114 }

void Point::setProcessed ( bool  processed  ) 

Definition at line 128 of file Point.cpp.

00129 {
00130         this->processed = processed;
00131 }

bool Point::isProcessed (  )  const

Definition at line 122 of file Point.cpp.

References processed.

Referenced by operator=(), and Point().

00123 {
00124         return processed;
00125 }


Member Data Documentation

double Point::x [private]

Definition at line 57 of file Point.h.

Referenced by getX(), operator=(), and Point().

double Point::y [private]

Definition at line 58 of file Point.h.

Referenced by getY(), operator=(), and Point().

double Point::z [private]

Definition at line 59 of file Point.h.

Referenced by getZ(), operator=(), and Point().

int Point::id [private]

Definition at line 60 of file Point.h.

Referenced by getId().

bool Point::processed [private]

Definition at line 61 of file Point.h.

Referenced by isProcessed(), operator=(), and Point().


The documentation for this class was generated from the following files:
Generated on Mon May 26 20:29:47 2008 for TARIS by  doxygen 1.5.4