Public Member Functions | Public Attributes

gnash::rtmp::RTMPPacket Struct Reference

An RTMPPacket class contains a full description of an RTMP packet. More...

#include <RTMP.h>

Collaboration diagram for gnash::rtmp::RTMPPacket:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 RTMPPacket (size_t reserve=0)
 Construct a packet with an optional reserved memory allocation.
 RTMPPacket (const RTMPPacket &other)
 Copy constructor.
 ~RTMPPacket ()

Public Attributes

RTMPHeader header
boost::shared_ptr< SimpleBufferbuffer
 A buffer with enough storage to write the entire message.
size_t bytesRead

Detailed Description

An RTMPPacket class contains a full description of an RTMP packet.

This comprises: header information an AMF payload. An RTMPPacket may be copied without a large penalty. This is to allow storage in the RTMP client's channels.


Constructor & Destructor Documentation

gnash::rtmp::RTMPPacket::RTMPPacket ( size_t  reserve = 0  )  [explicit]

Construct a packet with an optional reserved memory allocation.

Parameters:
reserve The amount of space in bytes to reserve for the message body. This can save reallocations when appending AMF data. Space for the header is always reserved and is not affected by this parameter.
gnash::rtmp::RTMPPacket::RTMPPacket ( const RTMPPacket other  ) 

Copy constructor.

Creates an identical RTMPPacket with shared ownership of the buffer.

References gnash::rtmp::RTMPHeader::headerSize.

gnash::rtmp::RTMPPacket::~RTMPPacket (  )  [inline]

Member Data Documentation

A buffer with enough storage to write the entire message.

This always includes at least the header. Storage for the message payload is added as necessary.

Referenced by gnash::rtmp::clearPayload(), gnash::rtmp::hasPayload(), gnash::rtmp::payloadData(), gnash::rtmp::payloadEnd(), and gnash::rtmp::payloadSize().

Referenced by gnash::rtmp::isReady().


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