#include <FMArrayPointer.h>
Inheritance diagram for fm::pvector< T >:
Public Types | |
typedef fm::vector< const void *, true > | Parent |
Defines the parent class to the pointer array. | |
typedef T * | item |
Defines the item pointer type contained by the pointer array. | |
typedef const T * | const_item |
Defines the constant-version of the item pointer type contained by the pointer array. | |
typedef item * | iterator |
Defines the item pointer iterator for the pointer array. | |
typedef const_item * | const_iterator |
Defines the constant-version of the item pointer iterator for the pointer array. | |
Public Member Functions | |
pvector () | |
Default constructor. | |
pvector (size_t size) | |
Constructor. | |
pvector (size_t size, const T &defaultValue) | |
Constructor. | |
pvector (const pvector< T > ©) | |
Copy constructor. | |
pvector (const T **values, size_t count) | |
Constructor. | |
~pvector () | |
Destructor. | |
T *& | front () |
Retrieves the first element of the pointer array. | |
const T *& | front () const |
See above. | |
T *& | back () |
Retrieves the last element of the pointer array. | |
const T *& | back () const |
See above. | |
T *& | at (size_t index) |
Retrieves an indexed object in the pointer array. | |
const T *& | at (size_t index) const |
See above. | |
template<class INTEGER> | |
T *& | operator[] (INTEGER index) |
See above. | |
template<class INTEGER> | |
const T *& | operator[] (INTEGER index) const |
See above. | |
iterator | begin () |
Retrieves an iterator for the first element in the pointer array. | |
const_iterator | begin () const |
See above. | |
iterator | end () |
Retrieves an iterator for the element after the last element in the pointer array. | |
const_iterator | end () const |
See above. | |
iterator | find (const T *item) |
Retrieves an iterator for a given element in the pointer array. | |
const_iterator | find (const T *item) const |
See above. | |
iterator | insert (iterator _iterator, T *object) |
Inserts an object in the container's containment pointer array. | |
void | insert (iterator _iterator, size_t count) |
Adds a given number of NULL pointers at a given position in the pointer array. | |
template<class _It> | |
void | insert (iterator _where, _It _startIterator, _It _endIterator) |
Inserts a list of pointers in the pointer array. | |
iterator | erase (iterator _it) |
Removes the value at the given position within the pointer array. | |
bool | erase (const T *value) |
Removes a given pointer from the pointer array. | |
void | erase (iterator first, iterator last) |
Removes the value at the given position within the pointer array. | |
void | erase (size_t index) |
Removes an indexed value contained within the list. | |
bool | release (const T *value) |
Releases a value contained within a list. | |
pvector< T > & | operator= (const pvector< T > &other) |
Copy constructor. | |
void | resize (size_t count) |
Resizes the pointer array to the given amount. |
Built on top of the FCollada specialized vector class, this class improves on the compilation time and the library size by re-using the <void*> template only once for all pointer vectors.
|
Constructor. Builds a dynamically-sized pointer array of the desired size.
|
|
Constructor. Builds a dynamically-sized pointer array of the desired size.
|
|
Copy constructor.
|
|
Constructor. Builds a dynamically-sized pointer array from a constant-sized array.
|
|
Retrieves an indexed object in the pointer array.
Reimplemented from fm::vector< const void *, true >. Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Retrieves the last element of the pointer array.
Reimplemented from fm::vector< const void *, true >. Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Retrieves an iterator for the first element in the pointer array.
Reimplemented from fm::vector< const void *, true >. Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Retrieves an iterator for the element after the last element in the pointer array.
Reimplemented from fm::vector< const void *, true >. Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Removes an indexed value contained within the list.
Reimplemented from fm::vector< const void *, true >. Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Removes the value at the given position within the pointer array.
Reimplemented in FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Removes a given pointer from the pointer array.
Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Removes the value at the given position within the pointer array.
Reimplemented in FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Retrieves an iterator for a given element in the pointer array.
Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Retrieves the first element of the pointer array.
Reimplemented from fm::vector< const void *, true >. Reimplemented in FUObjectContainer< ObjectClass >, FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Inserts a list of pointers in the pointer array.
Reimplemented in FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Adds a given number of NULL pointers at a given position in the pointer array.
|
|
Inserts an object in the container's containment pointer array.
Reimplemented in FUTrackedList< ObjectClass >, FUObjectContainer< FUPlugin >, FUObjectContainer< FCDAnimated >, FUObjectContainer< FCDPlaceHolder >, and FUTrackedList< FCDEntityReference >. |
|
Copy constructor. Overwrites the current data of the pointer array with the data of the given pointer array.
|
|
Releases a value contained within a list. Use this function only if there is no duplicate pointers within the list.
Reimplemented in FUTrackedList< ObjectClass >, and FUTrackedList< FCDEntityReference >. |
|
Resizes the pointer array to the given amount. It is intentional that the default value is NULL.
Reimplemented from fm::vector< const void *, true >. |