QtGStreamer 1.2.0
|
#include <QGst/Message>
Public Member Functions | |
ObjectPtr | source () const |
quint64 | timestamp () const |
QString | typeName () const |
MessageType | type () const |
StructureConstPtr | internalStructure () |
quint32 | sequenceNumber () const |
void | setSequenceNumber (quint32 num) |
![]() | |
MiniObjectPtr | copy () const |
bool | isWritable () const |
MiniObjectPtr | makeWritable () const |
Additional Inherited Members | |
![]() | |
typedef GstMiniObject | CType |
![]() | |
MiniObject (const MiniObject &) | |
MiniObject & | operator= (const MiniObject &) |
virtual void | ref (bool increaseRef) |
virtual void | unref () |
![]() | |
template<class T > | |
T * | object () const |
![]() | |
void * | m_object |
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.
ObjectPtr QGst::Message::source | ( | ) | const |
Definition at line 26 of file message.cpp.
quint64 QGst::Message::timestamp | ( | ) | const |
Definition at line 31 of file message.cpp.
QString QGst::Message::typeName | ( | ) | const |
Definition at line 36 of file message.cpp.
MessageType QGst::Message::type | ( | ) | const |
Definition at line 41 of file message.cpp.
StructureConstPtr QGst::Message::internalStructure | ( | ) |
Definition at line 46 of file message.cpp.
quint32 QGst::Message::sequenceNumber | ( | ) | const |
Definition at line 52 of file message.cpp.
void QGst::Message::setSequenceNumber | ( | quint32 | num | ) |
Definition at line 57 of file message.cpp.