File: qgsofflineediting.sip.in

package info (click to toggle)
qgis 3.40.11%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,183,800 kB
  • sloc: cpp: 1,595,841; python: 372,637; xml: 23,474; sh: 3,761; perl: 3,664; ansic: 2,257; sql: 2,137; yacc: 1,068; lex: 577; javascript: 540; lisp: 411; makefile: 154
file content (122 lines) | stat: -rw-r--r-- 3,814 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/core/qgsofflineediting.h                                         *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/





class QgsOfflineEditing : QObject
{
%Docstring(signature="appended")
Handles logic relating to synchronizing online and offline copies of
layer data.
%End

%TypeHeaderCode
#include "qgsofflineediting.h"
%End
  public:
    enum ProgressMode /BaseType=IntEnum/
    {
      CopyFeatures,
      ProcessFeatures,
      AddFields,
      AddFeatures,
      RemoveFeatures,
      UpdateFeatures,
      UpdateGeometries
    };

    enum ContainerType /BaseType=IntEnum/
    {
      SpatiaLite,
      GPKG
    };

    QgsOfflineEditing();

    bool convertToOfflineProject( const QString &offlineDataPath, const QString &offlineDbFile, const QStringList &layerIds, bool onlySelected = false, ContainerType containerType = SpatiaLite, const QString &layerNameSuffix = QStringLiteral( " (offline)" ) );
%Docstring
Convert current project for offline editing

:param offlineDataPath: Path to offline db file
:param offlineDbFile: Offline db file name
:param layerIds: List of layer names to convert
:param onlySelected: Only copy selected features from layers where a
                     selection is present
:param containerType: defines the SQLite file container type like
                      SpatiaLite or GPKG
:param layerNameSuffix: Suffix string added to the offline layer name
%End

    bool isOfflineProject() const;
%Docstring
Returns ``True`` if current project is offline
%End


    void synchronize( bool useTransaction = false );
%Docstring
Synchronize to remote layers

:param useTransaction: enforce the remote layer modifications with the
                       same source to be in a transaction group
%End

  signals:

    void progressStarted();
%Docstring
Emitted when the process has started.
%End

    void layerProgressUpdated( int layer, int numLayers );
%Docstring
Emitted whenever a new layer is being processed. It is possible to
estimate the progress of the complete operation by comparing the index
of the current ``layer`` to the total amount ``numLayers``.
%End

    void progressModeSet( QgsOfflineEditing::ProgressMode mode, long long maximum );
%Docstring
Emitted when the mode for the progress of the current operation is set.

:param mode: progress mode
:param maximum: total number of entities to process in the current
                operation
%End

    void progressUpdated( long long progress );
%Docstring
Emitted with the progress of the current mode

:param progress: current index of processed entities
%End

    void progressStopped();
%Docstring
Emitted when the processing of all layers has finished
%End

    void warning( const QString &title, const QString &message );
%Docstring
Emitted when a warning needs to be displayed.

:param title: title string for message
:param message: A descriptive message for the warning
%End

};

/************************************************************************
 * This file has been generated automatically from                      *
 *                                                                      *
 * src/core/qgsofflineediting.h                                         *
 *                                                                      *
 * Do not edit manually ! Edit header and run scripts/sipify.py again   *
 ************************************************************************/