reapired the mistake ,which is the regular expression can inut a nill string
This commit is contained in:
parent
cf21279738
commit
63c24c4c7e
|
@ -1017,6 +1017,7 @@ public boolean match(char[] str, char[] pattern) {
|
|||
|
||||
```java
|
||||
public boolean isNumeric(char[] str) {
|
||||
if(str.length==0||str==null) return false;
|
||||
return new String(str).matches("[+-]?\\d*(\\.\\d+)?([eE][+-]?\\d+)?");
|
||||
}
|
||||
```
|
||||
|
|
Loading…
Reference in New Issue
Block a user