OMK::Iii::AssociatedConnectorT< Type > Class Template Reference
[Interactive object]

The implementation class for associated connectors. More...

#include <OMKConnectors.h>

Inheritance diagram for OMK::Iii::AssociatedConnectorT< Type >:

Inheritance graph
[legend]
Collaboration diagram for OMK::Iii::AssociatedConnectorT< Type >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

virtual bool preConnect (const Name &interactor, const OMK::Type::AccessGroupLevel &freezeLevel, OMK::Type::AccessLevel tool)
 Connection method.
virtual bool loadParameters (const ConfigurationParameterDescriptor *node)
 Initialise the connector parameters with the configuration node.

Protected Attributes

IConnector_associatedConnector

Private Member Functions

 DECLARE_TEMPLATE_CONNECTOR_FACTORY (AssociatedConnectorT, Type)

Detailed Description

template<typename Type>
class OMK::Iii::AssociatedConnectorT< Type >

The implementation class for associated connectors.

Date:
2006-14-05
Author:
Beno� Chanclou
This connector allows the association with an other connector. This allows to offer two kinds of connector for the same attribute, for two categories or two type. See By offering two categories for the same parameter and By offering two types for the same parameter.
...
      Extensions
      {
        interaction
        {
          Class Interactive
          Connectors
          {
            parameter_number_one
            {
              Type Associated                          //<--- The new type
              AccessLevel 1
              Freezable on
              Category "absolute"                      //<--- The first category
              AssociatedTo parameter_number_one_offset //<--- The associated connector
            }
            parameter_number_one_inc                
            {
              Type Associated                          //<--- The new type
              Attribute parameter_number_one           //<--- The same id for the attribute
              AccessLevel 1
              Freezable on
              Category "offset"                        //<--- The other category
                                Convertor IntegratorInt
              AssociatedTo parameter_number_one        //<--- The associated connector
            }
...

Definition at line 254 of file OMKConnectors.h.


Member Function Documentation

template<typename Type>
OMK::Iii::AssociatedConnectorT< Type >::DECLARE_TEMPLATE_CONNECTOR_FACTORY ( AssociatedConnectorT< Type >  ,
Type   
) [private]

template<typename Type>
virtual bool OMK::Iii::AssociatedConnectorT< Type >::preConnect ( const Name interactor,
const OMK::Type::AccessGroupLevel freezeLevel,
OMK::Type::AccessLevel  tool 
) [virtual]

Connection method.

This method creates an input in its associated interactive object and connects it to the output of the interactor.
The name of the created input is the concatenation of the iterator name and its output.
See IConnector::connect.

Reimplemented from OMK::Iii::SimpleConnectorT< Type >.

template<typename T>
bool OMK::Iii::AssociatedConnectorT< T >::loadParameters ( const ConfigurationParameterDescriptor node  )  [virtual]

Initialise the connector parameters with the configuration node.

Parameters:
[in] node The configuration node of the connector
Can be owerwritten to add parameters to configure the connector. This method is called after all the connector of the object have been dynamically created. Does nothing by default.

Reimplemented from OMK::Iii::IConnector.

Definition at line 397 of file OMKConnectors.inl.

References OMK::Iii::AssociatedConnectorT< Type >::_associatedConnector, OMK::Iii::IConnector::_interactiveExtension, OMK::ParametersAccessor::get(), OMK::Iii::InteractiveExtension::getConnector(), OMK::Iii::IConnector::id(), and OMK::Iii::IConnector::loadParameters().

00398 {
00399   // Retrieve the associated connector
00400   Name id ;
00401   ParametersAccessor::get( node, "AssociatedTo", id ) ;
00402   _associatedConnector = this->_interactiveExtension->getConnector( id ) ;
00403 
00404   return OMK::Iii::SimpleConnectorT< T >::loadParameters( node ) ;
00405 }


Member Data Documentation

template<typename Type>
IConnector* OMK::Iii::AssociatedConnectorT< Type >::_associatedConnector [protected]

Definition at line 261 of file OMKConnectors.h.

Referenced by OMK::Iii::AssociatedConnectorT< Type >::loadParameters().


logo OpenMask

Documentation generated on Mon Jun 9 11:46:04 2008

Generated with doxygen by Dimitri van Heesch ,   1997-2007