ginga 1.0
The Ginga iTV middleware
Loading...
Searching...
No Matches
ginga::Switch Class Reference
Inheritance diagram for ginga::Switch:
Collaboration diagram for ginga::Switch:

Public Member Functions

 Switch (const string &)
 
string getObjectTypeAsString () override
 
string toString () override
 
bool beforeTransition (Event *, Event::Transition) override
 Initiates event transition.
 
bool afterTransition (Event *, Event::Transition) override
 Finishes event transition.
 
const list< pair< Object *, Predicate * > > * getRules ()
 
void addRule (Object *, Predicate *)
 
const map< string, list< Event * > > * getSwitchPorts ()
 
void addSwitchPort (const string &, const list< Event * > &)
 
- Public Member Functions inherited from ginga::Composition
 Composition (const string &)
 
const set< Object * > * getChildren ()
 
ObjectgetChildById (const string &)
 
ObjectgetChildByIdOrAlias (const string &)
 
void addChild (Object *)
 
- Public Member Functions inherited from ginga::Object
 Object (const string &)
 
string getId ()
 
DocumentgetDocument ()
 
void initDocument (Document *)
 
CompositiongetParent ()
 
void initParent (Composition *)
 
const list< pair< string, Composition * > > * getAliases ()
 
bool hasAlias (const string &)
 
void addAlias (const string &, Composition *=nullptr)
 
const set< Event * > * getEvents ()
 
EventgetEvent (Event::Type, const string &)
 
EventgetAttributionEvent (const string &)
 
void addAttributionEvent (const string &)
 
EventgetPresentationEvent (const string &)
 
EventgetPresentationEventByLabel (const string &)
 
void addPresentationEvent (const string &, Time, Time)
 
void addPresentationEvent (const string &, const string &)
 
EventgetSelectionEvent (const string &)
 
void addSelectionEvent (const string &)
 
EventgetLookAtEvent (const string &)
 
void addLookAtEvent (const string &)
 
EventgetLambda ()
 
bool isOccurring ()
 
bool isPaused ()
 
bool isSleeping ()
 
virtual string getProperty (const string &)
 
virtual void setProperty (const string &, const string &, Time dur=0)
 
const list< pair< Action, Time > > * getDelayedActions ()
 
void addDelayedAction (Event *, Event::Transition, const string &value="", Time delay=0)
 
virtual void sendKey (const string &, bool)
 
virtual void sendTick (Time, Time, Time)
 
Time getTime ()
 

Private Attributes

map< string, list< Event * > > _switchPorts
 List of switchPorts.
 
list< pair< Object *, Predicate * > > _rules
 
Object_selected
 

Additional Inherited Members

- Protected Member Functions inherited from ginga::Object
virtual void doStart ()
 
virtual void doStop ()
 
- Protected Attributes inherited from ginga::Composition
set< Object * > _children
 
- Protected Attributes inherited from ginga::Object
string _id
 
Document_doc
 
Composition_parent
 
list< pair< string, Composition * > > _aliases
 
Time _time
 
map< string, string > _properties
 
Event_lambda
 
set< Event * > _events
 
list< pair< Action, Time > > _delayed
 

Member Function Documentation

◆ afterTransition()

bool ginga::Switch::afterTransition ( Event * ,
Event::Transition  )
overridevirtual

Finishes event transition.

This function is called by Event::transition() immediately after transitioning evt. If the transition can finish successfully, the function returns true. Otherwise, if the transition must be reverted, e.g., due to some error, the function returns false.

Parameters
evtEvent that was transitioned.
transitionThe transition.
Returns
true if successful, or false otherwise (cancel transition).

Implements ginga::Object.

◆ beforeTransition()

bool ginga::Switch::beforeTransition ( Event * ,
Event::Transition  )
overridevirtual

Initiates event transition.

This function is called by Event::transition() immediately before transitioning evt. If the transition can go on, the function returns true. Otherwise, if the transition must be cancelled, e.g., due to some error, the function returns false.

Parameters
evtEvent to be transitioned.
transitionThe desired transition.
Returns
true if successful, or false otherwise (cancel transition).

Implements ginga::Object.

◆ getObjectTypeAsString()

string ginga::Switch::getObjectTypeAsString ( )
overridevirtual

Implements ginga::Object.

◆ toString()

string ginga::Switch::toString ( )
overridevirtual

Reimplemented from ginga::Object.


The documentation for this class was generated from the following files: