| Package | Description |
|---|---|
| com.linecorp.armeria.internal.server.annotation |
Various classes used internally.
|
| com.linecorp.armeria.server |
Server core.
|
| com.linecorp.armeria.server.annotation |
Annotations for building a RESTful service.
|
| Modifier and Type | Method and Description |
|---|---|
List<ResponseConverterFunction> |
AnnotatedServiceExtensions.responseConverters()
Returns the specified
ResponseConverterFunctions with the annotated service. |
| Modifier and Type | Method and Description |
|---|---|
static List<AnnotatedServiceElement> |
AnnotatedServiceFactory.find(String pathPrefix,
Object object,
List<RequestConverterFunction> requestConverterFunctions,
List<ResponseConverterFunction> responseConverterFunctions,
List<ExceptionHandlerFunction> exceptionHandlerFunctions)
Returns the list of
AnnotatedService defined by Path and HTTP method annotations
from the specified object, RequestConverterFunctions, ResponseConverterFunctions,
ExceptionHandlerFunctions and AnnotatedServiceExtensions. |
| Constructor and Description |
|---|
AnnotatedServiceExtensions(List<RequestConverterFunction> requestConverters,
List<ResponseConverterFunction> responseConverters,
List<ExceptionHandlerFunction> exceptionHandlers) |
| Modifier and Type | Method and Description |
|---|---|
VirtualHostAnnotatedServiceBindingBuilder |
VirtualHostAnnotatedServiceBindingBuilder.responseConverter(ResponseConverterFunction responseConverterFunction)
|
AnnotatedServiceBindingBuilder |
AnnotatedServiceBindingBuilder.responseConverter(ResponseConverterFunction responseConverterFunction)
|
VirtualHostAnnotatedServiceBindingBuilder |
VirtualHostAnnotatedServiceBindingBuilder.responseConverters(ResponseConverterFunction... responseConverterFunctions)
Adds the given
ResponseConverterFunctions to this
VirtualHostAnnotatedServiceBindingBuilder. |
AnnotatedServiceBindingBuilder |
AnnotatedServiceBindingBuilder.responseConverters(ResponseConverterFunction... responseConverterFunctions)
Adds the given
ResponseConverterFunctions to this AnnotatedServiceBindingBuilder. |
| Modifier and Type | Method and Description |
|---|---|
VirtualHostBuilder |
VirtualHostBuilder.annotatedService(String pathPrefix,
Object service,
Function<? super HttpService,? extends HttpService> decorator,
Iterable<? extends ExceptionHandlerFunction> exceptionHandlerFunctions,
Iterable<? extends RequestConverterFunction> requestConverterFunctions,
Iterable<? extends ResponseConverterFunction> responseConverterFunctions)
Binds the specified annotated service object under the specified path prefix.
|
ServerBuilder |
ServerBuilder.annotatedService(String pathPrefix,
Object service,
Function<? super HttpService,? extends HttpService> decorator,
Iterable<? extends ExceptionHandlerFunction> exceptionHandlerFunctions,
Iterable<? extends RequestConverterFunction> requestConverterFunctions,
Iterable<? extends ResponseConverterFunction> responseConverterFunctions)
Binds the specified annotated service object under the specified path prefix.
|
VirtualHostBuilder |
VirtualHostBuilder.annotatedServiceExtensions(Iterable<? extends RequestConverterFunction> requestConverterFunctions,
Iterable<? extends ResponseConverterFunction> responseConverterFunctions,
Iterable<? extends ExceptionHandlerFunction> exceptionHandlerFunctions)
Sets the
RequestConverterFunctions, ResponseConverterFunction
and ExceptionHandlerFunctions for creating an AnnotatedServiceExtensions. |
ServerBuilder |
ServerBuilder.annotatedServiceExtensions(Iterable<? extends RequestConverterFunction> requestConverterFunctions,
Iterable<? extends ResponseConverterFunction> responseConverterFunctions,
Iterable<? extends ExceptionHandlerFunction> exceptionHandlerFunctions)
Sets the
RequestConverterFunctions, ResponseConverterFunction
and ExceptionHandlerFunctions for creating an AnnotatedServiceExtensions. |
VirtualHostAnnotatedServiceBindingBuilder |
VirtualHostAnnotatedServiceBindingBuilder.responseConverters(Iterable<? extends ResponseConverterFunction> responseConverterFunctions)
Adds the given
ResponseConverterFunctions to this
VirtualHostAnnotatedServiceBindingBuilder. |
AnnotatedServiceBindingBuilder |
AnnotatedServiceBindingBuilder.responseConverters(Iterable<? extends ResponseConverterFunction> responseConverterFunctions)
Adds the given
ResponseConverterFunctions to this AnnotatedServiceBindingBuilder. |
| Modifier and Type | Class and Description |
|---|---|
class |
ByteArrayResponseConverterFunction
A response converter implementation which creates an
HttpResponse with
content-type: application/binary or content-type: application/octet-stream. |
class |
JacksonResponseConverterFunction
A response converter implementation which creates an
HttpResponse with
content-type: application/json; charset=utf-8 or content-type: application/json-seq. |
class |
NullToNoContentResponseConverterFunction
A response converter implementation which creates an
HttpResponse of HttpStatus.NO_CONTENT
when the specified result is null. |
class |
ServerSentEventResponseConverterFunction
A response converter implementation which creates an
HttpResponse with
content-type: text/event-stream. |
class |
StringResponseConverterFunction
A response converter implementation which creates an
HttpResponse with
content-type: text/plain. |
| Modifier and Type | Method and Description |
|---|---|
ResponseConverterFunction |
ResponseConverterFunctionProvider.createResponseConverterFunction(Type responseType,
ResponseConverterFunction responseConverter,
ExceptionHandlerFunction exceptionHandler)
Returns a
ResponseConverterFunction instance if there is a function which can convert
the responseType, otherwise return null. |
| Modifier and Type | Method and Description |
|---|---|
ResponseConverterFunction |
ResponseConverterFunctionProvider.createResponseConverterFunction(Type responseType,
ResponseConverterFunction responseConverter,
ExceptionHandlerFunction exceptionHandler)
Returns a
ResponseConverterFunction instance if there is a function which can convert
the responseType, otherwise return null. |
Copyright © 2020 LeanCloud. All rights reserved.