# 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 _security
else:
    from arc import _security

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__ = _security.delete_SwigPyIterator

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

import warnings

def deprecated(method):
    """This decorator is used to mark python methods as deprecated, _not_
    functions. It will result in a warning being emmitted when the method
    is used."""
    def newMethod(*args, **kwargs):
        warnings.warn("Call to deprecated method 'arc.%s.%s'." % (args[0].__class__.__name__, method.__name__), category = DeprecationWarning, stacklevel = 2)
        return method(*args, **kwargs)
    newMethod.__name__ = method.__name__
    newMethod.__doc__ = method.__doc__
    newMethod.__dict__.update(method.__dict__)
    return newMethod


class StaticPropertyWrapper(object):
    def __init__(self, wrapped_class):
        object.__setattr__(self, "wrapped_class", wrapped_class)

    def __getattr__(self, name):
        orig_attr = getattr(self.wrapped_class, name)
        if isinstance(orig_attr, property):
            return orig_attr.fget()
        else:
            return orig_attr

    def __setattr__(self, name, value):
        orig_attr = getattr(self.wrapped_class, name)
        if isinstance(orig_attr, property):
            orig_attr.fset(value)
        else:
            setattr(self.wrapped_class, name, value)



class Policy(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
    __swig_destroy__ = _security.delete_Policy

# Register Policy in _security:
_security.Policy_swigregister(Policy)
class Request(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
    __swig_destroy__ = _security.delete_Request

# Register Request in _security:
_security.Request_swigregister(Request)
DECISION_PERMIT = _security.DECISION_PERMIT
DECISION_DENY = _security.DECISION_DENY
DECISION_INDETERMINATE = _security.DECISION_INDETERMINATE
DECISION_NOT_APPLICABLE = _security.DECISION_NOT_APPLICABLE
class ResponseItem(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr
    res = property(_security.ResponseItem_res_get, _security.ResponseItem_res_set)

    def __init__(self):
        _security.ResponseItem_swiginit(self, _security.new_ResponseItem())
    __swig_destroy__ = _security.delete_ResponseItem

# Register ResponseItem in _security:
_security.ResponseItem_swigregister(ResponseItem)
class ResponseList(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def size(self):
        return _security.ResponseList_size(self)

    def getItem(self, n):
        return _security.ResponseList_getItem(self, n)

    def empty(self):
        return _security.ResponseList_empty(self)

    def __init__(self):
        _security.ResponseList_swiginit(self, _security.new_ResponseList())
    __swig_destroy__ = _security.delete_ResponseList

# Register ResponseList in _security:
_security.ResponseList_swigregister(ResponseList)
class Response(object):
    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def getResponseItems(self):
        return _security.Response_getResponseItems(self)

    def __init__(self):
        _security.Response_swiginit(self, _security.new_Response())
    __swig_destroy__ = _security.delete_Response

# Register Response in _security:
_security.Response_swigregister(Response)
class Source(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):
        _security.Source_swiginit(self, _security.new_Source(*args))
    __swig_destroy__ = _security.delete_Source

# Register Source in _security:
_security.Source_swigregister(Source)
class SourceFile(Source):
    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):
        _security.SourceFile_swiginit(self, _security.new_SourceFile(*args))
    __swig_destroy__ = _security.delete_SourceFile

# Register SourceFile in _security:
_security.SourceFile_swigregister(SourceFile)
class SourceURL(Source):
    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):
        _security.SourceURL_swiginit(self, _security.new_SourceURL(*args))
    __swig_destroy__ = _security.delete_SourceURL

# Register SourceURL in _security:
_security.SourceURL_swigregister(SourceURL)
class Evaluator(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

    def addPolicy(self, *args):
        return _security.Evaluator_addPolicy(self, *args)

    def evaluate(self, *args):
        return _security.Evaluator_evaluate(self, *args)
    __swig_destroy__ = _security.delete_Evaluator

# Register Evaluator in _security:
_security.Evaluator_swigregister(Evaluator)
class EvaluatorLoader(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):
        _security.EvaluatorLoader_swiginit(self, _security.new_EvaluatorLoader())

    def getEvaluator(self, classname):
        return _security.EvaluatorLoader_getEvaluator(self, classname)

    def getRequest(self, classname, requestsource):
        return _security.EvaluatorLoader_getRequest(self, classname, requestsource)

    def getPolicy(self, classname, policysource):
        return _security.EvaluatorLoader_getPolicy(self, classname, policysource)
    __swig_destroy__ = _security.delete_EvaluatorLoader

# Register EvaluatorLoader in _security:
_security.EvaluatorLoader_swigregister(EvaluatorLoader)