FREE::Setup Class Reference
[Setup]

Contains all information for a complete f.r.e.e. processing session. More...

#include <freSetup.h>

Inheritance diagram for FREE::Setup:

Inheritance graph
FREE::XMLStreamObject
[legend]
Collaboration diagram for FREE::Setup:

Collaboration graph
FREE::XMLStreamObject
[legend]

List of all members.

Public Types

typedef Setup Self
typedef itk::LightObject Superclass
typedef
itk::SmartPointer
< Self
Pointer
typedef
itk::SmartPointer
< const Self
ConstPointer
typedef ComponentSetup SectionSetup
typedef std::vector
< SectionSetup * > 
SectionVector
typedef ComponentSetup MediaContainerSetup
typedef std::vector
< ComponentSetup * > 
MediaContainerVector

Public Member Functions

virtual const char * GetNameOfClass () const
virtual
::itk::LightObject::Pointer 
CreateAnother (void) const
std::string GetName () const
void SetName (const std::string &sName)
std::string GetDescription () const
void SetDescription (const std::string &sDescription)
virtual void Reset ()
virtual ~Setup ()
Setupoperator= (const Setup &rSetup)
ComponentSetupCollectionComponents ()
const
ComponentSetupCollection
Components () const
ComponentSetupGetComponentByIDPath (const IDPath &idPath)
SectionVector GetSections () const
SectionSetupGetSection (const unsigned int &iIndex) const
unsigned int GetSectionCount () const
ComponentSetup *const GetRootComponent ()
const ComponentSetup
*const 
GetRootComponent () const

Static Public Member Functions

static Pointer New (void)

Protected Member Functions

 Setup ()
virtual void SubElementLoadProcessing (const std::string &rsXMLSubTag, const std::string &rsXMLSubElement, const std::string &rsXMLSubData)
virtual std::string SaveData (const unsigned int &iDepth, bool &bHasSubElements) const
virtual void SaveAttributes (AttributesSaveListType &rAttributes) const
virtual void SetNeededSubElements ()

Protected Attributes

std::string m_sName
std::string m_sDescription
ComponentSetup::Pointer m_Root

Private Member Functions

 Setup (const Setup &setup)


Detailed Description

Contains all information for a complete f.r.e.e. processing session.

Setup contains all information for all components and media used in a Session

Definition at line 38 of file freSetup.h.


Member Typedef Documentation

typedef Setup FREE::Setup::Self

Definition at line 41 of file freSetup.h.

typedef itk::LightObject FREE::Setup::Superclass

Definition at line 42 of file freSetup.h.

typedef itk::SmartPointer<Self> FREE::Setup::Pointer

Definition at line 43 of file freSetup.h.

typedef itk::SmartPointer<const Self> FREE::Setup::ConstPointer

Definition at line 44 of file freSetup.h.

typedef ComponentSetup FREE::Setup::SectionSetup

Definition at line 47 of file freSetup.h.

typedef std::vector<SectionSetup*> FREE::Setup::SectionVector

Definition at line 50 of file freSetup.h.

typedef ComponentSetup FREE::Setup::MediaContainerSetup

Definition at line 51 of file freSetup.h.

typedef std::vector<ComponentSetup*> FREE::Setup::MediaContainerVector

Definition at line 52 of file freSetup.h.


Constructor & Destructor Documentation

FREE::Setup::~Setup (  )  [virtual]

Definition at line 81 of file freSetup.cxx.

References Reset().

Here is the call graph for this function:

FREE::Setup::ResetFREE::XMLStreamObject::Reset

FREE::Setup::Setup (  )  [protected]

Normal Constructor

Definition at line 69 of file freSetup.cxx.

References m_Root, FREE::ComponentSetup::New(), and Reset().

Here is the call graph for this function:

FREE::ComponentSetup::NewFREE::Setup::ResetFREE::XMLStreamObject::Reset

FREE::Setup::Setup ( const Setup setup  )  [private]

Copy constructor

Definition at line 76 of file freSetup.cxx.


Member Function Documentation

virtual const char* FREE::Setup::GetNameOfClass (  )  const [inline, virtual]

Reimplemented from FREE::XMLStreamObject.

Definition at line 46 of file freSetup.h.

static Pointer FREE::Setup::New ( void   )  [inline, static]

Definition at line 47 of file freSetup.h.

Referenced by FREE::SetupOptimizationProcessorController::ActualizeMainComponent(), FREE::GenericSetupToImageAdaptor::AdaptSetup(), FREE::ConsistencyRegistrationMetric< VImageDimension >::ComputeDecomposedValue(), FREE::SetupInterpolator::InterpolateSetup(), and FREE::SetupTransform::TransformSetup().

virtual ::itk::LightObject::Pointer FREE::Setup::CreateAnother ( void   )  const [inline, virtual]

Definition at line 47 of file freSetup.h.

std::string FREE::Setup::GetName (  )  const

Implementation of FREE::Setup //////////////////////////////////////

Definition at line 42 of file freSetup.cxx.

References m_sName.

Referenced by operator=().

