@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,final String flags) throws ParserException {
super(pattern,flags);
int option = Option.SINGLELINE;
if (this.isIgnoreCase()) {
option |= Option.IGnorECASE;
}
if (this.isMultiline()) {
option &= ~Option.SINGLELINE;
option |= Option.NEGATE_SINGLELINE;
}
try {
RegExpScanner parsed;
try {
parsed = RegExpScanner.scan(pattern);
} catch (final PatternSyntaxException e) {
// refine the exception with a better Syntax error,if this
// passes,just rethrow what we have
Pattern.compile(pattern,0);
throw e;
}
if (parsed != null) {
final char[] javaPattern = parsed.getJavaPattern().tochararray();
this.regex = new Regex(javaPattern,javaPattern.length,option,Syntax.JAVASCRIPT);
this.groupsInNegativeLookahead = parsed.getGroupsInNegativeLookahead();
}
} catch (final PatternSyntaxException | JOniException e2) {
throwParserException("Syntax",e2.getMessage());
}
}
项目:openjdk-jdk10
文件:EncloseNode.java
@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: ").append(typetoString());
value.append("\n regNum: ").append(regNum);
value.append("\n option: ").append(Option.toString(option));
value.append("\n target: ").append(pad(target,level + 1));
value.append("\n callAddr: ").append(callAddr);
value.append("\n minLength: ").append(minLength);
value.append("\n maxLength: ").append(maxLength);
value.append("\n charLength: ").append(charLength);
value.append("\n optCount: ").append(optCount);
return value.toString();
}
项目:openjdk-jdk10
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:openjdk9
文件:EncloseNode.java
@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: ").append(typetoString());
value.append("\n regNum: ").append(regNum);
value.append("\n option: ").append(Option.toString(option));
value.append("\n target: ").append(pad(target,level + 1));
value.append("\n callAddr: ").append(callAddr);
value.append("\n minLength: ").append(minLength);
value.append("\n maxLength: ").append(maxLength);
value.append("\n charLength: ").append(charLength);
value.append("\n optCount: ").append(optCount);
return value.toString();
}
项目:openjdk9
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:kaziranga
文件:EncloseNode.java
@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:kaziranga
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:lookaside_java-1.8.0-openjdk
文件:EncloseNode.java
@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:lookaside_java-1.8.0-openjdk
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:jdk8u_nashorn
文件:EncloseNode.java
@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:jdk8u_nashorn
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:infobip-open-jdk-8
文件:EncloseNode.java
@Override
public String toString(final int level) {
final StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:infobip-open-jdk-8
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:OLD-OpenJDK8
文件:EncloseNode.java
@Override
public String toString(int level) {
StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:OLD-OpenJDK8
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,0);
throw e;
}
if (parsed != null) {
char[] javaPattern = parsed.getJavaPattern().tochararray();
this.regex = new Regex(javaPattern,e2.getMessage());
}
}
项目:nashorn-backport
文件:EncloseNode.java
@Override
public String toString(int level) {
StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:nashorn-backport
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
项目:nashorn
文件:EncloseNode.java
@Override
public String toString(int level) {
StringBuilder value = new StringBuilder(super.toString(level));
value.append("\n type: " + typetoString());
value.append("\n regNum: " + regNum);
value.append("\n option: " + Option.toString(option));
value.append("\n target: " + pad(target,level + 1));
value.append("\n callAddr: " + callAddr);
value.append("\n minLength: " + minLength);
value.append("\n maxLength: " + maxLength);
value.append("\n charLength: " + charLength);
value.append("\n optCount: " + optCount);
return value.toString();
}
项目:nashorn
文件:JoniRegExp.java
/**
* Construct a Regular expression from the given {@code pattern} and {@code flags} strings.
*
* @param pattern RegExp pattern string
* @param flags RegExp flag string
* @throws ParserException if flags is invalid or pattern string has Syntax error.
*/
public JoniRegExp(final String pattern,e2.getMessage());
}
}
@Override
public boolean search(final int start) {
return joniMatcher.search(start,input.length(),Option.NONE) > -1;
}
项目:openjdk-jdk10
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:openjdk9
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:kaziranga
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:lookaside_java-1.8.0-openjdk
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:jdk8u_nashorn
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:infobip-open-jdk-8
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:OLD-OpenJDK8
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:nashorn-backport
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
项目:nashorn
文件:JoniRegExp.java
@Override
public boolean search(final int start) {
return joniMatcher.search(start,Option.NONE) > -1;
}
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。