java.lang.Object
org.apache.jena.sparql.expr.nodevalue.NodeFunctions
Implementation of node-centric functions.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.jena.graph.Node
datatype
(org.apache.jena.graph.Node node) static NodeValue
static Duration
duration
(int seconds) A duration, tidedstatic boolean
hasLang
(org.apache.jena.graph.Node node) static NodeValue
static boolean
hasLangDir
(org.apache.jena.graph.Node node) static NodeValue
hasLangDir
(NodeValue nv) static org.apache.jena.graph.Node
Node to Node, skolemizing, and converting strings to URIs.static NodeValue
NodeValue to NodeValue, skolemizing, and converting strings to URIs.static boolean
isBlank
(org.apache.jena.graph.Node node) static NodeValue
static boolean
isIRI
(org.apache.jena.graph.Node node) static NodeValue
static boolean
isLiteral
(org.apache.jena.graph.Node node) static NodeValue
static NodeValue
static boolean
isURI
(org.apache.jena.graph.Node node) static NodeValue
static String
lang
(org.apache.jena.graph.Node node) static NodeValue
static String
langdir
(org.apache.jena.graph.Node node) static NodeValue
static boolean
langMatches
(String langStr, String langPattern) The algorithm for the SPARQL function "LANGMATCHES".static NodeValue
langMatches
(NodeValue nv, String langPattern) LANGMATCHESstatic NodeValue
langMatches
(NodeValue nv, NodeValue nvPattern) LANGMATCHESstatic boolean
rdfTermEquals
(org.apache.jena.graph.Node n1, org.apache.jena.graph.Node n2) static boolean
sameTerm
(org.apache.jena.graph.Node node1, org.apache.jena.graph.Node node2) sameTerm(x,y)static NodeValue
static NodeValue
static String
str
(org.apache.jena.graph.Node node) static NodeValue
static NodeValue
strDatatype
(NodeValue v1, NodeValue v2) static NodeValue
static NodeValue
strLangDir
(NodeValue v1, NodeValue v2, NodeValue v3) static NodeValue
struuid()
static NodeValue
uuid()
-
Constructor Details
-
NodeFunctions
public NodeFunctions()
-
-
Method Details
-
sameTerm
-
sameTerm
public static boolean sameTerm(org.apache.jena.graph.Node node1, org.apache.jena.graph.Node node2) sameTerm(x,y) -
rdfTermEquals
public static boolean rdfTermEquals(org.apache.jena.graph.Node n1, org.apache.jena.graph.Node n2) -
str
-
str
-
sortKey
-
datatype
-
datatype
public static org.apache.jena.graph.Node datatype(org.apache.jena.graph.Node node) -
isNumeric
-
hasLang
-
hasLang
public static boolean hasLang(org.apache.jena.graph.Node node) -
hasLangDir
-
hasLangDir
public static boolean hasLangDir(org.apache.jena.graph.Node node) -
lang
-
lang
-
langdir
-
langdir
-
langMatches
LANGMATCHES- Parameters:
nv
- The language stringnvPattern
- The pattern to match against- Returns:
- Boolean nodeValue
-
langMatches
LANGMATCHES- Parameters:
nv
- The language stringlangPattern
- The pattern to match against- Returns:
- Boolean nodeValue
-
langMatches
The algorithm for the SPARQL function "LANGMATCHES". Matching in SPARQL is defined to be the language tag matching of RFC 4647, part of BCP 47.SPARQL uses basic matching which is single "*" or a prefix of subtags.
This code does not implement extended matching correctly.
- Parameters:
langStr
- The language stringlangPattern
- The pattern to match against- Returns:
- Whether there is a match.
-
isIRI
-
isIRI
public static boolean isIRI(org.apache.jena.graph.Node node) -
isURI
-
isURI
public static boolean isURI(org.apache.jena.graph.Node node) -
isBlank
-
isBlank
public static boolean isBlank(org.apache.jena.graph.Node node) -
isLiteral
-
isLiteral
public static boolean isLiteral(org.apache.jena.graph.Node node) -
iri
NodeValue to NodeValue, skolemizing, and converting strings to URIs. -
iri
Node to Node, skolemizing, and converting strings to URIs. -
struuid
-
uuid
-
strDatatype
-
strLang
-
strLangDir
-
duration
A duration, tided
-