Medical Imaging Interaction Toolkit  2018.4.99-36d69b77
Medical Imaging Interaction Toolkit
mitk::NavigationDataSource Class Reference

Navigation Data source. More...

#include <mitkNavigationDataSource.h>

Inheritance diagram for mitk::NavigationDataSource:
Collaboration diagram for mitk::NavigationDataSource:

Public Member Functions

 mitkClassMacroItkParent (NavigationDataSource, itk::ProcessObject)
 
virtual std::string GetName ()
 
virtual void SetName (std::string _arg)
 Sets the human readable name of this source. There is also a default name, but you can use this method if you need to define it on your own. More...
 
NavigationDataGetOutput (void)
 return the output (output with id 0) of the filter More...
 
NavigationDataGetOutput (DataObjectPointerArraySizeType idx)
 return the output with id idx of the filter More...
 
NavigationDataGetOutput (const std::string &navDataName)
 return the output with name navDataName of the filter More...
 
NavigationTool::Pointer GetToolMetaData (DataObjectPointerArraySizeType idx)
 
NavigationTool::Pointer GetToolMetaData (const std::string &navDataName)
 
virtual mitk::NavigationToolStorage::Pointer GetToolMetaDataCollection ()
 
virtual void SetToolMetaDataCollection (mitk::NavigationToolStorage::Pointer _arg)
 
DataObjectPointerArraySizeType GetOutputIndex (std::string navDataName)
 return the index of the output with name navDataName, -1 if no output with that name was found More...
 
virtual void RegisterAsMicroservice ()
 Registers this object as a Microservice, making it available to every module and/or plugin. To unregister, call UnregisterMicroservice(). More...
 
virtual void UnRegisterMicroservice ()
 Registers this object as a Microservice, making it available to every module and/or plugin. More...
 
std::string GetMicroserviceID ()
 Returns the id that this device is registered with. The id will only be valid, if the NavigationDataSource has been registered using RegisterAsMicroservice(). More...
 
virtual void GraftNthOutput (unsigned int idx, itk::DataObject *graft)
 Graft the specified DataObject onto this ProcessObject's output. More...
 
virtual void GraftOutput (itk::DataObject *graft)
 Graft the specified DataObject onto this ProcessObject's output. More...
 
itk::DataObject::Pointer MakeOutput (DataObjectPointerArraySizeType idx) override
 
itk::DataObject::Pointer MakeOutput (const DataObjectIdentifierType &name) override
 
virtual void SetParameters (const mitk::PropertyList *)
 Set all filter parameters as the PropertyList p. More...
 
virtual mitk::PropertyList::ConstPointer GetParameters () const
 Get all filter parameters as a PropertyList. More...
 
virtual void Freeze ()
 
virtual void UnFreeze ()
 
virtual bool GetIsFrozen ()
 

Static Public Attributes

static const std::string US_INTERFACE_NAME
 These Constants are used in conjunction with Microservices. More...
 
static const std::string US_PROPKEY_DEVICENAME
 
static const std::string US_PROPKEY_ID
 
static const std::string US_PROPKEY_ISACTIVE
 

Protected Member Functions

 NavigationDataSource ()
 
 ~NavigationDataSource () override
 

Protected Attributes

std::string m_Name
 
bool m_IsFrozen
 
NavigationToolStorage::Pointer m_ToolMetaDataCollection
 

Detailed Description

Navigation Data source.

Documentation Base class for all navigation filters that produce NavigationData objects as output. This class defines the output-interface for NavigationDataFilters.

Warning
: if Update() is called on any output object, all NavigationData filters will generate new output data for all outputs, not just the one on which Update() was called.

Definition at line 40 of file mitkNavigationDataSource.h.

Constructor & Destructor Documentation

◆ NavigationDataSource()

mitk::NavigationDataSource::NavigationDataSource ( )
protected

Definition at line 28 of file mitkNavigationDataSource.cpp.

◆ ~NavigationDataSource()

