This class is used to abstract away knowledge of the cache data used for each node.
More...
|
| | VdfVector (const VdfVector &rhs) |
| | Copy constructor.
|
| |
| | VdfVector (const VdfVector &rhs, const VdfMask &mask) |
| | Copy constructor with subset copying.
|
| |
| | VdfVector (const VdfVector &rhs, const VdfMask &mask, ConstructBoxedCopyTag) |
| |
| | VdfVector (const VdfVector &rhs, size_t size) |
| | Construct a vector with the same element type as rhs and of size size.
|
| |
| | VdfVector (VdfVector &&rhs) |
| | Move constructor.
|
| |
| | ~VdfVector () |
| | Destructor.
|
| |
| size_t | GetSize () const |
| | Returns the number of elements held in this vector.
|
| |
| bool | IsEmpty () const |
| | Returns whether or not this vector is empty.
|
| |
| size_t | GetNumStoredElements () const |
| | Returns the number of elements for which this vector has storage.
|
| |
| template<typename TYPE > |
| void | Set (TYPE &&data) |
| | Forwards data into the vector.
|
| |
| template<typename TYPE > |
| void | Set (const Vdf_BoxedContainer< TYPE > &data) |
| | Copy boxed values into the vector.
|
| |
| template<typename TYPE > |
| void | Set (Vdf_BoxedContainer< TYPE > &data) |
| |
| template<typename TYPE > |
| void | Set (const Vdf_BoxedContainer< TYPE > &&data) |
| |
| template<typename TYPE > |
| void | Set (Vdf_BoxedContainer< TYPE > &&data) |
| | Move boxed values into the vector.
|
| |
| template<typename TYPE > |
| void | Resize (size_t size) |
| | Allocates space for size number of elements.
|
| |
| template<typename TYPE > |
| void | Resize (const VdfMask::Bits &bits) |
| | Allocates space for the elements denoted by bits.
|
| |
| void | Copy (const VdfVector &rhs, const VdfMask &mask) |
| | Copies the contents of rhs into this vector.
|
| |
| VDF_API void | Merge (const VdfVector &rhs, const VdfMask::Bits &bits) |
| | Merges the contents of rhs into this vector.
|
| |
| void | Merge (const VdfVector &rhs, const VdfMask &mask) |
| | Same as Merge(), but takes a VdfMask instead of a bitset.
|
| |
| bool | Share () const |
| | Embeds the current vector's existing implementaion into a reference counted implementaion so that the data can be shared without copying.
|
| |
| bool | IsShared () const |
| | Returns true if the vector has been shared.
|
| |
| bool | IsSharable () const |
| | Returns true if the vector can be shared.
|
| |
| template<typename T > |
| VtArray< T > | ExtractAsVtArray (const size_t size, const int offset) const |
| | Extracts this vector's values into a VtArray<T>.
|
| |
| template<typename TYPE > |
| ReadWriteAccessor< TYPE > | GetReadWriteAccessor () const |
| | GetReadWriteAccessor() allows low level access to the content of the VdfVector via the Vdf_VectorData base class.
|
| |
| template<typename TYPE > |
| ReadAccessor< TYPE > | GetReadAccessor () const |
| | GetReadAccessor() allows low level read-only access to the content of of the VdfVector via the Vdf_VectorData base class.
|
| |
| template<typename TYPE > |
| Vdf_VectorSubrangeAccessor< TYPE > | GetSubrangeAccessor () const |
| | Provide read-only access to the boxed subranges held by this vector.
|
| |
| template<typename TYPE > |
| bool | Holds () const |
| | Checks if a vector holds a specific type.
|
| |
| VdfVector & | operator= (const VdfVector &rhs) |
| | Copies the content of rhs into this vector.
|
| |
| VdfVector & | operator= (VdfVector &&rhs) |
| | Moves the content of rhs into this vector.
|
| |
| size_t | EstimateElementMemory () const |
| | Returns the number of bytes necessary to store a single element of this VdfVector.
|
| |
| DebugPrintable | GetDebugPrintable (const VdfMask &mask) const |
| | Returns an ostream-able object, which can be used to debug print the contents of this VdfVector, filtered by mask.
|
| |
This class is used to abstract away knowledge of the cache data used for each node.
Note that data can be put into a VdfVector only atomically, no incremental adding of elements is possible.
Note that Vdf requires the availability of the default and copy constructor for the given template parameter TYPE. Additional Vdf provides default fallback values via the VdfExecutionTypeRegistry. That is to give types the ability to have empty default constructors (for speed) but at the same time have well definied values to use in case we need to provide a "default".
Definition at line 55 of file vector.h.
Embeds the current vector's existing implementaion into a reference counted implementaion so that the data can be shared without copying.
Mutating the contents of the data holder once shared will cause detachment. Returns true if the sharing was successful.
Note: This method is not thread safe.
Definition at line 327 of file vector.h.