/*
 * 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 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qtextboundaryfinder.sip"
#include <qtextboundaryfinder.h>
#line 29 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQTextBoundaryFinder.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/sipQtCoreQTextBoundaryFinder.cpp"
#line 26 "/build/pyqt5/src/PyQt5-5.15.7/sip/QtCore/qtextboundaryfinder.sip"
#include <qtextboundaryfinder.h>
#line 36 "/build/pyqt5/src/PyQt5-5.15.7/build/QtCore/sipQtCoreQTextBoundaryFinder.cpp"


PyDoc_STRVAR(doc_QTextBoundaryFinder_isValid, "isValid(self) -> bool");

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

    {
        const  ::QTextBoundaryFinder *sipCpp;

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

            sipRes = sipCpp->isValid();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_isValid, doc_QTextBoundaryFinder_isValid);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_type, "type(self) -> QTextBoundaryFinder.BoundaryType");

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

    {
        const  ::QTextBoundaryFinder *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextBoundaryFinder, &sipCpp))
        {
             ::QTextBoundaryFinder::BoundaryType sipRes;

            sipRes = sipCpp->type();

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QTextBoundaryFinder_BoundaryType);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_type, doc_QTextBoundaryFinder_type);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_string, "string(self) -> str");

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

    {
        const  ::QTextBoundaryFinder *sipCpp;

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

            sipRes = new  ::QString(sipCpp->string());

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

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_string, doc_QTextBoundaryFinder_string);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_toStart, "toStart(self)");

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

    {
         ::QTextBoundaryFinder *sipCpp;

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

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_toStart, doc_QTextBoundaryFinder_toStart);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_toEnd, "toEnd(self)");

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

    {
         ::QTextBoundaryFinder *sipCpp;

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

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_toEnd, doc_QTextBoundaryFinder_toEnd);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_position, "position(self) -> int");

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

    {
        const  ::QTextBoundaryFinder *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextBoundaryFinder, &sipCpp))
        {
            int sipRes;

            sipRes = sipCpp->position();

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_position, doc_QTextBoundaryFinder_position);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_setPosition, "setPosition(self, int)");

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

    {
        int a0;
         ::QTextBoundaryFinder *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "Bi", &sipSelf, sipType_QTextBoundaryFinder, &sipCpp, &a0))
        {
            sipCpp->setPosition(a0);

            Py_INCREF(Py_None);
            return Py_None;
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_setPosition, doc_QTextBoundaryFinder_setPosition);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_toNextBoundary, "toNextBoundary(self) -> int");

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

    {
         ::QTextBoundaryFinder *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextBoundaryFinder, &sipCpp))
        {
            int sipRes;

            sipRes = sipCpp->toNextBoundary();

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_toNextBoundary, doc_QTextBoundaryFinder_toNextBoundary);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_toPreviousBoundary, "toPreviousBoundary(self) -> int");

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

    {
         ::QTextBoundaryFinder *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextBoundaryFinder, &sipCpp))
        {
            int sipRes;

            sipRes = sipCpp->toPreviousBoundary();

            return PyLong_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_toPreviousBoundary, doc_QTextBoundaryFinder_toPreviousBoundary);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_isAtBoundary, "isAtBoundary(self) -> bool");

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

    {
        const  ::QTextBoundaryFinder *sipCpp;

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

            sipRes = sipCpp->isAtBoundary();

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_isAtBoundary, doc_QTextBoundaryFinder_isAtBoundary);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTextBoundaryFinder_boundaryReasons, "boundaryReasons(self) -> QTextBoundaryFinder.BoundaryReasons");

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

    {
        const  ::QTextBoundaryFinder *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTextBoundaryFinder, &sipCpp))
        {
             ::QTextBoundaryFinder::BoundaryReasons*sipRes;

            sipRes = new  ::QTextBoundaryFinder::BoundaryReasons(sipCpp->boundaryReasons());

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

    sipNoMethod(sipParseErr, sipName_QTextBoundaryFinder, sipName_boundaryReasons, doc_QTextBoundaryFinder_boundaryReasons);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QTextBoundaryFinder(void *, int);}
static void release_QTextBoundaryFinder(void *sipCppV, int)
{
    delete reinterpret_cast< ::QTextBoundaryFinder *>(sipCppV);
}


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


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


extern "C" {static void assign_QTextBoundaryFinder(void *, Py_ssize_t, void *);}
static void assign_QTextBoundaryFinder(void *sipDst, Py_ssize_t sipDstIdx, void *sipSrc)
{
    reinterpret_cast< ::QTextBoundaryFinder *>(sipDst)[sipDstIdx] = *reinterpret_cast< ::QTextBoundaryFinder *>(sipSrc);
}


extern "C" {static void *copy_QTextBoundaryFinder(const void *, Py_ssize_t);}
static void *copy_QTextBoundaryFinder(const void *sipSrc, Py_ssize_t sipSrcIdx)
{
    return new  ::QTextBoundaryFinder(reinterpret_cast<const  ::QTextBoundaryFinder *>(sipSrc)[sipSrcIdx]);
}


extern "C" {static void dealloc_QTextBoundaryFinder(sipSimpleWrapper *);}
static void dealloc_QTextBoundaryFinder(sipSimpleWrapper *sipSelf)
{
    if (sipIsOwnedByPython(sipSelf))
    {
        release_QTextBoundaryFinder(sipGetAddress(sipSelf), 0);
    }
}


extern "C" {static void *init_type_QTextBoundaryFinder(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QTextBoundaryFinder(sipSimpleWrapper *, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
     ::QTextBoundaryFinder *sipCpp = SIP_NULLPTR;

    {
        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, ""))
        {
            sipCpp = new  ::QTextBoundaryFinder();

            return sipCpp;
        }
    }

    {
        const  ::QTextBoundaryFinder* a0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "J9", sipType_QTextBoundaryFinder, &a0))
        {
            sipCpp = new  ::QTextBoundaryFinder(*a0);

            return sipCpp;
        }
    }

    {
         ::QTextBoundaryFinder::BoundaryType a0;
        const  ::QString* a1;
        int a1State = 0;

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, SIP_NULLPTR, sipUnused, "EJ1", sipType_QTextBoundaryFinder_BoundaryType, &a0, sipType_QString, &a1, &a1State))
        {
            sipCpp = new  ::QTextBoundaryFinder(a0,*a1);
            sipReleaseType(const_cast< ::QString *>(a1), sipType_QString, a1State);

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


static PyMethodDef methods_QTextBoundaryFinder[] = {
    {sipName_boundaryReasons, meth_QTextBoundaryFinder_boundaryReasons, METH_VARARGS, doc_QTextBoundaryFinder_boundaryReasons},
    {sipName_isAtBoundary, meth_QTextBoundaryFinder_isAtBoundary, METH_VARARGS, doc_QTextBoundaryFinder_isAtBoundary},
    {sipName_isValid, meth_QTextBoundaryFinder_isValid, METH_VARARGS, doc_QTextBoundaryFinder_isValid},
    {sipName_position, meth_QTextBoundaryFinder_position, METH_VARARGS, doc_QTextBoundaryFinder_position},
    {sipName_setPosition, meth_QTextBoundaryFinder_setPosition, METH_VARARGS, doc_QTextBoundaryFinder_setPosition},
    {sipName_string, meth_QTextBoundaryFinder_string, METH_VARARGS, doc_QTextBoundaryFinder_string},
    {sipName_toEnd, meth_QTextBoundaryFinder_toEnd, METH_VARARGS, doc_QTextBoundaryFinder_toEnd},
    {sipName_toNextBoundary, meth_QTextBoundaryFinder_toNextBoundary, METH_VARARGS, doc_QTextBoundaryFinder_toNextBoundary},
    {sipName_toPreviousBoundary, meth_QTextBoundaryFinder_toPreviousBoundary, METH_VARARGS, doc_QTextBoundaryFinder_toPreviousBoundary},
    {sipName_toStart, meth_QTextBoundaryFinder_toStart, METH_VARARGS, doc_QTextBoundaryFinder_toStart},
    {sipName_type, meth_QTextBoundaryFinder_type, METH_VARARGS, doc_QTextBoundaryFinder_type}
};

static sipEnumMemberDef enummembers_QTextBoundaryFinder[] = {
    {sipName_BreakOpportunity, static_cast<int>( ::QTextBoundaryFinder::BreakOpportunity), 278},
    {sipName_EndOfItem, static_cast<int>( ::QTextBoundaryFinder::EndOfItem), 278},
    {sipName_Grapheme, static_cast<int>( ::QTextBoundaryFinder::Grapheme), 280},
    {sipName_Line, static_cast<int>( ::QTextBoundaryFinder::Line), 280},
    {sipName_MandatoryBreak, static_cast<int>( ::QTextBoundaryFinder::MandatoryBreak), 278},
    {sipName_NotAtBoundary, static_cast<int>( ::QTextBoundaryFinder::NotAtBoundary), 278},
    {sipName_Sentence, static_cast<int>( ::QTextBoundaryFinder::Sentence), 280},
    {sipName_SoftHyphen, static_cast<int>( ::QTextBoundaryFinder::SoftHyphen), 278},
    {sipName_StartOfItem, static_cast<int>( ::QTextBoundaryFinder::StartOfItem), 278},
    {sipName_Word, static_cast<int>( ::QTextBoundaryFinder::Word), 280},
};

PyDoc_STRVAR(doc_QTextBoundaryFinder, "\1QTextBoundaryFinder()\n"
"QTextBoundaryFinder(QTextBoundaryFinder)\n"
"QTextBoundaryFinder(QTextBoundaryFinder.BoundaryType, str)");


static pyqt5ClassPluginDef plugin_QTextBoundaryFinder = {
    SIP_NULLPTR,
    0,
    SIP_NULLPTR,
    SIP_NULLPTR
};


sipClassTypeDef sipTypeDef_QtCore_QTextBoundaryFinder = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QTextBoundaryFinder,
        SIP_NULLPTR,
        &plugin_QTextBoundaryFinder
    },
    {
        sipNameNr_QTextBoundaryFinder,
        {0, 0, 1},
        11, methods_QTextBoundaryFinder,
        10, enummembers_QTextBoundaryFinder,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QTextBoundaryFinder,
    -1,
    sipNameNr_sip_simplewrapper,
    SIP_NULLPTR,
    SIP_NULLPTR,
    init_type_QTextBoundaryFinder,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QTextBoundaryFinder,
    assign_QTextBoundaryFinder,
    array_QTextBoundaryFinder,
    copy_QTextBoundaryFinder,
    release_QTextBoundaryFinder,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    array_delete_QTextBoundaryFinder,
    sizeof ( ::QTextBoundaryFinder),
};