mitk::NavigationDataSource::~NavigationDataSource ( )
overrideprotected

Definition at line 33 of file mitkNavigationDataSource.cpp.

Member Function Documentation

◆ Freeze()

void mitk::NavigationDataSource::Freeze ( )
virtual

Freezes the navigation data source which means the current state is frozen and the output navigation data stays at it is. Calling Update() does not have any effect until UnFreeze() is called. This also means that the data source is not updated any more.

Definition at line 144 of file mitkNavigationDataSource.cpp.

References m_IsFrozen.

◆ GetIsFrozen()

virtual bool mitk::NavigationDataSource::GetIsFrozen ( )
virtual
Returns
Returns whether the data source is currently frozen.

◆ GetMicroserviceID()

std::string mitk::NavigationDataSource::GetMicroserviceID ( )

Returns the id that this device is registered with. The id will only be valid, if the NavigationDataSource has been registered using RegisterAsMicroservice().

Definition at line 90 of file mitkNavigationDataSource.cpp.

References us::ServiceRegistration< I1, I2, I3 >::GetReference(), and US_PROPKEY_ID.

◆ GetName()

virtual std::string mitk::NavigationDataSource::GetName ( )
virtual
Returns
Returns a human readable name of this source. There will be a default name, or you can set the name with the method SetName() if you want to change it.

Referenced by GetToolMetaData().

◆ GetOutput() [1/3]

mitk::NavigationData * mitk::NavigationDataSource::GetOutput ( void  )

return the output (output with id 0) of the filter

Definition at line 37 of file mitkNavigationDataSource.cpp.

Referenced by mitk::NodeDisplacementFilter::AddNode(), mitk::NavigationDataToNavigationDataFilter::ConnectTo(), mitk::NavigationDataToIGTLMessageFilter::ConnectTo(), mitk::TrackingDeviceSource::CreateOutputs(), mitk::NavigationDataToNavigationDataFilter::CreateOutputsForAllInputs(), mitk::IGTLMessageToNavigationDataFilter::CreateOutputsForAllInputs(), mitk::NavigationDataPassThroughFilter::GenerateData(), mitk::NavigationDataSmoothingFilter::GenerateData(), mitk::NavigationDataDelayFilter::GenerateData(), mitk::NavigationDataHandEyeCalibrationFilter::GenerateData(), mitk::NavigationDataDisplacementFilter::GenerateData(), mitk::NavigationDataSequentialPlayer::GenerateData(), mitk::NavigationDataTransformFilter::GenerateData(), mitk::NavigationDataPlayer::GenerateData(), mitk::NavigationDataToMessageFilter::GenerateData(), mitk::NavigationDataEvaluationFilter::GenerateData(), mitk::CameraVisualization::GenerateData(), mitk::NavigationDataRecorder::GenerateData(), mitk::TrackingDeviceSource::GenerateData(), mitk::NavigationDataSliceVisualization::GenerateData(), mitk::NavigationDataLandmarkTransformFilter::GenerateData(), mitk::NavigationDataObjectVisualizationFilter::GenerateData(), mitk::IGTLMessageToNavigationDataFilter::GenerateQuaternionTrackingDataData(), mitk::IGTLMessageToNavigationDataFilter::GenerateTrackingDataData(), mitk::IGTLMessageToNavigationDataFilter::GenerateTransformData(), GetToolMetaData(), mitk::NavigationDataPlayerBase::GraftEmptyOutput(), and GraftNthOutput().

◆ GetOutput() [2/3]

mitk::NavigationData * mitk::NavigationDataSource::GetOutput ( DataObjectPointerArraySizeType  idx)

return the output with id idx of the filter

Definition at line 45 of file mitkNavigationDataSource.cpp.

◆ GetOutput() [3/3]

mitk::NavigationData * mitk::NavigationDataSource::GetOutput ( const std::string &  navDataName)

return the output with name navDataName of the filter

Definition at line 55 of file mitkNavigationDataSource.cpp.

◆ GetOutputIndex()

