示例#1
0
    def __neg__(self):
        """-self Unary minus sign"""
        required_not_finalized(self)

        self.unary_operator = OPERATOR.neg

        return self.clone()
示例#2
0
    def finalize(self, context):
        """ """
        required_not_finalized(self)

        if self.order is None:
            SortOrderType.ASC

        self._finalized = True
示例#3
0
    def finalize(self, context):
        """ """
        required_not_finalized(self)

        # xxx: find type using Context
        # May path as Resource Attribute
        # Do validation
        if not self.path._finalized:
            self.path.finalize(context)

        if self.unary_operator is None:
            self.unary_operator = OPERATOR.pos

        self._finalized = True
示例#4
0
    def finalize(self, context):
        """ """
        required_not_finalized(self)

        self.validate(context.fhir_release)
        # # xxx: more things to do
        if self._non_fhir:
            ctx = EmptyPathInfoContext()
            ctx._path = self._raw
        else:
            ctx = proxy(
                PathInfoContext.context_from_path(self._path,
                                                  context.fhir_release))
        self.context = ctx
        self._finalized = True
示例#5
0
    def _finalize(self, context):
        """ """
        required_not_finalized(self)

        # xxx: find type using Context
        # May path as Resource Attribute
        # Do validation
        self.fhir_release = context.fhir_release
        if not self.path.is_finalized():
            self.path.finalize(context)

        if self.arithmetic_operator is None:
            self.arithmetic_operator = OPERATOR.and_

        if self.unary_operator is None:
            self.unary_operator = OPERATOR.pos

        if self.comparison_operator is None:
            self.comparison_operator = OPERATOR.eq

        self.validate()
示例#6
0
    def _add(self, other):
        """ """
        required_not_finalized(self)
        self.terms.append(IExistsTerm(other))

        return self.clone()
示例#7
0
 def finalize(self, path):
     """context: PathInfoContext """
     required_not_finalized(self)
     path = IElementPath(path)
     self.value = path.context.validate_value(self.raw)
     self._finalized = True
示例#8
0
    def __pos__(self):
        """+self Unary plus sign"""
        required_not_finalized(self)

        self.unary_operator = OPERATOR.pos
        return self.clone()