org.springframework.social.facebook.web
Class SignedRequestArgumentResolver
java.lang.Object
org.springframework.social.facebook.web.SignedRequestArgumentResolver
- All Implemented Interfaces:
- HandlerMethodArgumentResolver
public class SignedRequestArgumentResolver
- extends Object
- implements HandlerMethodArgumentResolver
Web argument resolver for controller handler method arguments that are annotated with SignedRequest
.
Binds JSON payload of the signed_request parameter to the parameter type.
JSON properties named with underbar (_) separates will be converted to camel-case when binding to field name. (e.g., "user_id" will bind to a property named "userId").
Any JSON properties without corresponding fields in the target type will be ignored.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SignedRequestArgumentResolver
public SignedRequestArgumentResolver(String appSecret)
supportsParameter
public boolean supportsParameter(MethodParameter parameter)
- Specified by:
supportsParameter
in interface HandlerMethodArgumentResolver
resolveArgument
public Object resolveArgument(MethodParameter parameter,
ModelAndViewContainer mavContainer,
NativeWebRequest request,
WebDataBinderFactory binderFactory)
throws Exception
- Specified by:
resolveArgument
in interface HandlerMethodArgumentResolver
- Throws:
Exception