SaxonC 12.4
Saxon Processor library for C/C++, PHP and Python
Loading...
Searching...
No Matches
SaxonApiException.h
1#ifndef SAXON_API_EXCEPTION_H
2#define SAXON_API_EXCEPTION_H
3
5// Copyright (c) 2022 - 2023 Saxonica Limited.
6// This Source Code Form is subject to the terms of the Mozilla Public License,
7// v. 2.0. If a copy of the MPL was not distributed with this file, You can
8// obtain one at http://mozilla.org/MPL/2.0/. This Source Code Form is
9// "Incompatible With Secondary Licenses", as defined by the Mozilla Public
10// License, v. 2.0.
12
13#include "SaxonProcessor.h"
14#include <exception>
15#include <iostream>
16
17class SaxonProcessor;
18
23class SaxonApiException : public std::exception {
24
25public:
29 SaxonApiException(bool staticError = false);
30
35 SaxonApiException(const char *err);
36
42
48 virtual const char *what();
49
60 SaxonApiException(const char *message, const char *errorCode,
61 const char *systemId, int linenumber);
62
66 virtual ~SaxonApiException() throw();
67
73 const char *getErrorCode();
74
81 int getLineNumber();
82
89 const char *getMessage();
90
98 const char *getMessageWithErrorCode();
99
107 const char *getCombinedStaticErrorMessages();
108
109 int staticErrorCount();
110
114 const char *getSystemId();
115
116private:
117 bool cppException;
118 bool isStaticError;
119 std::string message;
120 std::string s_message;
121 std::string ec_message;
122 int lineNumber;
123 std::string errorCode;
124 std::string systemId;
125};
126
127#endif /* SAXON_API_EXCEPTION_H */
Definition SaxonApiException.h:23
const char * getMessage()
Definition SaxonApiException.cpp:151
const char * getSystemId()
Definition SaxonApiException.cpp:137
const char * getErrorCode()
Definition SaxonApiException.cpp:116
int getLineNumber()
Definition SaxonApiException.cpp:130
const char * getMessageWithErrorCode()
Definition SaxonApiException.cpp:172
virtual const char * what()
Definition SaxonApiException.cpp:11
virtual ~SaxonApiException()
Definition SaxonApiException.cpp:89
const char * getCombinedStaticErrorMessages()
Definition SaxonApiException.cpp:193
Definition SaxonProcessor.h:117