Index

A C D E F G H I J L M N O P Q R S T U V W 
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form

A

addComplexRoute(HttpMethod, String, ComplexHandler) - Method in class name.martingeisse.grumpyrest.RestApi
Adds a route to handle requests.
addComplexRoute(HttpMethod, Path, ComplexHandler) - Method in class name.martingeisse.grumpyrest.RestApi
Adds a route to handle requests.
addCustomHeader(String, String) - Method in interface name.martingeisse.grumpyrest.response.ResponseTransmitter
Header Method: Adds a custom header to send to the client.
addRoute(HttpMethod, String, SimpleHandler) - Method in class name.martingeisse.grumpyrest.RestApi
Adds a route to handle requests.
addRoute(HttpMethod, Path, SimpleHandler) - Method in class name.martingeisse.grumpyrest.RestApi
Adds a route to handle requests.
addRoute(Route) - Method in class name.martingeisse.grumpyrest.RestApi
Adds a route to handle requests.

C

clear() - Method in class name.martingeisse.grumpyrest.response.ResponseFactoryRegistry
Removes all response factories from this registry.
ComplexHandler - Interface in name.martingeisse.grumpyrest
Interface for a handler in case a SimpleHandler is not flexible enough.
createResponse(RequestCycle, Object) - Method in interface name.martingeisse.grumpyrest.response.ResponseFactory
Creates a Response from the specified response value.
createResponse(RequestCycle, Object) - Method in class name.martingeisse.grumpyrest.response.ResponseFactoryRegistry
Converts a response value to a Response using an appropriate response factory from this registry.
createResponse(RequestCycle, Object) - Method in class name.martingeisse.grumpyrest.response.standard.IdentityResponseFactory
 
createResponse(RequestCycle, Object) - Method in class name.martingeisse.grumpyrest.response.standard.JsonResponseFactory
 
createResponse(RequestCycle, Object) - Method in class name.martingeisse.grumpyrest.response.standard.NullResponseFactory
 

D

DELETE - Enum constant in enum class name.martingeisse.grumpyrest.request.HttpMethod
HTTP DELETE method
doDelete(HttpServletRequest, HttpServletResponse) - Method in class name.martingeisse.grumpyrest.servlet.RestServlet
 
doGet(HttpServletRequest, HttpServletResponse) - Method in class name.martingeisse.grumpyrest.servlet.RestServlet
 
doPost(HttpServletRequest, HttpServletResponse) - Method in class name.martingeisse.grumpyrest.servlet.RestServlet
 
doPut(HttpServletRequest, HttpServletResponse) - Method in class name.martingeisse.grumpyrest.servlet.RestServlet
 
DUPLICATE_PARAMETER - Static variable in class name.martingeisse.grumpyrest.ExceptionMessages
Error message for a duplicate parameter, such as in the request path or querystring.

E

EnumParser<T extends Enum<T>> - Class in name.martingeisse.grumpyrest.request.stringparser.standard
A parser for enum types.
EnumParser(Class<T>) - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.EnumParser
Constructor
equals(Object) - Method in record class name.martingeisse.grumpyrest.request.path.Path
Indicates whether some other object is "equal to" this one.
equals(Object) - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Indicates whether some other object is "equal to" this one.
equals(Object) - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse.Field
Indicates whether some other object is "equal to" this one.
equals(Object) - Method in record class name.martingeisse.grumpyrest.Route
Indicates whether some other object is "equal to" this one.
equals(Object) - Method in record class name.martingeisse.grumpyrest.RouteMatchResult
Indicates whether some other object is "equal to" this one.
ExceptionMessages - Class in name.martingeisse.grumpyrest
This class is mostly useful for unit tests: If we hardcoded the error messages at the point these errors occur, then we would have to duplicate them in the tests.

F

