![]() |
![]() ![]()
|
|||
|
This reference documents the internal and external classes and messages of 'libpakt' and [pgstd] relevant to accessors. Internal classes cannot be instantiated via the 'Access Methods', but are relevant because external classes derive from them and inherit their attributes. External classes are listed here with their XML element name as class name, and are used directly in the serialization/deserialization process. |
||||
|
||||
4.1 p: namespaceThe p: namespace contains basic pakt classes and messages. It's URN is "http://subsignal.org/pakt/p/1.0". |
||||
|
| ||||
4.1.1 Classes in p: |
||||
|
| ||||
|
Object |
the root of pakt's internal class hierarchy. As an accessor, you will rarely be confronted with a raw pObject, but all objects inherit from it the name attribute. |
|||
|
name |
The name of an object, together with the names of all it's parents, defines its address for pakt's addressing scheme. It must be unique within all of it's parent's children (within it's siblings). If no name attribute is present when a pakt server encounters an object, a name will be made up. Names should not contain special characters like / or space. To be safe, make up names that consist solely of letters, digits, '-'s and underscores. |
|||
|
| ||||
|
GObject |
Inheritance graph: Object -> GObject wraps a glib-style object. On creation, it will scan the wrapped object's properties and add them as 'p:property' objects to itself. This is done before the deserialization of children, so delivering valid GProperties with the instantiation of a GObject will set the properties as expected. see also: 'GObject Interaction' |
|||
|
| ||||
|
p:property |
Inheritance graph: Object -> p:property wraps a glib-style property of the parent object.
|
|||
|
value |
the property value, converted to a string |
|||
|
| ||||
|
p:spec |
Inheritance graph: Object -> p:spec wraps a property's specification (GParamSpec), read-only. Always a child of 'p:property'.
|
|||
|
type |
the property data type. Primitive data types are: string, bool, int, uint, long, ulong, int64, uint64, float and double. the type attribute can contain any other glib-type name, though (for instance, a class name). |
|||
|
nick |
the nickname of the property |
|||
|
blurb |
a short text describing the property |
|||
|
default |
the default value of the property (not present if NULL) |
|||
|
minimum |
the minimum allowed value for numeric properties (not present for 'string's) |
|||
|
maximum |
the maximum allowed value for numeric properties (not present for 'string's) |
|||
|
readable |
wether the property is readable |
|||
|
writable |
wether the property is writable |
|||
|
| ||||
|
NamedGObject |
Inheritance graph: Object ->
GObject -> NamedGObject NamedGObjects wrap the special case of 'GObject's that have a "name" property themselves. The name of the wrapping object and that of the wrapped object are linked bidirectionally: if either one is changed, the other one is updated, too. |
|||
|
| ||||
|
Message |
Inheritance graph: Object -> Message a special object that will not really be attached to any other object, but redirect its contents to the specified 'target'. The basic messages are documented in 'Messages in p:'. If no target attribute is given, the message will be directed to the same target as its parent XML element; if the message has no parent, it will be directed to the root of the server's object space. see also: 'Messages' |
|||
|
target |
the target this message will be delivered to, following the 'Addressing Scheme'. |
|||
|
source |
the source of this message (optional). |
|||
|
| ||||
|
Private |
Whenever the server encounters an XML element with a name it cannot relate to any internal class, it will construct a private object to store the given data. This way, you can store arbitrary private data almost anywhere in the server's object space. Be aware, though, that you cannot manipulate the contents (children and attributes) of a private object using the usual functionality. Doing so will result in errors, data loss, memory leaks and possibly other Bad Stuff(TM). see also: 'Private Data' |
|||
|
| ||||
|
error |
If the server encounters an error during execution of some function, it will reply with an error object containing a descriptive error message as XML string content. |
|||
|
| ||||
4.1.2 Messages in p: |
||||
|
| ||||
|
p:get |
Inheritance graph: Object ->
Message -> p:get sending a 'get' message to some object of the object hierarchy will result in a reply containing the target object. |
|||
|
| ||||
|
p:set |
Inheritance graph: Object ->
Message -> p:set a 'set' message will update all attributes, and, recursively, all children of the target object.
|
|||
|
| ||||
|
p:add |
Inheritance graph: Object ->
Message -> p:add an 'add' message will deserialize its children and add them to the target object.
|
|||
|
| ||||
|
p:remove |
Inheritance graph: Object ->
Message -> p:remove a 'remove' message will remove the target object and all its children from the object space. |
|||
|
| ||||
|
p:monitor |
Inheritance graph: Object ->
Message -> p:monitor 'monitor' messages will attach a "watchdog" to the target object, so that you will receive notifications whenever some part of that object is changed. What kind of changes are monitored is determined by the 'what' property. If no 'what' property is given, all possible changes are monitored. The messages you get sent in response to a change will have a 'source' attribute corresponding to the location of the emitting object. If you set the 'replyto' attribute, its value will fill the 'target' of the message that is sent. |
|||
|
what |
defines which kind of changes are to be monitored. Must be one of the following, or empty:
|
|||
|
replyto |
the 'target' to send the notifications to. |
|||
|
||||
4.2 gst: namespaceThe gst: namespace contains classes that wrap gstreamer elements and other gstreamer fuctionality. It's URN is "http://subsignal.org/pakt/pgst/1.0". |
||||
|
| ||||
4.2.1 Classes in gst: |
||||
|
| ||||
|
Element |
Inheritance graph: Object ->
GObject ->
NamedGObject -> Element wraps a gstreamer element. From this base class, 'dynamic' classes for all available gstreamer elements are constructed. The derived classes will be in the 'gst: namespace' and have the name of the gstreamer element factory, for instance "gst:xvideosink". The element's parameters are added as 'p:property's by the more generic 'GObject' class. When the element is a gstreamer "bin" (bin, thread, or pipeline), the wrapped gstreamer elements of other 'Element's being added to the element will be added to the bin. The pads of the gstreamer element will be added as 'gst:pad' objects in a fashion very similar to that of 'p:property's being automatically generated for 'GObject's. |
|||
|
state |
describes the playing state of the element, can be one of:
Setting the 'state' attribute will attempt to change the state of the wrapped gstreamer element. The attribute will always reflect the current playing state. |
|||
|
| ||||
|
gst:pad |
Inheritance graph: Object ->
GObject ->
NamedGObject -> gst:pad wraps a gstreamer element pad. |
|||
|
direction |
describes the direction of the pad, can be one of:
'direction' is read-only. Setting it will produce no effect. |
|||
|
peer |
the peer (other 'gst:pad') this pad is linked to, in pakt 'Addressing Scheme' notation. Will be empty when the pad is unlinked. Setting the 'peer' property will unlink the pad if it is already connected, and attempt to link it to the given peer pad. The value of 'peer' will always contain the relative path to the current peer pad. |
|||
| ||||
![]() |
Warsaw Pakt: Accessor's Manual: Reference | |||