Skip to content
Permalink
Browse files

Update sip binding

  • Loading branch information
pblottiere committed Jul 17, 2017
1 parent 3480390 commit a7959b777a7016376880463538059c36e758d842
Showing with 10 additions and 78 deletions.
  1. +0 −29 python/core/qgsarchive.sip
  2. +1 −49 python/core/qgsproject.sip
  3. +9 −0 python/core/qgsziputils.sip
@@ -45,13 +45,6 @@ class QgsArchive
:rtype: bool
%End

bool zip();
%Docstring
Zip the content of this archive. THe current filename is used.
:return: false if something goes wrong, true otherwise
:rtype: bool
%End

virtual bool unzip( const QString &zipFilename );
%Docstring
Clear the current content of this archive and unzip. Files are unzipped
@@ -61,16 +54,6 @@ class QgsArchive
:rtype: bool
%End

bool unzip();
%Docstring
Clear the current content of this archive and unzip. If a project file
is found in the content, then this archive may be considered as a valid
one. Files are unzipped in the temporary directory. The current filename
is used.
:return: true if a project file has been found, false otherwise
:rtype: bool
%End

void clear();
%Docstring
Clear the current content of this archive and create a new temporary
@@ -84,18 +67,6 @@ class QgsArchive
\param filename A file to add when zipping this archive
%End

void setFileName( const QString &filename );
%Docstring
Set the filename to use when zipping/unzipping this archive.
\param filename The zip filename
%End

QString filename() const;
%Docstring
Returns the current zip filename.
:rtype: str
%End

QStringList files() const;
%Docstring
Returns the list of files within this archive
@@ -612,55 +612,7 @@ Returns the number of registered layers.
:rtype: QMap<str, QgsMapLayer *>
%End

bool unzip( const QString &filename );
%Docstring
Unzip a project
\param filename The zip file to unzip
:return: true if unzip is well performed, false otherwise
.. versionadded:: 3.0
:rtype: bool
%End

bool unzip();
%Docstring
Unzip a project with the current zip filename
:return: true if unzip is well performed, false otherwise
.. versionadded:: 3.0
:rtype: bool
%End

bool zip( const QString &filename );
%Docstring
Zip the project
\param filename The zip filename
:return: true if zip is well performed, false otherwise
.. versionadded:: 3.0
:rtype: bool
%End

bool zip();
%Docstring
Zip the project with the current zip filename
:return: true if zip is well performed, false otherwise
.. versionadded:: 3.0
:rtype: bool
%End

QString zipFileName() const;
%Docstring
Returns the current zip filename or an empty string if none.
.. versionadded:: 3.0
:rtype: str
%End

void setZipFileName( const QString &filename );
%Docstring
Sets the current zip filename.
\param filename The zip filename
.. versionadded:: 3.0
%End

bool unzipped() const;
bool isZipped() const;
%Docstring
Returns true if the project comes from a zip archive, false otherwise.
:rtype: bool
@@ -15,6 +15,15 @@
namespace QgsZipUtils
{

bool isZipFile( const QString &filename );
%Docstring
Returns true if the file name is a zipped file ( i.e with a '.qgz'
extension, false otherwise.
\param filename The name of the file
:return: true if the file is zipped, false otherwise
:rtype: bool
%End

bool unzip( const QString &zip, const QString &dir, QStringList &files /Out/ );
%Docstring
Unzip a zip file in an output directory. An error is returned if the zip

0 comments on commit a7959b7

Please sign in to comment.
You can’t perform that action at this time.