Inkscape
Vector Graphics Editor
Loading...
Searching...
No Matches
Inkscape::IO::BasicReader Class Reference

This class and its descendants are for unicode character-oriented input. More...

#include <inkscapestream.h>

Inheritance diagram for Inkscape::IO::BasicReader:
Inkscape::IO::Reader Inkscape::IO::InputStreamReader Inkscape::IO::StdReader

Public Member Functions

 BasicReader (Reader &sourceStream)
 
 ~BasicReader () override=default
 
int available () override
 Returns the number of bytes that can be read (or skipped over) from this reader without blocking by the next caller of a method for this reader.
 
void close () override
 Closes this reader and releases any system resources associated with the reader.
 
char get () override
 Reads the next byte of data from the reader.
 
Glib::ustring readLine () override
 Reads a line of data from the reader.
 
Glib::ustring readWord () override
 Reads a line of data from the reader.
 
const ReaderreadBool (bool &val) override
 
const Readeroperator>> (bool &val) override
 
const ReaderreadShort (short &val) override
 
const Readeroperator>> (short &val) override
 
const ReaderreadUnsignedShort (unsigned short &val) override
 
const Readeroperator>> (unsigned short &val) override
 
const ReaderreadInt (int &val) override
 
const Readeroperator>> (int &val) override
 
const ReaderreadUnsignedInt (unsigned int &val) override
 
const Readeroperator>> (unsigned int &val) override
 
const ReaderreadLong (long &val) override
 
const Readeroperator>> (long &val) override
 
const ReaderreadUnsignedLong (unsigned long &val) override
 
const Readeroperator>> (unsigned long &val) override
 
const ReaderreadFloat (float &val) override
 
const Readeroperator>> (float &val) override
 
const ReaderreadDouble (double &val) override
 
const Readeroperator>> (double &val) override
 
- Public Member Functions inherited from Inkscape::IO::Reader
 Reader ()=default
 Constructor.
 
virtual ~Reader ()=default
 Destructor.
 

Protected Member Functions

 BasicReader ()
 

Protected Attributes

Readersource
 

Detailed Description

This class and its descendants are for unicode character-oriented input.

Definition at line 323 of file inkscapestream.h.

Constructor & Destructor Documentation

◆ BasicReader() [1/2]

Inkscape::IO::BasicReader::BasicReader ( Reader sourceStream)

Definition at line 145 of file inkscapestream.cpp.

References source.

◆ ~BasicReader()

Inkscape::IO::BasicReader::~BasicReader ( )
overridedefault

◆ BasicReader() [2/2]

Inkscape::IO::BasicReader::BasicReader ( )
inlineprotected

Definition at line 384 of file inkscapestream.h.

References source.

Member Function Documentation

◆ available()

int Inkscape::IO::BasicReader::available ( )
overridevirtual

Returns the number of bytes that can be read (or skipped over) from this reader without blocking by the next caller of a method for this reader.

Implements Inkscape::IO::Reader.

Reimplemented in Inkscape::IO::InputStreamReader, and Inkscape::IO::StdReader.

Definition at line 155 of file inkscapestream.cpp.

References Inkscape::IO::Reader::available(), and source.

Referenced by readLine(), and readWord().

◆ close()

void Inkscape::IO::BasicReader::close ( )
overridevirtual

Closes this reader and releases any system resources associated with the reader.

Implements Inkscape::IO::Reader.

Reimplemented in Inkscape::IO::InputStreamReader, and Inkscape::IO::StdReader.

Definition at line 168 of file inkscapestream.cpp.

References Inkscape::IO::Reader::close(), and source.

◆ get()

char Inkscape::IO::BasicReader::get ( )
overridevirtual

Reads the next byte of data from the reader.

Implements Inkscape::IO::Reader.

Reimplemented in Inkscape::IO::InputStreamReader, and Inkscape::IO::StdReader.

Definition at line 177 of file inkscapestream.cpp.

References Inkscape::IO::Reader::get(), and source.

Referenced by readLine(), and readWord().

