/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.6.2
 *
 * Copyright (c) 2022 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt5.
 * 
 * This file may be used under the terms of the GNU General Public License
 * version 3.0 as published by the Free Software Foundation and appearing in
 * the file LICENSE included in the packaging of this file.  Please review the
 * following information to ensure the GNU General Public License version 3.0
 * requirements will be met: http://www.gnu.org/copyleft/gpl.html.
 * 
 * If you do not wish to use this file under the terms of the GPL version 3.0
 * then you may purchase a commercial license.  For more information contact
 * info@riverbankcomputing.com.
 * 
 * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
 * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 */

#include "sipAPIQtCore.h"

#line 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qsavefile.sip"
#include <qsavefile.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"

#line 27 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qstring.sip"
#include <qstring.h>
#line 33 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 28 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobject.sip"
#include <qobject.h>
#line 36 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qiodevice.sip"
#include <qiodevice.h>
#line 39 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 360 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qdatetime.sip"
#include <qdatetime.h>
#line 42 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qfiledevice.sip"
#include <qfiledevice.h>
#line 45 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qfiledevice.sip"
#include <qfiledevice.h>
#line 48 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 30 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qbytearray.sip"
#include <qbytearray.h>
#line 51 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 146 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 56 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qmetaobject.sip"
#include <qmetaobject.h>
#line 59 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 62 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 247 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 65 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 235 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 68 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qvariant.sip"
#include <qvariant.h>
#line 71 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 38 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 74 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 149 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 77 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 80 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qthread.sip"
#include <qthread.h>
#line 83 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 86 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qregexp.sip"
#include <qregexp.h>
#line 89 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qregularexpression.sip"
#include <qregularexpression.h>
#line 92 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qobjectdefs.sip"
#include <qobjectdefs.h>
#line 95 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQSaveFile.cpp"


class sipQSaveFile : public  ::QSaveFile
{
public:
    sipQSaveFile(const  ::QString&);
    sipQSaveFile( ::QObject*);
    sipQSaveFile(const  ::QString&, ::QObject*);
    virtual ~sipQSaveFile();

    int qt_metacall(QMetaObject::Call, int, void **) SIP_OVERRIDE;
    void *qt_metacast(const char *) SIP_OVERRIDE;
    const QMetaObject *metaObject() const SIP_OVERRIDE;

    /*
     * There is a protected method for every virtual method visible from
     * this class.
     */
protected:
     ::qint64 writeData(const char*,long long) SIP_OVERRIDE;
     ::qint64 readLineData(char*, ::qint64) SIP_OVERRIDE;
     ::qint64 readData(char*, ::qint64) SIP_OVERRIDE;
    bool waitForBytesWritten(int) SIP_OVERRIDE;
    bool waitForReadyRead(int) SIP_OVERRIDE;
    bool canReadLine() const SIP_OVERRIDE;
     ::qint64 bytesToWrite() const SIP_OVERRIDE;
     ::qint64 bytesAvailable() const SIP_OVERRIDE;
    bool reset() SIP_OVERRIDE;
    bool atEnd() const SIP_OVERRIDE;
    bool seek( ::qint64) SIP_OVERRIDE;
     ::qint64 size() const SIP_OVERRIDE;
     ::qint64 pos() const SIP_OVERRIDE;
    bool open( ::QIODevice::OpenMode) SIP_OVERRIDE;
    bool isSequential() const SIP_OVERRIDE;
    bool event( ::QEvent*) SIP_OVERRIDE;
    bool eventFilter( ::QObject*, ::QEvent*) SIP_OVERRIDE;
    void timerEvent( ::QTimerEvent*) SIP_OVERRIDE;
    void childEvent( ::QChildEvent*) SIP_OVERRIDE;
    void customEvent( ::QEvent*) SIP_OVERRIDE;
    void connectNotify(const  ::QMetaMethod&) SIP_OVERRIDE;
    void disconnectNotify(const  ::QMetaMethod&) SIP_OVERRIDE;
     ::QString fileName() const SIP_OVERRIDE;
    bool resize( ::qint64) SIP_OVERRIDE;
     ::QFileDevice::Permissions permissions() const SIP_OVERRIDE;
    bool setPermissions( ::QFileDevice::Permissions) SIP_OVERRIDE;

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipQSaveFile(const sipQSaveFile &);
    sipQSaveFile &operator = (const sipQSaveFile &);

    char sipPyMethods[26];
};

sipQSaveFile::sipQSaveFile(const  ::QString& a0):  ::QSaveFile(a0), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

