MIMEPart mPart = (MIMEPart)itParts.next();
Iterator extns = mPart.getExtensibilityElements().iterator();
while (extns.hasNext()) {
ExtensibilityElement extElement = (ExtensibilityElement)extns.next();
if (extElement instanceof MIMEContent) {
MIMEContent mimeContent = (MIMEContent)extElement;
String mimeJavaType = getJavaTypeForMimeType(mPart);
if (JavaType.Style.IN.equals(style)) {
String paramName = ProcessorUtil.mangleNameToVariableName(mimeContent.getPart());
JavaParameter jp = jm.getParameter(paramName);
if (jp == null) {
Message message = new Message("MIMEPART_CANNOT_MAP", LOG, mimeContent.getPart());
throw new ToolException(message);
}
if (!jp.getClassName().equals(mimeJavaType)) {
// jp.setType(mimeJavaType);
jp.setClassName(mimeJavaType);
}
} else if (JavaType.Style.OUT.equals(style)) {
if (mimeParts.size() > 2) {
// more than 1 mime:content part (1 root soap body),
// javaReturn will be set to void and
// all output parameter will be treated as the
// holder class
String paramName = ProcessorUtil.mangleNameToVariableName(mimeContent.getPart());
JavaParameter jp = jm.getParameter(paramName);
if (jp == null) {
Message message = new Message("MIMEPART_CANNOT_MAP", LOG, mimeContent
.getPart());
throw new ToolException(message);
} else {
if (!jp.getClassName().equals(mimeJavaType)) {
// jp.setType(mimeJavaType);