Inviwo 0.9.12-pre
Inviwo documentation
Loading...
Searching...
No Matches
inviwo::RepresentationFactory< Representation > Class Template Reference

#include <inviwo/core/datastructures/representationfactory.h>

+ Inheritance diagram for inviwo::RepresentationFactory< Representation >:

Public Member Functions

std::unique_ptr< Representation > createOrDefault (BaseReprId id, const typename Representation::ReprOwner *owner)
 
virtual BaseReprId getBaseReprId () const override
 
 RepresentationFactory (BaseReprId defaultRepresentation)
 
- Public Member Functions inherited from inviwo::StandardFactory< Representation, RepresentationFactoryObject< Representation >, std::type_index, const Representation::ReprOwner * >
virtual std::unique_ptr< Representation > create (std::type_index key, Args... args) const override
 
virtual bool hasKey (std::type_index key) const override
 
- Public Member Functions inherited from inviwo::Factory< T, K, Args >
virtual std::unique_ptr< T > create (K key, Args... args) const =0
 
virtual std::shared_ptr< T > createShared (K key, Args... args) const
 
 Factory (const Factory &)=delete
 
 Factory (Factory &&)=default
 
virtual bool hasKey (K key) const =0
 
Factoryoperator= (const Factory &)=delete
 
Factoryoperator= (Factory &&)=default
 
- Public Member Functions inherited from inviwo::FactoryRegister< FactoryObject, Key, LookUpKey >
FactoryObject * getFactoryObject (LookUpKey key) const
 
std::vector< Key > getKeys () const
 
auto getKeyView () const
 
auto getValueView () const
 
bool hasKey (LookUpKey key) const
 
virtual bool registerObject (FactoryObject *obj)
 
virtual bool unRegisterObject (FactoryObject *obj)
 
- Public Member Functions inherited from inviwo::Observable< T >
void addObserver (T *observer)
 
bool isObservedBy (T *observer) const
 
 Observable (const Observable< T > &other)
 
 Observable (Observable< T > &&other) noexcept
 
Observable< T > & operator= (const Observable< T > &other)
 
Observable< T > & operator= (Observable< T > &&other) noexcept
 
void removeObserver (T *observer)
 
virtual void startBlockingNotifications () override final
 
virtual void stopBlockingNotifications () override final
 

Additional Inherited Members

- Public Types inherited from inviwo::BaseRepresentationFactory
using BaseReprId = std::type_index
 
- Protected Member Functions inherited from inviwo::FactoryObservable< FactoryObject >
void notifyObserversOnRegister (FactoryObject *p)
 
void notifyObserversOnUnRegister (FactoryObject *p)
 
- Protected Member Functions inherited from inviwo::Observable< T >
template<typename C >
void forEachObserver (C callback)
 
- Protected Member Functions inherited from inviwo::ObservableInterface
void addObservationHelper (Observer *observer)
 
void removeObservationHelper (Observer *observer)
 
- Protected Attributes inherited from inviwo::FactoryRegister< FactoryObject, Key, LookUpKey >
std::map< Key, FactoryObject *, std::less<> > map_
 

Detailed Description

template<typename Representation>
class inviwo::RepresentationFactory< Representation >

Factory for representations of a specific base type (Volume Representation, Layer Representation, Buffer Representation, etc)

Template Parameters
Representationthe base representation type for the factory. All registered representation has to derive from this base class (for example
See also
VolumeRepresentation)
Data
DataRepresentation
RepresentationFactoryObject
RepresentationMetaFactory
InviwoApplication::getRepresentationFactory()
InviwoModule::registerRepresentationFactoryObject()
InviwoModule::registerRepresentationFactory()

Constructor & Destructor Documentation

◆ RepresentationFactory()

template<typename Representation >
inviwo::RepresentationFactory< Representation >::RepresentationFactory ( BaseReprId defaultRepresentation)
inline

Create a RepresentationFactory

Parameters
defaultRepresentationId of the default representation type to use in the factory

Member Function Documentation

◆ createOrDefault()

template<typename Representation >
std::unique_ptr< Representation > inviwo::RepresentationFactory< Representation >::createOrDefault ( BaseReprId id,
const typename Representation::ReprOwner * owner )
inline

Try to create a representation of the requested type, if that type was not found, return a representation of the default type.

◆ getBaseReprId()

template<typename Representation >
virtual BaseReprId inviwo::RepresentationFactory< Representation >::getBaseReprId ( ) const
inlineoverridevirtual

The documentation for this class was generated from the following file: