|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.dse.tools.workbench.tbg.TbgTagParser
This class implements a String parser used by the TBG application.
Fields inherited from interface com.ibm.dse.tools.workbench.tbg.TbgNames |
ATTRIB_LAST,
ATTRIB_SEP,
ATTRIBUTE,
END_SIMPLE_TAG,
END_TAG,
INI_FINAL_TAG,
INI_TAG,
LITERAL,
LITERAL_LAST1,
LITERAL_LAST2,
LITERAL_LAST3,
LITERAL_SEP1,
LITERAL_SEP2,
LITERAL_SEP3 |
Constructor Summary | |
TbgTagParser()
This constructor creates a TbgParser object. |
Method Summary | |
static boolean |
contains(java.lang.String line,
java.lang.String word)
Checks if the specified word is part of the specified line. |
static java.lang.String |
getAttribute(java.lang.String params,
java.lang.String attribute)
Returns the value of the required attribute if it exists. |
static java.lang.String |
getDate()
Returns the actual date. |
static java.lang.String |
getLiteral(java.lang.String text)
If the text is a literal returns its the value. |
static java.lang.String |
getTab(java.lang.String line)
Returns the initial blanks from a String. |
static java.lang.String |
getVariable(java.lang.String text)
Parses the structure name1.name2.name3 getting name1. |
static java.lang.String |
getVariableOut(java.lang.String text)
Parses the structure name1.name2.name3 taking out name1. |
static java.lang.String |
isAttribute(java.lang.String text)
If the specified text represents an attribute, returns the attribute name, otherwise returns the null. |
static boolean |
isFile(java.lang.String url)
Evaluates if the specified url is a file. |
static boolean |
isURL(java.lang.String url)
Evaluates if the specified url is a valid URL. |
static java.lang.String |
parseFirst(java.lang.String tag)
Parses the structure name1.name2.name3 getting name1. |
static java.lang.String |
parseFirstOut(java.lang.String tag)
Parses the structure name1.name2.name3 taking out name1 and returns name2.name3. |
static java.lang.String |
parseLast(java.lang.String tag)
Parses the structure name1.name2.name3 getting name3. |
static java.lang.String |
parseLastOut(java.lang.String text)
Parses the structure name1.name2.name3 taking out name3 and returns name1.name2 . |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public TbgTagParser()
Method Detail |
public static boolean contains(java.lang.String line, java.lang.String word)
line
- java.lang.String The line.word
- java.lang.String The tag.public static java.lang.String getAttribute(java.lang.String params, java.lang.String attribute)
params
- java.lang.String The line to look into.attribute
- java.lang.String The attribute to look for.public static java.lang.String getDate()
public static java.lang.String getLiteral(java.lang.String text)
The literal form can be:
text
- java.lang.String The text to compare.public static java.lang.String getTab(java.lang.String line)
line
- java.lang.Stringpublic static java.lang.String getVariable(java.lang.String text)
If the structure doesn't follow this structure returns null.
text
- java.lang.String String to parse.public static java.lang.String getVariableOut(java.lang.String text)
If the structure doesn't follow this structure returns null.
text
- java.lang.String String to parse.public static java.lang.String isAttribute(java.lang.String text)
text
- java.lang.String The text to examine.public static boolean isFile(java.lang.String url)
url
- java.lang.String The url to evaluate.public static boolean isURL(java.lang.String url)
url
- java.lang.String The url to evaluate.public static java.lang.String parseFirst(java.lang.String tag)
If the structure doesn't follow this structure returns null.
tag
- java.lang.String String to parse.public static java.lang.String parseFirstOut(java.lang.String tag)
If the structure doesn't follow this structure returns the text.
tag
- java.lang.String String to parse.public static java.lang.String parseLast(java.lang.String tag)
If the structure doesn't follow this structure returns null.
tag
- java.lang.String String to parse.public static java.lang.String parseLastOut(java.lang.String text)
If the structure doesn't follow this structure returns the whole text.
text
- java.lang.String String to parse.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |