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 |
Detailed Description
class bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >
Metafunction for generating ProxyVector storages.
- Template Parameters
-
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 224 of file proxyVector.hpp.
Member Typedef Documentation
◆ const_pointer
typedef container_t::const_pointer bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::const_pointer |
Definition at line 234 of file proxyVector.hpp.
◆ container_type
typedef container_t bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::container_type |
Definition at line 231 of file proxyVector.hpp.
◆ pointer
typedef container_t::pointer bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::pointer |
Definition at line 233 of file proxyVector.hpp.
Constructor & Destructor Documentation
◆ ~ProxyVectorStorage()
|
override |
Destructor.
Definition at line 398 of file proxyVector.tpp.
◆ ProxyVectorStorage() [1/2]
|
protected |
Constructor.
- Parameters
-
size is the size of the storage expressed in number of elements.
Definition at line 362 of file proxyVector.tpp.
◆ ProxyVectorStorage() [2/2]
|
protected |
Copy constructor.
- Parameters
-
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.
Member Function Documentation
◆ container() [1/2]
container_t * bitpit::ProxyVectorStorage< value_t, container_t, thread_safe >::container | ( | bool | forceCreation | ) |
Get a reference to the data container associated with the storage.
- Parameters
-
forceCreation if set to true and the storage is not associated with a container, an empty container will be created
- Returns
- A reference to the data container associated with the storage.
Definition at line 411 of file proxyVector.tpp.
◆ container() [2/2]
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.
- Parameters
-
forceCreation if set to true and the storage is not associated with a container, an empty container will be created
- Returns
- A reference to the data container associated with the storage.
Definition at line 428 of file proxyVector.tpp.
◆ data() [1/2]
|
overridevirtual |
Return a constant pointer to the data.
- Returns
- A constant pointer to the data.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 469 of file proxyVector.tpp.
◆ data() [2/2]
|
overridevirtual |
Return a pointer to the data.
- Returns
- A pointer to the data.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 454 of file proxyVector.tpp.
◆ empty()
|
overridevirtual |
Check if the storage is empty.
- Returns
- Returns true if the storage is empty, false otherwise.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 484 of file proxyVector.tpp.
◆ operator=()
|
protected |
Copy assigment operator.
- Parameters
-
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.
◆ resize()
|
overridevirtual |
Resize the storage.
- Returns
- The size of the storage expressed in number of elements.
Implements bitpit::ProxyVectorStorageInterface< container_t::pointer, container_t::const_pointer >.
Definition at line 514 of file proxyVector.tpp.
◆ size()
|
overridevirtual |
Get the size of the storage expressed in number of elements.
- Returns
- 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.
◆ swap()
|
noexcept |
Swaps the contents.
- Parameters
-
other is another storage of the same type
Definition at line 443 of file proxyVector.tpp.
Friends And Related Symbol Documentation
◆ ProxyVector
|
friend |
Definition at line 228 of file proxyVector.hpp.
The documentation for this class was generated from the following files:
- src/containers/proxyVector.hpp
- src/containers/proxyVector.tpp
