#include <BaseStorage.hh>
Public Member Functions | |
BaseStoreWrapper (UStorePtr _store) | |
virtual | ~BaseStoreWrapper () |
virtual bool | Add (TPtr _object) |
Add given element. If the element has already been added or its name or ID conflict with other existing elements, then no work will be done. More... | |
virtual bool | Contains (ConstTPtr _object) const |
Determine if store contains the given element. More... | |
virtual bool | ContainsId (unsigned int _id) const |
Determine if store contains the element with the given ID. More... | |
virtual bool | ContainsName (const std::string &_name) const |
Determine if store contains the element with the given name. More... | |
virtual void | Destroy (TPtr _object) |
Remove and destroy given element. If the given element does not exists, in this store, then no work will be done. More... | |
virtual void | DestroyAll () |
Remove and destroy all elements in store. More... | |
virtual void | DestroyById (unsigned int _id) |
Remove and destroy element with the given ID. If the specified element does not exists in this store, then no work will be done. More... | |
virtual void | DestroyByIndex (unsigned int _index) |
Remove and destroy element at the given index. If the specified element does not exists in this store, then no work will be done. More... | |
virtual void | DestroyByName (const std::string &_name) |
Remove and destroy element with the given name. If the specified element does not exists in this store, then no work will be done. More... | |
virtual TPtr | GetById (unsigned int _id) const |
Get element with the given ID. More... | |
virtual TPtr | GetByIndex (unsigned int _index) const |
Get element at the given index. More... | |
virtual TPtr | GetByName (const std::string &_name) const |
Get element with the given name. More... | |
virtual TPtr | Remove (TPtr _object) |
Remove given element. If the given element does not exists in this store, then no work will be done. More... | |
virtual void | RemoveAll () |
Remove all elements from store. More... | |
virtual TPtr | RemoveById (unsigned int _id) |
Remove element with the given ID. If the specified element does not exists in this store, then no work will be done. More... | |
virtual TPtr | RemoveByIndex (unsigned int _index) |
Remove element at the given index. If the specified element does not exists in this store, then no work will be done. More... | |
virtual TPtr | RemoveByName (const std::string &_name) |
Remove element with the given name. If the specified element does not exists in this store, then no work will be done. More... | |
virtual unsigned int | Size () const |
Get number of elements in this store. More... | |
Public Member Functions inherited from StoreWrapper< T, U > | |
virtual | ~StoreWrapper ()=default |
Public Member Functions inherited from Store< T > | |
virtual | ~Store ()=default |
Destructor. More... | |
Protected Attributes | |
UStorePtr | store |
Constructor & Destructor Documentation
◆ BaseStoreWrapper()
|
explicit |
◆ ~BaseStoreWrapper()
|
virtual |
Member Function Documentation
◆ Add()
|
virtual |
Add given element. If the element has already been added or its name or ID conflict with other existing elements, then no work will be done.
- Parameters
-
[in] _object Element to be added
- Returns
- True if successful
Implements Store< T >.
◆ Contains()
|
virtual |
Determine if store contains the given element.
- Parameters
-
[in] _object The element in question
- Returns
- True if this store contains the given element
Implements Store< T >.
◆ ContainsId()
|
virtual |
Determine if store contains the element with the given ID.
- Parameters
-
[in] _id ID of the element in question
- Returns
- True if this store contains the specified element
Implements Store< T >.
◆ ContainsName()
|
virtual |
Determine if store contains the element with the given name.
- Parameters
-
[in] _name Name of the element in question
- Returns
- True if this store contains the specified element
Implements Store< T >.
◆ Destroy()
|
virtual |
Remove and destroy given element. If the given element does not exists, in this store, then no work will be done.
- Parameters
-
[in] _object Element to be removed
Implements Store< T >.
◆ DestroyAll()
|
virtual |
Remove and destroy all elements in store.
Implements Store< T >.
◆ DestroyById()
|
virtual |
Remove and destroy element with the given ID. If the specified element does not exists in this store, then no work will be done.
- Parameters
-
[in] _id ID of the element to be removed
Implements Store< T >.
◆ DestroyByIndex()
|
virtual |
Remove and destroy element at the given index. If the specified element does not exists in this store, then no work will be done.
- Parameters
-
[in] _index Index of the element to be removed
Implements Store< T >.
◆ DestroyByName()
|
virtual |
Remove and destroy element with the given name. If the specified element does not exists in this store, then no work will be done.
- Parameters
-
[in] _name Name of the element to be removed
Implements Store< T >.
◆ GetById()
|
virtual |
Get element with the given ID.
- Parameters
-
[in] _id ID of the desired element
- Returns
- The specified element
Implements Store< T >.
◆ GetByIndex()
|
virtual |
Get element at the given index.
- Parameters
-
[in] _index Index of the desired element
- Returns
- The specified element
Implements Store< T >.
◆ GetByName()
|
virtual |
Get element with the given name.
- Parameters
-
[in] _name Name of the desired element
- Returns
- The specified element
Implements Store< T >.
◆ Remove()
|
virtual |
Remove given element. If the given element does not exists in this store, then no work will be done.
- Parameters
-
[in] _object Element to be removed
- Returns
- The removed element
Implements Store< T >.
◆ RemoveAll()
|
virtual |
Remove all elements from store.
Implements Store< T >.
◆ RemoveById()
|
virtual |
Remove element with the given ID. If the specified element does not exists in this store, then no work will be done.
- Parameters
-
[in] _id ID of the element to be removed
- Returns
- The removed element
Implements Store< T >.
◆ RemoveByIndex()
|
virtual |
Remove element at the given index. If the specified element does not exists in this store, then no work will be done.
- Parameters
-
[in] _index Index of the element to be removed
- Returns
- The removed element
Implements Store< T >.
◆ RemoveByName()
|
virtual |
Remove element with the given name. If the specified element does not exists in this store, then no work will be done.
- Parameters
-
[in] _name Name of the element to be removed
- Returns
- The removed element
Implements Store< T >.
◆ Size()
|
virtual |
Get number of elements in this store.
- Returns
- The number of elements in this store
Implements Store< T >.
Member Data Documentation
◆ store
|
protected |
The documentation for this class was generated from the following file: