Public Types | Public Member Functions | Protected Attributes
MAKLogger::DtMessageBuffer Class Reference

Message buffer class responsible for storing a list of messages and iterating through that list. More...

+ Collaboration diagram for MAKLogger::DtMessageBuffer:

List of all members.

Public Types

typedef std::list< DtPacket * > PacketList

Public Member Functions

 DtMessageBuffer ()
 CTOR creates an empty buffer.
 ~DtMessageBuffer ()
 DTOR clears the buffer before destructing.
const DtPacketfirst () const
 Get the first packet in the buffer.
const DtPacketlast () const
 Get the last packet in the buffer.
void setTime (DtAbsoluteTime)
 Sets the time of all messages in the buffer to the given time.
void sortByTime ()
 Sorts all messages by their time.
void offsetTime (DtRelativeTime offset)
 Adds the offset time to all messages in the buffer.
void add (DtPacket *)
 Packet is added to list and ownership is maintained.
void clear ()
 Clears the buffer and deletes all packets.
void merge (DtMessageBuffer &secondary)
 Merge two message buffers together, the secondary message buffer is cleared.
void merge (DtMessageBuffer &secondary, const DtAbsoluteTime &time, bool inclusive)
 Merge two message buffers together up to a specific time.
void merge (DtMessageBuffer &secondary, int count)
 Move a number of packets from the secondary head to the this buffer's tail.
size_t size () const
 Get the size of the buffer in packets.
size_t sizeOfPackets () const
 Get the size of the packets in the buffer in bytes.
void unfilterAll () const
 unfilter each packet in buffer.
void addAttribute (DtPacketAttributeSP attr)
 Add the attribute to each packet.
PacketList::iterator begin ()
 Get the iterator pointing to the first packet.
PacketList::const_iterator begin () const
 Get the iterator pointing to the first packet.
PacketList::iterator end ()
 Get the iterator pointing beyond the last packet.
PacketList::const_iterator end () const
 Get the iterator pointing beyond the last packet.

Protected Attributes

PacketList myMessages

Detailed Description

Message buffer class responsible for storing a list of messages and iterating through that list.


Member Function Documentation

void MAKLogger::DtMessageBuffer::merge ( DtMessageBuffer secondary)

Merge two message buffers together, the secondary message buffer is cleared.

void MAKLogger::DtMessageBuffer::merge ( DtMessageBuffer secondary,
const DtAbsoluteTime time,
bool  inclusive 
)

Merge two message buffers together up to a specific time.

All messages before that time are moved from the secondary buffer into this buffer. The time boundary can be inclusive.

void MAKLogger::DtMessageBuffer::merge ( DtMessageBuffer secondary,
int  count 
)

Move a number of packets from the secondary head to the this buffer's tail.

void MAKLogger::DtMessageBuffer::offsetTime ( DtRelativeTime  offset)

Adds the offset time to all messages in the buffer.

If the resulting time of any of the packets is less than zero the timestamp will be set to zero.


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

Document ID: Generated on Tue Oct 11 19:41:03 EDT 2011 from SVN revision 107422
Copyright © 2005-2011 VT MÄK Inc. All Rights Reserved (www.mak.com)