Gorgon Game Engine
LoadError Class Reference

This class represents a loading error. More...

Inheritance diagram for LoadError:
[legend]

Public Types

enum  ErrorType {
  Unknown, FileNotFound, Signature, VersionMismatch,
  Containment, UnknownNode, FileCannotBeOpened, NoFileObject,
  UnsupportedCompression
}
 Error types. More...
 

Public Member Functions

 LoadError (ErrorType number, const std::string &text)
 A constructor to allow custom text for the error. More...
 
 LoadError (ErrorType number=Unknown)
 Regular constructor, creates error text from error number. More...
 

Public Attributes

ErrorType number
 The type of loading error occurred. More...
 

Static Public Attributes

static const std::string ErrorStrings [8]
 Strings for error codes. More...
 

Detailed Description

This class represents a loading error.

Member Enumeration Documentation

◆ ErrorType

enum ErrorType

Error types.

Enumerator
Unknown 

An unknown error occurred.

FileNotFound 

Cannot find the given file.

Signature 

File does not contain correct signature and is probably not a Gorgon resource.

VersionMismatch 

Version in the file is not recognized.

Containment 

There is no containing root folder.

UnknownNode 

There is an unknown node in the file. This is never thrown in release mode.

FileCannotBeOpened 

Cannot open the given file.

NoFileObject 

There is no file object associated with the resource. Generally thrown during late loading.

UnsupportedCompression 

If the compression type in the file is not supported.

Constructor & Destructor Documentation

◆ LoadError() [1/2]

LoadError ( ErrorType  number = Unknown)

Regular constructor, creates error text from error number.

◆ LoadError() [2/2]

LoadError ( ErrorType  number,
const std::string &  text 
)

A constructor to allow custom text for the error.

Member Data Documentation

◆ ErrorStrings

const std::string ErrorStrings
static

Strings for error codes.

◆ number

ErrorType number

The type of loading error occurred.


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