|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.clarkparsia.sparqlowl.parser.ParserUtilities
public class ParserUtilities
Title: Parser Utilities
Description: Static utility methods and fields used by the ANTLR generated parser sources. This code is in a separate Java file rather than in the ANTLR sources to make it easier to maintain with comfortable Java tools (e.g., Eclipse).
Copyright: Copyright (c) 2009
Company: Clark & Parsia, LLC.
Constructor Summary | |
---|---|
ParserUtilities()
|
Method Summary | |
---|---|
static java.lang.String |
dropFirstAndLast(java.lang.String s)
Trim first and last character from s . |
static java.lang.String |
dropFirstAndLast3(java.lang.String s)
Trim first and last character from s . |
static java.lang.String |
sparqlUnescape(java.lang.String s)
Reverse character escaping in a string literal consistent with SPARQL A.7, A.8[91] |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ParserUtilities()
Method Detail |
---|
public static java.lang.String dropFirstAndLast(java.lang.String s)
s
. Used when the parser
matches STRING_LITERAL1 or STRING_LITERAL2 (SPARQL A.8[87]-[88])
s
- The string to be trimmed
public static java.lang.String dropFirstAndLast3(java.lang.String s)
s
. Used when the parser
matches STRING_LITERAL_LONG1 or STRING_LITERAL_LONG2 (SPARQL
A.8[89]-[90])
s
- The string to be trimmed
public static java.lang.String sparqlUnescape(java.lang.String s)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |