id3lib 3.8.3
ID3_MemoryReader Class Reference

#include <readers.h>

Inheritance diagram for ID3_MemoryReader:
ID3_Reader

Public Member Functions

 ID3_MemoryReader ()
 
 ID3_MemoryReader (const char_type *buf, size_type size)
 
 ID3_MemoryReader (const char *buf, size_type size)
 
virtual ~ID3_MemoryReader ()
 
virtual void close ()
 Close the reader.
 
virtual int_type peekChar ()
 Return the next character to be read without advancing the internal position.
 
virtual size_type readChars (char buf[], size_type len)
 Read up to len chars into buf and advance the internal position accordingly.
 
virtual size_type readChars (char_type buf[], size_type len)
 Read up to len characters into buf and advance the internal position accordingly.
 
virtual pos_type getCur ()
 Return the current position in the reader.
 
virtual pos_type getBeg ()
 Return the beginning position in the reader.
 
virtual pos_type getEnd ()
 Return the ending position in the reader.
 
virtual pos_type setCur (pos_type pos)
 Set the value of the internal position for reading.
 
- Public Member Functions inherited from ID3_Reader
virtual int_type readChar ()
 Read a single character and advance the internal position.
 
virtual size_type skipChars (size_type len)
 Skip up to len chars in the stream and advance the internal position accordingly.
 
virtual size_type remainingBytes ()
 
virtual bool atEnd ()
 

Protected Member Functions

void setBuffer (const char_type *buf, size_type size)
 

Additional Inherited Members

- Public Types inherited from ID3_Reader
typedef uint32 size_type
 
typedef uint8 char_type
 
typedef uint32 pos_type
 
typedef int32 off_type
 
typedef int16 int_type
 
- Static Public Attributes inherited from ID3_Reader
static const int_type END_OF_READER = -1
 

Detailed Description

Definition at line 88 of file readers.h.

Constructor & Destructor Documentation

◆ ID3_MemoryReader() [1/3]

ID3_MemoryReader::ID3_MemoryReader ( )
inline

Definition at line 101 of file readers.h.

◆ ID3_MemoryReader() [2/3]

ID3_MemoryReader::ID3_MemoryReader ( const char_type * buf,
size_type size )
inline

Definition at line 105 of file readers.h.

◆ ID3_MemoryReader() [3/3]

ID3_MemoryReader::ID3_MemoryReader ( const char * buf,
size_type size )
inline

Definition at line 109 of file readers.h.

◆ ~ID3_MemoryReader()

virtual ID3_MemoryReader::~ID3_MemoryReader ( )
inlinevirtual

Definition at line 113 of file readers.h.

Member Function Documentation

◆ close()

virtual void ID3_MemoryReader::close ( )
inlinevirtual

Close the reader.

Any further actions on the reader should fail.

Implements ID3_Reader.

Definition at line 114 of file readers.h.

◆ getBeg()

virtual pos_type ID3_MemoryReader::getBeg ( )
inlinevirtual

Return the beginning position in the reader.

Reimplemented from ID3_Reader.

Definition at line 139 of file readers.h.

◆ getCur()

virtual pos_type ID3_MemoryReader::getCur ( )
inlinevirtual

Return the current position in the reader.

Implements ID3_Reader.

Definition at line 134 of file readers.h.

◆ getEnd()

virtual pos_type ID3_MemoryReader::getEnd ( )
inlinevirtual

Return the ending position in the reader.

Reimplemented from ID3_Reader.

Definition at line 144 of file readers.h.

◆ peekChar()

virtual int_type ID3_MemoryReader::peekChar ( )
inlinevirtual

Return the next character to be read without advancing the internal position.

Returns END_OF_READER if there isn't a character to read.

Implements ID3_Reader.

Definition at line 116 of file readers.h.

◆ readChars() [1/2]

virtual size_type ID3_MemoryReader::readChars ( char buf[],
size_type len )
inlinevirtual

Read up to len chars into buf and advance the internal position accordingly.

Returns the number of characters read into buf.

Reimplemented from ID3_Reader.

Definition at line 128 of file readers.h.

◆ readChars() [2/2]

ID3_Reader::size_type ID3_MemoryReader::readChars ( char_type buf[],
size_type len )
virtual

Read up to len characters into buf and advance the internal position accordingly.

Returns the number of characters read into buf. Note that the value returned may be less than the number of bytes that the internal position advances, due to multi-byte characters.

Implements ID3_Reader.

Definition at line 33 of file readers.cpp.

◆ setBuffer()

void ID3_MemoryReader::setBuffer ( const char_type * buf,
size_type size )
inlineprotected

Definition at line 94 of file readers.h.

◆ setCur()

virtual pos_type ID3_MemoryReader::setCur ( pos_type pos)
inlinevirtual

Set the value of the internal position for reading.

Implements ID3_Reader.

Definition at line 151 of file readers.h.


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