Medical Imaging Interaction Toolkit  2024.06.99-60d9b802
Medical Imaging Interaction Toolkit
berry::ISourceProvider Struct Referenceabstract

#include <berryISourceProvider.h>

Inheritance diagram for berry::ISourceProvider:
Collaboration diagram for berry::ISourceProvider:

Public Types

typedef QHash< QString, Object::ConstPointerStateMapType
 
- Public Types inherited from berry::Object
typedef Object Self
 
typedef berry::SmartPointer< SelfPointer
 
typedef berry::SmartPointer< const SelfConstPointer
 
typedef berry::WeakPointer< SelfWeakPtr
 
typedef berry::WeakPointer< const SelfConstWeakPtr
 

Public Member Functions

 berryObjectMacro (berry::ISourceProvider)
 
 ~ISourceProvider () override
 
virtual void AddSourceProviderListener (ISourceProviderListener *listener)=0
 
virtual StateMapType GetCurrentState () const =0
 
virtual QList< QString > GetProvidedSourceNames () const =0
 
virtual void RemoveSourceProviderListener (ISourceProviderListener *listener)=0
 
- Public Member Functions inherited from berry::Object
virtual QString GetClassName () const
 
virtual Reflection::TypeInfo GetTypeInfo () const
 
virtual QList< Reflection::TypeInfoGetSuperclasses () const
 
virtual void Delete ()
 
QDebug Print (QDebug os, Indent Indent=0) const
 
virtual QString ToString () const
 
virtual uint HashCode () const
 
virtual bool operator< (const Object *) const
 
void Register () const
 
void UnRegister (bool del=true) const
 
int GetReferenceCount () const
 
void SetReferenceCount (int)
 
void AddDestroyListener (const MessageAbstractDelegate<> &delegate) const
 
void RemoveDestroyListener (const MessageAbstractDelegate<> &delegate) const
 
virtual bool operator== (const Object *) const
 

Additional Inherited Members

- Static Public Member Functions inherited from berry::Object
static const char * GetStaticClassName ()
 
static Reflection::TypeInfo GetStaticTypeInfo ()
 
static QList< Reflection::TypeInfoGetStaticSuperclasses ()
 
- Protected Member Functions inherited from berry::Object
 Object ()
 
virtual ~Object ()
 
virtual QDebug PrintSelf (QDebug os, Indent indent) const
 
virtual QDebug PrintHeader (QDebug os, Indent indent) const
 
virtual QDebug PrintTrailer (QDebug os, Indent indent) const
 
- Protected Attributes inherited from berry::Object
QAtomicInt m_ReferenceCount
 
QMutex m_ReferenceCountLock
 

Detailed Description

A provider of notifications for when a change has occurred to a particular type of source. These providers can be given to the appropriate service, and this service will then re-evaluate the appropriate pieces of its internal state in response to these changes.

It is recommended that clients subclass AbstractSourceProvider instead, as this provides some common support for listeners.

See also
IHandlerService
ISources

Definition at line 43 of file berryISourceProvider.h.

Member Typedef Documentation

◆ StateMapType

Definition at line 48 of file berryISourceProvider.h.

Constructor & Destructor Documentation

◆ ~ISourceProvider()

berry::ISourceProvider::~ISourceProvider ( )
override

Member Function Documentation

◆ AddSourceProviderListener()

virtual void berry::ISourceProvider::AddSourceProviderListener ( ISourceProviderListener listener)
pure virtual

Adds a listener to this source provider. This listener will be notified whenever the corresponding source changes.

Parameters
listenerThe listener to add; must not be null.

Implemented in berry::AbstractSourceProvider.

◆ berryObjectMacro()

berry::ISourceProvider::berryObjectMacro ( berry::ISourceProvider  )

◆ GetCurrentState()

virtual StateMapType berry::ISourceProvider::GetCurrentState ( ) const
pure virtual

Returns the current state of the sources tracked by this provider. This is used to provide a view of the world if the event loop is busy and things are some state has already changed.

For use with core expressions, this map should contain IEvaluationContext::UNDEFINED_VARIABLE for properties which are only sometimes available.

Returns
A map of variable names (String) to variable values (Object). This may be empty, and may be null.

◆ GetProvidedSourceNames()

virtual QList<QString> berry::ISourceProvider::GetProvidedSourceNames ( ) const
pure virtual

Returns the names of those sources provided by this class. This is used by clients of source providers to determine which source providers they actually need.

Returns
An array of source names. This value should never be null or empty.

◆ RemoveSourceProviderListener()

virtual void berry::ISourceProvider::RemoveSourceProviderListener ( ISourceProviderListener listener)
pure virtual

Removes a listener from this source provider. This listener will be notified whenever the corresponding source changes.

Parameters
listenerThe listener to remove; must not be null.

Implemented in berry::AbstractSourceProvider.


The documentation for this struct was generated from the following file: