![]() |
Exiv2
|
#include <slice.hpp>

Public Types | |
| typedef const T *::iterator | iterator |
| typedef const T *::const_iterator | const_iterator |
| typedef Internal::remove_cv< typenamecontainer::value_type >::type | value_type |
| Public Types inherited from Exiv2::Internal::MutableSliceBase< storage_type, data_type > | |
| typedef ConstSliceBase< storage_type, data_type >::iterator | iterator |
| typedef ConstSliceBase< storage_type, data_type >::const_iterator | const_iterator |
| typedef ConstSliceBase< storage_type, data_type >::value_type | value_type |
| Public Types inherited from Exiv2::Internal::ConstSliceBase< storage_type, data_type > | |
| typedef storage_type< data_type >::iterator | iterator |
| typedef storage_type< data_type >::const_iterator | const_iterator |
| typedef storage_type< data_type >::value_type | value_type |
| Public Types inherited from Exiv2::Internal::ConstSliceBase< Internal::PtrSliceStorage, const T * > | |
| typedef Internal::PtrSliceStorage< const T * >::iterator | iterator |
| typedef Internal::PtrSliceStorage< const T * >::const_iterator | const_iterator |
| typedef Internal::PtrSliceStorage< const T * >::value_type | value_type |
Public Member Functions | |
| Slice (const T *ptr, size_t begin, size_t end) | |
| Slice< const T * > | subSlice (size_t begin, size_t end) const |
| Public Member Functions inherited from Exiv2::Internal::MutableSliceBase< storage_type, data_type > | |
| MutableSliceBase (data_type &data, size_t begin, size_t end) | |
| value_type & | at (size_t index) |
| const value_type & | at (size_t index) const |
| iterator | begin () throw () |
| iterator | end () throw () |
| Public Member Functions inherited from Exiv2::Internal::ConstSliceBase< storage_type, data_type > | |
| ConstSliceBase (data_type &data, size_t begin, size_t end) | |
| const value_type & | at (size_t index) const |
| const_iterator | cbegin () const throw () |
| const_iterator | cend () const throw () |
| template<typename slice_type> | |
| slice_type | subSlice (size_t begin, size_t end) const |
| Public Member Functions inherited from Exiv2::Internal::SliceBase | |
| SliceBase (size_t begin, size_t end) | |
| size_t | size () const throw () |
| Public Member Functions inherited from Exiv2::Internal::ConstSliceBase< Internal::PtrSliceStorage, const T * > | |
| ConstSliceBase (const T *&data, size_t begin, size_t end) | |
| const value_type & | at (size_t index) const |
| const_iterator | cbegin () const throw () |
| const_iterator | cend () const throw () |
| slice_type | subSlice (size_t begin, size_t end) const |
Additional Inherited Members | |
| Protected Member Functions inherited from Exiv2::Internal::MutableSliceBase< storage_type, data_type > | |
| template<typename slice_type> | |
| slice_type | subSlice (size_t begin, size_t end) |
| Protected Member Functions inherited from Exiv2::Internal::SliceBase | |
| void | rangeCheck (size_t index) const |
| Protected Attributes inherited from Exiv2::Internal::ConstSliceBase< storage_type, data_type > | |
| storage_type< data_type > | storage_ |
| Protected Attributes inherited from Exiv2::Internal::SliceBase | |
| const size_t | begin_ |
| const size_t | end_ |
| Protected Attributes inherited from Exiv2::Internal::ConstSliceBase< Internal::PtrSliceStorage, const T * > | |
| Internal::PtrSliceStorage< const T * > | storage_ |
Specialization of slices for constant C-arrays.
These have exactly the same interface as the slices for STL-containers, with the crucial exception, that the slice's constructor cannot make a proper bounds check! It can only verify that you didn't accidentally swap begin and end!
|
inline |
Constructor.
| [in] | ptr | C-array of which a slice should be constructed. Must not be a null pointer. |
| [in] | begin | Index of the first element in the slice. |
| [in] | end | Index of the first element that is no longer in the slice. |
Please note that the constructor has no way how to verify that begin and end are not out of bounds of the provided array!
References Exiv2::Internal::MutableSliceBase< storage_type, data_type >::begin(), Exiv2::Internal::ConstSliceBase< Internal::PtrSliceStorage, const T * >::ConstSliceBase(), and Exiv2::Internal::MutableSliceBase< storage_type, data_type >::end().