Slicer  5.0
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
List of all members | Public Types | Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Friends
vtkSegmentationConverterFactory Class Reference

Class that can create vtkSegmentationConverter instances. More...

#include <Libs/vtkSegmentationCore/vtkSegmentationConverterFactory.h>

Inheritance diagram for vtkSegmentationConverterFactory:
Inheritance graph
[legend]
Collaboration diagram for vtkSegmentationConverterFactory:
Collaboration graph
[legend]

Public Types

typedef std::vector< vtkSmartPointer< vtkSegmentationConverterRule > > RuleListType
 
typedef vtkObject Superclass
 

Public Member Functions

vtkDataObject * ConstructRepresentationObjectByClass (std::string className)
 
vtkDataObject * ConstructRepresentationObjectByRepresentation (std::string representationName)
 
void CopyConverterRules (RuleListType &rules)
 
bool DisableConverterRule (std::string sourceRepresentationName, std::string targetRepresentationName)
 
void DisableRepresentation (std::string representationName)
 
virtual const char * GetClassName ()
 
const RuleListTypeGetConverterRules ()
 Get all registered converter rules. More...
 
virtual int IsA (const char *type)
 
void PrintSelf (ostream &os, vtkIndent indent) override
 
void RegisterConverterRule (vtkSegmentationConverterRule *rule)
 
void UnregisterConverterRule (vtkSegmentationConverterRule *rule)
 

Static Public Member Functions

static vtkSegmentationConverterFactoryGetInstance ()
 Return the singleton instance with no reference counting. More...
 
static int IsTypeOf (const char *type)
 
static vtkSegmentationConverterFactoryNew ()
 
static vtkSegmentationConverterFactorySafeDownCast (vtkObject *o)
 

Protected Types

typedef vtkSegmentationConverterFactory Self
 

Protected Member Functions

void operator= (const vtkSegmentationConverterFactory &)
 
 vtkSegmentationConverterFactory ()
 
 vtkSegmentationConverterFactory (const vtkSegmentationConverterFactory &)
 
 ~vtkSegmentationConverterFactory () override
 

Static Protected Member Functions

static void classFinalize ()
 
static void classInitialize ()
 

Protected Attributes

RuleListType Rules
 Registered converter rules. More...
 

Friends

class vtkSegmentationConverterFactoryInitialize
 

Detailed Description

Class that can create vtkSegmentationConverter instances.

This singleton class is a repository of all segmentation converter rules. Singleton pattern adopted from vtkEventBroker class.

Definition at line 41 of file vtkSegmentationConverterFactory.h.

Member Typedef Documentation

◆ RuleListType

Definition at line 44 of file vtkSegmentationConverterFactory.h.

◆ Self

Definition at line 107 of file vtkSegmentationConverterFactory.h.

◆ Superclass

Definition at line 46 of file vtkSegmentationConverterFactory.h.

Constructor & Destructor Documentation

◆ vtkSegmentationConverterFactory() [1/2]

vtkSegmentationConverterFactory::vtkSegmentationConverterFactory ( )
protected

◆ ~vtkSegmentationConverterFactory()

vtkSegmentationConverterFactory::~vtkSegmentationConverterFactory ( )
overrideprotected

◆ vtkSegmentationConverterFactory() [2/2]

vtkSegmentationConverterFactory::vtkSegmentationConverterFactory ( const vtkSegmentationConverterFactory )
protected

Member Function Documentation

◆ classFinalize()

static void vtkSegmentationConverterFactory::classFinalize ( )
staticprotected

◆ classInitialize()

static void vtkSegmentationConverterFactory::classInitialize ( )
staticprotected

◆ ConstructRepresentationObjectByClass()

vtkDataObject* vtkSegmentationConverterFactory::ConstructRepresentationObjectByClass ( std::string  className)

Constructs representation object from class name using the ConstructRepresentationObject methods in the registered conversion rules that must be able to instantiate the representation classes they support.

◆ ConstructRepresentationObjectByRepresentation()

vtkDataObject* vtkSegmentationConverterFactory::ConstructRepresentationObjectByRepresentation ( std::string  representationName)

Constructs representation object from representation name using the ConstructRepresentationObject methods in the registered conversion rules that must be able to instantiate the representation classes they support.

◆ CopyConverterRules()

void vtkSegmentationConverterFactory::CopyConverterRules ( RuleListType rules)

Create a copy of all registered converter rules. The rule argument is overwritten (any previous content is cleared) with rules copied from the list of all registered rules.

◆ DisableConverterRule()

bool vtkSegmentationConverterFactory::DisableConverterRule ( std::string  sourceRepresentationName,
std::string  targetRepresentationName 
)

Disable a converter rule, preventing it from being used. Achieved by unregistering the rule that can create the representation.

Returns
Success flag indicating whether a rule with the specified representations was found and disabled

◆ DisableRepresentation()

void vtkSegmentationConverterFactory::DisableRepresentation ( std::string  representationName)

Disable a representation, preventing it from being created. Achieved by unregistering the rules that can create the representation.

◆ GetClassName()

virtual const char* vtkSegmentationConverterFactory::GetClassName ( )
virtual

◆ GetConverterRules()

const RuleListType& vtkSegmentationConverterFactory::GetConverterRules ( )

Get all registered converter rules.

◆ GetInstance()

static vtkSegmentationConverterFactory* vtkSegmentationConverterFactory::GetInstance ( )
static

Return the singleton instance with no reference counting.

◆ IsA()

virtual int vtkSegmentationConverterFactory::IsA ( const char *  type)
virtual

◆ IsTypeOf()

static int vtkSegmentationConverterFactory::IsTypeOf ( const char *  type)
static

◆ New()

static vtkSegmentationConverterFactory* vtkSegmentationConverterFactory::New ( )
static

This is a singleton pattern New. There will only be ONE reference to a vtkSegmentationConverterFactory object per process. Clients that call this must call Delete on the object so that the reference counting will work. The single instance will be unreferenced when the program exits.

◆ operator=()

void vtkSegmentationConverterFactory::operator= ( const vtkSegmentationConverterFactory )
protected

◆ PrintSelf()

void vtkSegmentationConverterFactory::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
override

◆ RegisterConverterRule()

void vtkSegmentationConverterFactory::RegisterConverterRule ( vtkSegmentationConverterRule rule)

Add a converter rule. The factory (and all converter classes it creates) will keep a reference to this rule object, and it will not be deleted until all these referring classes are deleted.

◆ SafeDownCast()

static vtkSegmentationConverterFactory* vtkSegmentationConverterFactory::SafeDownCast ( vtkObject *  o)
static

◆ UnregisterConverterRule()

void vtkSegmentationConverterFactory::UnregisterConverterRule ( vtkSegmentationConverterRule rule)

Remove a converter rule from the factory. This does not affect converters that have already been created.

Friends And Related Function Documentation

◆ vtkSegmentationConverterFactoryInitialize

Definition at line 106 of file vtkSegmentationConverterFactory.h.

Member Data Documentation

◆ Rules

RuleListType vtkSegmentationConverterFactory::Rules
protected

Registered converter rules.

Definition at line 110 of file vtkSegmentationConverterFactory.h.


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