sipQSaveFile::sipQSaveFile( ::QObject*a0):  ::QSaveFile(a0), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

sipQSaveFile::sipQSaveFile(const  ::QString& a0, ::QObject*a1):  ::QSaveFile(a0,a1), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

sipQSaveFile::~sipQSaveFile()
{
    sipInstanceDestroyedEx(&sipPySelf);
}

const QMetaObject *sipQSaveFile::metaObject() const
{
    if (sipGetInterpreter())
        return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : sip_QtCore_qt_metaobject(sipPySelf,sipType_QSaveFile);

    return  ::QSaveFile::metaObject();
}

int sipQSaveFile::qt_metacall(QMetaObject::Call _c,int _id,void **_a)
{
    _id =  ::QSaveFile::qt_metacall(_c,_id,_a);

    if (_id >= 0)
    {
        SIP_BLOCK_THREADS
        _id = sip_QtCore_qt_metacall(sipPySelf,sipType_QSaveFile,_c,_id,_a);
        SIP_UNBLOCK_THREADS
    }

    return _id;
}

void *sipQSaveFile::qt_metacast(const char *_clname)
{
    void *sipCpp;

    return (sip_QtCore_qt_metacast(sipPySelf, sipType_QSaveFile, _clname, &sipCpp) ? sipCpp :  ::QSaveFile::qt_metacast(_clname));
}

 ::qint64 sipQSaveFile::writeData(const char*a0,long long a1)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[0], &sipPySelf, SIP_NULLPTR, sipName_writeData);

    if (!sipMeth)
        return  ::QSaveFile::writeData(a0,a1);

    extern  ::qint64 sipVH_QtCore_49(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const char*,long long);

    return sipVH_QtCore_49(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0, a1);
}

 ::qint64 sipQSaveFile::readLineData(char*a0, ::qint64 a1)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[1], &sipPySelf, SIP_NULLPTR, sipName_readLineData);

    if (!sipMeth)
        return  ::QSaveFile::readLineData(a0,a1);

    extern  ::qint64 sipVH_QtCore_48(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, char*, ::qint64);

    return sipVH_QtCore_48(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0, a1);
}

 ::qint64 sipQSaveFile::readData(char*a0, ::qint64 a1)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[2], &sipPySelf, SIP_NULLPTR, sipName_readData);

    if (!sipMeth)
        return  ::QSaveFile::readData(a0,a1);

    extern  ::qint64 sipVH_QtCore_47(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, char*, ::qint64);

    return sipVH_QtCore_47(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0, a1);
}

