ComponentInterface Class Reference

#include <componentInterface.h>

Inheritance diagram for ComponentInterface:

Inheritance graph
[legend]
List of all members.

Public Member Functions

 ComponentInterface ()
 Default constructor.
virtual ~ComponentInterface ()
 Destructor.
virtual bool isValid () const
 This will return true if the interface is valid.
SimComponentgetOwner ()
 Get the owner of this interface.
const SimComponentgetOwner () const
virtual bool assign (SimComponent *owner)
 This method is called in SimComponent::registerCachedInterface, and it should not get called anywhere else.
virtual void unassign ()
 This method is called in SimComponent::registerUnCachedInterface, and should not be called anywhere else.

Protected Attributes

SimComponentmOwner
 SimComponent _should no longer_ directly modify this value.

Constructor & Destructor Documentation

ComponentInterface::ComponentInterface (  )  [inline]

Default constructor.

virtual ComponentInterface::~ComponentInterface (  )  [inline, virtual]

Destructor.


Member Function Documentation

virtual bool ComponentInterface::isValid (  )  const [inline, virtual]

This will return true if the interface is valid.

Reimplemented in ValueWrapperInterface< T >, UnitTestComponentInterface, and ValueWrapperInterface< Box3F >.

SimComponent* ComponentInterface::getOwner (  )  [inline]

Get the owner of this interface.

const SimComponent* ComponentInterface::getOwner (  )  const [inline]

virtual bool ComponentInterface::assign ( SimComponent owner  )  [inline, virtual]

This method is called in SimComponent::registerCachedInterface, and it should not get called anywhere else.

The method can be overridden and if it returns false, than the interface will not get cached on the component, and registerCachedInterface will return false. If you return false from this method, mOwner should be set to NULL so that getOwner() returns properly, otherwise the interface will be unstable.

virtual void ComponentInterface::unassign (  )  [inline, virtual]

This method is called in SimComponent::registerUnCachedInterface, and should not be called anywhere else.

This method can be overridden, but the parent should be called.


Member Data Documentation

SimComponent _should no longer_ directly modify this value.