|
ginga 1.0
The Ginga iTV middleware
|
NCL document. More...
#include <Document.h>

Public Member Functions | |
| Document () | |
| Creates a new document. | |
| Document (const string &) | |
| Creates a new document with id. | |
| virtual | ~Document () |
| Destroys document. | |
| const set< Object * > * | getObjects () |
| Gets document objects. | |
| Object * | getObjectById (const string &) |
| Gets document object by id. | |
| Object * | getObjectByIdOrAlias (const string &) |
| Gets document object by id or alias. | |
| bool | addObject (Object *) |
| Adds object to document. | |
| const string | getId () |
| Gets document id. | |
| Context * | getRoot () |
| Gets document's root object. | |
| MediaSettings * | getSettings () |
| Gets document's settings object. | |
| const set< Media * > * | getMedias () |
| const set< Media * > * | getMediasRemote () |
| const set< Context * > * | getContexts () |
| const set< Switch * > * | getSwitches () |
| int | evalAction (Event *, Event::Transition, const string &value="") |
| Evaluates action over document. | |
| int | evalAction (Action) |
| Evaluates action over document. | |
| bool | evalPredicate (Predicate *) |
| bool | evalPropertyRef (const string &, string *) |
| bool | getData (const string &, void **) |
| bool | setData (const string &, void *, UserDataCleanFunc fn=nullptr) |
Private Member Functions | |
| list< Action > | evalActionInContext (Action, Context *) |
| Evaluates action over Context. | |
Private Attributes | |
| string | _id |
| set< Object * > | _objects |
| Objects. | |
| map< string, Object * > | _objectsById |
| Objects indexed by id. | |
| Context * | _root |
| Root context (body). | |
| MediaSettings * | _settings |
| Settings object. | |
| set< Media * > | _medias |
| Media objects. | |
| set< Media * > | _mediasRemote |
| Media objects. | |
| set< Context * > | _contexts |
| Context objects. | |
| set< Switch * > | _switches |
| Switch objects. | |
| UserData | _udata |
| Attached user data. | |
NCL document.
Maintains all objects in document.
| ginga::Document::Document | ( | ) |
Creates a new document.
This function creates a new NCL document containing a root context (the document body) with id "__root__" and a child settings media object with id "__settings__".
| ginga::Document::Document | ( | const string & | id | ) |
Creates a new document with id.
|
virtual |
Destroys document.
This function destroys the document and all its child objects.
| bool ginga::Document::addObject | ( | Object * | obj | ) |
Adds object to document.
This function assumes that obj is not in another document.
| obj | The object to add. |
true if successful, or false otherwise (object already in document). | const string ginga::Document::getId | ( | ) |
Gets document id.
| Object * ginga::Document::getObjectById | ( | const string & | id | ) |
Gets document object by id.
| id | Object id. |
| Object * ginga::Document::getObjectByIdOrAlias | ( | const string & | id | ) |
Gets document object by id or alias.
| id | Object id or alias. |
| const set< Object * > * ginga::Document::getObjects | ( | ) |
Gets document objects.
| Context * ginga::Document::getRoot | ( | ) |
Gets document's root object.
| MediaSettings * ginga::Document::getSettings | ( | ) |
Gets document's settings object.