public class LiteralImpl extends AbstractLiteral implements Serializable
| Constructor and Description |
|---|
LiteralImpl(String lexicalForm,
IRI dataType,
Language language) |
| Modifier and Type | Method and Description |
|---|---|
IRI |
getDataType()
The IRI identifying the datatype that determines how the lexical form
maps to a literal value.
|
Language |
getLanguage()
If and only if the datatype IRI is http://www.w3.org/1999/02/22-rdf-syntax-ns#langString, the language
tag for this Literal is a language tag as defined by BCP47.
If the datatype IRI is not http://www.w3.org/1999/02/22-rdf-syntax-ns#langString, this method must null. |
String |
getLexicalForm()
The lexical form of this literal, represented by a Unicode string.
|
int |
hashCode()
Returns the hash code of the lexical form plus the hash code of the
datatype plus if the literal has a language the hash code of the
language.
|
String |
toString() |
equalspublic IRI getDataType()
LiteralgetDataType in interface Literalpublic String getLexicalForm()
LiteralgetLexicalForm in interface Literalpublic int hashCode()
LiteralhashCode in interface LiteralhashCode in class AbstractLiteralpublic Language getLanguage()
LiteralgetLanguage in interface LiteralCopyright © 2015–2022 The Apache Software Foundation. All rights reserved.