|
TECA
The Toolkit for Extreme Climate Analysis
|
The concrete implementation of our type agnostic container for contiguous arrays. More...
#include <teca_variant_array_impl.h>
Public Types | |
| using | element_type = T |
| using | pointer_type = std::shared_ptr< T > |
Public Types inherited from teca_variant_array | |
| using | allocator = hamr::buffer_allocator |
| allocator types More... | |
Public Member Functions | |
| int | set_allocator (allocator alloc) override |
| std::string | get_class_name () const override |
| Returns the name of the class in a human readable form. More... | |
| void | initialize () override |
| Initialize all elements with T() More... | |
| void | synchronize () const override |
| Sycnhronize the stream used for data movement. More... | |
| const T * | data () const |
| T * | data () |
| const std::shared_ptr< T > & | pointer () const |
| std::shared_ptr< T > & | pointer () |
| int | cuda_accessible () const noexcept override |
| returns true if the data is accessible from CUDA codes More... | |
| int | host_accessible () const noexcept override |
| returns true if the data is accessible from codes running on the CPU More... | |
| unsigned long | size () const noexcept override |
| Get the current size of the data. More... | |
| void | resize (unsigned long n) override |
| Resize the data. More... | |
| void | resize (unsigned long n, const T &val) |
| void | reserve (unsigned long n) override |
| Reserve space. More... | |
| void | clear () noexcept override |
| Clear the data. More... | |
| void | swap (const p_teca_variant_array &other) override |
| virtual swap More... | |
| bool | equal (const const_p_teca_variant_array &other) const override |
| virtual equivalence test More... | |
| int | to_stream (teca_binary_stream &s) const override |
| Serialize to the stream. More... | |
| int | from_stream (teca_binary_stream &s) override |
| Deserialize from the stream. More... | |
| int | to_stream (std::ostream &s) const override |
| Serialize to the stream. More... | |
| int | from_stream (std::ostream &s) override |
| Deserialize from the stream. More... | |
| template<typename U = T> | |
| void | debug_print (typename std::enable_if< std::is_arithmetic< U >::value >::type *=0) const |
| Print the contents of the buffer for debugging. More... | |
| template<typename U = T> | |
| void | debug_print (typename std::enable_if<!std::is_arithmetic< U >::value >::type *=0) const |
| Print the contents of the buffer for debugging. More... | |
| teca_variant_array::allocator | get_allocator () const |
| teca_variant_array_impl () | |
| default construct (the object is unusable) More... | |
| teca_variant_array_impl (allocator alloc) | |
| construct with a specific allocator More... | |
| teca_variant_array_impl (allocator alloc, size_t n_elem) | |
| construct with preallocated size More... | |
| teca_variant_array_impl (allocator alloc, size_t n_elem, const T &val) | |
| construct with preallocated size and initialized to a specific value More... | |
| template<typename U > | |
| teca_variant_array_impl (allocator alloc, size_t n_elem, const U *vals) | |
| construct with preallocated size and initialized to a specific value More... | |
| template<typename U > | |
| teca_variant_array_impl (allocator alloc, const const_p_teca_variant_array_impl< U > &other) | |
| copy construct from an instance of different type More... | |
| template<typename delete_func_t > | |
| teca_variant_array_impl (allocator alloc, size_t size, int owner, T *ptr, delete_func_t df) | |
| zero-copy construct by setting buffer contents directly More... | |
| template<typename U > | |
| p_teca_variant_array_impl< T > | New (size_t n, const U &v, allocator alloc) |
| template<typename U > | |
| p_teca_variant_array_impl< T > | New (size_t n, const U *v, allocator alloc) |
| template<typename delete_func_t > | |
| p_teca_variant_array_impl< T > | New (size_t n, T *ptr, allocator alloc, int owner, delete_func_t df) |
| virtual void | append (const const_p_teca_variant_array &src)=0 |
| virtual void | append (const p_teca_variant_array &src) |
| append the passed array. More... | |
| virtual void | append (const const_p_teca_variant_array &src, size_t src_start, size_t n_elem)=0 |
| append a subset of the passed array More... | |
| virtual void | append (const p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| append a subset of the passed array More... | |
| template<typename T > | |
| void | append (const T &val) |
| append a single value. this array is extended as needed. More... | |
| template<typename T > | |
| void | append (const std::vector< T > &src) |
| template<typename T > | |
| void | append (const T *src, size_t src_start, size_t n_elem) |
| virtual void | assign (const const_p_teca_variant_array &src)=0 |
| virtual void | assign (const p_teca_variant_array &src) |
| assign the contents from the other array. More... | |
| virtual void | assign (const const_p_teca_variant_array &src, size_t src_start, size_t n_elem)=0 |
| assign a subset of the other array More... | |
| virtual void | assign (const p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| assign a subset of the other array More... | |
| template<typename T > | |
| void | assign (const std::vector< T > &src) |
| assign the contents from a vector of values. this array is resized as needed. More... | |
| template<typename T > | |
| void | assign (const T *src, size_t src_start, size_t n_elem) |
| assign the contents from a passed array. this array is resized as needed. More... | |
| virtual void | copy (const const_p_teca_variant_array &src) |
| copy the contents from the other array. More... | |
| virtual void | copy (const p_teca_variant_array &src) |
| copy the contents from the other array. More... | |
| void | copy (const const_p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| copy a subset of the other array More... | |
| virtual void | set (const const_p_teca_variant_array &src)=0 |
| virtual void | set (const p_teca_variant_array &src) |
| Set from the other array. More... | |
| virtual void | set (size_t dest_start, const const_p_teca_variant_array &src, size_t src_start, size_t n_elem)=0 |
| virtual void | set (size_t dest_start, const p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| template<typename T > | |
| void | set (unsigned long i, const T &val) |
| set a single value More... | |
| template<typename T > | |
| void | set (const std::vector< T > &src) |
| set the contents from a vector of values. this array is not resized. More... | |
| template<typename T > | |
| void | set (size_t dest_start, const T *src, size_t src_start, size_t n_elem) |
| set a subset of the array from a passed array. this array is not resized. More... | |
| virtual void | get (const p_teca_variant_array &dest) const=0 |
| virtual void | get (size_t src_start, const p_teca_variant_array &dest, size_t dest_start, size_t n_elem) const=0 |
| template<typename T > | |
| void | get (unsigned long i, T &val) const |
| get a single value More... | |
| template<typename T > | |
| T | get (unsigned long i) const |
| get a single value More... | |
| template<typename T > | |
| void | get (std::vector< T > &vals) const |
| get the contents into the passed vector. The vector is resized as needed. More... | |
| template<typename T > | |
| void | get (size_t src_start, T *dest, size_t dest_start, size_t n_elem) const |
| get a subset of the contents into the passed in array. More... | |
get | |
Copy the content of this array. The desitination must be large enough to hold the results. These calls could throw teca_bad_cast if the passed in type is not castable to the internal type. | |
| template<typename U > | |
| void | get (size_t i, U &val) const |
| T | get (size_t i) const |
| get a single value More... | |
| template<typename U > | |
| void | get (std::vector< U > &dest) const |
| get a vector of values More... | |
| template<typename U > | |
| void | get (size_t src_start, U *dest, size_t dest_start, size_t n_elem) const |
| get a range of values More... | |
| void | get (const p_teca_variant_array &dest) const override |
| get the contents into the other array. More... | |
| void | get (size_t src_start, const p_teca_variant_array &dest, size_t dest_start, size_t n_elem) const override |
| template<typename U > | |
| void | get (const p_teca_variant_array_impl< U > &dest) const |
| get the contents into the other array. More... | |
| template<typename U > | |
| void | get (size_t src_start, const p_teca_variant_array_impl< U > &dest, size_t dest_start, size_t n_elem) const |
set | |
Assign values to this array. This array must already be large enough to hold the result. If automatic resizing is desired use copy instead. These calls could throw teca_bad_cast if the passed in type is not castable to the internal type. | |
| template<typename U > | |
| void | set (size_t i, const U &val) |
| template<typename U > | |
| void | set (const std::vector< U > &src) |
| set from a vector of values More... | |
| template<typename U > | |
| void | set (size_t dest_start, const U *src, size_t src_start, size_t n_elem) |
| void | set (const const_p_teca_variant_array &src) override |
| Set from the other array. More... | |
| void | set (size_t dest_start, const const_p_teca_variant_array &src, size_t src_start, size_t n_elem) override |
| template<typename U > | |
| void | set (const const_p_teca_variant_array_impl< U > &src) |
| Set from the other array. More... | |
| template<typename U > | |
| void | set (size_t dest_start, const const_p_teca_variant_array_impl< U > &src, size_t src_start, size_t n_elem) |
assign | |
assign the contents of the passed array to this array. This array will be resized to hold the results. These calls could throw teca_bad_cast if the passed in type is not castable to the internal type. | |
| template<typename U > | |
| void | assign (const std::vector< U > &src) |
| template<typename U > | |
| void | assign (const U *src, size_t src_start, size_t n_elem) |
| assign a subset from the other array More... | |
| void | assign (const const_p_teca_variant_array &src) override |
| assign the contents from the other array. More... | |
| void | assign (const const_p_teca_variant_array &src, size_t src_start, size_t n_elem) override |
| assign a subset of the other array More... | |
| template<typename U > | |
| void | assign (const const_p_teca_variant_array_impl< U > &src) |
| assign the contents from the other array. More... | |
| template<typename U > | |
| void | assign (const p_teca_variant_array_impl< U > &src) |
| assign the contents from the other array. More... | |
| template<typename U > | |
| void | assign (const const_p_teca_variant_array_impl< U > &src, size_t src_start, size_t n_elem) |
| assign a subset of the other array More... | |
| template<typename U > | |
| void | copy (const const_p_teca_variant_array_impl< U > &src) |
| copy the contents from the other array. More... | |
| template<typename U > | |
| void | copy (const const_p_teca_variant_array_impl< U > &src, size_t src_start, size_t n_elem) |
| copy a subset of the other array More... | |
append | |
Append data at the back of the array. These calls could throw teca_bad_cast if the passed in type is not castable to the internal type. | |
| template<typename U > | |
| void | append (const U &val) |
| template<typename U > | |
| void | append (const std::vector< U > &vals) |
| append a vector of values More... | |
| template<typename U > | |
| void | append (const U *src, size_t src_start, size_t n_elem) |
| append a range of values More... | |
| void | append (const const_p_teca_variant_array &src) override |
| void | append (const const_p_teca_variant_array &src, size_t src_start, size_t n_elem) override |
| append a subset of the passed array More... | |
| template<typename U > | |
| void | append (const const_p_teca_variant_array_impl< U > &src) |
| template<typename U > | |
| void | append (const p_teca_variant_array_impl< U > &src) |
| template<typename U > | |
| void | append (const const_p_teca_variant_array_impl< U > &src, size_t src_start, size_t n_elem) |
get_accessible | |
get's a pointer to the raw data that is accessible on the named accelerator device or technology. | |
| const std::shared_ptr< const T > | get_host_accessible () const |
| const std::shared_ptr< const T > | get_cuda_accessible () const |
| Get a pointer to the data accessible within CUDA. More... | |
Public Member Functions inherited from teca_variant_array | |
| teca_variant_array (const teca_variant_array &other)=delete | |
| teca_variant_array (teca_variant_array &&other)=delete | |
| teca_variant_array & | operator= (teca_variant_array &other)=delete |
| teca_variant_array & | operator= (teca_variant_array &&other)=delete |
| p_teca_variant_array | new_instance () const |
| p_teca_variant_array | new_instance (size_t n) const |
| p_teca_variant_array | new_copy () const |
| p_teca_variant_array | new_copy (size_t src_start, size_t n_elem) const |
| template<typename T > | |
| void | get (unsigned long i, T &val) const |
| get a single value More... | |
| template<typename T > | |
| T | get (unsigned long i) const |
| get a single value More... | |
| template<typename T > | |
| void | get (std::vector< T > &vals) const |
| get the contents into the passed vector. The vector is resized as needed. More... | |
| template<typename T > | |
| void | get (size_t src_start, T *dest, size_t dest_start, size_t n_elem) const |
| get a subset of the contents into the passed in array. More... | |
| virtual void | set (const p_teca_variant_array &src) |
| Set from the other array. More... | |
| virtual void | set (size_t dest_start, const p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| template<typename T > | |
| void | set (unsigned long i, const T &val) |
| set a single value More... | |
| template<typename T > | |
| void | set (const std::vector< T > &src) |
| set the contents from a vector of values. this array is not resized. More... | |
| template<typename T > | |
| void | set (size_t dest_start, const T *src, size_t src_start, size_t n_elem) |
| set a subset of the array from a passed array. this array is not resized. More... | |
| virtual void | assign (const p_teca_variant_array &src) |
| assign the contents from the other array. More... | |
| virtual void | assign (const p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| assign a subset of the other array More... | |
| template<typename T > | |
| void | assign (const std::vector< T > &src) |
| assign the contents from a vector of values. this array is resized as needed. More... | |
| template<typename T > | |
| void | assign (const T *src, size_t src_start, size_t n_elem) |
| assign the contents from a passed array. this array is resized as needed. More... | |
| virtual void | copy (const const_p_teca_variant_array &src) |
| copy the contents from the other array. More... | |
| virtual void | copy (const p_teca_variant_array &src) |
| copy the contents from the other array. More... | |
| void | copy (const const_p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| copy a subset of the other array More... | |
| virtual void | append (const p_teca_variant_array &src) |
| append the passed array. More... | |
| virtual void | append (const p_teca_variant_array &src, size_t src_start, size_t n_elem) |
| append a subset of the passed array More... | |
| template<typename T > | |
| void | append (const T &val) |
| append a single value. this array is extended as needed. More... | |
| template<typename T > | |
| void | append (const std::vector< T > &src) |
| template<typename T > | |
| void | append (const T *src, size_t src_start, size_t n_elem) |
Friends | |
| class | teca_variant_array |
Array constructors | |
| static std::shared_ptr< teca_variant_array_impl< T > > | New () |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (allocator alloc) |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n) |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n, allocator alloc) |
| template<typename U > | |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n, const U &v) |
| template<typename U > | |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n, const U &v, allocator alloc) |
| template<typename U > | |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n, const U *v) |
| template<typename U > | |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n, const U *v, allocator alloc) |
| template<typename delete_func_t > | |
| static std::shared_ptr< teca_variant_array_impl< T > > | New (size_t n, T *ptr, allocator alloc, int owner, delete_func_t df) |
| p_teca_variant_array | new_copy (allocator alloc=allocator::malloc) const override |
| Returns a new instance initialized with a deep copy of this one. More... | |
| p_teca_variant_array | new_copy (size_t src_start, size_t n_elem, allocator alloc) const override |
| p_teca_variant_array | new_instance (allocator alloc) const override |
| Returns a new instance of the same type. More... | |
| p_teca_variant_array | new_instance (size_t n, allocator alloc) const override |
| Returns a new instance of the same type sized to hold n elements. More... | |
The concrete implementation of our type agnostic container for contiguous arrays.
|
inline |
default construct (the object is unusable)
|
inline |
construct with a specific allocator
|
inline |
construct with preallocated size
|
inline |
construct with preallocated size and initialized to a specific value
|
inline |
construct with preallocated size and initialized to a specific value
|
inline |
copy construct from an instance of different type
|
inline |
zero-copy construct by setting buffer contents directly
|
inlineoverridevirtual |
append the passed array.
Implements teca_variant_array.
| virtual void teca_variant_array::append |
append the passed array.
|
inlineoverridevirtual |
append a subset of the passed array
Implements teca_variant_array.
| virtual void teca_variant_array::append |
append a subset of the passed array
|
inline |
append the passed array.
|
inline |
append a subset of the passed array
| void teca_variant_array::append | ( | typename T | ) |
Append the contents from a vector of values. this array is extended as needed.
|
inline |
append a vector of values
| void teca_variant_array::append | ( | typename T | ) |
append a single value. this array is extended as needed.
| void teca_variant_array::append | ( | typename T | ) |
Append the contents from a passed array. this array is extended as needed.
|
inline |
append a single value
|
inline |
append a range of values
|
inlineoverridevirtual |
assign the contents from the other array.
Implements teca_variant_array.
| virtual void teca_variant_array::assign |
assign the contents from the other array.
|
inlineoverridevirtual |
assign a subset of the other array
Implements teca_variant_array.
| virtual void teca_variant_array::assign |
assign a subset of the other array
|
inline |
assign the contents from the other array.
|
inline |
assign a subset of the other array
|
inline |
assign the contents from the other array.
|
inline |
assign a subset of the other array
|
inline |
assign the contents from the other array.
| void teca_variant_array::assign | ( | typename T | ) |
assign the contents from a vector of values. this array is resized as needed.
|
inline |
assign the contents from a vector of values
| void teca_variant_array::assign | ( | typename T | ) |
assign the contents from a passed array. this array is resized as needed.
|
inline |
assign a subset from the other array
|
overridevirtualnoexcept |
Clear the data.
Implements teca_variant_array.
|
inline |
copy the contents from the other array.
|
inline |
copy a subset of the other array
|
inline |
copy the contents from the other array.
|
inline |
copy a subset of the other array
|
inline |
copy the contents from the other array.
|
inlineoverridevirtualnoexcept |
returns true if the data is accessible from CUDA codes
Implements teca_variant_array.
|
inline |
direct access to the internal memory. Use this when you are certain that the data is already accessible in the location where you will access it to save the cost of the std::shared_ptr copy constructor.
|
inline |
direct access to the internal memory. Use this when you are certain that the data is already accessible in the location where you will access it to save the cost of the std::shared_ptr copy constructor.
|
inline |
Print the contents of the buffer for debugging.
|
inline |
Print the contents of the buffer for debugging.
|
overridevirtual |
virtual equivalence test
Implements teca_variant_array.
|
inlineoverridevirtual |
Deserialize from the stream.
Implements teca_variant_array.
|
inlineoverridevirtual |
Deserialize from the stream.
Implements teca_variant_array.
|
inlineoverridevirtual |
get the contents into the other array.
Implements teca_variant_array.
| virtual void teca_variant_array::get |
get the contents into the other array.
|
inline |
get the contents into the other array.
|
inline |
get a single value
|
inline |
get a single value
|
inlineoverridevirtual |
get a subset of the contents into a subset of the other array
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
Implements teca_variant_array.
| virtual void teca_variant_array::get |
get a subset of the contents into a subset of the other array
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
|
inline |
get a subset of the contents into a subset of the other array
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
| void teca_variant_array::get | ( | typename T | ) |
get a subset of the contents into the passed in array.
|
inline |
get a range of values
| void teca_variant_array::get | ( | typename T | ) |
get the contents into the passed vector. The vector is resized as needed.
|
inline |
get a vector of values
| T teca_variant_array::get | ( | typename T | ) |
get a single value
| void teca_variant_array::get | ( | typename T | ) |
get a single value
|
overridevirtual |
Returns the name of the class in a human readable form.
Implements teca_variant_array.
|
inline |
Get a pointer to the data accessible within CUDA.
|
inline |
Get a pointer to the data accessible on the CPU
|
inlineoverridevirtualnoexcept |
returns true if the data is accessible from codes running on the CPU
Implements teca_variant_array.
|
inlineoverridevirtual |
Initialize all elements with T()
Implements teca_variant_array.
|
inlinestatic |
Allocate an array. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
static |
Allocate an array. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
inlinestatic |
Allocates an array with space for n elements. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
static |
Allocates an array with space for n elements. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
inlinestatic |
Allocate an array with space for n elements initialized with v. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
static |
Allocate an array with space for n elements initialized with v. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
inlinestatic |
Allocate an array with space for n elements initialized with v. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
static |
Allocate an array with space for n elements initialized with v. The default value of alloc sets the array up for use on the CPU using C++ new to allocate memory to hold the contents.
|
static |
construct by directly providing the buffer contents. This can be used for zero-copy transfer of data. One must also name the allocator type and device owning the data. In addition for new allocations the allocator type and owner are used internally to know how to automatically move data during inter technology transfers.
| [in] | alloc | an ::allocator indicating the technology backing the pointer |
| [in] | size | the number of elements in the array pointed to by ptr |
| [in] | owner | the device owning the memory, -1 for CPU. if the allocator is a GPU allocator and -1 is passed the driver API is used to determine the device that allocated the memory. |
| [in] | ptr | a pointer to the data |
| [in] | df | a function void df(void*ptr) used to delete the data when this instance is finished using it. |
|
overridevirtual |
Returns a new instance initialized with a deep copy of this one.
Implements teca_variant_array.
|
overridevirtual |
virtual copy construct. return a newly allocated object, initialized copy from a subset of this.
Implements teca_variant_array.
|
overridevirtual |
Returns a new instance of the same type.
Implements teca_variant_array.
|
overridevirtual |
Returns a new instance of the same type sized to hold n elements.
Implements teca_variant_array.
|
inline |
direct access to the internal memory. Use this when you are certain that the data is already accessible in the location where you will access it.
|
inline |
direct access to the internal memory. Use this when you are certain that the data is already accessible in the location where you will access it.
|
overridevirtual |
Reserve space.
Implements teca_variant_array.
|
overridevirtual |
Resize the data.
Implements teca_variant_array.
|
inlineoverridevirtual |
Set from the other array.
Implements teca_variant_array.
| virtual void teca_variant_array::set |
Set from the other array
|
inline |
Set from the other array.
|
inline |
Set from the other array.
| void teca_variant_array::set | ( | typename T | ) |
set the contents from a vector of values. this array is not resized.
|
inline |
set from a vector of values
|
inlineoverridevirtual |
Set a subset of this array from a subset of the other array.
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
Implements teca_variant_array.
| virtual void teca_variant_array::set |
Set a subset of this array from a subset opf the contents of the other array.
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
|
inline |
Set a subset of this array from a subset of the other array.
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
|
inline |
Set a subset of this array from a subset opf the contents of the other array.
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
| void teca_variant_array::set | ( | typename T | ) |
set a subset of the array from a passed array. this array is not resized.
|
inline |
set from a subset of the other array
| [in] | dest_start | the first location to assign to |
| [in] | src | the array to copy values from |
| [in] | src_start | the first location to copy from |
| [in] | n_elem | the number of elements to copy |
|
inline |
set a single value
| void teca_variant_array::set | ( | typename T | ) |
set a single value
|
overridevirtual |
Set the allocator. If the passed allocator is already in use this is a NOOP. Otherwise the contents of the variant array are reallocated and moved using a buffer allocated with the passed allocator. This can be used to explicitly move the data.
| [in] | alloc | the new ::allocator to use |
Implements teca_variant_array.
|
overridevirtualnoexcept |
Get the current size of the data.
Implements teca_variant_array.
|
overridevirtual |
virtual swap
Implements teca_variant_array.
|
inlineoverridevirtual |
Sycnhronize the stream used for data movement.
Implements teca_variant_array.
|
inlineoverridevirtual |
Serialize to the stream.
Implements teca_variant_array.
|
inlineoverridevirtual |
Serialize to the stream.
Implements teca_variant_array.