// HTTP extensions
if (msgExt != null) {
message.setHttpTransferCoding(msgExt.getHttpTransferCoding());
HTTPHeader[] headers = msgExt.getHttpHeaders();
for (int k = 0; k < headers.length; k++) {
Wsdl2HttpHeaderImpl h = new Wsdl2HttpHeaderImpl();
h.setName(headers[k].getName());
h.setRequired(headers[k].isRequired() ? headers[k].isRequired().booleanValue() : false);
if (!XSD_2001_SYSTEM.equals(headers[k].getTypeDefinition().getSystem())) {
throw new IllegalStateException("Unsupported type system: " + headers[k].getTypeDefinition().getSystem());
}
h.setType(headers[k].getTypeDefinition().getName());
message.addHttpHeader(h);
}
}
// Add the message
if (iMsgRef.getDirection() == Direction.IN) {