# This file was automatically generated by SWIG (https://www.swig.org).
# Version 4.4.1
#
# Do not make changes to this file unless you know what you are doing - modify
# the SWIG interface file instead.

"""
Geom2dConvert module, see official documentation at
https://dev.opencascade.org/doc/occt-7.9.0/refman/html/package_geom2dconvert.html
"""

from sys import version_info as _swig_python_version_info
# Import the low-level C/C++ module
if getattr(globals().get("__spec__"), "parent", None) or __package__ or "." in __name__:
    from . import _Geom2dConvert
else:
    import _Geom2dConvert

try:
    import builtins as __builtin__
except ImportError:
    import __builtin__

def _swig_repr(self):
    try:
        strthis = "proxy of " + self.this.__repr__()
    except __builtin__.Exception:
        strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)


def _swig_setattr_nondynamic_instance_variable(set):
    def set_instance_attr(self, name, value):
        if name == "this":
            set(self, name, value)
        elif name == "thisown":
            self.this.own(value)
        elif hasattr(self, name) and isinstance(getattr(type(self), name), property):
            set(self, name, value)
        else:
            raise AttributeError("You cannot add instance attributes to %s" % self)
    return set_instance_attr


def _swig_setattr_nondynamic_class_variable(set):
    def set_class_attr(cls, name, value):
        if hasattr(cls, name) and not isinstance(getattr(cls, name), property):
            set(cls, name, value)
        else:
            raise AttributeError("You cannot add class attributes to %s" % cls)
    return set_class_attr


def _swig_add_metaclass(metaclass):
    """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass"""
    def wrapper(cls):
        return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy())
    return wrapper


