# Path: pyknow/conditionalelement.py
# class ConditionalElement(tuple):
#     """Base Conditional Element"""
# 
#     def __new__(cls, *args):
#         return super(ConditionalElement, cls).__new__(cls, args)
# 
#     def __repr__(self):  # pragma: no cover
#         return "%s%s" % (self.__class__.__name__, super().__repr__())
# 
# Path: pyknow/pattern.py
# class Bindable:
#     def __rlshift__(self, other):
#         if not isinstance(other, str):
#             raise TypeError("%s can only be binded to a string" % self)
#         elif self.__bind__ is not None:
#             raise RuntimeError("%s can only be binded once" % repr(self))
#         else:
#             self.__bind__ = other
#             return self
# 
#     def __hash__(self):
#         return hash((self.__bind__, ) + tuple(self))
# 
#     def __eq__(self, other):
#         return (self.__class__ == other.__class__
#                 and self.__bind__ == other.__bind__
#                 and super().__eq__(other))


from collections.abc import Callable
from pyknow.conditionalelement import ConditionalElement
from pyknow.pattern import Bindable
        self[0].__rlshift__(other)
        return self


class L(Bindable, FieldConstraint):
    """Literal Field Constraint"""
    def __new__(cls, value, __bind__=None):
        obj = super(L, cls).__new__(cls, value)
        obj.__bind__ = __bind__
        return obj

    @property
    def value(self):
        return self[0]

    def __repr__(self):  # pragma: no cover
        return "L(%r)" % self.value


class W(Bindable, FieldConstraint):
    """Wildcard Field Constraint"""
    def __new__(cls, __bind__=None):
        obj = super(W, cls).__new__(cls)
        obj.__bind__ = __bind__
        return obj

    def __repr__(self):  # pragma: no cover
        return "W()" if self.__bind__ is None else "W(%r)" % self.__bind__



# Path: pyknow/conditionalelement.py
# class ConditionalElement(tuple):
#     """Base Conditional Element"""
# 
#     def __new__(cls, *args):
#         return super(ConditionalElement, cls).__new__(cls, args)
# 
#     def __repr__(self):  # pragma: no cover
#         return "%s%s" % (self.__class__.__name__, super().__repr__())
# 
# Path: pyknow/pattern.py
# class Bindable:
#     def __rlshift__(self, other):
#         if not isinstance(other, str):
#             raise TypeError("%s can only be binded to a string" % self)
#         elif self.__bind__ is not None:
#             raise RuntimeError("%s can only be binded once" % repr(self))
#         else:
#             self.__bind__ = other
#             return self
# 
#     def __hash__(self):
#         return hash((self.__bind__, ) + tuple(self))
# 
#     def __eq__(self, other):
#         return (self.__class__ == other.__class__
#                 and self.__bind__ == other.__bind__
#                 and super().__eq__(other))


# Path: pyknow/fieldconstraint.py
from collections.abc import Callable
from pyknow.conditionalelement import ConditionalElement
from pyknow.pattern import Bindable

        self[0].__rlshift__(other)
        return self


class L(Bindable, FieldConstraint):
    """Literal Field Constraint"""
    def __new__(cls, value, __bind__=None):
        obj = super(L, cls).__new__(cls, value)
        obj.__bind__ = __bind__
        return obj

    @property
    def value(self):
        return self[0]

    def __repr__(self):  # pragma: no cover
        return "L(%r)" % self.value


class W(Bindable, FieldConstraint):
    """Wildcard Field Constraint"""
    def __new__(cls, __bind__=None):
        obj = super(W, cls).__new__(cls)
        obj.__bind__ = __bind__
        return obj

    def __repr__(self):  # pragma: no cover
        return "W()" if self.__bind__ is None else "W(%r)" % self.__bind__



class P(Bindable, FieldConstraint):