FotoSHOCK
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
Public Types | Public Member Functions | List of all members
FotoSHOCKcore::FixedArray< T > Class Template Reference

Very simple implementation of a constant sized array with possibility for manual resize. More...

#include <FixedArray.hpp>

Public Types

typedef T value_type
 
typedef T * iterator
 
typedef const T * const_iterator
 
typedef T & reference
 
typedef const T & const_reference
 
typedef std::size_t size_type
 
typedef std::ptrdiff_t difference_type
 

Public Member Functions

 FixedArray (const size_type size)
 Create a new FixedArray. More...
 
 FixedArray (const FixedArray< value_type > &other)
 Copy constructor.
 
 ~FixedArray ()
 A destructor.
 
reference operator= (const_reference other)
 Assignment operator.
 
reference operator[] (size_type i)
 Array subscript operator. More...
 
const_reference operator[] (size_type i) const
 Array subscript operator. More...
 
size_type size () const
 Returns the size of a FixedArray object.
 

Detailed Description

template<typename T>
class FotoSHOCKcore::FixedArray< T >

Very simple implementation of a constant sized array with possibility for manual resize.

The FixedArray class is a simple wrapper around an ordinary array that stores the size of the array.

Template Parameters
Ttype stored in the FixedArray

Constructor & Destructor Documentation

template<typename T>
FotoSHOCKcore::FixedArray< T >::FixedArray ( const size_type  size)
inline

Create a new FixedArray.

The size of the FixedArray can't be changed later. If the size is <= 0, the created FixedArray is invalid and it cannot be used to hold content.

Member Function Documentation

template<typename T>
reference FotoSHOCKcore::FixedArray< T >::operator[] ( size_type  i)
inline

Array subscript operator.

Can be used only with arrays with non-zero size

template<typename T>
const_reference FotoSHOCKcore::FixedArray< T >::operator[] ( size_type  i) const
inline

Array subscript operator.

Can be used only with arrays with non-zero size


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