SLIP  1.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Protected Attributes | Friends | List of all members
slip::DPoint1d< CoordType > Class Template Reference

Difference of Point1D class, specialization of DPoint<CoordType,DIM> with DIM = 1. More...

#include <DPoint1d.hpp>

Inheritance diagram for slip::DPoint1d< CoordType >:
Inheritance graph

Public Types

typedef DPoint1d< CoordType > self
 
typedef DPoint< CoordType, 1 > base
 
typedef CoordType value_type
 
typedef value_typedpointer
 
typedef const value_typeconst_dpointer
 
typedef value_typereference
 
typedef const value_typeconst_reference
 
typedef
std::random_access_iterator_tag 
iterator_category
 

Public Member Functions

std::string name () const
 Returns the name of the class. More...
 
std::size_t dim () const
 Returns the dimension of the DPoint. More...
 
std::size_t size () const
 Returns the dimension of the DPoint. More...
 
std::size_t max_size () const
 Returns the maximal size of the DPoint. More...
 
bool empty () const
 Returns true if dimension of the DPoint is 0. More...
 
const block< value_type, DIM > & coord () const
 Return the coordinates of the DPoint. More...
 
void swap (self &other)
 Swaps two DPoint. More...
 
Constructors & Destructors
 DPoint1d ()
 Constructs a DPoint1d. More...
 
 DPoint1d (const CoordType &dx1)
 Constructs a DPoint1d. More...
 
Element access operators
void dx1 (const CoordType &dx)
 Accessor of the first coordinate of DPoint1d. More...
 
CoordType & dx1 ()
 Accessor/Mutator of the first coordinate of DPoint1d. More...
 
const CoordType & dx1 () const
 Accessor/Mutator of the first coordinate of DPoint1d. More...
 
Element access operators
reference operator[] (const std::size_t i)
 Returns the i'th coordinate of the DPoint. More...
 
const_reference operator[] (const std::size_t i) const
 Returns the i'th row of the DPoint. More...
 
Comparison operators
bool operator== (const self &other) const
 compare two DPoint. More...
 
bool operator!= (const self &other) const
 compare two DPoint. More...
 
Arithmetic operators
self operator- () const
 negate all the coordinates of a DPoint More...
 
self operator- (const self &other) const
 substract the coordinates of a two DPoint More...
 
selfoperator+= (const self &other)
 add the coordinates of a DPoint to the DPoint More...
 
self operator+ (const self &other) const
 add the coordinates of a two DPoint More...
 
selfoperator-= (const self &other)
 substract the coordinates of a DPoint to the DPoint More...
 

Protected Attributes

block< value_type, DIM > coord_
 The coordinates of the dpoint are stored in this block. More...
 

Friends

class boost::serialization::access
 

Detailed Description

template<typename CoordType>
class slip::DPoint1d< CoordType >

Difference of Point1D class, specialization of DPoint<CoordType,DIM> with DIM = 1.

Author
Benoit Tremblais <tremblais_AT_sic.univ-poitiers.fr> : conceptor
Julien Dombre <dombre_AT_sic.univ-poitiers.fr> : add mutator
Version
0.0.2
Date
2014/04/02
Since
1.0.0
Parameters
CoordTypeType of the coordinates of the DPoint1d

Definition at line 101 of file DPoint1d.hpp.

Member Typedef Documentation

template<typename CoordType >
typedef DPoint<CoordType,1> slip::DPoint1d< CoordType >::base

Definition at line 105 of file DPoint1d.hpp.

typedef const value_type* slip::DPoint< CoordType, DIM >::const_dpointer
inherited

Definition at line 114 of file DPoint.hpp.

typedef const value_type& slip::DPoint< CoordType, DIM >::const_reference
inherited

Definition at line 116 of file DPoint.hpp.

typedef value_type* slip::DPoint< CoordType, DIM >::dpointer
inherited

Definition at line 113 of file DPoint.hpp.

typedef std::random_access_iterator_tag slip::DPoint< CoordType, DIM >::iterator_category
inherited

Definition at line 121 of file DPoint.hpp.

typedef value_type& slip::DPoint< CoordType, DIM >::reference
inherited

Definition at line 115 of file DPoint.hpp.

template<typename CoordType >
typedef DPoint1d<CoordType> slip::DPoint1d< CoordType >::self

Definition at line 104 of file DPoint1d.hpp.

typedef CoordType slip::DPoint< CoordType, DIM >::value_type
inherited

Definition at line 112 of file DPoint.hpp.

Constructor & Destructor Documentation

template<typename CoordType >
slip::DPoint1d< CoordType >::DPoint1d ( )
inline

Constructs a DPoint1d.

