{
Method method = op.getMethod();
Class[] paramClasses = method.getParameterTypes();
boolean isDoc = binding.getStyle().equals(SoapConstants.STYLE_DOCUMENT);
MessagePartContainer inParts = binding.getHeaders(op.getInputMessage());
MessagePartContainer outParts = null;
if (op.hasOutput()) outParts = binding.getHeaders(op.getOutputMessage());
for (int j = 0; j < paramClasses.length; j++)
{
if (!paramClasses[j].equals(MessageContext.class) && isHeader(method, j))
{
if (isOutParam(method, j))
{
QName q = getOutParameterName(binding.getService(), op, method, j, isDoc);
outParts.addMessagePart(q, paramClasses[j]).setIndex(j);
}
if (isInParam(method, j))
{
QName q = getInParameterName(binding.getService(), op, method, j, isDoc);
inParts.addMessagePart(q, paramClasses[j]).setIndex(j);
}
}
}
Class returnType = method.getReturnType();
if (isHeader(method, -1))
{
if (isOutParam(method, -1))
{
QName q = getOutParameterName(binding.getService(), op, method, -1, isDoc);
outParts.addMessagePart(q, returnType).setIndex(-1);
}
if (isInParam(method, -1))
{
QName q = getInParameterName(binding.getService(), op, method, -1, isDoc);