Sync docs from master to gh-pages
This commit is contained in:
@@ -6765,6 +6765,13 @@ protected static final Pattern UUID = Pattern.compile('[a-z0-9]{8}-[a-z0-9]{4}-[
|
||||
protected static final Pattern ANY_DATE = Pattern.compile('(\\d\\d\\d\\d)-(0[1-9]|1[012])-(0[1-9]|[12][0-9]|3[01])')
|
||||
protected static final Pattern ANY_DATE_TIME = Pattern.compile('([0-9]{4})-(1[0-2]|0[1-9])-(3[01]|0[1-9]|[12][0-9])T(2[0-3]|[01][0-9]):([0-5][0-9]):([0-5][0-9])')
|
||||
protected static final Pattern ANY_TIME = Pattern.compile('(2[0-3]|[01][0-9]):([0-5][0-9]):([0-5][0-9])')
|
||||
protected static final Pattern NON_EMPTY = Pattern.compile(/.+/)
|
||||
protected static final Pattern NON_BLANK = Pattern.compile(/.*(\S+|\R).*|!^\R*$/)
|
||||
protected static final Pattern ISO8601_WITH_OFFSET = Pattern.compile(/([0-9]{4})-(1[0-2]|0[1-9])-(3[01]|0[1-9]|[12][0-9])T(2[0-3]|[01][0-9]):([0-5][0-9]):([0-5][0-9])(\.\d{3})?(Z|[+-][01]\d:[0-5]\d)/)
|
||||
|
||||
protected static Pattern anyOf(String... values){
|
||||
return Pattern.compile(values.collect({"^$it\$"}).join("|"))
|
||||
}
|
||||
|
||||
String onlyAlphaUnicode() {
|
||||
return ONLY_ALPHA_UNICODE.pattern()
|
||||
@@ -6808,6 +6815,18 @@ String isoDateTime() {
|
||||
|
||||
String isoTime() {
|
||||
return ANY_TIME.pattern()
|
||||
}
|
||||
|
||||
String iso8601WithOffset() {
|
||||
return ISO8601_WITH_OFFSET.pattern()
|
||||
}
|
||||
|
||||
String nonEmpty() {
|
||||
return NON_EMPTY.pattern()
|
||||
}
|
||||
|
||||
String nonBlank() {
|
||||
return NON_BLANK.pattern()
|
||||
}</code></pre>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user