Class VariablePathSegment
java.lang.Object
io.github.grumpystuff.grumpyrest.request.path.PathSegment
io.github.grumpystuff.grumpyrest.request.path.VariablePathSegment
This segment matches any request path segment. The request handling logic will generate a
PathArgument for
each such segment.-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class io.github.grumpystuff.grumpyrest.request.path.PathSegment
parse
-
Constructor Details
-
VariablePathSegment
Constructor.- Parameters:
variableName- the name of the variable. This is currently not used anywhere. It is usually specified by providing the whole path pattern as a string-based specification that contains variable path segments as :name which contains the variable name.
-
-
Method Details
-
getVariableName
Getter for the variable name- Returns:
- the variable name (currently not used anywhere)
-
matches
Description copied from class:PathSegmentChecks whether this segment matches a segment of a path from an incoming request.- Specified by:
matchesin classPathSegment- Parameters:
segment- the request path segment- Returns:
- true if the segment matches, false if not
-
toString
-