void FREE::Setup::SetName ( const std::string &  sName  ) 

Definition at line 49 of file freSetup.cxx.

References m_sName.

Referenced by FREE::SetupInterpolator::InterpolateSetup().

std::string FREE::Setup::GetDescription (  )  const

Definition at line 56 of file freSetup.cxx.

References m_sDescription.

Referenced by operator=().

void FREE::Setup::SetDescription ( const std::string &  sDescription  ) 

Definition at line 63 of file freSetup.cxx.

References m_sDescription.

void FREE::Setup::Reset (  )  [virtual]

Resets the setup by deleting all section and sets name (""), description ("") to their defaults (values in brackets).

Reimplemented from FREE::XMLStreamObject.

Definition at line 102 of file freSetup.cxx.

References m_Root, m_sDescription, m_sName, and FREE::XMLStreamObject::Reset().

Referenced by operator=(), Setup(), and ~Setup().

Here is the call graph for this function:

FREE::XMLStreamObject::Reset

Setup & FREE::Setup::operator= ( const Setup rSetup  ) 

Assignment operator.

Definition at line 88 of file freSetup.cxx.

References Components(), GetDescription(), GetName(), m_Root, m_sDescription, m_sName, Reset(), and FREE::XMLStreamObject::SaveToString().

Here is the call graph for this function:

FREE::Setup::ComponentsFREE::Setup::GetDescriptionFREE::Setup::GetNameFREE::Setup::ResetFREE::XMLStreamObject::SaveToStringFREE::XMLStreamObject::Reset

ComponentSetupCollection& FREE::Setup::Components (  )  [inline]

Definition at line 69 of file freSetup.h.

References m_Root.

Referenced by operator=().

const ComponentSetupCollection& FREE::Setup::Components (  )  const [inline]

Definition at line 70 of file freSetup.h.

References m_Root.

ComponentSetup * FREE::Setup::GetComponentByIDPath ( const IDPath idPath  ) 

Retrieve a component by a given component ID path

Parameters:
[in] idPath The component ID path addressing the wanted component.
Returns:
Returns the pointer to the addressed component. If no component has been found under the specified path, the return is NULL

Definition at line 168 of file freSetup.cxx.

References m_Root.

Referenced by FREE::SetupTransform::GetInitialValues(), FREE::SetupTransform::GetParameterValueType(), and FREE::SetupInterpolator::InterpolateComponent().

Setup::SectionVector FREE::Setup::GetSections (  )  const

Definition at line 175 of file freSetup.cxx.

References m_Root.

Referenced by FREE::SetupManager::ActualizeConstraintCache(), FREE::SessionBuilder::BuildSession(), GetSection(), GetSectionCount(), and FREE::SetupInterpolator::InterpolateComponent().

Setup::SectionSetup * FREE::Setup::GetSection ( const unsigned int &  iIndex  )  const

Definition at line 190 of file freSetup.cxx.

References GetSections().

Here is the call graph for this function:

FREE::Setup::GetSections

unsigned int FREE::Setup::GetSectionCount (  )  const

Definition at line 201 of file freSetup.cxx.

References GetSections().

Here is the call graph for this function:

FREE::Setup::GetSections

ComponentSetup* const FREE::Setup::GetRootComponent (  )  [inline]

Definition at line 82 of file freSetup.h.

References m_Root.

Referenced by FREE::GenericSetupToImageAdaptor::AdaptSetup(), FREE::GenericSetupToImageAdaptor::OverwriteComponent(), FREE::SetupManager::SetSetup(), and FREE::SessionInfo::SetSetup().

const ComponentSetup* const FREE::Setup::GetRootComponent (  )  const [inline]

Definition at line 83 of file freSetup.h.

References m_Root.

void FREE::Setup::SubElementLoadProcessing ( const std::string &  rsXMLSubTag,
const std::string &  rsXMLSubElement,
const std::string &  rsXMLSubData 
) [protected, virtual]

Function is called by after the parser has extracted a new sub element out of the xml data string. The tag of the sub element is passed, along with its data and a string containing the total element (needed to call subsequent LoadFromString). To change the loading behaviour, this class should be reimplemented. This function is also called for plain text data of the element. In this case rsXMLTag is cXML_Text (an empty string), if not there is a real sub element in the data. Depending on the structure the text case (rsXMLTag==cXML_Text) could occure more then once.

Example:

 <Element>aaaaaa<SubElement>bbbbbb</Subelement>cccccc</Element>\n
This string passed as rsXMLData in a call of LoadFromXMLString() would cause 3 calls of SubElementLoadProcessing() with following parameters:
1. rsXMLTag == cXML_Text; rsXMLSubElement == "aaaaaa"; rsXMLSubData == "aaaaaa"
2. rsXMLTag == "Subelement"; rsXMLSubElement == "<SubElement>bbbbbb</Subelement>"; rsXMLSubData == "bbbbbb"
1. rsXMLTag == cXML_Text; rsXMLSubElement == "cccccc"; rsXMLSubElement == "cccccc"
Parameters:
[in] rsXMLSubTag Reference to the tag of xml to be loaded with the function call.
[in] rsXMLSubElement Reference to the whole element string (with attributes, start and end tag).
[in] rsXMLSubData Reference to the whole data of the xml element (without start and end tag)

