Class QueryParameterRequirement
java.lang.Object
de.craftsblock.craftsnet.api.requirements.Requirement<Request,RouteRegistry.EndpointMapping>
de.craftsblock.craftsnet.api.requirements.web.WebRequirement
de.craftsblock.craftsnet.api.requirements.web.QueryParameterRequirement
A specific web requirement that checks if the url parameter list of an HTTP request matches certain criteria.
- Since:
- 3.0.6-SNAPSHOT
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanapplies(Request request, RouteRegistry.EndpointMapping endpointMapping) Checks if the requirement applies given the specified request and endpoint mapping.Methods inherited from class de.craftsblock.craftsnet.api.requirements.Requirement
getAnnotation
-
Constructor Details
-
QueryParameterRequirement
public QueryParameterRequirement()Constructs a new query parameter requirement.
-
-
Method Details
-
applies
Checks if the requirement applies given the specified request and endpoint mapping.- Specified by:
appliesin classRequirement<Request,RouteRegistry.EndpointMapping> - Parameters:
request- the HTTP requestendpointMapping- the endpoint mapping- Returns:
trueif the requirement applies,falseotherwise
-