1 #ifndef __CPPLUGINS__INTERFACE__PROCESSOBJECT__HXX__
2 #define __CPPLUGINS__INTERFACE__PROCESSOBJECT__HXX__
4 // -------------------------------------------------------------------------
6 T* cpPlugins::Interface::ProcessObject::
7 GetInput( unsigned int idx )
9 if( idx < this->m_Inputs.size( ) )
10 return( dynamic_cast< T* >( this->m_Inputs[ idx ].GetPointer( ) ) );
15 // -------------------------------------------------------------------------
17 const T* cpPlugins::Interface::ProcessObject::
18 GetInput( unsigned int idx ) const
20 if( idx < this->m_Inputs.size( ) )
22 dynamic_cast< const T* >( this->m_Inputs[ idx ].GetPointer( ) )
28 // -------------------------------------------------------------------------
30 T* cpPlugins::Interface::ProcessObject::
31 GetOutput( unsigned int idx )
33 if( idx < this->m_Outputs.size( ) )
34 return( dynamic_cast< T* >( this->m_Outputs[ idx ].GetPointer( ) ) );
39 // -------------------------------------------------------------------------
41 const T* cpPlugins::Interface::ProcessObject::
42 GetOutput( unsigned int idx ) const
44 if( idx < this->m_Outputs.size( ) )
46 dynamic_cast< const T* >( this->m_Outputs[ idx ].GetPointer( ) )
52 // -------------------------------------------------------------------------
54 void cpPlugins::Interface::ProcessObject::
55 _MakeOutput( unsigned int idx )
57 if( idx >= this->m_Outputs.size( ) )
59 this->m_Outputs[ idx ] = O::New( );
60 this->m_Outputs[ idx ]->SetSource( this );
63 #endif // __CPPLUGINS__INTERFACE__PROCESSOBJECT__HXX__