org.openapi4j.parser.validation.v3.Regexes Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of openapi-parser Show documentation
Show all versions of openapi-parser Show documentation
openapi4j schema parser & validator
package org.openapi4j.parser.validation.v3;
import java.util.regex.Pattern;
class Regexes {
private Regexes() {}
static final Pattern PATH_REGEX = Pattern.compile("/.*");
static final Pattern EXT_REGEX = Pattern.compile("x-.+");
static final Pattern NOEXT_REGEX = Pattern.compile("(?!x-).*");
static final Pattern NAME_REGEX = Pattern.compile("[a-zA-Z0-9._-]+");
static final Pattern NOEXT_NAME_REGEX = Pattern.compile("(?!x-)[a-zA-Z0-9._-]+");
static final Pattern METHOD_REGEX = Pattern.compile("get|put|post|delete|options|head|patch|trace");
static final Pattern PARAM_IN_REGEX = Pattern.compile("path|query|header|cookie");
static final Pattern STYLE_REGEX = Pattern.compile("matrix|label|form|simple|spaceDelimited|pipeDelimited|deepObject");
static final Pattern RESPONSE_REGEX = Pattern.compile("[1-5][0-9]{2}|[1-5]XX|default");
}