Field(String, String) - Constructor for record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse.Field
Constructor.
fields() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Returns the value of the fields record component.
FinishRequestException - Exception Class in name.martingeisse.grumpyrest.response
This exception type can be thrown to immediately finish handling a request and respond with a specific response value.
FinishRequestException(Object) - Constructor for exception class name.martingeisse.grumpyrest.response.FinishRequestException
Constructor.
FromStringParser - Interface in name.martingeisse.grumpyrest.request.stringparser
Implementations of this interface are used to parse a higher-level type from a string.
FromStringParserException - Exception Class in name.martingeisse.grumpyrest.request.stringparser
This exception gets thrown by a FromStringParser if the string to parse does not conform to the parser's expectation.
FromStringParserException(String) - Constructor for exception class name.martingeisse.grumpyrest.request.stringparser.FromStringParserException
Constructor
FromStringParserRegistry - Class in name.martingeisse.grumpyrest.request.stringparser
This registry keeps FromStringParsers used to parse path parameters and querystring parameters.
FromStringParserRegistry() - Constructor for class name.martingeisse.grumpyrest.request.stringparser.FromStringParserRegistry
Constructor.

G

generateRegistrable(Type) - Method in class name.martingeisse.grumpyrest.request.querystring.QuerystringParserRegistry
 
