Multi-set of sites. More...
#include <p_array.hh>
Inherits site_set_base_< P, p_array< P > >.
Public Types | |
| typedef p_indexed_bkd_piter < self_ >  | bkd_piter | 
| Backward Site_Iterator associated type.   | |
| typedef P | element | 
| Element associated type.   | |
| typedef p_indexed_fwd_piter < self_ >  | fwd_piter | 
| Forward Site_Iterator associated type.   | |
| typedef P | i_element | 
| Insertion element associated type.   | |
| typedef fwd_piter | piter | 
| Site_Iterator associated type.   | |
| typedef p_indexed_psite< self_ > | psite | 
| Psite associated type.   | |
Public Member Functions | |
| p_array< P > & | append (const P &p) | 
Append a point p.   | |
| p_array< P > & | append (const p_array< P > &other) | 
Append an array other of points.   | |
| void | change (const psite &p, const P &new_p) | 
Change site p into new_p.   | |
| void | clear () | 
| Clear this set.   | |
| bool | has (const util::index &i) const | 
Test is index i belongs to this site set.   | |
| bool | has (const psite &p) const | 
Test is p belongs to this site set.   | |
| void | insert (const P &p) | 
Insert a point p (equivalent as 'append').   | |
| bool | is_valid () const | 
| Test this set validity so returns always true.   | |
| std::size_t | memory_size () const | 
| Return the size of this site set in memory.   | |
| unsigned | nsites () const | 
| Give the number of sites.   | |
| const P & | operator[] (const util::index &i) const | 
| Return the i-th element.   | |
| P & | operator[] (unsigned i) | 
Return the i-th site (mutable).   | |
| const P & | operator[] (unsigned i) const | 
Return the i-th site (constant).   | |
| p_array () | |
| Constructor.   | |
| p_array (const std::vector< P > &vect) | |
Constructor from a vector vect.   | |
| void | reserve (size_type n) | 
Reserve n cells.   | |
| void | resize (size_t size) | 
| Update the size of this array.   | |
| const std::vector< P > & | std_vector () const | 
| Return the corresponding std::vector of points.   | |
Multi-set of sites.
Site set class based on std::vector.
Definition at line 84 of file p_array.hh.
| typedef p_indexed_bkd_piter<self_> mln::p_array< P >::bkd_piter | 
Backward Site_Iterator associated type.
Definition at line 100 of file p_array.hh.
| typedef P mln::p_array< P >::element | 
Element associated type.
Definition at line 91 of file p_array.hh.
| typedef p_indexed_fwd_piter<self_> mln::p_array< P >::fwd_piter | 
Forward Site_Iterator associated type.
Definition at line 97 of file p_array.hh.
| typedef P mln::p_array< P >::i_element | 
Insertion element associated type.
Definition at line 141 of file p_array.hh.
| typedef fwd_piter mln::p_array< P >::piter | 
Site_Iterator associated type.
Definition at line 103 of file p_array.hh.
| typedef p_indexed_psite<self_> mln::p_array< P >::psite | 
Psite associated type.
Definition at line 94 of file p_array.hh.
| mln::p_array< P >::p_array | ( | ) |  [inline] | 
        
Constructor.
Definition at line 340 of file p_array.hh.
| mln::p_array< P >::p_array | ( | const std::vector< P > & | vect | ) |  [inline] | 
        
Constructor from a vector vect. 
Definition at line 346 of file p_array.hh.
| p_array< P > & mln::p_array< P >::append | ( | const P & | p | ) |  [inline] | 
        
Append a point p. 
Definition at line 408 of file p_array.hh.
Referenced by mln::convert::to_p_array().
| p_array< P > & mln::p_array< P >::append | ( | const p_array< P > & | other | ) |  [inline] | 
        
Append an array other of points. 
Definition at line 425 of file p_array.hh.
References mln::p_array< P >::std_vector().
| void mln::p_array< P >::change | ( | const psite & | p, | |
| const P & | new_p | |||
| ) |  [inline] | 
        
Change site p into new_p. 
Definition at line 472 of file p_array.hh.
References mln::p_array< P >::has().
| void mln::p_array< P >::clear | ( | ) |  [inline] | 
        
Clear this set.
Definition at line 436 of file p_array.hh.
| bool mln::p_array< P >::has | ( | const psite & | p | ) |  const [inline] | 
        
Test is p belongs to this site set. 
Definition at line 362 of file p_array.hh.
Referenced by mln::p_array< P >::change(), and mln::p_array< P >::operator[]().
| bool mln::p_array< P >::has | ( | const util::index & | i | ) |  const [inline] | 
        
Test is index i belongs to this site set. 
Definition at line 375 of file p_array.hh.
References mln::p_array< P >::nsites().
| void mln::p_array< P >::insert | ( | const P & | p | ) |  [inline] | 
        
Insert a point p (equivalent as 'append'). 
Definition at line 417 of file p_array.hh.
| bool mln::p_array< P >::is_valid | ( | ) |  const [inline] | 
        
Test this set validity so returns always true.
Definition at line 383 of file p_array.hh.
| std::size_t mln::p_array< P >::memory_size | ( | ) |  const [inline] | 
        
Return the size of this site set in memory.
Definition at line 481 of file p_array.hh.
References mln::p_array< P >::nsites().
| unsigned mln::p_array< P >::nsites | ( | ) |  const [inline] | 
        
Give the number of sites.
Definition at line 400 of file p_array.hh.
Referenced by mln::registration::get_rot(), mln::p_array< P >::has(), mln::p_array< P >::memory_size(), and mln::p_array< P >::operator[]().
| P & mln::p_array< P >::operator[] | ( | unsigned | i | ) |  [inline] | 
        
Return the i-th site (mutable). 
Definition at line 463 of file p_array.hh.
References mln::p_array< P >::nsites().
| const P & mln::p_array< P >::operator[] | ( | const util::index & | i | ) |  const [inline] | 
        
Return the i-th element.
Definition at line 391 of file p_array.hh.
References mln::p_array< P >::has().
| const P & mln::p_array< P >::operator[] | ( | unsigned | i | ) |  const [inline] | 
        
Return the i-th site (constant). 
Definition at line 454 of file p_array.hh.
References mln::p_array< P >::nsites().
| void mln::p_array< P >::reserve | ( | size_type | n | ) |  [inline] | 
        
Reserve n cells. 
Definition at line 354 of file p_array.hh.
Referenced by mln::convert::to_p_array().
| void mln::p_array< P >::resize | ( | size_t | size | ) |  [inline] | 
        
Update the size of this array.
Definition at line 445 of file p_array.hh.
| const std::vector< P > & mln::p_array< P >::std_vector | ( | ) |  const [inline] | 
        
Return the corresponding std::vector of points.
Definition at line 489 of file p_array.hh.
Referenced by mln::p_array< P >::append().
 1.7.1