org.w3c.rdfpic.core
Class TxtSchemaParser
java.lang.Object
|
+--org.w3c.rdfpic.core.TxtSchemaParser
- class TxtSchemaParser
- extends java.lang.Object
A parser for a simple schema definition language.
It closely follow the following:
schema = [main]
main = STR | add | namedef | uridef
namedef = 'name' '=' STR
uridef = 'URI' '=' STR
builtin = 'builtin' '=' INT
add = 'add' '(' STR ',' STR ',' STR')' | 'add' '(' STR ',' STR ')'
INT = STR
The constructor parses the file immediate, and getSchema() can be used to
to retrieve the schema after successful parsing.
Methods inherited from class java.lang.Object |
,
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
toString,
wait,
wait,
wait |
tokGen
SimpleToken tokGen
current
java.lang.String current
schema
RdfSchema schema
vec
java.util.Vector vec
defs
java.util.Vector defs
expl
java.util.Vector expl
TxtSchemaParser
TxtSchemaParser(SimpleToken tokGen)
getSchema
public RdfSchema getSchema()
advance
private void advance()
mainP
private final void mainP()
throws SyntaxException
isStr
private final boolean isStr()
accept
private final void accept(java.lang.String str)
throws SyntaxException
strP
private final boolean strP()
throws SyntaxException
extract
private final java.lang.String extract()
throws SyntaxException
test
private final void test()
throws SyntaxException
addP
private final boolean addP()
throws SyntaxException
namedefP
private final boolean namedefP()
throws SyntaxException
builtinP
private final boolean builtinP()
throws SyntaxException
uridefP
private final boolean uridefP()
throws SyntaxException