Blender V2.61 - r43446

gim_array< T > Class Template Reference

Very simple array container with fast access and simd memory. More...

#include <gim_array.h>

Inheritance diagram for gim_array< T >:
Inheritance graph
[legend]

List of all members.

Public Member Functions

void destroyData ()
bool resizeData (GUINT newsize)
bool growingCheck ()
bool reserve (GUINT size)
void clear_range (GUINT start_range)
void clear ()
void clear_memory ()
 gim_array ()
 gim_array (GUINT reservesize)
 ~gim_array ()
GUINT size () const
GUINT max_size () const
T & operator[] (size_t i)
const T & operator[] (size_t i) const
T * pointer ()
const T * pointer () const
T * get_pointer_at (GUINT i)
const T * get_pointer_at (GUINT i) const
T & at (GUINT i)
const T & at (GUINT i) const
T & front ()
const T & front () const
T & back ()
const T & back () const
void swap (GUINT i, GUINT j)
void push_back (const T &obj)
void push_back_mem ()
 Simply increase the m_size, doesn't call the new element constructor.
void push_back_memcpy (const T &obj)
void pop_back ()
void pop_back_mem ()
 Simply decrease the m_size, doesn't call the deleted element destructor.
void erase (GUINT index)
 fast erase
void erase_sorted_mem (GUINT index)
void erase_sorted (GUINT index)
void insert_mem (GUINT index)
void insert (const T &obj, GUINT index)
void resize (GUINT size, bool call_constructor=true)
void refit ()

Public Attributes

T * m_data
GUINT m_size
GUINT m_allocated_size

Detailed Description

template<typename T>
class gim_array< T >

Very simple array container with fast access and simd memory.

Definition at line 43 of file gim_array.h.


Constructor & Destructor Documentation

template<typename T>
gim_array< T >::gim_array ( ) [inline]

public operations

Definition at line 123 of file gim_array.h.

template<typename T>
gim_array< T >::gim_array ( GUINT  reservesize) [inline]

public operations

Definition at line 130 of file gim_array.h.

template<typename T>
gim_array< T >::~gim_array ( ) [inline]

public operations

Definition at line 139 of file gim_array.h.


Member Function Documentation

template<typename T>
T& gim_array< T >::at ( GUINT  i) [inline]

public operations

Definition at line 178 of file gim_array.h.

template<typename T>
const T& gim_array< T >::at ( GUINT  i) const [inline]

public operations

Definition at line 183 of file gim_array.h.

template<typename T>
T& gim_array< T >::back ( ) [inline]
template<typename T>
const T& gim_array< T >::back ( ) const [inline]

public operations

Definition at line 203 of file gim_array.h.

template<typename T>
void gim_array< T >::clear ( ) [inline]

public operations

Definition at line 111 of file gim_array.h.

Referenced by gim_hash_table< T >::clear(), gim_array< GIM_CONTACT >::clear_memory(), and GIM_BOX_TREE::clearNodes().

template<typename T>
void gim_array< T >::clear_memory ( ) [inline]

public operations

Definition at line 117 of file gim_array.h.

Referenced by gim_array< GIM_CONTACT >::~gim_array().

template<typename T>
void gim_array< T >::clear_range ( GUINT  start_range) [inline]

public operations

Definition at line 103 of file gim_array.h.

Referenced by gim_array< GIM_CONTACT >::clear(), and gim_array< GIM_CONTACT >::resize().

template<typename T>
void gim_array< T >::destroyData ( ) [inline]

protected operations

Definition at line 55 of file gim_array.h.

Referenced by gim_array< GIM_CONTACT >::clear_memory(), and gim_array< GIM_CONTACT >::resizeData().

template<typename T>
void gim_array< T >::erase ( GUINT  index) [inline]

fast erase

Definition at line 248 of file gim_array.h.

Referenced by gim_hash_table< T >::_erase_unsorted().

template<typename T>
void gim_array< T >::erase_sorted ( GUINT  index) [inline]

public operations

Definition at line 266 of file gim_array.h.

Referenced by gim_hash_table< T >::_erase_sorted().

template<typename T>
void gim_array< T >::erase_sorted_mem ( GUINT  index) [inline]

public operations

Definition at line 257 of file gim_array.h.

Referenced by gim_array< GIM_CONTACT >::erase_sorted().

template<typename T>
T& gim_array< T >::front ( ) [inline]

public operations

Definition at line 188 of file gim_array.h.

template<typename T>
const T& gim_array< T >::front ( ) const [inline]

public operations

Definition at line 193 of file gim_array.h.

template<typename T>
T* gim_array< T >::get_pointer_at ( GUINT  i) [inline]

public operations

Definition at line 168 of file gim_array.h.

template<typename T>
const T* gim_array< T >::get_pointer_at ( GUINT  i) const [inline]

public operations

Definition at line 173 of file gim_array.h.

template<typename T>
bool gim_array< T >::growingCheck ( ) [inline]
template<typename T>
void gim_array< T >::insert ( const T &  obj,
GUINT  index 
) [inline]

public operations

Definition at line 282 of file gim_array.h.

Referenced by gim_hash_table< T >::_insert_in_pos().

template<typename T>
void gim_array< T >::insert_mem ( GUINT  index) [inline]

public operations

Definition at line 272 of file gim_array.h.

Referenced by gim_array< GIM_CONTACT >::insert().

template<typename T>
GUINT gim_array< T >::max_size ( ) const [inline]

public operations

Definition at line 149 of file gim_array.h.

template<typename T>
T& gim_array< T >::operator[] ( size_t  i) [inline]

public operations

Definition at line 154 of file gim_array.h.

template<typename T>
const T& gim_array< T >::operator[] ( size_t  i) const [inline]

public operations

Definition at line 158 of file gim_array.h.

template<typename T>
T* gim_array< T >::pointer ( ) [inline]
template<typename T>
const T* gim_array< T >::pointer ( ) const [inline]

public operations

Definition at line 164 of file gim_array.h.

template<typename T>
void gim_array< T >::pop_back ( ) [inline]
template<typename T>
void gim_array< T >::pop_back_mem ( ) [inline]

Simply decrease the m_size, doesn't call the deleted element destructor.

Definition at line 242 of file gim_array.h.

template<typename T>
void gim_array< T >::push_back ( const T &  obj) [inline]
template<typename T>
void gim_array< T >::push_back_mem ( ) [inline]

Simply increase the m_size, doesn't call the new element constructor.

Definition at line 222 of file gim_array.h.

template<typename T>
void gim_array< T >::push_back_memcpy ( const T &  obj) [inline]

public operations

Definition at line 228 of file gim_array.h.

template<typename T>
void gim_array< T >::refit ( ) [inline]

public operations

Definition at line 315 of file gim_array.h.

template<typename T>
bool gim_array< T >::reserve ( GUINT  size) [inline]
template<typename T>
void gim_array< T >::resize ( GUINT  size,
bool  call_constructor = true 
) [inline]
template<typename T>
bool gim_array< T >::resizeData ( GUINT  newsize) [inline]
template<typename T>
GUINT gim_array< T >::size ( ) const [inline]
template<typename T>
void gim_array< T >::swap ( GUINT  i,
GUINT  j 
) [inline]

public operations

Definition at line 209 of file gim_array.h.

Referenced by GIM_BOX_TREE::_sort_and_calc_splitting_index(), and gim_array< GIM_CONTACT >::erase().


Member Data Documentation

template<typename T>
GUINT gim_array< T >::m_allocated_size
template<typename T>
T* gim_array< T >::m_data
template<typename T>
GUINT gim_array< T >::m_size

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