Definition at line 173 of file DPoint1d.hpp.

template<typename CoordType >
slip::DPoint1d< CoordType >::DPoint1d ( const CoordType &  dx1)
inline

Constructs a DPoint1d.

Parameters
dx1first coordinate of the DPoint1d

Definition at line 180 of file DPoint1d.hpp.

Member Function Documentation

const block<value_type,DIM>& slip::DPoint< CoordType, DIM >::coord ( ) const
inherited

Return the coordinates of the DPoint.

std::size_t slip::DPoint< CoordType, DIM >::dim ( ) const
inherited

Returns the dimension of the DPoint.

Returns
the dimension (number of coordinates) of the DPoint
template<typename CoordType >
void slip::DPoint1d< CoordType >::dx1 ( const CoordType &  dx)
inline

Accessor of the first coordinate of DPoint1d.

Parameters
dxfirst coordinate of the minimal point p1

Definition at line 191 of file DPoint1d.hpp.

template<typename CoordType >
CoordType & slip::DPoint1d< CoordType >::dx1 ( )
inline

Accessor/Mutator of the first coordinate of DPoint1d.

Returns
reference to the first coordinate of the DPoint1d

Definition at line 187 of file DPoint1d.hpp.

template<typename CoordType >
const CoordType & slip::DPoint1d< CoordType >::dx1 ( ) const
inline

Accessor/Mutator of the first coordinate of DPoint1d.

Returns
reference to the first coordinate of the DPoint1d

Definition at line 195 of file DPoint1d.hpp.

bool slip::DPoint< CoordType, DIM >::empty ( ) const
inherited

Returns true if dimension of the DPoint is 0.

Returns
true if the dimension of the DPoint is 0, false else
std::size_t slip::DPoint< CoordType, DIM >::max_size ( ) const
inherited

Returns the maximal size of the DPoint.

Returns
the dimension (number of coordinates) of the DPoint
template<typename CoordType >
std::string slip::DPoint1d< CoordType >::name ( ) const
inline

Returns the name of the class.

Definition at line 200 of file DPoint1d.hpp.

bool slip::DPoint< CoordType, DIM >::operator!= ( const self other) const
inherited

compare two DPoint.

Parameters
otherDPoint to compare
Returns
true if the two dpoint don't have the same coordinates
self slip::DPoint< CoordType, DIM >::operator+ ( const self other) const
inherited

add the coordinates of a two DPoint

Parameters
otherDPoint to add with
Returns
a DPoint
self& slip::DPoint< CoordType, DIM >::operator+= ( const self other)
inherited

add the coordinates of a DPoint to the DPoint

Parameters
otherDPoint to add with
Returns
a DPoint
self slip::DPoint< CoordType, DIM >::operator- ( ) const
inherited

negate all the coordinates of a DPoint

Returns
a DPoint with negate coordinates
self slip::DPoint< CoordType, DIM >::operator- ( const self other) const
inherited

substract the coordinates of a two DPoint

Parameters
otherDPoint to add with
Returns
a DPoint
self& slip::DPoint< CoordType, DIM >::operator-= ( const self other)
inherited

substract the coordinates of a DPoint to the DPoint

Parameters
otherDPoint to add with
Returns
a DPoint
bool slip::DPoint< CoordType, DIM >::operator== ( const self other) const
inherited

compare two DPoint.

Parameters
otherDPoint to compare
Returns
true if the two dpoint have the same coordinates
reference slip::DPoint< CoordType, DIM >::operator[] ( const std::size_t  i)
inherited

Returns the i'th coordinate of the DPoint.

Parameters
iindex of the coordinate to return
Returns
value of the i'th row of the DPoint.
Precondition
0 <= i < dim
const_reference slip::DPoint< CoordType, DIM >::operator[] ( const std::size_t  i) const
inherited

Returns the i'th row of the DPoint.

Parameters
iindex of the coordinate to return
Returns
value of the i'th row of the DPoint
Precondition
0 <= i < dim
std::size_t slip::DPoint< CoordType, DIM >::size ( ) const
inherited

Returns the dimension of the DPoint.

Returns
the dimension (number of coordinates) of the DPoint
void slip::DPoint< CoordType, DIM >::swap ( self other)
inherited

Swaps two DPoint.

Parameters
otherDPoint to swap with

Friends And Related Function Documentation

template<typename CoordType >
friend class boost::serialization::access
friend

Definition at line 154 of file DPoint1d.hpp.

Member Data Documentation

block<value_type,DIM> slip::DPoint< CoordType, DIM >::coord_
protectedinherited

The coordinates of the dpoint are stored in this block.

Definition at line 321 of file DPoint.hpp.


The documentation for this class was generated from the following file: