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

from sys import version_info as _swig_python_version_info
# Import the low-level C/C++ module
if __package__ or "." in __name__:
    from . import _cmicrostructure
else:
    import _cmicrostructure

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__)


import ooflib.SWIG.common.coord
import ooflib.SWIG.common.pixelgroup
import ooflib.SWIG.common.pixelattribute
import ooflib.SWIG.common.timestamp
class SegmentSection(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")
    category = property(_cmicrostructure.SegmentSection_category_get)

    def pixelLength(self):
        return _cmicrostructure.SegmentSection_pixelLength(self)

    def physicalLength(self):
        return _cmicrostructure.SegmentSection_physicalLength(self)

    def physicalPt0(self):
        return _cmicrostructure.SegmentSection_physicalPt0(self)

    def physicalPt1(self):
        return _cmicrostructure.SegmentSection_physicalPt1(self)

    def pixelPt0(self):
        return _cmicrostructure.SegmentSection_pixelPt0(self)

    def pixelPt1(self):
        return _cmicrostructure.SegmentSection_pixelPt1(self)

    def __repr__(self):
        return _cmicrostructure.SegmentSection___repr__(self)
    __swig_destroy__ = _cmicrostructure.delete_SegmentSection

# Register SegmentSection in _cmicrostructure:
_cmicrostructure.SegmentSection_swigregister(SegmentSection)
class CMicrostructure(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, name, arg3, arg4):
        _cmicrostructure.CMicrostructure_swiginit(self, _cmicrostructure.new_CMicrostructure(name, arg3, arg4))
    __swig_destroy__ = _cmicrostructure.delete_CMicrostructure

    def destroy(self):
        return _cmicrostructure.CMicrostructure_destroy(self)

    def name(self):
        return _cmicrostructure.CMicrostructure_name(self)

    def sizeOfPixels(self):
        return _cmicrostructure.CMicrostructure_sizeOfPixels(self)

    def physical2Pixel(self, Point):
        return _cmicrostructure.CMicrostructure_physical2Pixel(self, Point)

    def rename(self, name):
        return _cmicrostructure.CMicrostructure_rename(self, name)

    def getTimeStamp(self):
        return _cmicrostructure.CMicrostructure_getTimeStamp(self)

    def setCurrentActiveArea(self, arg2):
        return _cmicrostructure.CMicrostructure_setCurrentActiveArea(self, arg2)

    def nGroups(self):
        return _cmicrostructure.CMicrostructure_nGroups(self)

    def getGroup(self, name):
        return _cmicrostructure.CMicrostructure_getGroup(self, name)

    def findGroup(self, name):
        return _cmicrostructure.CMicrostructure_findGroup(self, name)

    def removeGroup(self, name):
        return _cmicrostructure.CMicrostructure_removeGroup(self, name)

    def removeAllGroups(self):
        return _cmicrostructure.CMicrostructure_removeAllGroups(self)

    def renameGroupC(self, oldname, newname):
        return _cmicrostructure.CMicrostructure_renameGroupC(self, oldname, newname)

    def groupNames(self):
        return _cmicrostructure.CMicrostructure_groupNames(self)

    def nCategories(self):
        return _cmicrostructure.CMicrostructure_nCategories(self)

    def category(self, iPoint):
        return _cmicrostructure.CMicrostructure_category(self, iPoint)

    def recategorize(self):
        return _cmicrostructure.CMicrostructure_recategorize(self)

    def is_categorized(self):
        return _cmicrostructure.CMicrostructure_is_categorized(self)

    def getCategoryMap(self):
        return _cmicrostructure.CMicrostructure_getCategoryMap(self)

    def getCategoryMapRO(self):
        return _cmicrostructure.CMicrostructure_getCategoryMapRO(self)

    def getRepresentativePixel(self, category):
        return _cmicrostructure.CMicrostructure_getRepresentativePixel(self, category)

    def edgeHomogeneity(self, arg2, arg3):
        return _cmicrostructure.CMicrostructure_edgeHomogeneity(self, arg2, arg3)

    def getSegmentSections(self, arg2, arg3, arg4):
        return _cmicrostructure.CMicrostructure_getSegmentSections(self, arg2, arg3, arg4)

# Register CMicrostructure in _cmicrostructure:
_cmicrostructure.CMicrostructure_swigregister(CMicrostructure)

def get_globalMicrostructureCount():
    return _cmicrostructure.get_globalMicrostructureCount()