generateRegistrable(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.FromStringParserRegistry
 
GET - Enum constant in enum class name.martingeisse.grumpyrest.request.HttpMethod
HTTP GET method
getApi() - Method in class name.martingeisse.grumpyrest.RequestCycle
Getter method for the RestApi that handles the request
getErrorMessageForUnknownKey(Type) - Method in class name.martingeisse.grumpyrest.request.querystring.QuerystringParserRegistry
 
getErrorMessageForUnknownKey(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.FromStringParserRegistry
 
getFieldErrors() - Method in exception class name.martingeisse.grumpyrest.request.querystring.QuerystringParsingException
Getter for the field errors
getFromStringParserRegistry() - Method in class name.martingeisse.grumpyrest.RestApi
Getter method for the registry for from-string parsers.
getHeader(String) - Method in interface name.martingeisse.grumpyrest.request.Request
Getter method for HTTP request headers.
getHighlevelRequest() - Method in class name.martingeisse.grumpyrest.RequestCycle
The high-level Request object that makes all relevant properties of the HTTP request available.
getJsonEngine() - Method in class name.martingeisse.grumpyrest.RestApi
Getter method for the JsonEngine.
getMatchedRoute() - Method in class name.martingeisse.grumpyrest.RequestCycle
Getter method for the route that matched this request.
getMethod() - Method in interface name.martingeisse.grumpyrest.request.Request
Getter method for the HTTP method.
getName() - Method in class name.martingeisse.grumpyrest.request.PathArgument
Getter for the name of the path parameter.
getOutputStream() - Method in interface name.martingeisse.grumpyrest.response.ResponseTransmitter
Body method: Obtains the output stream to send body data to the client.
getPath(HttpServletRequest) - Method in enum class name.martingeisse.grumpyrest.servlet.RequestPathSourcingStrategy
Determines the request path from a servlet request object.
getPathArguments() - Method in interface name.martingeisse.grumpyrest.request.Request
Getter method for the path arguments bound to path parameters in the matched route.
getPathArguments() - Method in class name.martingeisse.grumpyrest.RequestCycle
Getter method for the path arguments that are bound to variables in the path of the matched route.
getPathSegments() - Method in class name.martingeisse.grumpyrest.RequestCycle
Getter method for the requested path, split into segments at slashes
getQuerystringParserRegistry() - Method in class name.martingeisse.grumpyrest.RestApi
Getter method for the registry for whole-querystring parsers.
getResponseFactoryRegistry() - Method in class name.martingeisse.grumpyrest.RestApi
Getter method for the registry for custom response factories.
getResponseTransmitter() - Method in class name.martingeisse.grumpyrest.RequestCycle
Returns an object that is used by Response implementations to transmit the response to the client.
getResponseValue() - Method in exception class name.martingeisse.grumpyrest.response.NoResponseFactoryException
Getter for the response value
getRoutes() - Method in class name.martingeisse.grumpyrest.RestApi
Returns a snapshot of the currently present routes.
getServletRequest() - Method in class name.martingeisse.grumpyrest.RequestCycle
Getter method for the underlying servlet request
getText() - Method in class name.martingeisse.grumpyrest.request.path.LiteralPathSegment
Getter method for the segment text
getText() - Method in class name.martingeisse.grumpyrest.request.PathArgument
Getter for the textual value of the path argument
getValue(TypeToken<T>) - Method in class name.martingeisse.grumpyrest.request.PathArgument
Converts the path argument to the specified type.
getValue(Class<T>) - Method in class name.martingeisse.grumpyrest.request.PathArgument
Converts the path argument to the specified class type.
getValue(Type) - Method in class name.martingeisse.grumpyrest.request.PathArgument
Converts the path argument to the specified type.
getVariableName() - Method in class name.martingeisse.grumpyrest.request.path.VariablePathSegment
Getter for the variable name
getWrappedResponseValue() - Method in exception class name.martingeisse.grumpyrest.response.FinishRequestException
 
getWrappedResponseValue() - Method in interface name.martingeisse.grumpyrest.response.ResponseValueWrapper
Getter method for the response value wrapped by this wrapper.

H

handle(Request) - Method in interface name.martingeisse.grumpyrest.SimpleHandler
Handles a request.
handle(RequestCycle) - Method in interface name.martingeisse.grumpyrest.ComplexHandler
Handles a request.
handle(RequestCycle) - Method in class name.martingeisse.grumpyrest.RestApi
Handles a request cycle.
handler() - Method in record class name.martingeisse.grumpyrest.Route
Returns the value of the handler record component.
hashCode() - Method in record class name.martingeisse.grumpyrest.request.path.Path
Returns a hash code value for this object.
hashCode() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse.Field
Returns a hash code value for this object.
hashCode() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Returns a hash code value for this object.
hashCode() - Method in record class name.martingeisse.grumpyrest.Route
Returns a hash code value for this object.
hashCode() - Method in record class name.martingeisse.grumpyrest.RouteMatchResult
Returns a hash code value for this object.
HttpMethod - Enum Class in name.martingeisse.grumpyrest.request
HTTP methods as an enum.

I

ID_NOT_FOUND - Static variable in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
This response indicates that the route is known in principle, but contains an ID that does not exist.
IdentityResponseFactory - Class in name.martingeisse.grumpyrest.response.standard
This simply accepts response values that implement Response themselves and returns them unchanged.
IdentityResponseFactory() - Constructor for class name.martingeisse.grumpyrest.response.standard.IdentityResponseFactory
Constructor.
INSTANCE - Static variable in class name.martingeisse.grumpyrest.response.standard.NopResponse
A shared instance of this class that can be used to reduce memory usage.
IntegerFromStringParser - Class in name.martingeisse.grumpyrest.request.stringparser.standard
Parses integers from their usual decimal text representation.
IntegerFromStringParser() - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.IntegerFromStringParser
Constructor.
INTERNAL_SERVER_ERROR - Static variable in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
The standard response for "something went wrong in the server", usually an uncaught exception.
invokeHandler(RequestCycle) - Method in record class name.martingeisse.grumpyrest.Route
Calls the handler for the specified request cycle.
IO_ERROR - Static variable in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
This gets responded (if even possible) when reading the request failed with a network error.

J

JSON_EXPECTED - Static variable in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Most endpoints expect a JSON request body (if they expect a request body at all), so here is a standard response for other request content types.
JsonResponseFactory - Class in name.martingeisse.grumpyrest.response.standard
Converts any JSON-able value into a Response by invoking the JsonEngine, then sending the result with HTTP status code 200.
JsonResponseFactory() - Constructor for class name.martingeisse.grumpyrest.response.standard.JsonResponseFactory
Constructor.

L

LiteralPathSegment - Class in name.martingeisse.grumpyrest.request.path
This segment only matches a request path segment with the exact same text.
LiteralPathSegment(String) - Constructor for class name.martingeisse.grumpyrest.request.path.LiteralPathSegment
Constructor.
LocalDateParser - Class in name.martingeisse.grumpyrest.request.stringparser.standard
A parser for LocalDate.
LocalDateParser() - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.LocalDateParser
Constructor
LocalDateTimeParser - Class in name.martingeisse.grumpyrest.request.stringparser.standard
A parser for LocalDateTime.
LocalDateTimeParser() - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.LocalDateTimeParser
Constructor
LocalTimeParser - Class in name.martingeisse.grumpyrest.request.stringparser.standard
A parser for LocalTime.
LocalTimeParser() - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.LocalTimeParser
Constructor

M

match(List<String>, ParseFromStringService) - Method in record class name.martingeisse.grumpyrest.request.path.Path
Matches a request path (i.e. a list of strings) against this path.
match(RequestCycle) - Method in class name.martingeisse.grumpyrest.RestApi
Matches the specified request cycle against all routes.
match(RequestCycle) - Method in record class name.martingeisse.grumpyrest.Route
Tries to match the specified request cycle against this route.
matches(String) - Method in enum class name.martingeisse.grumpyrest.request.HttpMethod
Checks whether this method matches the specified other method.
matches(String) - Method in class name.martingeisse.grumpyrest.request.path.LiteralPathSegment
 
matches(String) - Method in class name.martingeisse.grumpyrest.request.path.PathSegment
Checks whether this segment matches a segment of a path from an incoming request.
matches(String) - Method in class name.martingeisse.grumpyrest.request.path.VariablePathSegment
 
message() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse.Field
Returns the value of the message record component.
message() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Returns the value of the message record component.
method() - Method in record class name.martingeisse.grumpyrest.Route
Returns the value of the method record component.
MISSING_PARAMETER - Static variable in class name.martingeisse.grumpyrest.ExceptionMessages
Error message for a missing parameter, such as in the request path or querystring.

N

name.martingeisse.grumpyrest - package name.martingeisse.grumpyrest
 
name.martingeisse.grumpyrest.request - package name.martingeisse.grumpyrest.request
 
name.martingeisse.grumpyrest.request.path - package name.martingeisse.grumpyrest.request.path
 
name.martingeisse.grumpyrest.request.querystring - package name.martingeisse.grumpyrest.request.querystring
 
name.martingeisse.grumpyrest.request.stringparser - package name.martingeisse.grumpyrest.request.stringparser
 
name.martingeisse.grumpyrest.request.stringparser.standard - package name.martingeisse.grumpyrest.request.stringparser.standard
 
name.martingeisse.grumpyrest.response - package name.martingeisse.grumpyrest.response
 
name.martingeisse.grumpyrest.response.standard - package name.martingeisse.grumpyrest.response.standard
 
name.martingeisse.grumpyrest.servlet - package name.martingeisse.grumpyrest.servlet
 
NopResponse - Class in name.martingeisse.grumpyrest.response.standard
Does not respond at all.
NopResponse() - Constructor for class name.martingeisse.grumpyrest.response.standard.NopResponse
Constructor.
NoResponseFactoryException - Exception Class in name.martingeisse.grumpyrest.response
This exception type gets thrown if no response factory can be found for a specific response value.
NoResponseFactoryException(Object) - Constructor for exception class name.martingeisse.grumpyrest.response.NoResponseFactoryException
Constructor.
NullResponseFactory - Class in name.martingeisse.grumpyrest.response.standard
Produces an empty 200 response when null is returned as a response value.
NullResponseFactory() - Constructor for class name.martingeisse.grumpyrest.response.standard.NullResponseFactory
Constructor.

O

onSeal() - Method in class name.martingeisse.grumpyrest.response.ResponseFactoryRegistry
 
OptionalFieldParser - Class in name.martingeisse.grumpyrest.request.stringparser.standard
Parses an optional field, returning an OptionalField which wraps the parsed value (or nothing if the field to parse is absent).
OptionalFieldParser(FromStringParserRegistry) - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.OptionalFieldParser
Constructor.

P

parse(String) - Static method in record class name.martingeisse.grumpyrest.request.path.Path
Creates an instance from a string-based specification, using :name for path parameters.
parse(String) - Static method in class name.martingeisse.grumpyrest.request.path.PathSegment
Parses an instance from a single segment of a string-based path specification.
parse(Map<String, String>, Type) - Method in interface name.martingeisse.grumpyrest.request.querystring.QuerystringParser
Converts the querystring to an application object.
parse(Map<String, String>, Type) - Method in class name.martingeisse.grumpyrest.request.querystring.QuerystringToRecordParser
 
parseBody(TypeToken<T>) - Method in interface name.martingeisse.grumpyrest.request.Request
Parses the request body using the JSON parsing mechanism defined by JsonEngine and the JSON-able types defined in the engine's JsonRegistries.
parseBody(Class<T>) - Method in interface name.martingeisse.grumpyrest.request.Request
Parses the request body using the JSON parsing mechanism defined by JsonEngine and the JSON-able types defined in the engine's JsonRegistries.
parseBody(Type) - Method in interface name.martingeisse.grumpyrest.request.Request
Parses the request body using the JSON parsing mechanism defined by JsonEngine and the JSON-able types defined in the engine's JsonRegistries.
parseFromAbsentString(Type) - Method in interface name.martingeisse.grumpyrest.request.stringparser.FromStringParser
"Parses" a value from an absent string.
parseFromAbsentString(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.OptionalFieldParser
 
parseFromString(String, Type) - Method in interface name.martingeisse.grumpyrest.request.stringparser.FromStringParser
Parses a value from a string.
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.FromStringParserRegistry
 
parseFromString(String, Type) - Method in interface name.martingeisse.grumpyrest.request.stringparser.ParseFromStringService
Parses a string to obtain a value of the specified type.
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.EnumParser
 
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.IntegerFromStringParser
 
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.LocalDateParser
 
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.LocalDateTimeParser
 
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.LocalTimeParser
 
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.OptionalFieldParser
 
parseFromString(String, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.StringFromStringParser
 
ParseFromStringService - Interface in name.martingeisse.grumpyrest.request.stringparser
This interface exposes only the FromStringParserRegistry.parseFromString(String, Type) method.
parseQuerystring(TypeToken<T>) - Method in interface name.martingeisse.grumpyrest.request.Request
Parses the whole querystring into an object.
parseQuerystring(Class<T>) - Method in interface name.martingeisse.grumpyrest.request.Request
Parses the whole querystring into an object.
parseQuerystring(Type) - Method in interface name.martingeisse.grumpyrest.request.Request
Parses the whole querystring into an object.
path() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse.Field
Returns the value of the path record component.
path() - Method in record class name.martingeisse.grumpyrest.Route
Returns the value of the path record component.
Path - Record Class in name.martingeisse.grumpyrest.request.path
A path -- actually a path pattern -- that determines whether the actual path provided by a request matches a route.
Path(List<PathSegment>) - Constructor for record class name.martingeisse.grumpyrest.request.path.Path
Compact constructor.
PATH_INFO_ONLY - Enum constant in enum class name.martingeisse.grumpyrest.servlet.RequestPathSourcingStrategy
The request path only consists of the path info.
PathArgument - Class in name.martingeisse.grumpyrest.request
A concrete argument that was bound to a path parameter.
PathArgument(String, String, ParseFromStringService) - Constructor for class name.martingeisse.grumpyrest.request.PathArgument
NOT PUBLIC API
pathArguments() - Method in record class name.martingeisse.grumpyrest.RouteMatchResult
Returns the value of the pathArguments record component.
PathSegment - Class in name.martingeisse.grumpyrest.request.path
A single segment from a Path.
PathSegment() - Constructor for class name.martingeisse.grumpyrest.request.path.PathSegment
Constructor.
PathUtil - Class in name.martingeisse.grumpyrest.request.path
NOT PUBLIC API
POST - Enum constant in enum class name.martingeisse.grumpyrest.request.HttpMethod
HTTP POST method
PUT - Enum constant in enum class name.martingeisse.grumpyrest.request.HttpMethod
HTTP PUT method

Q

QuerystringParser - Interface in name.martingeisse.grumpyrest.request.querystring
A QuerystringParser turns a querystring into a Java Object, typically a record since parsers for them can be auto-generated.
QuerystringParserRegistry - Class in name.martingeisse.grumpyrest.request.querystring
A registry for QuerystringParser objects.
QuerystringParserRegistry(FromStringParserRegistry) - Constructor for class name.martingeisse.grumpyrest.request.querystring.QuerystringParserRegistry
Constructor.
QuerystringParsingException - Exception Class in name.martingeisse.grumpyrest.request.querystring
Represents one or more errors from parsing the querystring.
QuerystringParsingException(Map<String, String>) - Constructor for exception class name.martingeisse.grumpyrest.request.querystring.QuerystringParsingException
Creates an instance from a set of field errors, represented as a field-name-to-error map.
QuerystringToRecordParser - Class in name.martingeisse.grumpyrest.request.querystring
This class implements an auto-generated record parser.

R

register(ResponseFactory) - Method in class name.martingeisse.grumpyrest.response.ResponseFactoryRegistry
Registers a response factory to this registry, to be used when converting a response value to a Response.
registerDeserializer(JsonDeserializer) - Method in class name.martingeisse.grumpyrest.RestApi
Registers the specified deserializer with the JsonEngine.
registerDualConverter(T) - Method in class name.martingeisse.grumpyrest.RestApi
Registers the specified dual converter with the JsonEngine.
registerFromStringParser(FromStringParser) - Method in class name.martingeisse.grumpyrest.RestApi
Registers a from-string parser to support new types of path parameters and querystring parameters.
registerResponseFactory(ResponseFactory) - Method in class name.martingeisse.grumpyrest.RestApi
Registers a ResponseFactory to support new kinds of response values.
registerSerializer(JsonSerializer<?>) - Method in class name.martingeisse.grumpyrest.RestApi
Registers the specified serializer with the JsonEngine.
registrableSupports(QuerystringParser, Type) - Method in class name.martingeisse.grumpyrest.request.querystring.QuerystringParserRegistry
 
registrableSupports(FromStringParser, Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.FromStringParserRegistry
 
Request - Interface in name.martingeisse.grumpyrest.request
This interface provides access to all properties of an HTTP request that are relevant for the REST API.
requestBodyValidationFailed(List<FieldErrorNode.FlattenedError>) - Static method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
This is an error response for failed request body validation.
requestBodyValidationFailed(JsonDeserializationException) - Static method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
This is an error response for failed request body validation.
requestBodyValidationFailed(FieldErrorNode) - Static method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
This is an error response for failed request body validation.
RequestCycle - Class in name.martingeisse.grumpyrest
Holds the run-time state of processing a single request.
RequestCycle(RestApi, HttpServletRequest, HttpServletResponse, RequestPathSourcingStrategy) - Constructor for class name.martingeisse.grumpyrest.RequestCycle
NOT PUBLIC API
RequestPathSourcingStrategy - Enum Class in name.martingeisse.grumpyrest.servlet
This object defines how to obtain the request path from the servlet request.
Response - Interface in name.martingeisse.grumpyrest.response
An object that knows how to express itself via HTTP to the client.
ResponseFactory - Interface in name.martingeisse.grumpyrest.response
This factory knows how to turn specific kinds of response values into Response objects.
ResponseFactoryRegistry - Class in name.martingeisse.grumpyrest.response
Allows to register ResponseFactorys that provide Response implementations for the response values returned by handlers.
ResponseFactoryRegistry() - Constructor for class name.martingeisse.grumpyrest.response.ResponseFactoryRegistry
Constructor.
ResponseTransmitter - Interface in name.martingeisse.grumpyrest.response
This interface is used by the Response to transmit itself to the client.
ResponseValueWrapper - Interface in name.martingeisse.grumpyrest.response
If a handler returns an object implementing this interface, then it will be unwrapped (possibly multiple times if the wrapped value implements this interface again) before an appropriate Response is created for it.
RestApi - Class in name.martingeisse.grumpyrest
This class is the main Entry point into grumpyrest.
RestApi() - Constructor for class name.martingeisse.grumpyrest.RestApi
Constructor.
RestServlet - Class in name.martingeisse.grumpyrest.servlet
Java servlet that serves a REST API defined by a RestApi object.
RestServlet(RestApi, RequestPathSourcingStrategy) - Constructor for class name.martingeisse.grumpyrest.servlet.RestServlet
Constructor.
route() - Method in record class name.martingeisse.grumpyrest.RouteMatchResult
Returns the value of the route record component.
Route - Record Class in name.martingeisse.grumpyrest
A route is, conceptually, a set of criteria that determine whether the route matches a specific requests, as well as a handler that defines what to do for requests that match.
Route(HttpMethod, String, ComplexHandler) - Constructor for record class name.martingeisse.grumpyrest.Route
This constructor specifies the path pattern as a string instead of a Path object.
Route(HttpMethod, String, SimpleHandler) - Constructor for record class name.martingeisse.grumpyrest.Route
Constructor for a SimpleHandler which also specifies the path pattern as a string instead of a Path object.
Route(HttpMethod, Path, ComplexHandler) - Constructor for record class name.martingeisse.grumpyrest.Route
Standard constructor.
Route(HttpMethod, Path, SimpleHandler) - Constructor for record class name.martingeisse.grumpyrest.Route
Constructor for a SimpleHandler.
RouteMatchResult - Record Class in name.martingeisse.grumpyrest
RouteMatchResult(Route, List<PathArgument>) - Constructor for record class name.martingeisse.grumpyrest.RouteMatchResult
Compact constructor.

S

seal() - Method in class name.martingeisse.grumpyrest.RestApi
Seals this API, also sealing all registries used in it.
segments() - Method in record class name.martingeisse.grumpyrest.request.path.Path
Returns the value of the segments record component.
setContentType(String) - Method in interface name.martingeisse.grumpyrest.response.ResponseTransmitter
Header Method: Sets the Content-Type header to send to the client.
setStatus(int) - Method in interface name.martingeisse.grumpyrest.response.ResponseTransmitter
Header Method: Sets the HTTP status code to send to the client.
SimpleHandler - Interface in name.martingeisse.grumpyrest
Interface for a handler in the most common, "simple", case.
splitIntoSegments(String) - Static method in class name.martingeisse.grumpyrest.request.path.PathUtil
NOT PUBLIC API
StandardErrorResponse - Record Class in name.martingeisse.grumpyrest.response.standard
Implements a standard JSON-based error response format, combined with a selectable HTTP status code.
StandardErrorResponse(int, String) - Constructor for record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Constructor without field errors.
StandardErrorResponse(int, String, List<StandardErrorResponse.Field>) - Constructor for record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Compact constructor.
StandardErrorResponse(int, String, StandardErrorResponse.Field) - Constructor for record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Constructor with a single field error.
StandardErrorResponse.Field - Record Class in name.martingeisse.grumpyrest.response.standard
Represents an error for a single field.
STARTING_WITH_CONTEXT_PATH - Enum constant in enum class name.martingeisse.grumpyrest.servlet.RequestPathSourcingStrategy
The request path is built by concatenating the context path, servlet path and path info.
STARTING_WITH_SERVLET_PATH - Enum constant in enum class name.martingeisse.grumpyrest.servlet.RequestPathSourcingStrategy
The request path is built by concatenating the servlet path and path info.
status() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Returns the value of the status record component.
StatusOnlyResponse - Class in name.martingeisse.grumpyrest.response.standard
Sends an empty response with a configurable HTTP status code.
StatusOnlyResponse(int) - Constructor for class name.martingeisse.grumpyrest.response.standard.StatusOnlyResponse
Constructor.
StringFromStringParser - Class in name.martingeisse.grumpyrest.request.stringparser.standard
Returns the argument text as a String without any actual parsing.
StringFromStringParser() - Constructor for class name.martingeisse.grumpyrest.request.stringparser.standard.StringFromStringParser
Constructor.
supportsType(Type) - Method in interface name.martingeisse.grumpyrest.request.querystring.QuerystringParser
Checks if this parser supports the specified type.
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.querystring.QuerystringToRecordParser
 
supportsType(Type) - Method in interface name.martingeisse.grumpyrest.request.stringparser.FromStringParser
Checks if this parser supports the specified type.
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.EnumParser
 
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.IntegerFromStringParser
 
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.LocalDateParser
 
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.LocalDateTimeParser
 
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.LocalTimeParser
 
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.OptionalFieldParser
 
supportsType(Type) - Method in class name.martingeisse.grumpyrest.request.stringparser.standard.StringFromStringParser
 

T

toString() - Method in class name.martingeisse.grumpyrest.request.path.LiteralPathSegment
 
toString() - Method in record class name.martingeisse.grumpyrest.request.path.Path
Returns a string representation of this record class.
toString() - Method in class name.martingeisse.grumpyrest.request.path.VariablePathSegment
 
toString() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse.Field
Returns a string representation of this record class.
toString() - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
Returns a string representation of this record class.
toString() - Method in record class name.martingeisse.grumpyrest.Route
Returns a string representation of this record class.
toString() - Method in record class name.martingeisse.grumpyrest.RouteMatchResult
Returns a string representation of this record class.
transmit(ResponseTransmitter) - Method in interface name.martingeisse.grumpyrest.response.Response
Transmits this response using the specified response transmitter.
transmit(ResponseTransmitter) - Method in class name.martingeisse.grumpyrest.response.standard.NopResponse
 
transmit(ResponseTransmitter) - Method in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
 
transmit(ResponseTransmitter) - Method in class name.martingeisse.grumpyrest.response.standard.StatusOnlyResponse
 
trimSlashes(String) - Static method in class name.martingeisse.grumpyrest.request.path.PathUtil
NOT PUBLIC API

U

UNEXPECTED_PARAMETER - Static variable in class name.martingeisse.grumpyrest.ExceptionMessages
Error message for an unexpected parameter, such as in the request path or querystring.
UNKNOWN_URL - Static variable in record class name.martingeisse.grumpyrest.response.standard.StandardErrorResponse
This response indicates that no route is known for the requested URL.

V

valueOf(String) - Static method in enum class name.martingeisse.grumpyrest.request.HttpMethod
Returns the enum constant of this class with the specified name.
valueOf(String) - Static method in enum class name.martingeisse.grumpyrest.servlet.RequestPathSourcingStrategy
Returns the enum constant of this class with the specified name.
values() - Static method in enum class name.martingeisse.grumpyrest.request.HttpMethod
Returns an array containing the constants of this enum class, in the order they are declared.
values() - Static method in enum class name.martingeisse.grumpyrest.servlet.RequestPathSourcingStrategy
Returns an array containing the constants of this enum class, in the order they are declared.
VariablePathSegment - Class in name.martingeisse.grumpyrest.request.path
This segment matches any request path segment.
VariablePathSegment(String) - Constructor for class name.martingeisse.grumpyrest.request.path.VariablePathSegment
Constructor.

W

writeJson(Object) - Method in interface name.martingeisse.grumpyrest.response.ResponseTransmitter
Body method: Converts the specified value to JSON and sends it to the client using the body output stream.
A C D E F G H I J L M N O P Q R S T U V W 
All Classes and Interfaces|All Packages|Constant Field Values|Serialized Form