typedef itk::SmartPointer< Self > Pointer;
typedef itk::SmartPointer< const Self > ConstPointer;
- typedef cpPlugins::BaseObjects::ProcessObject TProcess;
+ typedef cpPlugins::BaseObjects::DataObject TDataObject;
+ typedef cpPlugins::BaseObjects::ProcessObject TFilter;
typedef cpPlugins::BaseObjects::Widget TWidget;
- typedef cpPlugins::Interface::Plugins TInterface;
+ typedef cpPlugins::Interface::Plugins TPlugins;
- typedef std::map< std::string, TProcess::Pointer > TFilters;
- typedef
- std::map< std::string, std::pair< std::string, std::string > >
- TExposedPorts;
+ typedef std::map< std::string, TFilter::Pointer > TFilters;
+
+ /* TODO
+ typedef
+ std::map< std::string, std::pair< std::string, std::string > >
+ TExposedPorts;
+ */
public:
itkNewMacro( Self );
// Filter management
std::vector< std::string > GetFiltersNames( ) const;
- TProcess* GetFilter(
- const std::string& name
- );
- const TProcess* GetFilter(
- const std::string& name
- ) const;
- TWidget* GetWidget(
- const std::string& name
- );
- const TWidget* GetWidget(
- const std::string& name
- ) const;
+ TFilter* GetFilter( const std::string& name );
+ const TFilter* GetFilter( const std::string& name ) const;
+ TWidget* GetWidget( const std::string& name );
+ const TWidget* GetWidget( const std::string& name ) const;
bool HasFilter( const std::string& name ) const;
bool HasWidget( const std::string& name ) const;
- TProcess* CreateFilter(
- const std::string& category,
- const std::string& filter,
- const std::string& name
+ TFilter* CreateFilter(
+ const std::string& category, const std::string& filter
);
bool RenameFilter(
const std::string& old_name, const std::string& new_name
void AddInteractor( vtkRenderWindowInteractor* iren );
// Exposed ports
- const TExposedPorts& GetExposedInputs( ) const;
- const TExposedPorts& GetExposedOutputs( ) const;
- cpPlugins::BaseObjects::DataObject* GetExposedOutput(
- const std::string& name
- );
- const cpPlugins::BaseObjects::DataObject* GetExposedOutput(
- const std::string& name
- ) const;
- bool ExposeInput(
- const std::string& name,
- const std::string& filter, const std::string& filter_input
- );
- bool ExposeOutput(
- const std::string& name,
- const std::string& filter, const std::string& filter_output
- );
- void HideInput( const std::string& name );
- void HideOutput( const std::string& name );
- bool RenameExposedInput(
- const std::string& old_name,
- const std::string& new_name
- );
- bool RenameExposedOutput(
- const std::string& old_name,
- const std::string& new_name
- );
+ /* TODO
+ const TExposedPorts& GetExposedInputs( ) const;
+ const TExposedPorts& GetExposedOutputs( ) const;
+ cpPlugins::BaseObjects::DataObject* GetExposedOutput(
+ const std::string& name
+ );
+ const cpPlugins::BaseObjects::DataObject* GetExposedOutput(
+ const std::string& name
+ ) const;
+ bool ExposeInput(
+ const std::string& name,
+ const std::string& filter, const std::string& filter_input
+ );
+ bool ExposeOutput(
+ const std::string& name,
+ const std::string& filter, const std::string& filter_output
+ );
+ void HideInput( const std::string& name );
+ void HideOutput( const std::string& name );
+ bool RenameExposedInput(
+ const std::string& old_name,
+ const std::string& new_name
+ );
+ bool RenameExposedOutput(
+ const std::string& old_name,
+ const std::string& new_name
+ );
+ */
// Connection management
- std::vector< std::pair< std::string, std::string > > GetConnections(
- const std::string& origin, const std::string& destination
- ) const;
- void Connect(
- const std::string& orig_filter, const std::string& dest_filter,
- const std::string& output_name, const std::string& input_name
- );
- void Connect(
- cpPlugins::BaseObjects::DataObject* output,
- const std::string& dest_filter, const std::string& input_name
+ bool Connect(
+ const std::string& origin_filter,
+ const std::string& origin_output,
+ const std::string& destination_filter,
+ const std::string& destination_input
);
- void Connect(
- cpPlugins::BaseObjects::DataObject* output,
- const std::string& exposed_input_name
+ bool Connect(
+ TDataObject* input,
+ const std::string& destination_filter,
+ const std::string& destination_input
);
- void Disconnect(
- const std::string& orig_filter, const std::string& dest_filter,
- const std::string& output_name, const std::string& input_name
+ bool Disconnect(
+ const std::string& origin_filter,
+ const std::string& origin_output,
+ const std::string& destination_filter,
+ const std::string& destination_input
);
- void Disconnect(
- const std::string& dest_filter, const std::string& input_name
- );
- void Disconnect( const std::string& dest_filter );
+
+ /* TODO
+ std::vector< std::pair< std::string, std::string > > GetConnections(
+ const std::string& origin, const std::string& destination
+ ) const;
+ void Connect(
+ const std::string& orig_filter, const std::string& dest_filter,
+ const std::string& output_name, const std::string& input_name
+ );
+ void Connect(
+ cpPlugins::BaseObjects::DataObject* output,
+ const std::string& dest_filter, const std::string& input_name
+ );
+ void Connect(
+ cpPlugins::BaseObjects::DataObject* output,
+ const std::string& exposed_input_name
+ );
+ void Disconnect(
+ const std::string& orig_filter, const std::string& dest_filter,
+ const std::string& output_name, const std::string& input_name
+ );
+ void Disconnect(
+ const std::string& dest_filter, const std::string& input_name
+ );
+ void Disconnect( const std::string& dest_filter );
+ */
// Pipeline execution
- void Execute( );
- void Execute( const std::string& name );
+ void Update( );
+ void Update( const std::string& name );
protected:
Workspace( );
Self& operator=( const Self& other );
protected:
+ TPlugins::Pointer m_Plugins;
TFilters m_Filters;
bool m_PrintExecution;
- TExposedPorts m_ExposedInputs;
- TExposedPorts m_ExposedOutputs;
+ /* TODO
+ TExposedPorts m_ExposedInputs;
+ TExposedPorts m_ExposedOutputs;
+ */
std::set< vtkRenderWindowInteractor* > m_Interactors;
};