Support Forum       G3D Web Page     
Public Types | Public Member Functions | Public Attributes | List of all members
G3D::TextInput::WrongTokenType Class Reference

Thrown by the read methods. More...

Inherits G3D::TextInput::TokenException.

Public Types

enum  { UNKNOWN = -1 }
 

Public Member Functions

 WrongTokenType (const String &src, int ln, int ch, Token::Type e, Token::Type a)
 
String formatFileInfo () const
 If information is known, ends in ": ", otherwise empty. More...
 

Public Attributes

Token::Type actual
 
int64 byte
 For a binary file, the location of the parse error. More...
 
int character
 Character number (in the line) of the start of the token which caused the exception. More...
 
Token::Type expected
 
String filename
 Empty means unknown. More...
 
int line
 For a text file, the line number is the line number of start of token which caused the exception. More...
 
String message
 

Detailed Description

Thrown by the read methods.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
inherited
Enumerator
UNKNOWN 

Constructor & Destructor Documentation

◆ WrongTokenType()

G3D::TextInput::WrongTokenType::WrongTokenType ( const String src,
int  ln,
int  ch,
Token::Type  e,
Token::Type  a 
)

Member Function Documentation

◆ formatFileInfo()

String G3D::ParseError::formatFileInfo ( ) const
inherited

If information is known, ends in ": ", otherwise empty.

Referenced by G3D::AnyTableReader::get().

Member Data Documentation

◆ actual

Token::Type G3D::TextInput::WrongTokenType::actual

◆ byte

int64 G3D::ParseError::byte
inherited

For a binary file, the location of the parse error.

ParseError::UNKNOWN if unknown.

◆ character

int G3D::ParseError::character
inherited

Character number (in the line) of the start of the token which caused the exception.

1 is the character in the line. ParseError::UNKNOWN if unknown.

Referenced by G3D::Any::IndexOutOfBounds::IndexOutOfBounds(), and G3D::Any::KeyNotFound::KeyNotFound().

◆ expected

Token::Type G3D::TextInput::WrongTokenType::expected

◆ filename

String G3D::ParseError::filename
inherited

◆ line

int G3D::ParseError::line
inherited

For a text file, the line number is the line number of start of token which caused the exception.

1 is the first line of the file. ParseError::UNKNOWN if unknown. Note that you can use TextInput::Settings::startingLineNumberOffset to shift the effective line number that is reported by that class.

Referenced by G3D::Any::IndexOutOfBounds::IndexOutOfBounds(), and G3D::Any::KeyNotFound::KeyNotFound().

◆ message

String G3D::ParseError::message
inherited

documentation generated on Wed Nov 24 2021 08:02:01 using doxygen 1.8.15