use of com.ibm.dtfj.javacore.parser.framework.tag.LineRule in project openj9 by eclipse.
the class EnvironmentTagParser method addProcessIDRule.
/**
* Add rule for the process id (2CIPROCESSID tag)
*/
private void addProcessIDRule() {
ILineRule lineRule = new LineRule() {
public void processLine(String source, int startingOffset) {
// pid is in decimal then hex, we only need the first one.
consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
addToken(PID_STRING, CommonPatternMatchers.dec);
}
};
addTag(T_1CIPROCESSID, lineRule);
}
use of com.ibm.dtfj.javacore.parser.framework.tag.LineRule in project openj9 by eclipse.
the class EnvironmentTagParser method addEnvironmentVars.
private void addEnvironmentVars() {
ILineRule lineRule = new LineRule() {
public void processLine(String source, int startingOffset) {
consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
addToken(ENV_NAME, NOT_EQUALS);
if (consumeUntilFirstMatch(CommonPatternMatchers.equals)) {
addToken(ENV_VALUE, CommonPatternMatchers.allButLineFeed);
}
}
};
addTag(T_2CIENVVAR, lineRule);
}
use of com.ibm.dtfj.javacore.parser.framework.tag.LineRule in project openj9 by eclipse.
the class EnvironmentTagParser method addJITModesRule.
/**
* Add rule for the JIT modes (2CICMDLINE tag)
*/
private void addJITModesRule() {
ILineRule lineRule = new LineRule() {
public void processLine(String source, int startingOffset) {
// command line is on a single line, can include whitespace, separators etc
// Java 7.0 - can get [not available]
addToken(JIT_MODE, CommonPatternMatchers.allButLineFeed);
}
};
addTag(T_1CIJITMODES, lineRule);
}
use of com.ibm.dtfj.javacore.parser.framework.tag.LineRule in project openj9 by eclipse.
the class EnvironmentTagParser method addUserArgs.
/**
* Add rule for an individual user args line (2CIUSERARG tag)
*/
private void addUserArgs() {
final Matcher hexEnd = CommonPatternMatchers.generateMatcher(" 0x\\p{XDigit}+[\\r\\n]*$");
ILineRule lineRule = new LineRule() {
public void processLine(String source, int startingOffset) {
// each user arg setting is on a separate line, comprising a string after
// some whitespace, with optional extra information (hex address) following
consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
if (addAllCharactersAsTokenUntilFirstMatch(ARG_STRING, hexEnd) != null) {
addPrefixedHexToken(ARG_EXTRA);
} else {
addToken(ARG_STRING, CommonPatternMatchers.allButLineFeed);
}
}
};
addTag(T_2CIUSERARG, lineRule);
}
use of com.ibm.dtfj.javacore.parser.framework.tag.LineRule in project openj9 by eclipse.
the class EnvironmentTagParser method addStartTimeNanoRule.
/**
* Add rule for the JVM start nanotime line
* 1CISTARTNANO JVM start nanotime: 3534023113503
*/
private void addStartTimeNanoRule() {
ILineRule lineRule = new LineRule() {
public void processLine(String source, int startingOffset) {
// 1TINANOTIME System nanotime: 3534320355422
consumeUntilFirstMatch(CommonPatternMatchers.colon);
consumeUntilFirstMatch(CommonPatternMatchers.whitespace);
addToken(START_NANO, CommonPatternMatchers.allButLineFeed);
}
};
addTag(T_1CISTARTNANO, lineRule);
}
Aggregations