itk::ProcessObject::DataObjectPointerArraySizeType mitk::NavigationDataSource::GetOutputIndex ( std::string  navDataName)

return the index of the output with name navDataName, -1 if no output with that name was found

Warning
if a subclass has outputs that have different data type than mitk::NavigationData, they have to overwrite this method

Definition at line 64 of file mitkNavigationDataSource.cpp.

◆ GetParameters()

mitk::PropertyList::ConstPointer mitk::NavigationDataSource::GetParameters ( ) const
virtual

Get all filter parameters as a PropertyList.

This method allows to get all parameters of a filter with one method call. The returned PropertyList must be assigned to a SmartPointer immediately, or else it will get destroyed. Every filter must overwrite this method to create a filter-specific PropertyList. Note that property names must be unique over all MITK-IGT filters. Therefore each filter should use its name as a prefix for each property name. Secondly, each filter should list the property names and data types in the method documentation.

Reimplemented in mitk::CameraVisualization, and mitk::NavigationDataDisplacementFilter.

Definition at line 136 of file mitkNavigationDataSource.cpp.

References mitk::PropertyList::New().

◆ GetToolMetaData() [1/2]

mitk::NavigationTool::Pointer mitk::NavigationDataSource::GetToolMetaData ( DataObjectPointerArraySizeType  idx)
Returns
Returns the metadata of the navigation tool at the given idx. Returns an empty object if no metadata is available.

Definition at line 154 of file mitkNavigationDataSource.cpp.

References GetName(), GetOutput(), and mitk::NavigationTool::New().

◆ GetToolMetaData() [2/2]

mitk::NavigationTool::Pointer mitk::NavigationDataSource::GetToolMetaData ( const std::string &  navDataName)
Returns
Returns the metadata of the navigation tool with the given name. Returns an empty object if no metadata is available.

Definition at line 160 of file mitkNavigationDataSource.cpp.

References m_ToolMetaDataCollection, and mitk::NavigationTool::New().

◆ GetToolMetaDataCollection()

virtual mitk::NavigationToolStorage::Pointer mitk::NavigationDataSource::GetToolMetaDataCollection ( )
virtual
Returns
Returns the metadata of all tools identified by the tool name. There is no need to set the metadata of the tools, so not every tool has metadata available. Returns an empty tool storage if no metadata was set at all.

◆ GraftNthOutput()

void mitk::NavigationDataSource::GraftNthOutput ( unsigned int  idx,
itk::DataObject *  graft 
)
virtual

Graft the specified DataObject onto this ProcessObject's output.

See itk::ImageSource::GraftNthOutput for details

Definition at line 99 of file mitkNavigationDataSource.cpp.

References GetOutput().

Referenced by GraftOutput().

◆ GraftOutput()

void mitk::NavigationDataSource::GraftOutput ( itk::DataObject *  graft)
virtual

Graft the specified DataObject onto this ProcessObject's output.

See itk::ImageSource::Graft Output for details

Definition at line 94 of file mitkNavigationDataSource.cpp.

References GraftNthOutput().

◆ MakeOutput() [1/2]

itk::DataObject::Pointer mitk::NavigationDataSource::MakeOutput ( DataObjectPointerArraySizeType  idx)
override

Allocates a new output object and returns it. Currently the index idx is not evaluated.

Parameters
idxthe index of the output for which an object should be created
Returns
the new object

Definition at line 121 of file mitkNavigationDataSource.cpp.

References mitk::NavigationData::New().

Referenced by mitk::TrackingDeviceSource::CreateOutputs(), mitk::NavigationDataPlayerBase::InitPlayer(), and MakeOutput().

◆ MakeOutput() [2/2]

itk::DataObject::Pointer mitk::NavigationDataSource::MakeOutput ( const DataObjectIdentifierType &  name)
override

This is a default implementation to make sure we have something. Once all the subclasses of ProcessObject provide an appopriate MakeOutput(), then ProcessObject::MakeOutput() can be made pure virtual.

