Metafunction for generating ProxyVector storages. More...
#include <proxyVector.hpp>
Public Types | |
typedef container_t::const_pointer | const_pointer |
typedef container_t | container_type |
typedef container_t::pointer | pointer |
Public Member Functions | |
~ProxyVectorStorage () override | |
container_t * | container (bool forceCreation) |
const container_t * | container (bool forceCreation) const |
const_pointer | data () const override |
pointer | data () override |
bool | empty () const override |
void | resize (std::size_t size) override |
std::size_t | size () const override |
void | swap (ProxyVectorStorage &other) noexcept |
Protected Member Functions | |
ProxyVectorStorage (const ProxyVectorStorage &other) | |
ProxyVectorStorage (ProxyVectorStorage &&other)=default | |
ProxyVectorStorage (std::size_t size=0) | |
ProxyVectorStorage & | operator= (const ProxyVectorStorage &other) |
ProxyVectorStorage & | operator= (ProxyVectorStorage &&other)=default |
Friends | |
template<typename PXV_value_t , bool PXV_thread_safe> | |
class | ProxyVector |
Metafunction for generating ProxyVector storages.
value_t | is the type of the objects handled by the storage |
container_t | defines the type of container where the data is stored |
thread_safe | controls if it is safe to use the container in a multi-threaded code |
Definition at line 225 of file proxyVector.hpp.
typedef container_t::const_pointer bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::const_pointer |
Definition at line 235 of file proxyVector.hpp.
typedef container_t bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::container_type |
Definition at line 232 of file proxyVector.hpp.
typedef container_t::pointer bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::pointer |
Definition at line 234 of file proxyVector.hpp.
|
override |
Destructor.
Definition at line 398 of file proxyVector.tpp.
|
protected |
Constructor.
size | is the size of the storage expressed in number of elements. |
Definition at line 362 of file proxyVector.tpp.
|
protected |
Copy constructor.
other | is another storage of the same type (i.e., instantiated with the same template parameters) whose content is copied in this container. |
Definition at line 374 of file proxyVector.tpp.
container_t * bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::container | ( | bool | forceCreation | ) |
Get a reference to the data container associated with the storage.
forceCreation | if set to true and the storage is not associated with a container, an empty container will be created |
Definition at line 411 of file proxyVector.tpp.
const container_t * bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::container | ( | bool | forceCreation | ) | const |
Get a reference to the data container associated with the storage.
forceCreation | if set to true and the storage is not associated with a container, an empty container will be created |
Definition at line 428 of file proxyVector.tpp.
|
overridevirtual |
Return a constant pointer to the data.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 469 of file proxyVector.tpp.
|
overridevirtual |
Return a pointer to the data.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 454 of file proxyVector.tpp.
|
overridevirtual |
Check if the storage is empty.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 484 of file proxyVector.tpp.
|
protected |
Copy assigment operator.
other | is another storage of the same type (i.e., instantiated with the same template parameters) whose content is copied in this container. |
Definition at line 386 of file proxyVector.tpp.
|
overridevirtual |
Resize the storage.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 514 of file proxyVector.tpp.
|
overridevirtual |
Get the size of the storage expressed in number of elements.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 499 of file proxyVector.tpp.
|
noexcept |
Swaps the contents.
other | is another storage of the same type |
Definition at line 443 of file proxyVector.tpp.
|
friend |
Definition at line 229 of file proxyVector.hpp.