@Override public final void handleReturnValue(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws Exception { if (returnValue != null) { handleReturnValueInternal(messageContext, returnType, returnValue); } }
private Unmarshaller createUnmarshaller(Class<?> clazz) throws JAXBException { return createUnmarshaller(getJaxbContext(clazz)); }
private Marshaller createMarshaller(Class<?> clazz) throws JAXBException { return createMarshaller(getJaxbContext(clazz)); }
@Override protected void handleReturnValueInternal(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { Class<?> parameterType = returnType.getParameterType(); marshalToResponsePayload(messageContext, parameterType, returnValue); }
@Override protected void handleReturnValueInternal(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { JAXBElement<?> element = (JAXBElement<?>) returnValue; marshalToResponsePayload(messageContext, element.getDeclaredType(), element); } }
private Marshaller createMarshaller(Class<?> clazz) throws JAXBException { JAXBContext jaxbContext = getJaxbContext(clazz); return jaxbContext.createMarshaller(); }
@Override public JAXBElement<?> resolveArgument(MessageContext messageContext, MethodParameter parameter) throws JAXBException { ParameterizedType parameterizedType = (ParameterizedType) parameter.getGenericParameterType(); Class<?> clazz = (Class<?>) parameterizedType.getActualTypeArguments()[0]; return unmarshalElementFromRequestPayload(messageContext, clazz); }
private Unmarshaller createUnmarshaller(Class<?> clazz) throws JAXBException { return createUnmarshaller(getJaxbContext(clazz)); }
private Marshaller createMarshaller(Class<?> clazz) throws JAXBException { return createMarshaller(getJaxbContext(clazz)); }
@Override protected void handleReturnValueInternal(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { Class<?> parameterType = returnType.getParameterType(); marshalToResponsePayload(messageContext, parameterType, returnValue); }
@Override protected void handleReturnValueInternal(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { JAXBElement<?> element = (JAXBElement<?>) returnValue; marshalToResponsePayload(messageContext, element.getDeclaredType(), element); } }
private Unmarshaller createUnmarshaller(Class<?> clazz) throws JAXBException { JAXBContext jaxbContext = getJaxbContext(clazz); return jaxbContext.createUnmarshaller(); }
@Override public final void handleReturnValue(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws Exception { if (returnValue != null) { handleReturnValueInternal(messageContext, returnType, returnValue); } }
private Unmarshaller createUnmarshaller(Class<?> clazz) throws JAXBException { return createUnmarshaller(getJaxbContext(clazz)); }
private Marshaller createMarshaller(Class<?> clazz) throws JAXBException { return createMarshaller(getJaxbContext(clazz)); }
public void handleReturnValue(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { Class<?> parameterType = returnType.getParameterType(); marshalToResponsePayload(messageContext, parameterType, returnValue); }
public void handleReturnValue(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { JAXBElement<?> element = (JAXBElement<?>) returnValue; marshalToResponsePayload(messageContext, element.getDeclaredType(), element); } }
@Override public final void handleReturnValue(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws Exception { if (returnValue != null) { handleReturnValueInternal(messageContext, returnType, returnValue); } }
@Override protected void handleReturnValueInternal(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { Class<?> parameterType = returnType.getParameterType(); marshalToResponsePayload(messageContext, parameterType, returnValue); }
@Override protected void handleReturnValueInternal(MessageContext messageContext, MethodParameter returnType, Object returnValue) throws JAXBException { JAXBElement<?> element = (JAXBElement<?>) returnValue; marshalToResponsePayload(messageContext, element.getDeclaredType(), element); } }