Definition at line 126 of file mitkNavigationDataSource.cpp.

References MakeOutput(), and mitk::NavigationData::New().

◆ mitkClassMacroItkParent()

mitk::NavigationDataSource::mitkClassMacroItkParent ( NavigationDataSource  ,
itk::ProcessObject   
)

◆ RegisterAsMicroservice()

void mitk::NavigationDataSource::RegisterAsMicroservice ( )
virtual

Registers this object as a Microservice, making it available to every module and/or plugin. To unregister, call UnregisterMicroservice().

Definition at line 73 of file mitkNavigationDataSource.cpp.

References us::GetModuleContext(), mitk::UIDGenerator::GetUID(), m_Name, US_PROPKEY_DEVICENAME, and US_PROPKEY_ID.

◆ SetName()

virtual void mitk::NavigationDataSource::SetName ( std::string  _arg)
virtual

Sets the human readable name of this source. There is also a default name, but you can use this method if you need to define it on your own.

Referenced by mitk::TrackingDeviceSource::CreateOutputs(), mitk::NavigationDataPlayerBase::NavigationDataPlayerBase(), and mitk::TrackingDeviceSource::SetTrackingDevice().

◆ SetParameters()

virtual void mitk::NavigationDataSource::SetParameters ( const mitk::PropertyList )
inlinevirtual

Set all filter parameters as the PropertyList p.

This method allows to set all parameters of a filter with one method call. For the names of the parameters, take a look at the GetParameters method of the filter This method has to be overwritten by each MITK-IGT filter.

Reimplemented in mitk::CameraVisualization, and mitk::NavigationDataDisplacementFilter.

Definition at line 161 of file mitkNavigationDataSource.h.

◆ SetToolMetaDataCollection()

virtual void mitk::NavigationDataSource::SetToolMetaDataCollection ( mitk::NavigationToolStorage::Pointer  _arg)
virtual

Sets the tool metadata as NavigationToolStorage object.

◆ UnFreeze()

void mitk::NavigationDataSource::UnFreeze ( )
virtual

Unfreezes the data source.

Definition at line 149 of file mitkNavigationDataSource.cpp.

References m_IsFrozen.

◆ UnRegisterMicroservice()

void mitk::NavigationDataSource::UnRegisterMicroservice ( )
virtual

Registers this object as a Microservice, making it available to every module and/or plugin.

Definition at line 85 of file mitkNavigationDataSource.cpp.

References us::ServiceRegistrationBase::Unregister().

Member Data Documentation

◆ m_IsFrozen

bool mitk::NavigationDataSource::m_IsFrozen
protected

◆ m_Name

std::string mitk::NavigationDataSource::m_Name
protected

Definition at line 194 of file mitkNavigationDataSource.h.

Referenced by RegisterAsMicroservice().

◆ m_ToolMetaDataCollection

NavigationToolStorage::Pointer mitk::NavigationDataSource::m_ToolMetaDataCollection
protected

Holds the metadata of all tools identified by the tool name. There is no need to set the metadata of the tools, so not every tool has metadata available.

Definition at line 201 of file mitkNavigationDataSource.h.

Referenced by GetToolMetaData().

◆ US_INTERFACE_NAME

const std::string mitk::NavigationDataSource::US_INTERFACE_NAME
static

These Constants are used in conjunction with Microservices.

Definition at line 118 of file mitkNavigationDataSource.h.

◆ US_PROPKEY_DEVICENAME

const std::string mitk::NavigationDataSource::US_PROPKEY_DEVICENAME
static

◆ US_PROPKEY_ID

const std::string mitk::NavigationDataSource::US_PROPKEY_ID
static

Definition at line 120 of file mitkNavigationDataSource.h.

Referenced by GetMicroserviceID(), and RegisterAsMicroservice().

◆ US_PROPKEY_ISACTIVE

const std::string mitk::NavigationDataSource::US_PROPKEY_ISACTIVE
static

Definition at line 121 of file mitkNavigationDataSource.h.


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