bool sipQSaveFile::waitForBytesWritten(int a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[3], &sipPySelf, SIP_NULLPTR, sipName_waitForBytesWritten);

    if (!sipMeth)
        return  ::QSaveFile::waitForBytesWritten(a0);

    extern bool sipVH_QtCore_14(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, int);

    return sipVH_QtCore_14(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

bool sipQSaveFile::waitForReadyRead(int a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[4], &sipPySelf, SIP_NULLPTR, sipName_waitForReadyRead);

    if (!sipMeth)
        return  ::QSaveFile::waitForReadyRead(a0);

    extern bool sipVH_QtCore_14(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, int);

    return sipVH_QtCore_14(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

bool sipQSaveFile::canReadLine() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[5]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_canReadLine);

    if (!sipMeth)
        return  ::QSaveFile::canReadLine();

    extern bool sipVH_QtCore_11(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_11(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

 ::qint64 sipQSaveFile::bytesToWrite() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[6]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_bytesToWrite);

    if (!sipMeth)
        return  ::QSaveFile::bytesToWrite();

    extern  ::qint64 sipVH_QtCore_45(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_45(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

 ::qint64 sipQSaveFile::bytesAvailable() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[7]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_bytesAvailable);

    if (!sipMeth)
        return  ::QSaveFile::bytesAvailable();

    extern  ::qint64 sipVH_QtCore_45(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_45(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::reset()
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[8], &sipPySelf, SIP_NULLPTR, sipName_reset);

    if (!sipMeth)
        return  ::QSaveFile::reset();

    extern bool sipVH_QtCore_11(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_11(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::atEnd() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[9]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_atEnd);

    if (!sipMeth)
        return  ::QSaveFile::atEnd();

    extern bool sipVH_QtCore_11(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_11(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::seek( ::qint64 a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[10], &sipPySelf, SIP_NULLPTR, sipName_seek);

    if (!sipMeth)
        return  ::QSaveFile::seek(a0);

    extern bool sipVH_QtCore_46(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::qint64);

    return sipVH_QtCore_46(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

 ::qint64 sipQSaveFile::size() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[11]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_size);

    if (!sipMeth)
        return  ::QSaveFile::size();

    extern  ::qint64 sipVH_QtCore_45(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_45(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

 ::qint64 sipQSaveFile::pos() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[12]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_pos);

    if (!sipMeth)
        return  ::QSaveFile::pos();

    extern  ::qint64 sipVH_QtCore_45(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_45(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::open( ::QIODevice::OpenMode a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[13], &sipPySelf, SIP_NULLPTR, sipName_open);

    if (!sipMeth)
        return  ::QSaveFile::open(a0);

    extern bool sipVH_QtCore_44(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QIODevice::OpenMode);

    return sipVH_QtCore_44(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

bool sipQSaveFile::isSequential() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[14]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_isSequential);

    if (!sipMeth)
        return  ::QSaveFile::isSequential();

    extern bool sipVH_QtCore_11(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_11(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::event( ::QEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[15], &sipPySelf, SIP_NULLPTR, sipName_event);

    if (!sipMeth)
        return  ::QSaveFile::event(a0);

    extern bool sipVH_QtCore_0(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QEvent*);

    return sipVH_QtCore_0(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

bool sipQSaveFile::eventFilter( ::QObject*a0, ::QEvent*a1)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[16], &sipPySelf, SIP_NULLPTR, sipName_eventFilter);

    if (!sipMeth)
        return  ::QSaveFile::eventFilter(a0,a1);

    extern bool sipVH_QtCore_1(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QObject*, ::QEvent*);

    return sipVH_QtCore_1(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0, a1);
}

void sipQSaveFile::timerEvent( ::QTimerEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[17], &sipPySelf, SIP_NULLPTR, sipName_timerEvent);

    if (!sipMeth)
    {
         ::QSaveFile::timerEvent(a0);
        return;
    }

    extern void sipVH_QtCore_2(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QTimerEvent*);

    sipVH_QtCore_2(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

void sipQSaveFile::childEvent( ::QChildEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[18], &sipPySelf, SIP_NULLPTR, sipName_childEvent);

    if (!sipMeth)
    {
         ::QSaveFile::childEvent(a0);
        return;
    }

    extern void sipVH_QtCore_3(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QChildEvent*);

    sipVH_QtCore_3(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

void sipQSaveFile::customEvent( ::QEvent*a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[19], &sipPySelf, SIP_NULLPTR, sipName_customEvent);

    if (!sipMeth)
    {
         ::QSaveFile::customEvent(a0);
        return;
    }

    extern void sipVH_QtCore_4(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QEvent*);

    sipVH_QtCore_4(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

void sipQSaveFile::connectNotify(const  ::QMetaMethod& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[20], &sipPySelf, SIP_NULLPTR, sipName_connectNotify);

    if (!sipMeth)
    {
         ::QSaveFile::connectNotify(a0);
        return;
    }

    extern void sipVH_QtCore_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QMetaMethod&);

    sipVH_QtCore_5(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

void sipQSaveFile::disconnectNotify(const  ::QMetaMethod& a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[21], &sipPySelf, SIP_NULLPTR, sipName_disconnectNotify);

    if (!sipMeth)
    {
         ::QSaveFile::disconnectNotify(a0);
        return;
    }

    extern void sipVH_QtCore_5(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, const  ::QMetaMethod&);

    sipVH_QtCore_5(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

 ::QString sipQSaveFile::fileName() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[22]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_fileName);

    if (!sipMeth)
        return  ::QSaveFile::fileName();

    extern  ::QString sipVH_QtCore_50(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_50(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::resize( ::qint64 a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[23], &sipPySelf, SIP_NULLPTR, sipName_resize);

    if (!sipMeth)
        return  ::QSaveFile::resize(a0);

    extern bool sipVH_QtCore_46(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::qint64);

    return sipVH_QtCore_46(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}

 ::QFileDevice::Permissions sipQSaveFile::permissions() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[24]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_permissions);

    if (!sipMeth)
        return  ::QSaveFile::permissions();

    extern  ::QFileDevice::Permissions sipVH_QtCore_51(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtCore_51(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth);
}

bool sipQSaveFile::setPermissions( ::QFileDevice::Permissions a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[25], &sipPySelf, SIP_NULLPTR, sipName_setPermissions);

    if (!sipMeth)
        return  ::QSaveFile::setPermissions(a0);

    extern bool sipVH_QtCore_52(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *,  ::QFileDevice::Permissions);

    return sipVH_QtCore_52(sipGILState, sipVEH_QtCore_PyQt5, sipPySelf, sipMeth, a0);
}


PyDoc_STRVAR(doc_QSaveFile_fileName, "fileName(self) -> str");

extern "C" {static PyObject *meth_QSaveFile_fileName(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_fileName(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const  ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QSaveFile, &sipCpp))
        {
             ::QString*sipRes;

            sipRes = new  ::QString((sipSelfWasArg ? sipCpp-> ::QSaveFile::fileName() : sipCpp->fileName()));

            return sipConvertFromNewType(sipRes,sipType_QString,SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_fileName, doc_QSaveFile_fileName);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_setFileName, "setFileName(self, str)");

extern "C" {static PyObject *meth_QSaveFile_setFileName(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_setFileName(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QString* a0;
        int a0State = 0;
         ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QSaveFile, &sipCpp, sipType_QString, &a0, &a0State))
        {
            sipCpp->setFileName(*a0);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_setFileName, doc_QSaveFile_setFileName);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_open, "open(self, Union[QIODevice.OpenMode, QIODevice.OpenModeFlag]) -> bool");

extern "C" {static PyObject *meth_QSaveFile_open(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_open(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
         ::QIODevice::OpenMode* a0;
        int a0State = 0;
         ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "BJ1", &sipSelf, sipType_QSaveFile, &sipCpp, sipType_QIODevice_OpenMode, &a0, &a0State))
        {
            bool sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = (sipSelfWasArg ? sipCpp-> ::QSaveFile::open(*a0) : sipCpp->open(*a0));
            Py_END_ALLOW_THREADS
            sipReleaseType(a0, sipType_QIODevice_OpenMode, a0State);

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_open, doc_QSaveFile_open);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_commit, "commit(self) -> bool");

extern "C" {static PyObject *meth_QSaveFile_commit(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_commit(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QSaveFile, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->commit();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_commit, doc_QSaveFile_commit);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_cancelWriting, "cancelWriting(self)");

extern "C" {static PyObject *meth_QSaveFile_cancelWriting(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_cancelWriting(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
         ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QSaveFile, &sipCpp))
        {
            sipCpp->cancelWriting();

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_cancelWriting, doc_QSaveFile_cancelWriting);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_setDirectWriteFallback, "setDirectWriteFallback(self, bool)");

extern "C" {static PyObject *meth_QSaveFile_setDirectWriteFallback(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_setDirectWriteFallback(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        bool a0;
         ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bb", &sipSelf, sipType_QSaveFile, &sipCpp, &a0))
        {
            sipCpp->setDirectWriteFallback(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_setDirectWriteFallback, doc_QSaveFile_setDirectWriteFallback);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_directWriteFallback, "directWriteFallback(self) -> bool");

extern "C" {static PyObject *meth_QSaveFile_directWriteFallback(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_directWriteFallback(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const  ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QSaveFile, &sipCpp))
        {
            bool sipRes;

            sipRes = sipCpp->directWriteFallback();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_directWriteFallback, doc_QSaveFile_directWriteFallback);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QSaveFile_writeData, "writeData(self, PyQt5.sip.array[bytes]) -> int");

extern "C" {static PyObject *meth_QSaveFile_writeData(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_writeData(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!sipSelf || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const char* a0;
        Py_ssize_t a1;
         ::QSaveFile *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "pk", &sipSelf, sipType_QSaveFile, &sipCpp, &a0, &a1))
        {
             ::qint64 sipRes;

            Py_BEGIN_ALLOW_THREADS
            sipRes = (sipSelfWasArg ? sipCpp-> ::QSaveFile::writeData(a0,(long long)a1) : sipCpp->writeData(a0,(long long)a1));
            Py_END_ALLOW_THREADS

            return PyLong_FromLongLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QSaveFile, sipName_writeData, doc_QSaveFile_writeData);

    return SIP_NULLPTR;
}


extern "C" {static PyObject *meth_QSaveFile_close(PyObject *, PyObject *);}
static PyObject *meth_QSaveFile_close(PyObject *, PyObject *)
{

    sipNoMethod(SIP_NULLPTR, sipName_QSaveFile, sipName_close, SIP_NULLPTR);

    return SIP_NULLPTR;
}


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_QSaveFile(void *, const sipTypeDef *);}
static void *cast_QSaveFile(void *sipCppV, const sipTypeDef *targetType)
{
     ::QSaveFile *sipCpp = reinterpret_cast< ::QSaveFile *>(sipCppV);

    if (targetType == sipType_QSaveFile)
        return sipCppV;

    sipCppV = ((const sipClassTypeDef *)sipType_QFileDevice)->ctd_cast(static_cast< ::QFileDevice *>(sipCpp), targetType);
    if (sipCppV)
        return sipCppV;

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QSaveFile(void *, int);}
static void release_QSaveFile(void *sipCppV, int)
{
     ::QSaveFile *sipCpp = reinterpret_cast< ::QSaveFile *>(sipCppV);

    if (QThread::currentThread() == sipCpp->thread())
        delete sipCpp;
    else
        sipCpp->deleteLater();
}


extern "C" {static void *array_QSaveFile(Py_ssize_t);}
static void *array_QSaveFile(Py_ssize_t sipNrElem)
{
    return new  ::QSaveFile[sipNrElem];
}


extern "C" {static void array_delete_QSaveFile(void *);}
static void array_delete_QSaveFile(void *sipCpp)
{
    delete[] reinterpret_cast< ::QSaveFile *>(sipCpp);
}


extern "C" {static void dealloc_QSaveFile(sipSimpleWrapper *);}
static void dealloc_QSaveFile(sipSimpleWrapper *sipSelf)
{
    if (sipIsDerivedClass(sipSelf))
        reinterpret_cast<sipQSaveFile *>(sipGetAddress(sipSelf))->sipPySelf = SIP_NULLPTR;

    if (sipIsOwnedByPython(sipSelf))
    {
        release_QSaveFile(sipGetAddress(sipSelf), sipIsDerivedClass(sipSelf));
    }
}


extern "C" {static void *init_type_QSaveFile(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QSaveFile(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **sipOwner, PyObject **sipParseErr)
{
    sipQSaveFile *sipCpp = SIP_NULLPTR;

    {
        const  ::QString* a0;
        int a0State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J1", sipType_QString, &a0, &a0State))
        {
            sipCpp = new sipQSaveFile(*a0);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    {
         ::QObject* a0 = 0;

        static const char *sipKwdList[] = {
            sipName_parent,
        };

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "|JH", sipType_QObject, &a0, sipOwner))
        {
            sipCpp = new sipQSaveFile(a0);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    {
        const  ::QString* a0;
        int a0State = 0;
         ::QObject* a1;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J1JH", sipType_QString, &a0, &a0State, sipType_QObject, &a1, sipOwner))
        {
            sipCpp = new sipQSaveFile(*a0,a1);
            sipReleaseType(const_cast< ::QString *>(a0), sipType_QString, a0State);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QSaveFile[] = {{84, 255, 1}};


static PyMethodDef methods_QSaveFile[] = {
    {sipName_cancelWriting, meth_QSaveFile_cancelWriting, METH_VARARGS, doc_QSaveFile_cancelWriting},
    {sipName_close, meth_QSaveFile_close, METH_VARARGS, SIP_NULLPTR},
    {sipName_commit, meth_QSaveFile_commit, METH_VARARGS, doc_QSaveFile_commit},
    {sipName_directWriteFallback, meth_QSaveFile_directWriteFallback, METH_VARARGS, doc_QSaveFile_directWriteFallback},
    {sipName_fileName, meth_QSaveFile_fileName, METH_VARARGS, doc_QSaveFile_fileName},
    {sipName_open, meth_QSaveFile_open, METH_VARARGS, doc_QSaveFile_open},
    {sipName_setDirectWriteFallback, meth_QSaveFile_setDirectWriteFallback, METH_VARARGS, doc_QSaveFile_setDirectWriteFallback},
    {sipName_setFileName, meth_QSaveFile_setFileName, METH_VARARGS, doc_QSaveFile_setFileName},
    {sipName_writeData, meth_QSaveFile_writeData, METH_VARARGS, doc_QSaveFile_writeData}
};

PyDoc_STRVAR(doc_QSaveFile, "\1QSaveFile(str)\n"
"QSaveFile(parent: QObject = None)\n"
"QSaveFile(str, QObject)");


static pyqt5ClassPluginDef plugin_QSaveFile = {
    & ::QSaveFile::staticMetaObject,
    0,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtCore_QSaveFile = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QSaveFile,
        SIP_NULLPTR,
        &plugin_QSaveFile
    },
    {
        sipNameNr_QSaveFile,
        {0, 0, 1},
        9, methods_QSaveFile,
        0, SIP_NULLPTR,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QSaveFile,
    -1,
    -1,
    supers_QSaveFile,
    SIP_NULLPTR,
    init_type_QSaveFile,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QSaveFile,
    SIP_NULLPTR,
    array_QSaveFile,
    SIP_NULLPTR,
    release_QSaveFile,
    cast_QSaveFile,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QSaveFile,
    sizeof ( ::QSaveFile),
};
