|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ValueMaker
Describes a set of strings that are obtained in some way from one or more database columns.
Typical implementations are Attribute
(describing the set
of strings contained in one database column), Pattern
(describing the set of strings that is obtained by sticking
the values of several database fields into a string pattern),
and BlankNodeID
(similar).
There are several other ValueSources that modify the behaviour
of another underlying ValueSource, implementing the Decorator
pattern. This includes TranslationTable
.TranslatingValueSource
(translates values using a translation table or translation class)
and the various value restrictions (@link RegexRestriction et. al.).
ValueSources are used by NodeMakers. A node maker wraps the strings into Jena nodes, thus creating a description of a set of RDF nodes.
Method Summary | |
---|---|
Map |
attributeConditions(String value)
Returns a map of database fields and values corresponding to the argument. |
void |
describeSelf(NodeSetFilter c)
|
String |
makeValue(ResultRow row)
Retrieves a value from a database row according to some rule or pattern. |
boolean |
matches(String value)
Checks if a given value fits this source without querying the database. |
Set |
projectionAttributes()
Returns a set of all columns containing data necessary for this ValueSource. |
ValueMaker |
replaceColumns(ColumnRenamer renamer)
|
Method Detail |
---|
boolean matches(String value)
Map attributeConditions(String value)
For example, a ValueSource that corresponds directly to a single DB column would return a single-entry map with that column as the key, and value as the value.
The result is undefined if matches(String)
is false
for the same value.
value
- a non-null value
Attribute
keys, and string valuesSet projectionAttributes()
String makeValue(ResultRow row)
row
- the database row
void describeSelf(NodeSetFilter c)
ValueMaker replaceColumns(ColumnRenamer renamer)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |