ug4
ug::Field< T > Class Template Reference

#include <field.h>

Public Member Functions

T & at (size_t x, size_t y)
 
const T & at (size_t x, size_t y) const
 
size_t capacity () const
 
void copy (size_t x, size_t y, const Field &f)
 
T * data ()
 
const T * data () const
 
 Field ()
 
 Field (const Field &f)
 
 Field (size_t width, size_t height)
 
 Field (size_t width, size_t height, const T &value)
 
void fill (size_t x, size_t y, size_t w, size_t h, const T &value)
 
void fill_all (const T &value)
 
size_t height () const
 
Fieldoperator= (const Field &field)
 
void resize_no_copy (size_t width, size_t height)
 
size_t size () const
 
void swap (Field &f)
 
size_t width () const
 
 ~Field ()
 

Private Member Functions

size_t array_index (size_t x, size_t y) const
 
template<class Archive >
void load (Archive &ar, const unsigned int version)
 
template<class Archive >
void save (Archive &ar, const unsigned int version) const
 

Private Attributes

size_t m_capacity
 
T * m_data
 
size_t m_height
 
size_t m_width
 

Friends

class boost::serialization::access
 

Constructor & Destructor Documentation

◆ Field() [1/4]

template<class T >
ug::Field< T >::Field

◆ Field() [2/4]

template<class T >
ug::Field< T >::Field ( size_t  width,
size_t  height 
)

◆ Field() [3/4]

template<class T >
ug::Field< T >::Field ( size_t  width,
size_t  height,
const T &  value 
)

◆ Field() [4/4]

template<class T >
ug::Field< T >::Field ( const Field< T > &  f)

◆ ~Field()

template<class T >
ug::Field< T >::~Field

Member Function Documentation

◆ array_index()

template<class T >
size_t ug::Field< T >::array_index ( size_t  x,
size_t  y 
) const
inlineprivate

◆ at() [1/2]

◆ at() [2/2]

template<class T >
const T & ug::Field< T >::at ( size_t  x,
size_t  y 
) const
inline

◆ capacity()

template<class T >
size_t ug::Field< T >::capacity ( ) const
inline

◆ copy()

template<class T >
void ug::Field< T >::copy ( size_t  x,
size_t  y,
const Field< T > &  f 
)

◆ data() [1/2]

template<class T >
T* ug::Field< T >::data ( )
inline

◆ data() [2/2]

template<class T >
const T* ug::Field< T >::data ( ) const
inline

◆ fill()

template<class T >
void ug::Field< T >::fill ( size_t  x,
size_t  y,
size_t  w,
size_t  h,
const T &  value 
)

◆ fill_all()

template<class T >
void ug::Field< T >::fill_all ( const T &  value)

◆ height()

◆ load()

template<class T >
template<class Archive >
void ug::Field< T >::load ( Archive &  ar,
const unsigned int  version 
)
private

References s.

◆ operator=()

template<class T >
Field< T > & ug::Field< T >::operator= ( const Field< T > &  field)

◆ resize_no_copy()

template<class T >
void ug::Field< T >::resize_no_copy ( size_t  width,
size_t  height 
)

◆ save()

template<class T >
template<class Archive >
void ug::Field< T >::save ( Archive &  ar,
const unsigned int  version 
) const
private

References s.

◆ size()

template<class T >
size_t ug::Field< T >::size ( ) const
inline

◆ swap()

template<class T >
void ug::Field< T >::swap ( Field< T > &  f)

◆ width()

Friends And Related Function Documentation

◆ boost::serialization::access

template<class T >
friend class boost::serialization::access
friend

Member Data Documentation

◆ m_capacity

template<class T >
size_t ug::Field< T >::m_capacity
private

◆ m_data

template<class T >
T* ug::Field< T >::m_data
private

◆ m_height

template<class T >
size_t ug::Field< T >::m_height
private

◆ m_width

template<class T >
size_t ug::Field< T >::m_width
private

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