class _SwigNonDynamicMeta(type):
    """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
    __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)


class SwigPyIterator(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined - class is abstract")
    __repr__ = _swig_repr
    __swig_destroy__ = _Geom2dConvert.delete_SwigPyIterator

    def value(self):
        return _Geom2dConvert.SwigPyIterator_value(self)

    def incr(self, n=1):
        return _Geom2dConvert.SwigPyIterator_incr(self, n)

    def decr(self, n=1):
        return _Geom2dConvert.SwigPyIterator_decr(self, n)

    def distance(self, x):
        return _Geom2dConvert.SwigPyIterator_distance(self, x)

    def equal(self, x):
        return _Geom2dConvert.SwigPyIterator_equal(self, x)

    def copy(self):
        return _Geom2dConvert.SwigPyIterator_copy(self)

    def next(self):
        return _Geom2dConvert.SwigPyIterator_next(self)

    def __next__(self):
        return _Geom2dConvert.SwigPyIterator___next__(self)

    def previous(self):
        return _Geom2dConvert.SwigPyIterator_previous(self)

    def advance(self, n):
        return _Geom2dConvert.SwigPyIterator_advance(self, n)

    def __eq__(self, x):
        return _Geom2dConvert.SwigPyIterator___eq__(self, x)

    def __ne__(self, x):
        return _Geom2dConvert.SwigPyIterator___ne__(self, x)

    def __iadd__(self, n):
        return _Geom2dConvert.SwigPyIterator___iadd__(self, n)

    def __isub__(self, n):
        return _Geom2dConvert.SwigPyIterator___isub__(self, n)

    def __add__(self, n):
        return _Geom2dConvert.SwigPyIterator___add__(self, n)

    def __sub__(self, *args):
        return _Geom2dConvert.SwigPyIterator___sub__(self, *args)
    def __iter__(self):
        return self

# Register SwigPyIterator in _Geom2dConvert:
_Geom2dConvert.SwigPyIterator_swigregister(SwigPyIterator)

def _dumps_object(klass):
    """ Overwrite default string output for any wrapped object.
    By default, __repr__ method returns something like:
    <OCC.Core.TopoDS.TopoDS_Shape; proxy of <Swig Object of type 'TopoDS_Shape *' at 0x02BB0758> >
    This is too much verbose.
    We prefer :
    <class 'gp_Pnt'>
    or
    <class 'TopoDS_Shape'>
    """
    klass_name = str(klass.__class__).split(".")[3].split("'")[0]
    repr_string = "<class '" + klass_name + "'"
# for TopoDS_Shape, we also look for the base type
    if klass_name == "TopoDS_Shape":
        if klass.IsNull():
            repr_string += ": Null>"
            return repr_string
        st = klass.ShapeType()
        types = {OCC.Core.TopAbs.TopAbs_VERTEX: "Vertex",
                 OCC.Core.TopAbs.TopAbs_SOLID: "Solid",
                 OCC.Core.TopAbs.TopAbs_EDGE: "Edge",
                 OCC.Core.TopAbs.TopAbs_FACE: "Face",
                 OCC.Core.TopAbs.TopAbs_SHELL: "Shell",
                 OCC.Core.TopAbs.TopAbs_WIRE: "Wire",
                 OCC.Core.TopAbs.TopAbs_COMPOUND: "Compound",
                 OCC.Core.TopAbs.TopAbs_COMPSOLID: "Compsolid"}
        repr_string += "; Type:%s" % types[st]        
    elif hasattr(klass, "IsNull"):
        if klass.IsNull():
            repr_string += "; Null"
    repr_string += ">"
    return repr_string


def process_exception(error, method_name, class_name):
    return _Geom2dConvert.process_exception(error, method_name, class_name)

import warnings
from OCC.Wrapper.wrapper_utils import Proxy, deprecated

class ios_base(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    erase_event = _Geom2dConvert.ios_base_erase_event
    imbue_event = _Geom2dConvert.ios_base_imbue_event
    copyfmt_event = _Geom2dConvert.ios_base_copyfmt_event

    def register_callback(self, __fn, __index):
        return _Geom2dConvert.ios_base_register_callback(self, __fn, __index)

    def flags(self, *args):
        return _Geom2dConvert.ios_base_flags(self, *args)

    def setf(self, *args):
        return _Geom2dConvert.ios_base_setf(self, *args)

    def unsetf(self, __mask):
        return _Geom2dConvert.ios_base_unsetf(self, __mask)

    def precision(self, *args):
        return _Geom2dConvert.ios_base_precision(self, *args)

    def width(self, *args):
        return _Geom2dConvert.ios_base_width(self, *args)

    @staticmethod
    def sync_with_stdio(__sync=True):
        return _Geom2dConvert.ios_base_sync_with_stdio(__sync)

    def imbue(self, __loc):
        return _Geom2dConvert.ios_base_imbue(self, __loc)

    def getloc(self):
        return _Geom2dConvert.ios_base_getloc(self)

    @staticmethod
    def xalloc():
        return _Geom2dConvert.ios_base_xalloc()

    def iword(self, __ix):
        return _Geom2dConvert.ios_base_iword(self, __ix)

    def pword(self, __ix):
        return _Geom2dConvert.ios_base_pword(self, __ix)
    __swig_destroy__ = _Geom2dConvert.delete_ios_base

# Register ios_base in _Geom2dConvert:
_Geom2dConvert.ios_base_swigregister(ios_base)
cvar = _Geom2dConvert.cvar
ios_base.boolalpha = _Geom2dConvert.cvar.ios_base_boolalpha
ios_base.dec = _Geom2dConvert.cvar.ios_base_dec
ios_base.fixed = _Geom2dConvert.cvar.ios_base_fixed
ios_base.hex = _Geom2dConvert.cvar.ios_base_hex
ios_base.internal = _Geom2dConvert.cvar.ios_base_internal
ios_base.left = _Geom2dConvert.cvar.ios_base_left
ios_base.oct = _Geom2dConvert.cvar.ios_base_oct
ios_base.right = _Geom2dConvert.cvar.ios_base_right
ios_base.scientific = _Geom2dConvert.cvar.ios_base_scientific
ios_base.showbase = _Geom2dConvert.cvar.ios_base_showbase
ios_base.showpoint = _Geom2dConvert.cvar.ios_base_showpoint
ios_base.showpos = _Geom2dConvert.cvar.ios_base_showpos
ios_base.skipws = _Geom2dConvert.cvar.ios_base_skipws
ios_base.unitbuf = _Geom2dConvert.cvar.ios_base_unitbuf
ios_base.uppercase = _Geom2dConvert.cvar.ios_base_uppercase
ios_base.adjustfield = _Geom2dConvert.cvar.ios_base_adjustfield
ios_base.basefield = _Geom2dConvert.cvar.ios_base_basefield
ios_base.floatfield = _Geom2dConvert.cvar.ios_base_floatfield
ios_base.badbit = _Geom2dConvert.cvar.ios_base_badbit
ios_base.eofbit = _Geom2dConvert.cvar.ios_base_eofbit
ios_base.failbit = _Geom2dConvert.cvar.ios_base_failbit
ios_base.goodbit = _Geom2dConvert.cvar.ios_base_goodbit
ios_base.app = _Geom2dConvert.cvar.ios_base_app
ios_base.ate = _Geom2dConvert.cvar.ios_base_ate
ios_base.binary = _Geom2dConvert.cvar.ios_base_binary
ios_base.ios_base_in = _Geom2dConvert.cvar.ios_base_ios_base_in
ios_base.out = _Geom2dConvert.cvar.ios_base_out
ios_base.trunc = _Geom2dConvert.cvar.ios_base_trunc
ios_base.beg = _Geom2dConvert.cvar.ios_base_beg
ios_base.cur = _Geom2dConvert.cvar.ios_base_cur
ios_base.end = _Geom2dConvert.cvar.ios_base_end

class ios(ios_base):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def rdstate(self):
        return _Geom2dConvert.ios_rdstate(self)

    def clear(self, *args):
        return _Geom2dConvert.ios_clear(self, *args)

    def setstate(self, __state):
        return _Geom2dConvert.ios_setstate(self, __state)

    def good(self):
        return _Geom2dConvert.ios_good(self)

    def eof(self):
        return _Geom2dConvert.ios_eof(self)

    def fail(self):
        return _Geom2dConvert.ios_fail(self)

    def bad(self):
        return _Geom2dConvert.ios_bad(self)

    def exceptions(self, *args):
        return _Geom2dConvert.ios_exceptions(self, *args)

    def __init__(self, __sb):
        _Geom2dConvert.ios_swiginit(self, _Geom2dConvert.new_ios(__sb))
    __swig_destroy__ = _Geom2dConvert.delete_ios

    def tie(self, *args):
        return _Geom2dConvert.ios_tie(self, *args)

    def rdbuf(self, *args):
        return _Geom2dConvert.ios_rdbuf(self, *args)

    def copyfmt(self, __rhs):
        return _Geom2dConvert.ios_copyfmt(self, __rhs)

    def fill(self, *args):
        return _Geom2dConvert.ios_fill(self, *args)

    def imbue(self, __loc):
        return _Geom2dConvert.ios_imbue(self, __loc)

    def narrow(self, __c, __dfault):
        return _Geom2dConvert.ios_narrow(self, __c, __dfault)

    def widen(self, __c):
        return _Geom2dConvert.ios_widen(self, __c)

# Register ios in _Geom2dConvert:
_Geom2dConvert.ios_swigregister(ios)
class ostream(ios):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, __sb):
        _Geom2dConvert.ostream_swiginit(self, _Geom2dConvert.new_ostream(__sb))
    __swig_destroy__ = _Geom2dConvert.delete_ostream

    def __lshift__(self, *args):
        return _Geom2dConvert.ostream___lshift__(self, *args)

    def put(self, __c):
        return _Geom2dConvert.ostream_put(self, __c)

    def write(self, __s, __n):
        return _Geom2dConvert.ostream_write(self, __s, __n)

    def flush(self):
        return _Geom2dConvert.ostream_flush(self)

    def tellp(self):
        return _Geom2dConvert.ostream_tellp(self)

    def seekp(self, *args):
        return _Geom2dConvert.ostream_seekp(self, *args)

# Register ostream in _Geom2dConvert:
_Geom2dConvert.ostream_swigregister(ostream)
class istream(ios):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, __sb):
        _Geom2dConvert.istream_swiginit(self, _Geom2dConvert.new_istream(__sb))
    __swig_destroy__ = _Geom2dConvert.delete_istream

    def __rshift__(self, *args):
        return _Geom2dConvert.istream___rshift__(self, *args)

    def gcount(self):
        return _Geom2dConvert.istream_gcount(self)

    def get(self, *args):
        return _Geom2dConvert.istream_get(self, *args)

    def getline(self, *args):
        return _Geom2dConvert.istream_getline(self, *args)

    def ignore(self, *args):
        return _Geom2dConvert.istream_ignore(self, *args)

    def peek(self):
        return _Geom2dConvert.istream_peek(self)

    def read(self, __s, __n):
        return _Geom2dConvert.istream_read(self, __s, __n)

    def readsome(self, __s, __n):
        return _Geom2dConvert.istream_readsome(self, __s, __n)

    def putback(self, __c):
        return _Geom2dConvert.istream_putback(self, __c)

    def unget(self):
        return _Geom2dConvert.istream_unget(self)

    def sync(self):
        return _Geom2dConvert.istream_sync(self)

    def tellg(self):
        return _Geom2dConvert.istream_tellg(self)

    def seekg(self, *args):
        return _Geom2dConvert.istream_seekg(self, *args)

# Register istream in _Geom2dConvert:
_Geom2dConvert.istream_swigregister(istream)
class iostream(istream, ostream):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, __sb):
        _Geom2dConvert.iostream_swiginit(self, _Geom2dConvert.new_iostream(__sb))
    __swig_destroy__ = _Geom2dConvert.delete_iostream

# Register iostream in _Geom2dConvert:
_Geom2dConvert.iostream_swigregister(iostream)
cin = cvar.cin
cout = cvar.cout
cerr = cvar.cerr
clog = cvar.clog

endl_cb_ptr = _Geom2dConvert.endl_cb_ptr
endl = _Geom2dConvert.endl
ends_cb_ptr = _Geom2dConvert.ends_cb_ptr
ends = _Geom2dConvert.ends
flush_cb_ptr = _Geom2dConvert.flush_cb_ptr
flush = _Geom2dConvert.flush
import OCC.Core.Standard
import OCC.Core.NCollection
import OCC.Core.Geom2d
import OCC.Core.gp
import OCC.Core.TColStd
import OCC.Core.TCollection
import OCC.Core.GeomAbs
import OCC.Core.TColgp
import OCC.Core.TColGeom2d
import OCC.Core.Convert
import OCC.Core.Adaptor2d

from enum import IntEnum
from OCC.Core.Exception import *



class Geom2dConvert_SequenceOfPPoint(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def begin(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_begin(self)

    def end(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_end(self)

    def cbegin(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_cbegin(self)

    def cend(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_cend(self)

    def __init__(self, *args):
        _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_swiginit(self, _Geom2dConvert.new_Geom2dConvert_SequenceOfPPoint(*args))

    def Size(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Size(self)

    def Length(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Length(self)

    def Lower(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Lower(self)

    def Upper(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Upper(self)

    def IsEmpty(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_IsEmpty(self)

    def Reverse(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Reverse(self)

    def Exchange(self, I, J):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Exchange(self, I, J)

    @staticmethod
    def delNode(theNode, theAl):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_delNode(theNode, theAl)

    def Clear(self, theAllocator=0):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Clear(self, theAllocator)

    def Assign(self, theOther):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Assign(self, theOther)

    def Set(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Set(self, *args)

    def Remove(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Remove(self, *args)

    def Append(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Append(self, *args)

    def Prepend(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Prepend(self, *args)

    def InsertBefore(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_InsertBefore(self, *args)

    def InsertAfter(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_InsertAfter(self, *args)

    def Split(self, theIndex, theSeq):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Split(self, theIndex, theSeq)

    def First(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_First(self)

    def ChangeFirst(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_ChangeFirst(self)

    def Last(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Last(self)

    def ChangeLast(self):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_ChangeLast(self)

    def Value(self, theIndex):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_Value(self, theIndex)

    def ChangeValue(self, theIndex):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_ChangeValue(self, theIndex)

    def __call__(self, *args):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint___call__(self, *args)

    def SetValue(self, theIndex, theItem):
        return _Geom2dConvert.Geom2dConvert_SequenceOfPPoint_SetValue(self, theIndex, theItem)
    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_SequenceOfPPoint

    def __len__(self):
        return self.Size()


# Register Geom2dConvert_SequenceOfPPoint in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_SequenceOfPPoint_swigregister(Geom2dConvert_SequenceOfPPoint)
class geom2dconvert(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    @staticmethod
    def C0BSplineToArrayOfC1BSplineCurve(*args):
        r"""

        Parameters
        ----------
        BS: Geom2d_BSplineCurve
        tabBS: TColGeom2d_HArray1OfBSplineCurve
        Tolerance: float

        Return
        -------
        None

        Description
        -----------
        This Method reduces as far as it is possible the multiplicities of the knots of the BSpline BS.(keeping the geometry). It returns an array of BSpline C1. Tolerance is a geometrical tolerance.

        Parameters
        ----------
        BS: Geom2d_BSplineCurve
        tabBS: TColGeom2d_HArray1OfBSplineCurve
        AngularTolerance: float
        Tolerance: float

        Return
        -------
        None

        Description
        -----------
        This Method reduces as far as it is possible the multiplicities of the knots of the BSpline BS.(keeping the geometry). It returns an array of BSpline C1. tolerance is a geometrical tolerance.

        """
        return _Geom2dConvert.geom2dconvert_C0BSplineToArrayOfC1BSplineCurve(*args)

    @staticmethod
    def C0BSplineToC1BSplineCurve(*args):
        r"""

        Parameters
        ----------
        BS: Geom2d_BSplineCurve
        Tolerance: float

        Return
        -------
        None

        Description
        -----------
        This Method reduces as far as it is possible the multiplicities of the knots of the BSpline BS.(keeping the geometry). It returns a new BSpline which could still be C0. tolerance is a geometrical tolerance.

        """
        return _Geom2dConvert.geom2dconvert_C0BSplineToC1BSplineCurve(*args)

    @staticmethod
    def ConcatC1(*args):
        r"""

        Parameters
        ----------
        ArrayOfCurves: TColGeom2d_Array1OfBSplineCurve
        ArrayOfToler: TColStd_Array1OfReal
        ArrayOfIndices: TColStd_HArray1OfInteger
        ArrayOfConcatenated: TColGeom2d_HArray1OfBSplineCurve
        ClosedTolerance: float

        Return
        -------
        ClosedFlag: bool

        Description
        -----------
        This Method concatenates C1 the ArrayOfCurves as far as it is possible. ArrayOfCurves[0..N-1] ArrayOfToler contains the biggest tolerance of the two points shared by two consecutives curves. Its dimension: [0..N-2] ClosedFlag indicates if the ArrayOfCurves is closed. In this case ClosedTolerance contains the biggest tolerance of the two points which are at the closure. Otherwise its value is 0.0 ClosedFlag becomes False on the output if it is impossible to build closed curve.

        Parameters
        ----------
        ArrayOfCurves: TColGeom2d_Array1OfBSplineCurve
        ArrayOfToler: TColStd_Array1OfReal
        ArrayOfIndices: TColStd_HArray1OfInteger
        ArrayOfConcatenated: TColGeom2d_HArray1OfBSplineCurve
        ClosedTolerance: float
        AngularTolerance: float

        Return
        -------
        ClosedFlag: bool

        Description
        -----------
        This Method concatenates C1 the ArrayOfCurves as far as it is possible. ArrayOfCurves[0..N-1] ArrayOfToler contains the biggest tolerance of the two points shared by two consecutives curves. Its dimension: [0..N-2] ClosedFlag indicates if the ArrayOfCurves is closed. In this case ClosedTolerance contains the biggest tolerance of the two points which are at the closure. Otherwise its value is 0.0 ClosedFlag becomes False on the output if it is impossible to build closed curve.

        """
        return _Geom2dConvert.geom2dconvert_ConcatC1(*args)

    @staticmethod
    def ConcatG1(*args):
        r"""

        Parameters
        ----------
        ArrayOfCurves: TColGeom2d_Array1OfBSplineCurve
        ArrayOfToler: TColStd_Array1OfReal
        ArrayOfConcatenated: TColGeom2d_HArray1OfBSplineCurve
        ClosedTolerance: float

        Return
        -------
        ClosedFlag: bool

        Description
        -----------
        This Method concatenates G1 the ArrayOfCurves as far as it is possible. ArrayOfCurves[0..N-1] ArrayOfToler contains the biggest tolerance of the two points shared by two consecutives curves. Its dimension: [0..N-2] ClosedFlag indicates if the ArrayOfCurves is closed. In this case ClosedTolerance contains the biggest tolerance of the two points which are at the closure. Otherwise its value is 0.0 ClosedFlag becomes False on the output if it is impossible to build closed curve.

        """
        return _Geom2dConvert.geom2dconvert_ConcatG1(*args)

    @staticmethod
    def CurveToBSplineCurve(*args):
        r"""

        Parameters
        ----------
        C: Geom2d_Curve
        Parameterisation: Convert_ParameterisationType (optional, default to Convert_TgtThetaOver2)

        Return
        -------
        opencascade::handle<Geom2d_BSplineCurve>

        Description
        -----------
        This function converts a non infinite curve from Geom into a B-spline curve. C must be an ellipse or a circle or a trimmed conic or a trimmed line or a Bezier curve or a trimmed Bezier curve or a BSpline curve or a trimmed BSpline curve or an Offset curve or a trimmed Offset curve. The returned B-spline is not periodic except if C is a Circle or an Ellipse. ParameterisationType applies only if the curve is a Circle or an ellipse: TgtThetaOver2, TgtThetaOver2_1, TgtThetaOver2_2, TgtThetaOver2_3, TgtThetaOver2_4, Purpose: this is the classical rational parameterisation 2 1 - t cos(theta) = ------ 2 1 + t //! 2t sin(theta) = ------ 2 1 + t //! t = tan (theta/2) //! with TgtThetaOver2 the routine will compute the number of spans using the rule num_spans = [ (ULast - UFirst) / 1.2 ] + 1 with TgtThetaOver2_N, N spans will be forced: an error will be raized if (ULast - UFirst) >= PI and N = 1, ULast - UFirst >= 2 PI and N = 2 //! QuasiAngular, here t is a rational function that approximates theta ----> tan(theta/2). Nevetheless the composing with above function yields exact functions whose square sum up to 1 RationalC1 ; t is replaced by a polynomial function of u so as to grant C1 contiuity across knots. Exceptions Standard_DomainError if the curve C is infinite. Standard_ConstructionError: - if C is a complete circle or ellipse, and if Parameterisation is not equal to Convert_TgtThetaOver2 or to Convert_RationalC1, or - if C is a trimmed circle or ellipse and if Parameterisation is equal to Convert_TgtThetaOver2_1 and if U2 - U1 > 0.9999 * Pi where U1 and U2 are respectively the first and the last parameters of the trimmed curve (this method of parameterization cannot be used to convert a half-circle or a half-ellipse, for example), or - if C is a trimmed circle or ellipse and Parameterisation is equal to Convert_TgtThetaOver2_2 and U2 - U1 > 1.9999 * Pi where U1 and U2 are respectively the first and the last parameters of the trimmed curve (this method of parameterization cannot be used to convert a quasi-complete circle or ellipse).

        """
        return _Geom2dConvert.geom2dconvert_CurveToBSplineCurve(*args)

    @staticmethod
    def SplitBSplineCurve(*args):
        r"""

        Parameters
        ----------
        C: Geom2d_BSplineCurve
        FromK1: int
        ToK2: int
        SameOrientation: bool (optional, default to Standard_True)

        Return
        -------
        opencascade::handle<Geom2d_BSplineCurve>

        Description
        -----------
        -- Convert a curve to BSpline by Approximation //! This method computes the arc of B-spline curve between the two knots FromK1 and ToK2. If C is periodic the arc has the same orientation as C if SameOrientation = Standard_True. If C is not periodic SameOrientation is not used for the computation and C is oriented from the knot fromK1 to the knot toK2. We just keep the local definition of C between the knots FromK1 and ToK2. The returned B-spline curve has its first and last knots with a multiplicity equal to degree + 1, where degree is the polynomial degree of C. The indexes of the knots FromK1 and ToK2 doesn't include the repetition of multiple knots in their definition. //! Raised if FromK1 or ToK2 are out of the bounds [FirstUKnotIndex, LastUKnotIndex] Raised if FromK1 = ToK2.

        Parameters
        ----------
        C: Geom2d_BSplineCurve
        FromU1: float
        ToU2: float
        ParametricTolerance: float
        SameOrientation: bool (optional, default to Standard_True)

        Return
        -------
        opencascade::handle<Geom2d_BSplineCurve>

        Description
        -----------
        This function computes the segment of B-spline curve between the parametric values FromU1, ToU2. If C is periodic the arc has the same orientation as C if SameOrientation = True. If C is not periodic SameOrientation is not used for the computation and C is oriented fromU1 toU2. If U1 and U2 and two parametric values we consider that U1 = U2 if Abs (U1 - U2) <= ParametricTolerance and ParametricTolerance must be greater or equal to Resolution from package gp. //! Raised if FromU1 or ToU2 are out of the parametric bounds of the curve (The tolerance criterion is ParametricTolerance). Raised if Abs (FromU1 - ToU2) <= ParametricTolerance Raised if ParametricTolerance < Resolution from gp.

        """
        return _Geom2dConvert.geom2dconvert_SplitBSplineCurve(*args)

    __repr__ = _dumps_object


    def __init__(self):
        _Geom2dConvert.geom2dconvert_swiginit(self, _Geom2dConvert.new_geom2dconvert())
    __swig_destroy__ = _Geom2dConvert.delete_geom2dconvert

# Register geom2dconvert in _Geom2dConvert:
_Geom2dConvert.geom2dconvert_swigregister(geom2dconvert)
class Geom2dConvert_ApproxArcsSegments(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr
    StatusOK = _Geom2dConvert.Geom2dConvert_ApproxArcsSegments_StatusOK
    StatusNotDone = _Geom2dConvert.Geom2dConvert_ApproxArcsSegments_StatusNotDone
    StatusError = _Geom2dConvert.Geom2dConvert_ApproxArcsSegments_StatusError


    class Status(IntEnum):
    	StatusOK = 0
    	StatusNotDone = 1
    	StatusError = 2
    StatusOK = Status.StatusOK
    StatusNotDone = Status.StatusNotDone
    StatusError = Status.StatusError


    def __init__(self, *args):
        r"""

        Parameters
        ----------
        theCurve: Adaptor2d_Curve2d
        theTolerance: float
        theAngleTol: float

        Return
        -------
        None

        Description
        -----------
        Constructor.

        """
        _Geom2dConvert.Geom2dConvert_ApproxArcsSegments_swiginit(self, _Geom2dConvert.new_Geom2dConvert_ApproxArcsSegments(*args))

    def GetResult(self, *args):
        r"""
        Return
        -------
        TColGeom2d_SequenceOfCurve

        Description
        -----------
        Get the result curve after approximation.

        """
        return _Geom2dConvert.Geom2dConvert_ApproxArcsSegments_GetResult(self, *args)

    __repr__ = _dumps_object

    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_ApproxArcsSegments

# Register Geom2dConvert_ApproxArcsSegments in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_ApproxArcsSegments_swigregister(Geom2dConvert_ApproxArcsSegments)
class Geom2dConvert_ApproxCurve(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, *args):
        r"""

        Parameters
        ----------
        Curve: Geom2d_Curve
        Tol2d: float
        Order: GeomAbs_Shape
        MaxSegments: int
        MaxDegree: int

        Return
        -------
        None

        Description
        -----------
        Constructs an approximation framework defined by - the 2D conic Curve - the tolerance value Tol2d - the degree of continuity Order - the maximum number of segments allowed MaxSegments - the highest degree MaxDegree which the polynomial defining the BSpline is allowed to have.

        Parameters
        ----------
        Curve: Adaptor2d_Curve2d
        Tol2d: float
        Order: GeomAbs_Shape
        MaxSegments: int
        MaxDegree: int

        Return
        -------
        None

        Description
        -----------
        Constructs an approximation framework defined by - the 2D conic Curve - the tolerance value Tol2d - the degree of continuity Order - the maximum number of segments allowed MaxSegments - the highest degree MaxDegree which the polynomial defining the BSpline is allowed to have.

        """
        _Geom2dConvert.Geom2dConvert_ApproxCurve_swiginit(self, _Geom2dConvert.new_Geom2dConvert_ApproxCurve(*args))

    def Curve(self, *args):
        r"""
        Return
        -------
        opencascade::handle<Geom2d_BSplineCurve>

        Description
        -----------
        Returns the 2D BSpline curve resulting from the approximation algorithm.

        """
        return _Geom2dConvert.Geom2dConvert_ApproxCurve_Curve(self, *args)

    def Dump(self, *args):
        r"""

        Parameters
        ----------

        Return
        -------
        o: Standard_OStream

        Description
        -----------
        Print on the stream o information about the object.

        """
        return _Geom2dConvert.Geom2dConvert_ApproxCurve_Dump(self, *args)

    def HasResult(self, *args):
        r"""
        Return
        -------
        bool

        Description
        -----------
        returns Standard_True if the approximation did come out with a result that is not NECESSARELY within the required tolerance.

        """
        return _Geom2dConvert.Geom2dConvert_ApproxCurve_HasResult(self, *args)

    def IsDone(self, *args):
        r"""
        Return
        -------
        bool

        Description
        -----------
        returns Standard_True if the approximation has been done with within required tolerance.

        """
        return _Geom2dConvert.Geom2dConvert_ApproxCurve_IsDone(self, *args)

    def MaxError(self, *args):
        r"""
        Return
        -------
        float

        Description
        -----------
        Returns the greatest distance between a point on the source conic and the BSpline curve resulting from the approximation. (>0 when an approximation has been done, 0 if no approximation).

        """
        return _Geom2dConvert.Geom2dConvert_ApproxCurve_MaxError(self, *args)

    __repr__ = _dumps_object

    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_ApproxCurve

# Register Geom2dConvert_ApproxCurve in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_ApproxCurve_swigregister(Geom2dConvert_ApproxCurve)
class Geom2dConvert_BSplineCurveKnotSplitting(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, *args):
        r"""

        Parameters
        ----------
        BasisCurve: Geom2d_BSplineCurve
        ContinuityRange: int

        Return
        -------
        None

        Description
        -----------
        Determines points at which the BSpline curve BasisCurve should be split in order to obtain arcs with a degree of continuity equal to ContinuityRange. These points are knot values of BasisCurve. They are identified by indices in the knots table of BasisCurve. Use the available interrogation functions to access computed values, followed by the global function SplitBSplineCurve (provided by the package Geom2dConvert) to split the curve. Exceptions Standard_RangeError if ContinuityRange is less than zero.

        """
        _Geom2dConvert.Geom2dConvert_BSplineCurveKnotSplitting_swiginit(self, _Geom2dConvert.new_Geom2dConvert_BSplineCurveKnotSplitting(*args))

    def NbSplits(self, *args):
        r"""
        Return
        -------
        int

        Description
        -----------
        Returns the number of points at which the analysed BSpline curve should be split, in order to obtain arcs with the continuity required by this framework. All these points correspond to knot values. Note that the first and last points of the curve, which bound the first and last arcs, are counted among these splitting points.

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveKnotSplitting_NbSplits(self, *args)

    def SplitValue(self, *args):
        r"""

        Parameters
        ----------
        Index: int

        Return
        -------
        int

        Description
        -----------
        Returns the split knot of index Index to the split knots table computed in this framework. The returned value is an index in the knots table of the BSpline curve analysed by this algorithm. Notes: - If Index is equal to 1, the corresponding knot gives the first point of the curve. - If Index is equal to the number of split knots computed in this framework, the corresponding point is the last point of the curve. Exceptions Standard_RangeError if Index is less than 1 or greater than the number of split knots computed in this framework.

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveKnotSplitting_SplitValue(self, *args)

    def Splitting(self, *args):
        r"""

        Parameters
        ----------
        SplitValues: TColStd_Array1OfInteger

        Return
        -------
        None

        Description
        -----------
        Loads the SplitValues table with the split knots values computed in this framework. Each value in the table is an index in the knots table of the BSpline curve analysed by this algorithm. The values in SplitValues are given in ascending order and comprise the indices of the knots which give the first and last points of the curve. Use two consecutive values from the table as arguments of the global function SplitBSplineCurve (provided by the package Geom2dConvert) to split the curve. Exceptions Standard_DimensionError if the array SplitValues was not created with the following bounds: - 1, and - the number of split points computed in this framework (as given by the function NbSplits).

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveKnotSplitting_Splitting(self, *args)

    __repr__ = _dumps_object

    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_BSplineCurveKnotSplitting

