Main Page | Class Hierarchy | Class List | File List | Class Members | File Members | Related Pages

MP3Iterator Class Reference

Wrapper class for MP3 stream. More...

Collaboration diagram for MP3Iterator:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 MP3Iterator (Bitstream &bs, int type)
 ~MP3Iterator ()
MP3Frameoperator-> () const
MP3Iteratoroperator++ ()

Detailed Description

Wrapper class for MP3 stream.

This class should used always to access frames from an MP3 stream. Frames are deallocated automatically when they are not needed, so it's really dangerous to keep pointer to more than one frame. This class does not allow it, while providing tranesparent acces to MP3Frame methods.

Definition at line 22 of file mp3iterator.h.


Constructor & Destructor Documentation

MP3Iterator::MP3Iterator Bitstream bs,
int  type
 

Constructor.

Construts an MP3Stream and reads first frame.

Parameters:
bs Input Bitstream
type Write mode as defined in MP3Frame

Definition at line 8 of file mp3iterator.cpp.

References MP3Stream::First().

MP3Iterator::~MP3Iterator  ) 
 

Destructor.

Deletes MP3Stream with all allocated frames.

Definition at line 14 of file mp3iterator.cpp.


Member Function Documentation

MP3Iterator & MP3Iterator::operator++  ) 
 

Moves to next frame.

Also deletes unneded frames.

Returns:
itself

Definition at line 24 of file mp3iterator.cpp.

References MP3Frame::Next(), MP3Frame::normal, MP3Stream::SeekTo(), and MP3Stream::WriteMode().

MP3Frame * MP3Iterator::operator->  )  const
 

Redirection to method of MP3Frame.

This way all methods are accessible and no one needs to keep a pointer to real frame

Returns:
Current frame

Definition at line 19 of file mp3iterator.cpp.


Generated on Wed Sep 6 00:18:19 2006 for Kraken by  doxygen 1.4.4