|
Groovy JDK |
Method Summary | |
---|---|
boolean
|
isCase(Object switchValue)
'Case' implementation for the Pattern class, which allows testing a String against a number of regular expressions. |
Method Detail |
---|
public boolean isCase(Object switchValue)
switch( str ) { case ~/one/ : // the regex 'one' matches the value of str }Note that this returns true for the case where both the pattern and the 'switch' values are
null
.switchValue
- the switch value.
|
Groovy JDK |