本文整理了Java中org.apache.regexp.RE.getParenStart
方法的一些代码示例,展示了RE.getParenStart
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。RE.getParenStart
方法的具体详情如下:
包路径:org.apache.regexp.RE
类名称:RE
方法名:getParenStart
[英]Returns the start index of a given paren level.
[中]返回给定paren级别的开始索引。
代码示例来源:origin: com.github.jkutner/saferegex
/**
* Returns the length of a given paren level.
*
* @param which Nesting level of subexpression
* @return Number of characters in the parenthesized subexpression
*/
public final int getParenLength(int which)
{
if (which < parenCount)
{
return getParenEnd(which) - getParenStart(which);
}
return -1;
}
代码示例来源:origin: com.github.jkutner/saferegex
/**
* Gets the contents of a parenthesized subexpression after a successful match.
*
* @param which Nesting level of subexpression
* @return String
*/
public String getParen(int which)
{
int start;
if (which < parenCount && (start = getParenStart(which)) >= 0)
{
return search.substring(start, getParenEnd(which));
}
return null;
}
代码示例来源:origin: com.github.jkutner/saferegex
int start = getParenStart(0);
代码示例来源:origin: com.github.jkutner/saferegex
ret.append(substituteIn.substring(pos, getParenStart(0)));
代码示例来源:origin: org.apache.cocoon/cocoon-linkrewriter-impl
newLink = createTransformedLink(link);
if (newLink != null) {
bufOut.replace(r.getParenStart(i) + offset,
r.getParenEnd(i) + offset,
newLink);
代码示例来源:origin: bcel/bcel
int startExpr = regex.getParenStart(0);
int endExpr = regex.getParenEnd(0);
int lenExpr = regex.getParenLength(0);
代码示例来源:origin: com.github.jkutner/saferegex
if (getParenStart(opdata) == -1)
内容来源于网络,如有侵权,请联系作者删除!