|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.knime.core.util.tokenizer.Comment
public class Comment
Created for each comment pattern of the FileTokenizer keeping
its specifics.
| Constructor Summary | |
|---|---|
Comment(NodeSettingsRO settings)
Creates a new Comment object and sets its parameters from
the config object. |
|
Comment(String left,
String right,
boolean returnAsToken,
boolean includeInToken)
Creates a new Comment object. |
|
| Method Summary | |
|---|---|
String |
getBegin()
|
String |
getEnd()
|
char |
getFirstCharOfBegin()
|
boolean |
includeInToken()
|
boolean |
returnAsSeparateToken()
|
(package private) void |
saveToConfig(NodeSettingsWO cfg)
Writes the object into a NodeSettings object. |
String |
toString()
Returns "[begin]...[end], i, r" for block comments, or "[begin] SL, i, r" for single line comments, with 'i' only printed when flag "indcludeInToken" is set, and 'r' only printed when flag "returnAsSeparateToken is set. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Comment(String left,
String right,
boolean returnAsToken,
boolean includeInToken)
FileTokenizerSettings class.
left - The comment start pattern.right - The comment end pattern.returnAsToken - boolean flag.includeInToken - boolean flag.TokenizerSettingsComment(NodeSettingsRO settings) throws InvalidSettingsException
Comment object and sets its parameters from
the config object. If config doesn't contain all necessary
parameters or contains inconsistent settings it will throw an
IllegalArguments exception
settings - an object the parameters are read from.
InvalidSettingsException - if the config is not valid. Huh.| Method Detail |
|---|
void saveToConfig(NodeSettingsWO cfg)
NodeSettings object. If this config
object is then used to construct a new Comment this and
the new object should be identical.
cfg - a config object the internal values of this object will be
stored into.public String getBegin()
public String getEnd()
public char getFirstCharOfBegin()
public boolean includeInToken()
true if this comment will be included in the
current token.public boolean returnAsSeparateToken()
true if this comment will be returned as separate
token.public String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||