#include <freMediaBridgeController.h>


Public Types | |
| typedef MediaContainer | ComponentType |
| typedef MediaContainerControllerBase < MediaContainer > | Superclass |
Public Member Functions | |
| virtual const char * | GetNameOfClass () const |
| MediaBridgeController () | |
| virtual ValidityTag::Pointer | GetMediaValidityTag (const MediaID &mediaID, SessionComponentCache *pComponentCache) const |
| virtual ValidityTag::Pointer | GetMediaValidityTagRequirement (const MediaID &mediaID, SessionComponentCache *pComponentCache) const |
| virtual std::string | GetMediaControllerID (const MediaID &mediaID, SessionComponentCache *pComponentCache) const |
Protected Member Functions | |
| virtual void | SetMediaCasted (const MediaID &mediaID, GenericMediaType *pMedia, ComponentType *pComponent, SessionComponentCache *pComponentCache, SessionInfo *pSessionInfo) const |
| virtual GenericMediaPointer | GetMediaCasted (const MediaID &mediaID, ComponentType *pComponent, SessionComponentCache *pComponentCache, SessionInfo *pSessionInfo) const |
Definition at line 38 of file freMediaBridgeController.h.
The component class managed by the controller. The component class must be a derivation from itk::LightObject to ensure the ability to use the smartpointer concept of itk
Reimplemented from FREE::MediaContainerControllerBase< TMediaContainer >.
Reimplemented in FREE::MediaDrainController.
Definition at line 41 of file freMediaBridgeController.h.
Reimplemented from FREE::MediaContainerControllerBase< TMediaContainer >.
Reimplemented in FREE::MediaDrainController.
Definition at line 42 of file freMediaBridgeController.h.
| FREE::MediaBridgeController::MediaBridgeController | ( | ) |
Definition at line 85 of file freMediaBridgeController.cxx.
References FREE::ComponentControllerInterface::m_Description, FREE::ControllerID::MediaBridgeController, and FREE::ComponentControllerInterface::UpdateControllerID().

| virtual const char* FREE::MediaBridgeController::GetNameOfClass | ( | ) | const [inline, virtual] |
Reimplemented from FREE::MediaContainerControllerBase< TMediaContainer >.
Reimplemented in FREE::MediaDrainController.
Definition at line 44 of file freMediaBridgeController.h.
| ValidityTag::Pointer FREE::MediaBridgeController::GetMediaValidityTag | ( | const MediaID & | mediaID, | |
| SessionComponentCache * | pComponentCache | |||
| ) | const [virtual] |
Retrieves the validity tag of the media specified by the mediaID. The tag is used to decide if a media component is outdated or up to date. It determines the time when the medium was actualized the last time. This can be used by other controllers that link to the media to decide if they may be outdated.
Reimplement GetMediaValidityTag() to realize special controller behavior.
This version checks the cache repository for an element with key "MediaValidityTag_[mediaID]" and returns the ValidityTag. (e.g.: mediaID = finalImage -> key = MediaValidityTag_finalImage). If no element exists with this key, but the media is defined in the controller profile, a NULL-ValidityTag will be returned (always outdated compared to others). If neither an element nor a profile entry can be found, an exception will be thrown.
| [in] | mediaID | ID specifying the wanted media. |
| [in] | pComponentCache | Pointer to the component cache. |
Reimplemented from FREE::ComponentControllerBase< TMediaContainer >.
Reimplemented in FREE::MediaDrainController.
Definition at line 93 of file freMediaBridgeController.cxx.
References catchAllNPassMacro, FREE::KeyedCollectionBase< TKey, TElement, TIdentifierClass >::GetElement(), FREE::ComponentControllerBase< TMediaContainer >::GetMediaValidityTag(), FREE::SessionAccessor::GetValidityTag(), FREE::ComponentSetup::MediaLinks(), FREE::SessionComponentCache::Setup(), and throwCtrlExceptionMacro.

| ValidityTag::Pointer FREE::MediaBridgeController::GetMediaValidityTagRequirement | ( | const MediaID & | mediaID, | |
| SessionComponentCache * | pComponentCache | |||
| ) | const [virtual] |
Retrieves the validity tag requirement of the media specified by the mediaID. The requirement is the most up to date ValidityTag in the dependency chain of a media component.
Reimplement GetMediaValidityTagRequirement() to realize special controller behavior accordingly a certain dependency chain.
This version returns only the ValidityTag of the specified media; thus the media has no dependencies.
| [in] | mediaID | ID specifying the wanted media. |
| [in] | pComponentCache | Pointer to the component cache. |
Reimplemented from FREE::ComponentControllerBase< TMediaContainer >.
Definition at line 114 of file freMediaBridgeController.cxx.
References catchAllNPassMacro, FREE::KeyedCollectionBase< TKey, TElement, TIdentifierClass >::GetElement(), FREE::ComponentControllerBase< TMediaContainer >::GetMediaValidityTagRequirement(), FREE::SessionAccessor::GetValidityTagRequirement(), FREE::ComponentSetup::MediaLinks(), FREE::SessionComponentCache::Setup(), and throwCtrlExceptionMacro.
Referenced by FREE::MediaDrainController::SaveMedia().

| std::string FREE::MediaBridgeController::GetMediaControllerID | ( | const MediaID & | mediaID, | |
| SessionComponentCache * | pComponentCache | |||
| ) | const [virtual] |
Retrieves the ID of the actual controller of the given media. Every controller has default types/controllers for its media, but they could be invalid by linking media (e.g. media type is intensity image media, but the actually linked medium could be of subtype region image media.).
| [in] | mediaID | ID specifying the wanted media. |
| [in] | pComponentCache | Pointer to the component cache. |
Reimplemented from FREE::ComponentControllerBase< TMediaContainer >.
Definition at line 135 of file freMediaBridgeController.cxx.
References catchAllNPassMacro, FREE::csUndefinedController, FREE::KeyedCollectionBase< TKey, TElement, TIdentifierClass >::GetElement(), FREE::SessionAccessor::GetMediaControllerID(), FREE::ComponentSetup::MediaLinks(), FREE::SessionComponentCache::Setup(), and throwCtrlExceptionMacro.

| void FREE::MediaBridgeController::SetMediaCasted | ( | const MediaID & | mediaID, | |
| GenericMediaType * | pMedia, | |||
| ComponentType * | pComponent, | |||
| SessionComponentCache * | pComponentCache, | |||
| SessionInfo * | pSessionInfo | |||
| ) | const [protected, virtual] |
Reimplemented in FREE::MediaDrainController.
Definition at line 61 of file freMediaBridgeController.cxx.
References catchAllNPassMacro, FREE::KeyedCollectionBase< TKey, TElement, TIdentifierClass >::GetElement(), FREE::ComponentSetup::MediaLinks(), FREE::SessionAccessor::SetMedia(), FREE::ComponentControllerBase< TMediaContainer >::SetMediaCasted(), FREE::SessionComponentCache::Setup(), and throwCtrlExceptionMacro.

| MediaBridgeController::GenericMediaPointer FREE::MediaBridgeController::GetMediaCasted | ( | const MediaID & | mediaID, | |
| ComponentType * | pComponent, | |||
| SessionComponentCache * | pComponentCache, | |||
| SessionInfo * | pSessionInfo | |||
| ) | const [protected, virtual] |
Implementation of FREE::MediaBridgeController //////////////////////
Definition at line 35 of file freMediaBridgeController.cxx.
References catchAllNPassMacro, FREE::KeyedCollectionBase< TKey, TElement, TIdentifierClass >::GetElement(), FREE::SessionAccessor::GetLinkedMedia(), FREE::ComponentControllerBase< TMediaContainer >::GetMediaCasted(), FREE::ComponentSetup::MediaLinks(), FREE::SessionComponentCache::Setup(), and throwCtrlExceptionMacro.

1.5.3 written by Dimitri van Heesch,
© 1997-2000