*/
protected boolean findProbe(Pattern pattern){
switchPattern(pattern);
- if( getMatcher().find() ) return true;
- return false;
+ boolean result = getMatcher().find();
+ return result;
}
/**
*/
protected boolean lookingAtProbe(Pattern pattern){
switchPattern(pattern);
- if( getMatcher().lookingAt() ) return true;
- return false;
+ boolean result = getMatcher().lookingAt();
+ return result;
}
/**
*/
protected boolean matchesProbe(Pattern pattern){
switchPattern(pattern);
- if( getMatcher().matches() ) return true;
- return false;
+ boolean result = getMatcher().matches();
+ return result;
}
/**
* @return ヒットしていたらtrue
*/
protected boolean isGroupMatched(int group){
- if(matchStart(group) >= 0) return true;
- return false;
+ boolean result = matchStart(group) >= 0;
+ return result;
}
/**
for( ; regionStart < regionEnd; regionStart++){
char letter = rawContent.charAt(regionStart);
+ boolean spaceCh;
switch(letter){
case '\u0020':
case '\t':
case '\n':
case '\r':
- hasSpace = true;
- continue;
+ spaceCh = true;
+ break;
default:
+ spaceCh = false;
break;
}
- break;
+ if(spaceCh){
+ hasSpace = true;
+ }else{
+ break;
+ }
}
if(hasSpace){