Reimplemented from FREE::XMLStreamObject.

Definition at line 120 of file freSetup.cxx.

References catchAllNPassMacro, FREE::cXML_SetupDescription, FREE::cXML_SetupName, FREE::cXML_SetupSections, FREE::XMLStreamObject::LoadFromString(), m_Root, m_sDescription, and m_sName.

Here is the call graph for this function:

FREE::XMLStreamObject::LoadFromStringFREE::XMLStreamObject::CB_Static_EndElementFREE::XMLStreamObject::CB_Static_StartElementFREE::XMLStreamObject::CheckValidLoadingFREE::XMLStreamObject::FinalizeLoadingFREE::XMLStreamObject::ResetFREE::XMLStreamObject::ResetLoadingHelpersFREE::XMLStreamObject::ResetRequirementsFREE::Convert::ToStrFREE::XMLStreamObject::CB_EndElementFREE::XMLStreamObject::CB_Static_CharacterDataHandlerFREE::XMLStreamObject::CommitSubElementFREE::XMLStreamObject::CB_CharacterDataHandlerFREE::XMLStreamObject::ExtractSubElementContentStringFREE::XMLStreamObject::ExtractSubElementXmlStringFREE::XMLStreamObject::NotifyFoundSubElementFREE::XMLStreamObject::SubElementLoadProcessingFREE::XMLStreamObject::CB_StartElementFREE::XMLStreamObject::AttributesLoadProcessingFREE::XMLStreamObject::ConvertExpatAttrToMapFREE::XMLStreamObject::GetXMLTagFREE::XMLStreamObject::SetNeededSubElements

std::string FREE::Setup::SaveData ( const unsigned int &  iDepth,
bool &  bHasSubElements 
) const [protected, virtual]

Function that returns the data of the object converted to a xml element. This function is called by SaveToString() to compose the whole xml string and should contain the data/value of the xml element couples.

Parameters:
[in] iDepth The depth of the data within the xml structure tree. Used to realize correct indentation of the formated data by AddIndentation().
[out] bHasSubElements Indicates whether the data string contains sub elements or just a plain value. By default bHasSubElements is true when the functon is called by SaveToString(). Reset the value to reset behavior of SaveToString. Example: <element attr1="1" attr2="a">aaaaaa<subElement>bbbbbb</subelement></element> For this xml string the function should return: "aaaaaa<subElement>bbbbbb</subElement>"
Returns:
Data of the xml as xml string.

Reimplemented from FREE::XMLStreamObject.

Definition at line 145 of file freSetup.cxx.

References FREE::XMLStreamObject::AddSubElement(), FREE::cXML_SetupDescription, FREE::cXML_SetupName, m_Root, m_sDescription, and m_sName.

Here is the call graph for this function:

FREE::XMLStreamObject::AddSubElementFREE::XMLStreamObject::AddIndentationFREE::XMLStreamObject::CreateSimpleElementFREE::Convert::ToStr

void FREE::Setup::SaveAttributes ( AttributesSaveListType rAttributes  )  const [protected, virtual]

Definition at line 113 of file freSetup.cxx.

References FREE::cXML_SetupVersion.

void FREE::Setup::SetNeededSubElements (  )  [protected, virtual]

This function inserts all elements, which have to be present in a loading string, into m_NeededSubElements by AddNeededSubElement(). This Function is called by ResetRequirements() and should be reimplemented by Tasks to be adaptet to the requirements of the class.

Reimplemented from FREE::XMLStreamObject.

Definition at line 161 of file freSetup.cxx.

References FREE::XMLStreamObject::AddNeededSubElement(), and FREE::cXML_SetupName.

Here is the call graph for this function:

FREE::XMLStreamObject::AddNeededSubElement


Member Data Documentation

std::string FREE::Setup::m_sName [protected]

The Name of the whole setup. It can be freely set and has only identification purpose for the user/GUI (not for f.r.e.e.).

Definition at line 99 of file freSetup.h.

Referenced by GetName(), operator=(), Reset(), SaveData(), SetName(), and SubElementLoadProcessing().

std::string FREE::Setup::m_sDescription [protected]

A brief description of the setup, can be placed here.

Definition at line 102 of file freSetup.h.

Referenced by GetDescription(), operator=(), Reset(), SaveData(), SetDescription(), and SubElementLoadProcessing().

ComponentSetup::Pointer FREE::Setup::m_Root [protected]

The root of the setup, containing all sections and media containers.

Definition at line 105 of file freSetup.h.

Referenced by Components(), GetComponentByIDPath(), GetRootComponent(), GetSections(), operator=(), Reset(), SaveData(), Setup(), and SubElementLoadProcessing().


The documentation for this class was generated from the following files:
Generated at Sat Oct 13 18:29:37 2007 for f.r.e.e. - Flexible Registration and Evaluation Engine by doxygen 1.5.3 written by Dimitri van Heesch, © 1997-2000