Class that represents a list type (extends from std::vector). More...
#include <SPL/Runtime/Type/List.h>

Public Member Functions |
|
| list () | |
| list (typename list< T >::size_type n, const T &v=T()) | |
| list (const std::vector< T > &x) | |
| list (const list< T > &x) | |
| template<class InputIterator > | |
| list (InputIterator first, InputIterator last) | |
| list (const ConstValueHandle &o) | |
| template<class T2 > | |
| list (const list< T2 > &o) | |
| template<class T2 , int32_t msize> | |
| list (const blist< T2, msize > &o) | |
| list (const List &o) | |
| virtual | ~list () |
| std::vector< T >::const_reference | at (typename std::vector< T >::size_type idx) const |
| std::vector< T >::reference | at (typename std::vector< T >::size_type idx) |
| list< T > & | add (const T &v) |
| const list< T > & | operator= (const list< T > &o) |
| const list< T > & | operator= (const std::vector< T > &o) |
| bool | operator== (const list< T > &o) const |
| bool | operator!= (const list< T > &ov) const |
| template<class BufferType > | |
| void | serialize (ByteBuffer< BufferType > &buf) const |
| template<class BufferType > | |
| void | deserialize (ByteBuffer< BufferType > &buf) |
| void | serialize (std::ostream &ostr) const |
| void | serializeWithPrecision (std::ostream &ostr) const |
| void | deserialize (std::istream &istr, bool withSuffix=false) |
| void | deserializeWithNanAndInfs (std::istream &istr, bool withSuffix=false) |
| size_t | hashCode () const |
|
Reflective interfaces
|
|
| virtual bool | equals (const Collection &ot) const |
| virtual Collection * | clone () const |
| virtual void | assignFrom (const Collection &ot) |
| virtual void | swapWith (Collection &ot) |
| virtual Meta::Type | getElementMetaType () const |
| virtual ValueHandle | createElement () const |
| virtual int32_t | getSize () const |
| virtual ValueHandle | getElement (const size_t &i) |
| virtual ConstValueHandle | getElement (const size_t &i) const |
| virtual ValueHandle | getElement (const ConstListIterator &it) |
| virtual ConstValueHandle | getElement (const ConstListIterator &it) const |
| virtual void | insertElement (const ConstListIterator &it, const ConstValueHandle &v) |
| virtual void | removeElement (const ConstListIterator &it) |
| virtual void | removeAllElements () |
| virtual void | pushBack (const ConstValueHandle &v) |
| virtual void | popBack () |
| virtual size_t | getSerializedSize () const |
Public Member Functions inherited from SPL::List |
|
| virtual | ~List () |
| virtual ListIterator | getBeginIterator () |
| virtual ConstListIterator | getBeginIterator () const |
| virtual ListIterator | getEndIterator () |
| virtual ConstListIterator | getEndIterator () const |
| const List & | operator= (const List &ov) |
Public Member Functions inherited from SPL::Collection |
|
| virtual | ~Collection () |
| Destructor. |
|
Additional Inherited Members |
|
Public Attributes inherited from std::vector< T > |
|
| T | elements |
| STL member. |
|
Class that represents a list type (extends from std::vector).
|
inlineexplicit |
Construct using a value
| n | number of elements |
| v | value to use |
Construct from an STL vector
| x | STL vector to use |
Copy constructor
| x | list to construct from |
|
inline |
Construct from a sequence
| first | begin iterator, inclusive |
| last | end iterator, exclusive |
|
inline |
Construct from a value handle
| o | value handle to construct from |
Construct from an assignable list
| o | list to construct from |
|
inline |
Construct from an assignable blist
| o | list to construct from |
Construct from a reflective list
| o | reflective list to construct from |
|
inline |
Subscript the list (read-only)
| idx | element index |
| SPLRuntimeInvalidIndexException | exception if the index is out of range |
|
inline |
Subscript the list (read-write)
| idx | element index |
| SPLRuntimeInvalidIndexException | exception if the index is out of range |
Append to list
| v | Value to be added |
Assignment operator (from another list)
| o | list to assign from |
Assignment operator (from an STL vector)
| o | STL list to assign from |
Equality comparison
| o | list to compare with |
Non-equality comparison
| ov | list to compare with |
|
inline |
Serialize (binary)
| buf | byte buffer to use |
|
inline |
Deserialize (binary)
| buf | byte buffer to use |
|
virtual |
|
virtual |
Serialize (character), with maximum precision for floats
| ostr | output stream |
Implements SPL::Collection.
|
virtual |
Deserialize (character)
| istr | input stream |
| withSuffix | if true then consume suffix, otherwise (false) assume no suffix is present |
Implements SPL::Collection.
| void SPL::list< T >::deserializeWithNanAndInfs | ( | std::istream & | istr, |
| bool | withSuffix = false |
||
| ) |
Deserialize with Inf and Nan (character)
| istr | input stream |
| withSuffix | if true then consume suffix, otherwise (false) assume no suffix is present |
|
inlinevirtual |
|
inlinevirtual |
Compare with another collection
| ot | other collection to compare to |
Implements SPL::Collection.
|
inlinevirtual |
Create a clone of the collection object
Implements SPL::Collection.
|
inlinevirtual |
Assign this collection using another collection
| ot | other collection to assign from |
| SPLRuntimeTypeMismatchException | if the types do not match |
Implements SPL::Collection.
|
inlinevirtual |
Swap this collection with another collection
| ot | other collection to swap with |
| SPLRuntimeTypeMismatchException | if the types do not match |
Implements SPL::Collection.
|
inlinevirtual |
|
inlinevirtual |
Create a new element. The returned value handle is wrapper for an object allocated on the heap. As a result, the caller is responsible for cleaning up the memory by calling ValueHandle::deleteValue()
Implements SPL::List.
|
inlinevirtual |
|
inlinevirtual |
Get the element at a given index
| i | index of the element |
Implements SPL::List.
|
inlinevirtual |
Get the element at a given index
| i | index of the element |
Implements SPL::List.
|
inlinevirtual |
Get the element at a given position
| it | position of the element |
Implements SPL::List.
|
inlinevirtual |
Get the element at a given position
| it | position of the element |
Implements SPL::List.
|
inlinevirtual |
Insert a given element at a given index
| it | position of the element |
| v | element to insert |
Implements SPL::List.
|
inlinevirtual |
|
inlinevirtual |
Remove all elements
Implements SPL::List.
|
inlinevirtual |
Push a given element to the end of the list
| v | element to push back |
Implements SPL::List.
|
inlinevirtual |
Pop the last element from the end of the list
Implements SPL::List.
|
inlinevirtual |
Get the size in bytes when serialized
Implements SPL::Collection.