|
DynExp
Highly flexible laboratory automation for dynamically changing experiments.
|
This class defines a list of LinkedObjectWrapperContainer instances. The list owns the contained LinkedObjectWrapperContainer instances. Intances of this class should be owned by classes derived from class InstrumentDataBase or class ModuleDataBase. These instances provide access to objects referenced by object link list parameters (ListParam). The list's entries are exclusively managed by the respective instance of class RunnableInstance. RunnableInstance stores references to list entries. Every list manipulation RunnableInstance is not aware of might cause dangling references!
More...
#include <Object.h>
Public Member Functions | |
| LinkedObjectWrapperContainerList ()=default | |
| ~LinkedObjectWrapperContainerList ()=default | |
| const auto & | GetList () const noexcept |
| Returns Containers. | |
| const auto & | GetLabels () const noexcept |
| Returns ObjectLabels. | |
| std::string_view | GetIconPath () const |
| Returns IconPath. | |
| template<typename IndexType > | |
| auto & | operator[] (IndexType Index) |
Returns a stored LinkedObjectWrapperContainer instance selected by its list index. | |
Private Types | |
| using | ContainerType = LinkedObjectWrapperContainer< ObjectT > |
Type of the owned LinkedObjectWrapperContainer instances. | |
Private Attributes | |
| std::vector< std::unique_ptr< ContainerType > > | Containers |
List of the owned LinkedObjectWrapperContainer instances. std::vector of pointers since insertion and erasure do invalidate references to elements. | |
| Util::TextListType | ObjectLabels |
| Holds a human-readable identifier for each linked object. | |
| std::string | IconPath |
| Holds the path to the icon of the linked objects' base type (e.g. hardware adapter, instrument). | |
Friends | |
| class | RunnableInstance |
This class defines a list of LinkedObjectWrapperContainer instances. The list owns the contained LinkedObjectWrapperContainer instances. Intances of this class should be owned by classes derived from class InstrumentDataBase or class ModuleDataBase. These instances provide access to objects referenced by object link list parameters (ListParam). The list's entries are exclusively managed by the respective instance of class RunnableInstance. RunnableInstance stores references to list entries. Every list manipulation RunnableInstance is not aware of might cause dangling references!
| ObjectT | Type of the managed Object. |
|
private |
Type of the owned LinkedObjectWrapperContainer instances.
|
default |
|
default |
|
inline |
|
inlinenoexcept |
Returns ObjectLabels.
|
inlinenoexcept |
Returns Containers.
|
inline |
Returns a stored LinkedObjectWrapperContainer instance selected by its list index.
| IndexType | Type of Index. Needs to be castable to size_t |
| Index | Index of the entry in Containers to return |
Index. | Util::OutOfRangeException | is thrown if Index exceeds the amount of list entries in Containers. |
|
friend |
|
private |
List of the owned LinkedObjectWrapperContainer instances. std::vector of pointers since insertion and erasure do invalidate references to elements.
|
private |
|
private |