|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.bigdata.rdf.lexicon.LexiconKeyBuilder
public class LexiconKeyBuilder
Flyweight helper class for building (and decoding to the extent possible)
unsigned byte[] keys for RDF Values and term identifiers. In general,
keys for RDF values are formed by a leading byte that indicates the type of
the value (URI, BNode, or some type of Literal), followed by the components
of that value type.
| Field Summary | |
|---|---|
IKeyBuilder |
keyBuilder
|
| Fields inherited from interface com.bigdata.rdf.lexicon.ITermIndexCodes |
|---|
TERM_CODE_BND, TERM_CODE_DTL, TERM_CODE_LCL, TERM_CODE_LIT, TERM_CODE_URI |
| Constructor Summary | |
|---|---|
protected |
LexiconKeyBuilder(IKeyBuilder keyBuilder)
Normally invoked by Term2IdTupleSerializer.getLexiconKeyBuilder() |
| Method Summary | |
|---|---|
byte[] |
blankNode2Key(String id)
|
byte[] |
datatypeLiteral2key(URI datatype,
String value)
Formats a datatype literal sort key. |
byte[] |
languageCodeLiteral2key(String languageCode,
String text)
Note: The language code is serialized as US-ASCII UPPER CASE for the purposes of defining the total key ordering. |
byte[] |
plainLiteral2key(String text)
|
byte[] |
uri2key(String uri)
Returns the sort key for the URI. |
byte[] |
value2Key(Value value)
Return an unsigned byte[] that locates the value within a total ordering over the RDF value space. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public final IKeyBuilder keyBuilder
| Constructor Detail |
|---|
protected LexiconKeyBuilder(IKeyBuilder keyBuilder)
Term2IdTupleSerializer.getLexiconKeyBuilder()
keyBuilder - The IKeyBuilder that will determine the distinctions
and sort order among the rdf Values. In general, this
should support Unicode and should use
StrengthEnum.Identical so that all distinctions in the
Value space are recognized by the lexicon.IKeyBuilder,
IKeyBuilderFactory| Method Detail |
|---|
public byte[] uri2key(String uri)
uri - The URI.
public byte[] plainLiteral2key(String text)
public byte[] languageCodeLiteral2key(String languageCode,
String text)
Literal.getLanguage()
public byte[] datatypeLiteral2key(URI datatype,
String value)
datatype - value -
public byte[] blankNode2Key(String id)
public byte[] value2Key(Value value)
value - An RDF value.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||