# This file was automatically generated by SWIG (http://www.swig.org).
# Version 4.0.2
#
# 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
if _swig_python_version_info < (2, 7, 0):
    raise RuntimeError("Python 2.7 or later required")

# Import the low-level C/C++ module
if __package__ or "." in __name__:
    from . import _sorted_interval_list
else:
    import _sorted_interval_list

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 == "thisown":
            self.this.own(value)
        elif name == "this":
            set(self, name, 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 Domain(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):
        _sorted_interval_list.Domain_swiginit(self, _sorted_interval_list.new_Domain(*args))

    @staticmethod
    def AllValues() -> "operations_research::Domain":
        return _sorted_interval_list.Domain_AllValues()

    @staticmethod
    def FromValues(values: "std::vector< int64_t >") -> "operations_research::Domain":
        return _sorted_interval_list.Domain_FromValues(values)

    @staticmethod
    def FromIntervals(intervals: "std::vector< std::vector< int64_t > > const &") -> "operations_research::Domain":
        return _sorted_interval_list.Domain_FromIntervals(intervals)

    @staticmethod
    def FromFlatIntervals(flat_intervals: "std::vector< int64_t > const &") -> "operations_research::Domain":
        return _sorted_interval_list.Domain_FromFlatIntervals(flat_intervals)

    def FlattenedIntervals(self) -> "std::vector< int64_t >":
        return _sorted_interval_list.Domain_FlattenedIntervals(self)

    def IsEmpty(self) -> "bool":
        return _sorted_interval_list.Domain_IsEmpty(self)

    def Size(self) -> "int64_t":
        return _sorted_interval_list.Domain_Size(self)

    def Min(self) -> "int64_t":
        return _sorted_interval_list.Domain_Min(self)

    def Max(self) -> "int64_t":
        return _sorted_interval_list.Domain_Max(self)

    def Contains(self, value: "int64_t") -> "bool":
        return _sorted_interval_list.Domain_Contains(self, value)

    def Complement(self) -> "operations_research::Domain":
        return _sorted_interval_list.Domain_Complement(self)

    def Negation(self) -> "operations_research::Domain":
        return _sorted_interval_list.Domain_Negation(self)

    def IntersectionWith(self, domain: "Domain") -> "operations_research::Domain":
        return _sorted_interval_list.Domain_IntersectionWith(self, domain)

    def UnionWith(self, domain: "Domain") -> "operations_research::Domain":
        return _sorted_interval_list.Domain_UnionWith(self, domain)

    def AdditionWith(self, domain: "Domain") -> "operations_research::Domain":
        return _sorted_interval_list.Domain_AdditionWith(self, domain)

    def __str__(self) -> "std::string":
        return _sorted_interval_list.Domain___str__(self)

    def __lt__(self, other: "Domain") -> "bool":
        return _sorted_interval_list.Domain___lt__(self, other)

    def __eq__(self, other: "Domain") -> "bool":
        return _sorted_interval_list.Domain___eq__(self, other)

    def __ne__(self, other: "Domain") -> "bool":
        return _sorted_interval_list.Domain___ne__(self, other)
    __swig_destroy__ = _sorted_interval_list.delete_Domain

# Register Domain in _sorted_interval_list:
_sorted_interval_list.Domain_swigregister(Domain)

def Domain_AllValues() -> "operations_research::Domain":
    return _sorted_interval_list.Domain_AllValues()

def Domain_FromValues(values: "std::vector< int64_t >") -> "operations_research::Domain":
    return _sorted_interval_list.Domain_FromValues(values)

def Domain_FromIntervals(intervals: "std::vector< std::vector< int64_t > > const &") -> "operations_research::Domain":
    return _sorted_interval_list.Domain_FromIntervals(intervals)

def Domain_FromFlatIntervals(flat_intervals: "std::vector< int64_t > const &") -> "operations_research::Domain":
    return _sorted_interval_list.Domain_FromFlatIntervals(flat_intervals)


def __lshift__(*args) -> "std::ostream &":
    return _sorted_interval_list.__lshift__(*args)


