Warning: session_start(): open(/var/lib/php/sessions/sess_jpoln8ect7dbn9kkfitq0jc7f0, O_RDWR) failed: No space left on device (28) in /var/www/tb-usercake/models/config.php on line 51
Warning: session_start(): Failed to read session data: files (path: /var/lib/php/sessions) in /var/www/tb-usercake/models/config.php on line 51
persistable srecord RegExp(S pattern, bool caseInsensitive) {
transient Pattern compiled;
S error;
*(S *pattern) {}
// TODO: don't compile again when error detected?
java.util.regex.Pattern compile aka get() {
try {
compiled if null = compileRegexpPossiblyIC(pattern, caseInsensitive);
error = null;
ret compiled;
} catch e {
error = exceptionToStringShort(e);
null;
}
}
bool valid() {
ret compile() != null;
}
bool containsSpecialChars() {
ret containsRegExpSpecialChars(pattern);
}
bool containedIn(S s) {
ret regexpContains(s, getForce());
}
java.util.regex.Pattern getForce() {
var pattern = get();
if (error != null) fail(error, pattern);
ret pattern;
}
}