|
SLIP
1.4
|
This is container to handle a pyramid of containers. More...
#include <Pyramid.hpp>
Public Types | |
| typedef Container | value_type |
| typedef Pyramid< Container > | self |
| typedef const Pyramid< Container > | const_self |
| typedef value_type & | reference |
| typedef value_type const & | const_reference |
| typedef value_type * | pointer |
| typedef value_type const * | const_pointer |
| typedef ptrdiff_t | difference_type |
| typedef std::size_t | size_type |
| typedef pointer | iterator |
| typedef const_pointer | const_iterator |
Public Member Functions | |
| size_type | size () const |
| Returns the number of containers in the Pyramid. More... | |
| size_type | max_size () const |
| Returns the maximal size (number of container) in the Pyramid. More... | |
| bool | empty () const |
| Returns true if the Pyramid is empty. (Thus size() == 0) More... | |
| void | swap (self &rhs) |
| Swaps data with another Pyramid. More... | |
| void | fill (const typename Container::value_type &val) |
| Fill all the container of the Pyramid with val. More... | |
Constructors & Destructors | |
| Pyramid () | |
| Constructs a Pyramid with no data and zero levels. More... | |
| template<typename Iterator > | |
| Pyramid (Iterator init_container_first, Iterator init_container_last, const size_type levels) | |
| Constructs a Pyramid of levels level and copy the finest level (0 level) with the range [init_container_first, init_container_last). All other levels are initialized with the default constructor of the Container elements. More... | |
| Pyramid (const self &rhs) | |
| Constructs a copy of the Pyramid rhs. More... | |
| ~Pyramid () | |
| Destructor of the Pyramid. More... | |
Assignment operators | |
| self & | operator= (const self &rhs) |
| Assigns rhs to the Pyramid. More... | |
Accessors | |
| size_type | levels () const |
| const slip::Array< size_type > & | base_size () const |
Element access operators | |
| reference | operator[] (const size_type n) |
| Subscript access to the data contained in the Pyramid. More... | |
| const_reference | operator[] (const size_type n) const |
| Subscript access to the data contained in the Pyramid. More... | |
Friends | |
| class | boost::serialization::access |
i/o operators | |
| std::ostream & | operator<< (std::ostream &out, const self &a) |
| Write the Pyramid to the ouput stream. More... | |
Comparison operators | |
| bool | operator== (const Array< Container > &x, const Array< Container > &y) |
| Array equality comparison More... | |
| bool | operator!= (const Array< Container > &x, const Array< Container > &y) |
| Array inequality comparison More... | |
This is container to handle a pyramid of containers.
| Container | Type of the element in the Pyramid |
Definition at line 485 of file Pyramid.hpp.
| typedef const_pointer slip::Pyramid< Container >::const_iterator |
Definition at line 529 of file Pyramid.hpp.
| typedef value_type const* slip::Pyramid< Container >::const_pointer |
Definition at line 522 of file Pyramid.hpp.
| typedef value_type const& slip::Pyramid< Container >::const_reference |
Definition at line 519 of file Pyramid.hpp.
| typedef const Pyramid<Container> slip::Pyramid< Container >::const_self |
Definition at line 516 of file Pyramid.hpp.
| typedef ptrdiff_t slip::Pyramid< Container >::difference_type |
Definition at line 525 of file Pyramid.hpp.
| typedef pointer slip::Pyramid< Container >::iterator |
Definition at line 528 of file Pyramid.hpp.
| typedef value_type* slip::Pyramid< Container >::pointer |
Definition at line 521 of file Pyramid.hpp.
| typedef value_type& slip::Pyramid< Container >::reference |
Definition at line 518 of file Pyramid.hpp.
| typedef Pyramid<Container> slip::Pyramid< Container >::self |
Definition at line 515 of file Pyramid.hpp.
| typedef std::size_t slip::Pyramid< Container >::size_type |
Definition at line 526 of file Pyramid.hpp.
| typedef Container slip::Pyramid< Container >::value_type |
Definition at line 514 of file Pyramid.hpp.
|
inline |
Constructs a Pyramid with no data and zero levels.
Definition at line 539 of file Pyramid.hpp.
|
inline |
Constructs a Pyramid of levels level and copy the finest level (0 level) with the range [init_container_first, init_container_last). All other levels are initialized with the default constructor of the Container elements.
| init_container_first | initial container |
| init_container_last | initial container |
| levels |
Definition at line 567 of file Pyramid.hpp.
|
inline |
Constructs a copy of the Pyramid rhs.
Definition at line 597 of file Pyramid.hpp.
|
inline |
Destructor of the Pyramid.
Definition at line 613 of file Pyramid.hpp.
|
inline |
Definition at line 665 of file Pyramid.hpp.
|
inline |
Returns true if the Pyramid is empty. (Thus size() == 0)
Definition at line 744 of file Pyramid.hpp.
|
inline |
Fill all the container of the Pyramid with val.
| val | Value to fill |
Definition at line 766 of file Pyramid.hpp.
|
inline |
Definition at line 660 of file Pyramid.hpp.
|
inline |
Returns the maximal size (number of container) in the Pyramid.
Definition at line 736 of file Pyramid.hpp.
|
inline |
Assigns rhs to the Pyramid.
| rhs | Pyramid to get the values from. |
Definition at line 631 of file Pyramid.hpp.
|
inline |
Subscript access to the data contained in the Pyramid.
| n | The index of the element for which data should be accessed. |
This operator allows for easy, array-style, data access. Note that data access with this operator is unchecked and out_of_range lookups are not defined.
Definition at line 687 of file Pyramid.hpp.
|
inline |
Subscript access to the data contained in the Pyramid.
| n | The index of the element for which data should be accessed. |
This operator allows for easy, array-style, data access. Note that data access with this operator is unchecked and out_of_range lookups are not defined.
Definition at line 705 of file Pyramid.hpp.
|
inline |
Returns the number of containers in the Pyramid.
Definition at line 729 of file Pyramid.hpp.
|
inline |
Swaps data with another Pyramid.
| rhs | A Pyramid of the same element type |
Definition at line 753 of file Pyramid.hpp.
|
friend |
Definition at line 819 of file Pyramid.hpp.
|
friend |
Array inequality comparison
| x | A Array |
| y | A Array of the same type of x |
|
friend |
Write the Pyramid to the ouput stream.
| out | output std::ostream |
| a | Pyramid to write to the output stream |
Definition at line 868 of file Pyramid.hpp.
|
friend |
Array equality comparison
| x | A Array |
| y | A Array of the same type of x |
1.8.6