Skip to content
Permalink
Browse files
Qgis::HttpMethod should be an enum class
  • Loading branch information
nyalldawson committed Sep 6, 2021
1 parent ce29af6 commit 8f2eb9238fa98c6a7559e36a5048588d17963820
Showing with 7 additions and 2 deletions.
  1. +5 −0 python/core/auto_additions/qgis.py
  2. +1 −1 python/core/auto_generated/qgis.sip.in
  3. +1 −1 src/core/qgis.h
@@ -276,6 +276,11 @@
Qgis.BrowserDirectoryMonitoring.__doc__ = 'Browser directory item monitoring switches.\n\n.. versionadded:: 3.20\n\n' + '* ``Default``: ' + Qgis.BrowserDirectoryMonitoring.Default.__doc__ + '\n' + '* ``NeverMonitor``: ' + Qgis.BrowserDirectoryMonitoring.NeverMonitor.__doc__ + '\n' + '* ``AlwaysMonitor``: ' + Qgis.BrowserDirectoryMonitoring.AlwaysMonitor.__doc__
# --
Qgis.BrowserDirectoryMonitoring.baseClass = Qgis
# monkey patching scoped based enum
Qgis.HttpMethod.Get.__doc__ = "GET method"
Qgis.HttpMethod.Post.__doc__ = "POST method"
Qgis.HttpMethod.__doc__ = 'Different methods of HTTP requests\n\n.. versionadded:: 3.22\n\n' + '* ``Get``: ' + Qgis.HttpMethod.Get.__doc__ + '\n' + '* ``Post``: ' + Qgis.HttpMethod.Post.__doc__
# --
Qgis.HttpMethod.baseClass = Qgis
QgsVectorLayerExporter.ExportError = Qgis.VectorExportResult
# monkey patching scoped based enum
@@ -211,7 +211,7 @@ The development version
AlwaysMonitor,
};

enum HttpMethod
enum class HttpMethod
{
Get,
Post
@@ -313,7 +313,7 @@ class CORE_EXPORT Qgis
* Different methods of HTTP requests
* \since 3.22
*/
enum HttpMethod
enum class HttpMethod : int
{
Get = 0, //!< GET method
Post = 1 //!< POST method

0 comments on commit 8f2eb92

Please sign in to comment.