public class RDFLiteralNode extends RDFNode
Constructor and Description |
---|
RDFLiteralNode(java.lang.String literal,
IRI datatype) |
RDFLiteralNode(java.lang.String literal,
java.lang.String lang) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
IRI |
getDatatype() |
IRI |
getIRI()
Gets the URI of the resource.
|
java.lang.String |
getLang()
Gets the lang
|
java.lang.String |
getLiteral()
Gets the lexical form of this literal.
|
int |
hashCode() |
boolean |
isAnonymous()
Determines if this node is a resource and is anonymous.
|
boolean |
isLiteral() |
boolean |
isTyped() |
java.lang.String |
toString() |
public RDFLiteralNode(java.lang.String literal, IRI datatype)
literal
- lexical formdatatype
- typepublic RDFLiteralNode(java.lang.String literal, java.lang.String lang)
literal
- lexical formlang
- language tagpublic boolean isAnonymous()
RDFNode
isAnonymous
in class RDFNode
true
if this is a resource node (i.e.
isLiteral
returns false
) and the
node is anonymous, or false
if this is a
resource node and is not anonymous.public java.lang.String getLiteral()
public java.lang.String getLang()
null
if there is no langpublic IRI getDatatype()
null
if there is no datatypepublic boolean isTyped()
public boolean isLiteral()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object