Soprano 2.9.4
Public Member Functions | List of all members
Soprano::Error::ParserError Class Reference

Represents a parser error in Soprano. More...

#include <Soprano/Error/ParserError>

+ Inheritance diagram for Soprano::Error::ParserError:

Public Member Functions

 ParserError ()
 
 ParserError (const Locator &, const QString &message=QString(), int code=ErrorParsingFailed)
 
 ParserError (const Error &)
 
 ~ParserError ()
 
ParserErroroperator= (const Error &)
 
Locator locator () const
 
- Public Member Functions inherited from Soprano::Error::Error
 Error ()
 
 Error (const QString &message, int code=ErrorUnknown)
 
 Error (const Error &)
 
virtual ~Error ()
 
Erroroperator= (const Error &)
 
 operator bool () const
 
QString message () const
 
int code () const
 
bool isParserError () const
 
ParserError toParserError () const
 

Detailed Description

Represents a parser error in Soprano.

ParserError represents an error during parsing of either a query string (Soprano::Query::Parser::parseQuery()) or an RDF serialization (Soprano::Parser::parseStream()). Error and ParserError can be used together and copied without loosing information.

The following code is perfectly valid and works:

ParserError pe( 3, 4 );
Error e = pe;
ParserError otherPe = e;
qDebug() << "Parsing failed at line " << otherPe.line() << " and column " << otherPe.column();
Represents an error in Soprano.
Definition: error.h:78
Represents a parser error in Soprano.
Definition: error.h:201
Author
Sebastian Trueg trueg.nosp@m.@kde.nosp@m..org
See also
Error handling in Soprano

Definition at line 200 of file error.h.

Constructor & Destructor Documentation

◆ ParserError() [1/3]

Soprano::Error::ParserError::ParserError ( )

Create an Error object, representing success, i.e. no error.

◆ ParserError() [2/3]

Soprano::Error::ParserError::ParserError ( const Locator ,
const QString message = QString(),
int  code = ErrorParsingFailed 
)

◆ ParserError() [3/3]

Soprano::Error::ParserError::ParserError ( const Error )

◆ ~ParserError()

Soprano::Error::ParserError::~ParserError ( )

Member Function Documentation

◆ operator=()

ParserError & Soprano::Error::ParserError::operator= ( const Error )

◆ locator()

Locator Soprano::Error::ParserError::locator ( ) const

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