2017-06-26 09:57:09 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/server/qgsserverexception.h *
|
|
|
|
* *
|
2024-08-11 07:55:04 +10:00
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.py again *
|
2017-06-26 09:57:09 +02:00
|
|
|
************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2017-01-11 22:59:27 +01:00
|
|
|
|
2019-08-06 16:38:21 +02:00
|
|
|
|
|
|
|
|
2017-01-11 22:59:27 +01:00
|
|
|
class QgsServerException
|
|
|
|
{
|
2021-03-22 21:13:52 +01:00
|
|
|
%Docstring(signature="appended")
|
2018-05-26 14:10:30 +10:00
|
|
|
Exception base class for server exceptions.
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-11 22:59:27 +01:00
|
|
|
%TypeHeaderCode
|
2017-06-26 09:57:09 +02:00
|
|
|
#include "qgsserverexception.h"
|
2017-01-11 22:59:27 +01:00
|
|
|
%End
|
|
|
|
public:
|
2017-05-01 16:42:33 +02:00
|
|
|
QgsServerException( const QString &message, int responseCode = 500 );
|
2017-06-26 09:57:09 +02:00
|
|
|
%Docstring
|
|
|
|
Constructor
|
|
|
|
%End
|
2017-01-11 22:59:27 +01:00
|
|
|
|
|
|
|
int responseCode() const;
|
2017-06-26 09:57:09 +02:00
|
|
|
%Docstring
|
2017-12-15 10:36:55 -04:00
|
|
|
|
|
|
|
:return: the return HTTP response code associated with this exception
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
2017-01-11 22:59:27 +01:00
|
|
|
|
2017-06-26 09:57:09 +02:00
|
|
|
virtual QByteArray formatResponse( QString &responseFormat /Out/ ) const;
|
|
|
|
%Docstring
|
2019-03-22 12:36:52 +00:00
|
|
|
Formats the exception for sending to client
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2017-06-26 09:57:09 +02:00
|
|
|
|
2019-03-22 12:36:52 +00:00
|
|
|
:return: - QByteArray The formatted response.
|
2019-02-04 08:26:11 +10:00
|
|
|
- responseFormat: QString to store the content type of the response format.
|
2017-12-15 10:36:55 -04:00
|
|
|
|
2019-03-22 12:36:52 +00:00
|
|
|
The default implementation returns text/xml format.
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
|
|
|
|
|
|
|
};
|
2017-01-11 22:59:27 +01:00
|
|
|
|
|
|
|
class QgsOgcServiceException
|
|
|
|
{
|
2021-03-22 21:13:52 +01:00
|
|
|
%Docstring(signature="appended")
|
2018-05-26 14:10:30 +10:00
|
|
|
Exception base class for service exceptions.
|
2017-06-26 09:57:09 +02:00
|
|
|
|
2017-12-15 10:36:55 -04:00
|
|
|
Note that this exception is associated with a default return code 200 which may be
|
|
|
|
not appropriate in some situations.
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-11 22:59:27 +01:00
|
|
|
%TypeHeaderCode
|
2017-06-26 09:57:09 +02:00
|
|
|
#include "qgsserverexception.h"
|
2017-01-11 22:59:27 +01:00
|
|
|
%End
|
|
|
|
public:
|
2024-12-10 14:52:35 +01:00
|
|
|
QgsOgcServiceException( const QString &code, const QString &message, const QString &locator = QString(), int responseCode = 200, const QString &version = QStringLiteral( "1.3.0" ) );
|
2017-06-26 09:57:09 +02:00
|
|
|
%Docstring
|
|
|
|
Construction
|
|
|
|
%End
|
2017-01-11 22:59:27 +01:00
|
|
|
|
|
|
|
QString message() const;
|
2017-06-26 09:57:09 +02:00
|
|
|
%Docstring
|
2018-05-25 13:54:27 +10:00
|
|
|
Returns the exception message
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
|
|
|
|
2024-12-10 14:52:35 +01:00
|
|
|
QString code() const;
|
2017-06-26 09:57:09 +02:00
|
|
|
%Docstring
|
2018-05-25 13:54:27 +10:00
|
|
|
Returns the exception code
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
|
|
|
|
2017-01-11 22:59:27 +01:00
|
|
|
QString locator() const;
|
2017-06-26 09:57:09 +02:00
|
|
|
%Docstring
|
2018-05-25 13:54:27 +10:00
|
|
|
Returns the locator
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
2017-01-11 22:59:27 +01:00
|
|
|
|
2017-06-26 09:57:09 +02:00
|
|
|
QString version() const;
|
|
|
|
%Docstring
|
2018-05-25 13:54:27 +10:00
|
|
|
Returns the exception version
|
2017-06-26 09:57:09 +02:00
|
|
|
%End
|
2017-01-11 22:59:27 +01:00
|
|
|
|
2017-06-26 09:57:09 +02:00
|
|
|
virtual QByteArray formatResponse( QString &responseFormat /Out/ ) const;
|
2017-12-15 08:57:22 +10:00
|
|
|
|
2017-01-11 22:59:27 +01:00
|
|
|
|
2017-06-26 09:57:09 +02:00
|
|
|
};
|
2017-01-11 22:59:27 +01:00
|
|
|
|
|
|
|
|
2019-08-06 16:38:21 +02:00
|
|
|
|
2017-06-26 09:57:09 +02:00
|
|
|
/************************************************************************
|
|
|
|
* This file has been generated automatically from *
|
|
|
|
* *
|
|
|
|
* src/server/qgsserverexception.h *
|
|
|
|
* *
|
2024-08-11 07:55:04 +10:00
|
|
|
* Do not edit manually ! Edit header and run scripts/sipify.py again *
|
2017-06-26 09:57:09 +02:00
|
|
|
************************************************************************/
|