regexper-static/src/js/parser/javascript/repeat_spec.js

22 lines
403 B
JavaScript
Raw Normal View History

export default {
minimum() {
if (this._min) {
return Number(this._min.textValue);
} else if (this._exact) {
return Number(this._exact.textValue);
} else {
return 0;
}
},
maximum() {
if (this._max) {
return Number(this._max.textValue);
} else if (this._exact) {
return Number(this._exact.textValue);
} else {
return -1;
}
}
};