Go to Overview over all GrAL packages.
Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

point Class Reference

#include <point.h>

List of all members.

Public Types

enum  { no_init = 0, zero_init = 1 }

Public Methods

 point ()
 point (int n1, int init)
 point (int n1)
 point (const double x1)
 point (const double x, const double y)
 point (const double x, const double y, const double z)
 point (const double a[], int nn)
 point (const point &v)
 ~point ()
int dim () const
point & operator= (const point &v)
point & operator+= (const point &v)
point & operator-= (const point &v)
point & operator *= (const double d)
point & operator/= (const double d)
double & operator[] (int i)
const double & operator[] (int i) const
double length () const
double length2 () const
point normalize () const

Protected Attributes

int n
double * x

Friends

point combine (const point &a, const point &b)
point operator- (const point &a)
point operator+ (const point &a, const point &b)
point operator- (const point &a, const point &b)
point operator * (const point &a, const double d)
point operator * (const double d, const point &a)
double operator * (const point &a, const point &b)
point operator/ (const point &a, const double d)
ostream & operator<< (ostream &s, const point &v)
istream & operator>> (istream &s, point &v)
void swap (point &a, point &b)


Member Enumeration Documentation

anonymous enum
 

Enumeration values:
no_init 
zero_init 

Definition at line 34 of file point.h.


Constructor & Destructor Documentation

point::point   [inline]
 

Definition at line 35 of file point.h.

References n, and x.

point::point int    n1,
int    init
[inline]
 

Definition at line 37 of file point.h.

References n, x, and zero_init.

point::point int    n1 [inline, explicit]
 

Definition at line 39 of file point.h.

References n, and x.

point::point const double    x1 [explicit]
 

Definition at line 9 of file point.C.

References n, and x.

point::point const double    x,
const double    y
 

Definition at line 11 of file point.C.

References n, and x.

point::point const double    x,
const double    y,
const double    z
 

Definition at line 14 of file point.C.

References n, and x.

point::point const double    a[],
int    nn
 

Definition at line 25 of file point.C.

References n, and x.

point::point const point &    v
 

Definition at line 17 of file point.C.

References n, and x.

point::~point   [inline]
 

Definition at line 45 of file point.h.

References n, and x.


Member Function Documentation

int point::dim   const [inline]
 

Definition at line 47 of file point.h.

References n.

Referenced by point_traits< point >::Dim, and IsNullvector.

point & point::operator= const point &    v
 

Definition at line 36 of file point.C.

References n, and x.

point & point::operator+= const point &    v
 

Definition at line 47 of file point.C.

References n, and x.

point & point::operator-= const point &    v
 

Definition at line 54 of file point.C.

References n, and x.

point & point::operator *= const double    d
 

Definition at line 62 of file point.C.

References n, and x.

point & point::operator/= const double    d
 

Definition at line 70 of file point.C.

References n, and x.

double & point::operator[] int    i [inline]
 

Definition at line 80 of file point.h.

References n, and x.

const double & point::operator[] int    i const [inline]
 

Definition at line 86 of file point.h.

References n, and x.

double point::length   const
 

Definition at line 80 of file point.C.

References length2.

Referenced by normalize.

double point::length2   const
 

Definition at line 83 of file point.C.

References n, and x.

Referenced by length.

point point::normalize   const
 

Definition at line 91 of file point.C.

References length.


Friends And Related Function Documentation

point combine const point &    a,
const point &    b
[friend]
 

Definition at line 132 of file point.C.

point operator- const point &    a [friend]
 

Definition at line 103 of file point.C.

point operator+ const point &    a,
const point &    b
[friend]
 

Definition at line 111 of file point.C.

point operator- const point &    a,
const point &    b
[friend]
 

Definition at line 121 of file point.C.

point operator * const point &    a,
const double    d
[friend]
 

Definition at line 142 of file point.C.

point operator * const double    d,
const point &    a
[friend]
 

Definition at line 150 of file point.C.

double operator * const point &    a,
const point &    b
[friend]
 

Definition at line 157 of file point.C.

point operator/ const point &    a,
const double    d
[friend]
 

Definition at line 153 of file point.C.

ostream& operator<< ostream &    s,
const point &    v
[friend]
 

Definition at line 167 of file point.C.

istream& operator>> istream &    s,
point &    v
[friend]
 

Definition at line 174 of file point.C.

void swap point &    a,
point &    b
[friend]
 

Definition at line 180 of file point.C.


Member Data Documentation

int point::n [protected]
 

Definition at line 25 of file point.h.

Referenced by combine, dim, length2, operator *, operator *=, operator+, operator+=, operator-, operator-=, operator/=, operator<<, operator=, operator>>, operator[], point, and ~point.

double* point::x [protected]
 

Definition at line 26 of file point.h.

Referenced by length2, operator *=, operator+=, operator-=, operator/=, operator=, operator[], point, and ~point.


The documentation for this class was generated from the following files:
Copyright (c) Guntram Berti 1997-2002. See the GrAL Homepage for up-to-date information.

Generated at Tue Feb 26 15:57:34 2002 for Geometry by doxygen 1.2.11-20011104 written by Dimitri van Heesch, © 1997-2000