# Register Geom2dConvert_BSplineCurveKnotSplitting in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_BSplineCurveKnotSplitting_swigregister(Geom2dConvert_BSplineCurveKnotSplitting)
class Geom2dConvert_BSplineCurveToBezierCurve(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, *args):
        r"""

        Parameters
        ----------
        BasisCurve: Geom2d_BSplineCurve

        Return
        -------
        None

        Description
        -----------
        Computes all the data needed to convert - the BSpline curve BasisCurve, into a series of adjacent Bezier arcs. The result consists of a series of BasisCurve arcs limited by points corresponding to knot values of the curve. Use the available interrogation functions to ascertain the number of computed Bezier arcs, and then to construct each individual Bezier curve (or all Bezier curves). Note: ParametricTolerance is not used.

        Parameters
        ----------
        BasisCurve: Geom2d_BSplineCurve
        U1: float
        U2: float
        ParametricTolerance: float

        Return
        -------
        None

        Description
        -----------
        Computes all the data needed to convert the portion of the BSpline curve BasisCurve limited by the two parameter values U1 and U2 for Example if there is a Knot Uk and Uk < U < Uk + ParametricTolerance/2 the last curve corresponds to the span [Uk-1, Uk] and not to [Uk, Uk+1] The result consists of a series of BasisCurve arcs limited by points corresponding to knot values of the curve. Use the available interrogation functions to ascertain the number of computed Bezier arcs, and then to construct each individual Bezier curve (or all Bezier curves). Note: ParametricTolerance is not used. Raises DomainError if U1 or U2 are out of the parametric bounds of the basis curve [FirstParameter, LastParameter]. The Tolerance criterion is ParametricTolerance. Raised if Abs (U2 - U1) <= ParametricTolerance.

        """
        _Geom2dConvert.Geom2dConvert_BSplineCurveToBezierCurve_swiginit(self, _Geom2dConvert.new_Geom2dConvert_BSplineCurveToBezierCurve(*args))

    def Arc(self, *args):
        r"""

        Parameters
        ----------
        Index: int

        Return
        -------
        opencascade::handle<Geom2d_BezierCurve>

        Description
        -----------
        Constructs and returns the Bezier curve of index Index to the table of adjacent Bezier arcs computed by this algorithm. This Bezier curve has the same orientation as the BSpline curve analyzed in this framework. Exceptions Standard_OutOfRange if Index is less than 1 or greater than the number of adjacent Bezier arcs computed by this algorithm.

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveToBezierCurve_Arc(self, *args)

    def Arcs(self, *args):
        r"""

        Parameters
        ----------
        Curves: TColGeom2d_Array1OfBezierCurve

        Return
        -------
        None

        Description
        -----------
        Constructs all the Bezier curves whose data is computed by this algorithm and loads these curves into the Curves table. The Bezier curves have the same orientation as the BSpline curve analyzed in this framework. Exceptions Standard_DimensionError if the Curves array was not created with the following bounds: - 1 , and - the number of adjacent Bezier arcs computed by this algorithm (as given by the function NbArcs).

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveToBezierCurve_Arcs(self, *args)

    def Knots(self, *args):
        r"""

        Parameters
        ----------
        TKnots: TColStd_Array1OfReal

        Return
        -------
        None

        Description
        -----------
        This methode returns the bspline's knots associated to the converted arcs Raises DimensionError if the length of Curves is not equal to NbArcs + 1.

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveToBezierCurve_Knots(self, *args)

    def NbArcs(self, *args):
        r"""
        Return
        -------
        int

        Description
        -----------
        Returns the number of BezierCurve arcs. If at the creation time you have decomposed the basis curve between the parametric values UFirst, ULast the number of BezierCurve arcs depends on the number of knots included inside the interval [UFirst, ULast]. If you have decomposed the whole basis B-spline curve the number of BezierCurve arcs NbArcs is equal to the number of knots less one.

        """
        return _Geom2dConvert.Geom2dConvert_BSplineCurveToBezierCurve_NbArcs(self, *args)

    __repr__ = _dumps_object

    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_BSplineCurveToBezierCurve

# Register Geom2dConvert_BSplineCurveToBezierCurve in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_BSplineCurveToBezierCurve_swigregister(Geom2dConvert_BSplineCurveToBezierCurve)
class Geom2dConvert_CompCurveToBSplineCurve(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, *args):
        r"""

        Parameters
        ----------
        Parameterisation: Convert_ParameterisationType (optional, default to Convert_TgtThetaOver2)

        Return
        -------
        None

        Description
        -----------
        Initialize the algorithme - Parameterisation is used to convert.

        Parameters
        ----------
        BasisCurve: Geom2d_BoundedCurve
        Parameterisation: Convert_ParameterisationType (optional, default to Convert_TgtThetaOver2)

        Return
        -------
        None

        Description
        -----------
        Initialize the algorithme with one curve - Parameterisation is used to convert.

        """
        _Geom2dConvert.Geom2dConvert_CompCurveToBSplineCurve_swiginit(self, _Geom2dConvert.new_Geom2dConvert_CompCurveToBSplineCurve(*args))

    def Add(self, *args):
        r"""

        Parameters
        ----------
        NewCurve: Geom2d_BoundedCurve
        Tolerance: float
        After: bool (optional, default to Standard_False)

        Return
        -------
        bool

        Description
        -----------
        Append a curve in the BSpline Return False if the curve is not G0 with the BSplineCurve. Tolerance is used to check continuity and decrease Multiplicity at the common Knot After is useful if BasisCurve is a closed curve .

        """
        return _Geom2dConvert.Geom2dConvert_CompCurveToBSplineCurve_Add(self, *args)

    def BSplineCurve(self, *args):
        r"""
        Return
        -------
        opencascade::handle<Geom2d_BSplineCurve>

        Description
        -----------
        No available documentation.

        """
        return _Geom2dConvert.Geom2dConvert_CompCurveToBSplineCurve_BSplineCurve(self, *args)

    def Clear(self, *args):
        r"""
        Return
        -------
        None

        Description
        -----------
        Clear result curve.

        """
        return _Geom2dConvert.Geom2dConvert_CompCurveToBSplineCurve_Clear(self, *args)

    __repr__ = _dumps_object

    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_CompCurveToBSplineCurve

# Register Geom2dConvert_CompCurveToBSplineCurve in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_CompCurveToBSplineCurve_swigregister(Geom2dConvert_CompCurveToBSplineCurve)
class Geom2dConvert_PPoint(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, *args):
        r"""
        Return
        -------
        None

        Description
        -----------
        Empty constructor.

        Parameters
        ----------
        theParameter: float
        thePoint: gp_XY
        theD1: gp_XY

        Return
        -------
        None

        Description
        -----------
        Constructor.

        Parameters
        ----------
        theParameter: float
        theAdaptor: Adaptor2d_Curve2d

        Return
        -------
        None

        Description
        -----------
        Constructor.

        """
        _Geom2dConvert.Geom2dConvert_PPoint_swiginit(self, _Geom2dConvert.new_Geom2dConvert_PPoint(*args))

    def D1(self, *args):
        r"""
        Return
        -------
        gp_XY

        Description
        -----------
        Query the first derivatives.

        """
        return _Geom2dConvert.Geom2dConvert_PPoint_D1(self, *args)

    def Dist(self, *args):
        r"""

        Parameters
        ----------
        theOth: Geom2dConvert_PPoint

        Return
        -------
        float

        Description
        -----------
        Compute the distance between two 2d points.

        """
        return _Geom2dConvert.Geom2dConvert_PPoint_Dist(self, *args)

    def Parameter(self, *args):
        r"""
        Return
        -------
        float

        Description
        -----------
        Query the parameter value.

        """
        return _Geom2dConvert.Geom2dConvert_PPoint_Parameter(self, *args)

    def Point(self, *args):
        r"""
        Return
        -------
        gp_XY

        Description
        -----------
        Query the point location.

        """
        return _Geom2dConvert.Geom2dConvert_PPoint_Point(self, *args)

    def SetD1(self, *args):
        r"""

        Parameters
        ----------
        theD1: gp_XY

        Return
        -------
        None

        Description
        -----------
        Change the value of the derivative at the point.

        """
        return _Geom2dConvert.Geom2dConvert_PPoint_SetD1(self, *args)

    def __ne_wrapper__(self, other):
        return _Geom2dConvert.Geom2dConvert_PPoint___ne_wrapper__(self, other)

    def __ne__(self, right):
        try:
            return self.__ne_wrapper__(right)
        except:
            return True


    def __eq_wrapper__(self, other):
        return _Geom2dConvert.Geom2dConvert_PPoint___eq_wrapper__(self, other)

    def __eq__(self, right):
        try:
            return self.__eq_wrapper__(right)
        except:
            return False


    __repr__ = _dumps_object

    __swig_destroy__ = _Geom2dConvert.delete_Geom2dConvert_PPoint

# Register Geom2dConvert_PPoint in _Geom2dConvert:
_Geom2dConvert.Geom2dConvert_PPoint_swigregister(Geom2dConvert_PPoint)



@deprecated
def geom2dconvert_C0BSplineToArrayOfC1BSplineCurve(*args):
	return geom2dconvert.C0BSplineToArrayOfC1BSplineCurve(*args)

@deprecated
def geom2dconvert_C0BSplineToArrayOfC1BSplineCurve(*args):
	return geom2dconvert.C0BSplineToArrayOfC1BSplineCurve(*args)

@deprecated
def geom2dconvert_C0BSplineToC1BSplineCurve(*args):
	return geom2dconvert.C0BSplineToC1BSplineCurve(*args)

@deprecated
def geom2dconvert_ConcatC1(*args):
	return geom2dconvert.ConcatC1(*args)

@deprecated
def geom2dconvert_ConcatC1(*args):
	return geom2dconvert.ConcatC1(*args)

@deprecated
def geom2dconvert_ConcatG1(*args):
	return geom2dconvert.ConcatG1(*args)

@deprecated
def geom2dconvert_CurveToBSplineCurve(*args):
	return geom2dconvert.CurveToBSplineCurve(*args)

@deprecated
def geom2dconvert_SplitBSplineCurve(*args):
	return geom2dconvert.SplitBSplineCurve(*args)

@deprecated
def geom2dconvert_SplitBSplineCurve(*args):
	return geom2dconvert.SplitBSplineCurve(*args)



