Java Code Examples for com.sun.tools.internal.ws.api.wsdl.TWSDLExtension#getClass()

The following examples show how to use com.sun.tools.internal.ws.api.wsdl.TWSDLExtension#getClass() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: WSDLModelerBase.java    From TencentKona-8 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 2
Source File: WSDLModelerBase.java    From jdk8u60 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 3
Source File: WSDLModelerBase.java    From openjdk-jdk8u with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 4
Source File: WSDLModelerBase.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 5
Source File: WSDLModelerBase.java    From openjdk-jdk9 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 6
Source File: WSDLModelerBase.java    From hottub with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 7
Source File: WSDLModelerBase.java    From openjdk-8-source with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}
 
Example 8
Source File: WSDLModelerBase.java    From openjdk-8 with GNU General Public License v2.0 6 votes vote down vote up
/**
 * @return List of SOAPHeader extensions
 */
protected List<SOAPHeader> getHeaderExtensions(TWSDLExtensible extensible) {
    List<SOAPHeader> headerList = new ArrayList<SOAPHeader>();
    for (TWSDLExtension extension : extensible.extensions()) {
        if (extension.getClass()==MIMEMultipartRelated.class) {
            for( MIMEPart part : ((MIMEMultipartRelated) extension).getParts() ) {
                boolean isRootPart = isRootPart(part);
                for (TWSDLExtension obj : part.extensions()) {
                    if (obj instanceof SOAPHeader) {
                        //bug fix: 5024015
                        if (!isRootPart) {
                            warning((Entity) obj, ModelerMessages.MIMEMODELER_WARNING_IGNORINGINVALID_HEADER_PART_NOT_DECLARED_IN_ROOT_PART(info.bindingOperation.getName()));
                            return new ArrayList<SOAPHeader>();
                        }
                        headerList.add((SOAPHeader) obj);
                    }
                }
            }
        } else if (extension instanceof SOAPHeader) {
            headerList.add((SOAPHeader) extension);
        }
    }
     return headerList;
}