◆ operator>>() [1/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( bool &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 344 of file inkscapestream.h.

References readBool().

◆ operator>>() [2/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( double &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 376 of file inkscapestream.h.

References readDouble().

◆ operator>>() [3/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( float &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 372 of file inkscapestream.h.

References readFloat().

◆ operator>>() [4/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( int &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 356 of file inkscapestream.h.

References readInt().

◆ operator>>() [5/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( long &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 364 of file inkscapestream.h.

References readLong().

◆ operator>>() [6/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( short &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 348 of file inkscapestream.h.

References readShort().

◆ operator>>() [7/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( unsigned int &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 360 of file inkscapestream.h.

References readUnsignedInt().

◆ operator>>() [8/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( unsigned long &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 368 of file inkscapestream.h.

References readUnsignedLong().

◆ operator>>() [9/9]

const Reader & Inkscape::IO::BasicReader::operator>> ( unsigned short &  val)
inlineoverridevirtual

Implements Inkscape::IO::Reader.

Definition at line 352 of file inkscapestream.h.

References readUnsignedShort().

◆ readBool()

const Reader & Inkscape::IO::BasicReader::readBool ( bool &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 254 of file inkscapestream.cpp.

References buf, and readWord().

Referenced by operator>>().

◆ readDouble()

const Reader & Inkscape::IO::BasicReader::readDouble ( double &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 327 of file inkscapestream.cpp.

References buf, Inkscape::IO::getDouble(), and readWord().

Referenced by operator>>().

◆ readFloat()

const Reader & Inkscape::IO::BasicReader::readFloat ( float &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 318 of file inkscapestream.cpp.

References buf, Inkscape::IO::getDouble(), and readWord().

Referenced by operator>>().

◆ readInt()

const Reader & Inkscape::IO::BasicReader::readInt ( int &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 282 of file inkscapestream.cpp.

References buf, Inkscape::IO::getLong(), and readWord().

Referenced by operator>>().

◆ readLine()

Glib::ustring Inkscape::IO::BasicReader::readLine ( )
overridevirtual

Reads a line of data from the reader.

Implements Inkscape::IO::Reader.

Definition at line 189 of file inkscapestream.cpp.

References available(), and get().

◆ readLong()

const Reader & Inkscape::IO::BasicReader::readLong ( long &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 300 of file inkscapestream.cpp.

References buf, Inkscape::IO::getLong(), and readWord().

Referenced by operator>>().

◆ readShort()

const Reader & Inkscape::IO::BasicReader::readShort ( short &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 264 of file inkscapestream.cpp.

References buf, Inkscape::IO::getLong(), and readWord().

Referenced by operator>>().

◆ readUnsignedInt()

const Reader & Inkscape::IO::BasicReader::readUnsignedInt ( unsigned int &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 291 of file inkscapestream.cpp.

References buf, Inkscape::IO::getULong(), and readWord().

Referenced by operator>>().

◆ readUnsignedLong()

const Reader & Inkscape::IO::BasicReader::readUnsignedLong ( unsigned long &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 309 of file inkscapestream.cpp.

References buf, Inkscape::IO::getULong(), and readWord().

Referenced by operator>>().

◆ readUnsignedShort()

const Reader & Inkscape::IO::BasicReader::readUnsignedShort ( unsigned short &  val)
overridevirtual

Implements Inkscape::IO::Reader.

Definition at line 273 of file inkscapestream.cpp.

References buf, Inkscape::IO::getULong(), and readWord().

Referenced by operator>>().

◆ readWord()

Glib::ustring Inkscape::IO::BasicReader::readWord ( )
overridevirtual

Reads a line of data from the reader.

Implements Inkscape::IO::Reader.

Definition at line 205 of file inkscapestream.cpp.

References available(), and get().

Referenced by readBool(), readDouble(), readFloat(), readInt(), readLong(), readShort(), readUnsignedInt(), readUnsignedLong(), and readUnsignedShort().

Member Data Documentation

◆ source

Reader* Inkscape::IO::BasicReader::source
protected

Definition at line 382 of file inkscapestream.h.

Referenced by available(), BasicReader(), BasicReader(), close(), and get().


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