public class DefaultLambdaHandler<B,R>
extends io.github.stepio.lambda.LambdaHandler
| Modifier and Type | Field and Description |
|---|---|
protected Class<B> |
bodyClass |
protected com.fasterxml.jackson.databind.ObjectMapper |
objectMapper |
protected ConcurrentMap<Class<?>,com.fasterxml.jackson.databind.ObjectReader> |
readers |
protected Class<R> |
responseClass |
protected ConcurrentMap<Class<?>,com.fasterxml.jackson.databind.ObjectWriter> |
writers |
| Constructor and Description |
|---|
DefaultLambdaHandler() |
DefaultLambdaHandler(Class<B> bodyClass,
Class<R> responseClass) |
| Modifier and Type | Method and Description |
|---|---|
protected B |
body(com.amazonaws.services.lambda.runtime.events.APIGatewayProxyRequestEvent request) |
protected Type[] |
genericTypes() |
protected com.fasterxml.jackson.databind.ObjectReader |
reader(Class<?> type) |
void |
registerCustom(io.github.stepio.lambda.enums.Method method,
Function<BodyRequestContext<B>,R> customHandler) |
void |
setObjectMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper) |
protected com.amazonaws.services.lambda.runtime.events.APIGatewayProxyResponseEvent |
wrap(R response) |
protected com.fasterxml.jackson.databind.ObjectWriter |
writer(Class<?> type) |
protected com.fasterxml.jackson.databind.ObjectMapper objectMapper
protected ConcurrentMap<Class<?>,com.fasterxml.jackson.databind.ObjectReader> readers
protected ConcurrentMap<Class<?>,com.fasterxml.jackson.databind.ObjectWriter> writers
public void setObjectMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
protected com.fasterxml.jackson.databind.ObjectReader reader(Class<?> type)
protected com.fasterxml.jackson.databind.ObjectWriter writer(Class<?> type)
public void registerCustom(io.github.stepio.lambda.enums.Method method,
Function<BodyRequestContext<B>,R> customHandler)
protected B body(com.amazonaws.services.lambda.runtime.events.APIGatewayProxyRequestEvent request)
protected com.amazonaws.services.lambda.runtime.events.APIGatewayProxyResponseEvent wrap(R response)
protected Type[] genericTypes()
Copyright © 2020. All rights reserved.