Class StatementPattern

    • Field Detail

      • CARDINALITY_NOT_SET

        @Deprecated
        public static final double CARDINALITY_NOT_SET
        Deprecated.
        See Also:
        Constant Field Values
      • subjectVar

        private Var subjectVar
      • predicateVar

        private Var predicateVar
      • objectVar

        private Var objectVar
      • contextVar

        private Var contextVar
      • assuredBindingNames

        private java.util.Set<java.lang.String> assuredBindingNames
      • varList

        private java.util.List<Var> varList
    • Constructor Detail

      • StatementPattern

        @Deprecated(since="4.0.0",
                    forRemoval=true)
        public StatementPattern()
        Deprecated, for removal: This API element is subject to removal in a future version.
      • StatementPattern

        public StatementPattern​(Var subject,
                                Var predicate,
                                Var object)
        Creates a statement pattern that matches a subject-, predicate- and object variable against statements from all contexts.
      • StatementPattern

        public StatementPattern​(StatementPattern.Scope scope,
                                Var subject,
                                Var predicate,
                                Var object)
        Creates a statement pattern that matches a subject-, predicate- and object variable against statements from the specified context scope.
      • StatementPattern

        public StatementPattern​(Var subject,
                                Var predicate,
                                Var object,
                                Var context)
        Creates a statement pattern that matches a subject-, predicate-, object- and context variable against statements from all contexts.
      • StatementPattern

        public StatementPattern​(StatementPattern.Scope scope,
                                Var subjVar,
                                Var predVar,
                                Var objVar,
                                Var conVar)
        Creates a statement pattern that matches a subject-, predicate-, object- and context variable against statements from the specified context scope.
    • Method Detail

      • setScope

        @Deprecated(since="4.0.0",
                    forRemoval=true)
        public void setScope​(StatementPattern.Scope scope)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Sets the context scope for the statement pattern.
      • getSubjectVar

        public Var getSubjectVar()
      • setSubjectVar

        @Deprecated(since="4.0.0",
                    forRemoval=true)
        public void setSubjectVar​(Var subject)
        Deprecated, for removal: This API element is subject to removal in a future version.
      • getPredicateVar

        public Var getPredicateVar()
      • setPredicateVar

        @Deprecated(since="4.0.0",
                    forRemoval=true)
        public void setPredicateVar​(Var predicate)
        Deprecated, for removal: This API element is subject to removal in a future version.
      • getObjectVar

        public Var getObjectVar()
      • setObjectVar

        @Deprecated(since="4.0.0",
                    forRemoval=true)
        public void setObjectVar​(Var object)
        Deprecated, for removal: This API element is subject to removal in a future version.
      • getContextVar

        public Var getContextVar()
        Returns the context variable, if available.
      • setContextVar

        @Deprecated(since="4.0.0",
                    forRemoval=true)
        public void setContextVar​(Var context)
        Deprecated, for removal: This API element is subject to removal in a future version.
      • getBindingNames

        public java.util.Set<java.lang.String> getBindingNames()
        Description copied from interface: TupleExpr
        Gets the names of the bindings that are, or can be, returned by this tuple expression when it is evaluated.
        Specified by:
        getBindingNames in interface TupleExpr
        Returns:
        A set of binding names.
      • getAssuredBindingNames

        public java.util.Set<java.lang.String> getAssuredBindingNames()
        Description copied from interface: TupleExpr
        Gets the names of the bindings that are guaranteed to be present in the results produced by this tuple expression.
        Specified by:
        getAssuredBindingNames in interface TupleExpr
        Returns:
        A set of binding names.
      • getBindingsInternal

        private java.util.Set<java.lang.String> getBindingsInternal()
      • getVarList

        public java.util.List<Var> getVarList()
      • getVarListInternal

        private java.util.List<Var> getVarListInternal()
      • getSize

        private int getSize()
      • getVars

        public <L extends java.util.Collection<Var>> L getVars​(L varCollection)
        Adds the variables of this statement pattern to the supplied collection.
      • visit

        public <X extends java.lang.Exception> void visit​(QueryModelVisitor<X> visitor)
                                                   throws X extends java.lang.Exception
        Description copied from interface: QueryModelNode
        Visits this node. The node reports itself to the visitor with the proper runtime type.
        Specified by:
        visit in interface QueryModelNode
        Throws:
        X extends java.lang.Exception
      • equals

        public boolean equals​(java.lang.Object other)
        Description copied from interface: QueryModelNode
        Returns true if this query model node and its children are recursively equal to o and its children.
        Specified by:
        equals in interface QueryModelNode
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object