Operation<?> operation = message.get(Operation.class);
if (operation instanceof Wsdl2HttpOperation == false) {
return;
}
Wsdl2HttpBinding httpBinding = (Wsdl2HttpBinding) message.get(Binding.class);
Wsdl2HttpOperation httpOperation = (Wsdl2HttpOperation) operation;
Wsdl2HttpMessage httpMessage;
String serialization;
if (server) {
httpMessage = httpOperation.getInput();
serialization = httpOperation.getHttpInputSerialization();
} else {
httpMessage = httpOperation.getOutput();
serialization = httpOperation.getHttpOutputSerialization();
}
if (httpMessage.getContentModel() == ContentModel.ELEMENT ||
httpMessage.getContentModel() == ContentModel.ANY) {
// Serialization rules for XML
if (HttpConstants.SERIAL_APP_URLENCODED.equals(serialization)) {