QtGStreamer  0.10.2
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator
Public Member Functions
QGst::Message Class Reference

#include <QGst/Message>

Inheritance diagram for QGst::Message:
Inheritance graph
Collaboration diagram for QGst::Message:
Collaboration graph

List of all members.

Public Member Functions

ObjectPtr source () const
quint64 timestamp () const
QString typeName () const
MessageType type () const
StructurePtr internalStructure ()
quint32 sequenceNumber () const
void setSequenceNumber (quint32 num)

Detailed Description

Wrapper class for GstMessage.

Messages are lightweight objects to signal the application of pipeline events. They are posted by objects in the pipeline and are passed to the application using the Bus.

Messages are implemented as a subclass of MiniObject with a generic GstStructure as the content. This allows for writing custom messages without requiring an API change while allowing a wide range of different types of messages.

In these bindings, for convenience, each message type has its own Message subclass. This does not reflect 1-1 the native C API, where there is only one Message class with tens of 'new_foo' and 'parse_foo' methods. You can use RefPointer::dynamicCast() to cast a MessagePtr to a RefPointer of one of the Message subclasses and it will behave as expected (i.e. it will only succeed if the message type matches the message type that the subclass handles). Note however that the Message subclasses cannot be used with Value::get(), since a GValue will actually contain a GstMessage (the subclasses do not exist in C) and Value::get() is not able to do dynamic casts. As a result of that, Message subclasses also cannot be used as arguments in slots connected to GObject signals, even though you may know that your slot will only be called with that type of message.

Definition at line 47 of file message.h.

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