ITK
4.3.0
Insight Segmentation and Registration Toolkit
|
#include <itkNeighborhoodAllocator.h>
A memory allocator for use as the default allocator type in Neighborhood.
This is a memory allocator for use as the default allocator type in Neighborhood. The API is designed to mimic that of vnl_vector so that vnl_vector can also be used as an allocator for Neighborhood.
The decision to create this allocator with the vnl_vector api (versus using an STL allocator and wrapping the vnl_vector API) was made because the STL allocator API is not guaranteed stable at this time.
Definition at line 40 of file itkNeighborhoodAllocator.h.
Public Types | |
typedef const TPixel * | const_iterator |
typedef TPixel * | iterator |
typedef NeighborhoodAllocator | Self |
Public Member Functions | |
NeighborhoodAllocator () | |
bool | operator!= (const Self &other) const |
bool | operator== (const Self &other) const |
~NeighborhoodAllocator () | |
void | Allocate (unsigned int n) |
void | Deallocate () |
NeighborhoodAllocator (const Self &other) | |
const Self & | operator= (const Self &other) |
iterator | begin () |
const_iterator | begin () const |
iterator | end () |
const_iterator | end () const |
unsigned int | size () const |
const TPixel & | operator[] (unsigned int i) const |
TPixel & | operator[] (unsigned int i) |
void | set_size (unsigned int n) |
Protected Attributes | |
TPixel * | m_Data |
unsigned int | m_ElementCount |
typedef const TPixel* itk::NeighborhoodAllocator< TPixel >::const_iterator |
Definition at line 51 of file itkNeighborhoodAllocator.h.
typedef TPixel* itk::NeighborhoodAllocator< TPixel >::iterator |
Iterator support. Note that the naming of the typedefs is on purpose. itk::Neighborhood makes reference to the allocator, which because it may be vnl or other type, uses the lower case/underscore forms iterator and const_iterator.
Definition at line 50 of file itkNeighborhoodAllocator.h.
typedef NeighborhoodAllocator itk::NeighborhoodAllocator< TPixel >::Self |
Standard class typedefs.
Definition at line 44 of file itkNeighborhoodAllocator.h.
|
inline |
Default constructor
Definition at line 54 of file itkNeighborhoodAllocator.h.
|
inline |
Default destructor
Definition at line 57 of file itkNeighborhoodAllocator.h.
|
inline |
Copy constructor.
Definition at line 77 of file itkNeighborhoodAllocator.h.
|
inline |
Allocates memory using new()
Definition at line 61 of file itkNeighborhoodAllocator.h.
Referenced by itk::NeighborhoodAllocator< ScalarValueType >::set_size().
|
inline |
STL-style iterator support for the memory buffer.
Definition at line 114 of file itkNeighborhoodAllocator.h.
Referenced by itk::operator<<().
|
inline |
STL-style iterator support for the memory buffer.
Definition at line 116 of file itkNeighborhoodAllocator.h.
|
inline |
Deallocates memory using delete[]().
Definition at line 69 of file itkNeighborhoodAllocator.h.
Referenced by itk::NeighborhoodAllocator< ScalarValueType >::set_size(), and itk::NeighborhoodAllocator< ScalarValueType >::~NeighborhoodAllocator().
|
inline |
STL-style iterator support for the memory buffer.
Definition at line 118 of file itkNeighborhoodAllocator.h.
|
inline |
STL-style iterator support for the memory buffer.
Definition at line 120 of file itkNeighborhoodAllocator.h.
|
inline |
Not Equal operator.
Definition at line 108 of file itkNeighborhoodAllocator.h.
|
inline |
Assignment operator.
Definition at line 89 of file itkNeighborhoodAllocator.h.
|
inline |
Comparison operator.
Definition at line 102 of file itkNeighborhoodAllocator.h.
|
inline |
Data access methods
Definition at line 127 of file itkNeighborhoodAllocator.h.
Referenced by itk::NeighborhoodAllocator< ScalarValueType >::NeighborhoodAllocator(), and itk::NeighborhoodAllocator< ScalarValueType >::operator=().
|
inline |
Data access methods
Definition at line 129 of file itkNeighborhoodAllocator.h.
|
inline |
Allocates or Reallocates a buffer of size n
Definition at line 134 of file itkNeighborhoodAllocator.h.
Referenced by itk::NeighborhoodAllocator< ScalarValueType >::NeighborhoodAllocator(), and itk::NeighborhoodAllocator< ScalarValueType >::operator=().
|
inline |
STL-style iterator support for the memory buffer.
Definition at line 122 of file itkNeighborhoodAllocator.h.
Referenced by itk::operator<<().
|
protected |
Definition at line 143 of file itkNeighborhoodAllocator.h.
Referenced by itk::NeighborhoodAllocator< ScalarValueType >::Allocate(), itk::NeighborhoodAllocator< ScalarValueType >::begin(), itk::NeighborhoodAllocator< ScalarValueType >::Deallocate(), itk::NeighborhoodAllocator< ScalarValueType >::end(), itk::NeighborhoodAllocator< ScalarValueType >::operator!=(), itk::NeighborhoodAllocator< ScalarValueType >::operator==(), itk::NeighborhoodAllocator< ScalarValueType >::operator[](), and itk::NeighborhoodAllocator< ScalarValueType >::set_size().
|
protected |
Definition at line 142 of file itkNeighborhoodAllocator.h.
Referenced by itk::NeighborhoodAllocator< ScalarValueType >::Allocate(), itk::NeighborhoodAllocator< ScalarValueType >::Deallocate(), itk::NeighborhoodAllocator< ScalarValueType >::end(), itk::NeighborhoodAllocator< ScalarValueType >::NeighborhoodAllocator(), itk::NeighborhoodAllocator< ScalarValueType >::operator=(), and itk::NeighborhoodAllocator< ScalarValueType >::size().