src/wsdl/org/apache/axis/wsdl/wsdl2ws/c/AllParamWriter.java
/**
     * genarate all the wrappets for custom complex types.
     * @see org.apache.axis.wsdl.wsdl2ws.SourceWriter#writeSource()
     */
genarate all the wrappets for custom complex types.
genarate all the wrappets for custom complex types .
public void writeSource() throws WrapperFault
    {
        Iterator types = wscontext.getTypemap().getTypes().iterator();
        Type type = null;
        while (types.hasNext())
        {
            try
            {
                type = (Type) types.next();
                if (!type.isExternalized())
                {
                    if(WSDL2Ws.c_veryVerbose)
                        System.out.println("\nSkipping type " + type.getName());
                }                
                else if (type.isArray())
                {
                    QName qname = type.getName();
                    if (WSDL2Ws.c_veryVerbose)
                        System.out.println("\nArray processing for type: " + qname);
                    String elementType = type.getElementType();
                    if (elementType != null)
                    {
                        if (TypeMap.isAnonymousType(elementType))
                            elementType = CUtils.sanitizeString(elementType);
                        if (WSDL2Ws.c_veryVerbose)
                            System.out.println("    Array element type " 
                                    + type.getElementType() + " normalized to " + elementType);
                        QName elementQname = new QName(qname.getNamespaceURI(), elementType);                       
                        Type currentType = wscontext.getTypemap().getType(elementQname);
                        if (currentType != null)
                            if ( currentType.isSimpleType())
                            {
                                if (WSDL2Ws.c_veryVerbose)
                                    System.out.println("    Array writer not called - element type is simple");
                                continue;
                            }
                    }
                    ArrayParamHeaderWriter writer = (new ArrayParamHeaderWriter(wscontext, type));
                    if (!writer.isSimpleTypeArray())
                    {
                        if (WSDL2Ws.c_veryVerbose)
                            System.out.println("    Array writer called......");
                        writer.writeSource();
                        (new ArrayParamWriter(wscontext, type)).writeSource();
                    }
                }
                else
                {
                    if (WSDL2Ws.c_veryVerbose)
                        System.out.println("\nstruct writer called for......" + type.getName());
                    (new BeanParamWriter(wscontext, type)).writeSource();
                    (new ParmHeaderFileWriter(wscontext, type)).writeSource();
                }
            }
            catch (Exception e)
            {
                System.out.println(
                        "Error occurred generating code for " + type.getName()
                            + ". Other classes will continue to be generated.");
                e.printStackTrace();
            }
        }
    }
public void writeSource ( ) throws WrapperFault { Iterator types = wscontext . getTypemap ( ) . getTypes ( ) . iterator ( ) ; Type type = null ; while ( types . hasNext ( ) ) { try { type = ( Type ) types . next ( ) ; if ( ! type . isExternalized ( ) ) { if ( WSDL2Ws . c_veryVerbose ) System . out . println ( "\nSkipping type " + type . getName ( ) ) ; } else if ( type . isArray ( ) ) { QName qname = type . getName ( ) ; if ( WSDL2Ws . c_veryVerbose ) System . out . println ( "\nArray processing for type: " + qname ) ; String elementType = type . getElementType ( ) ; if ( elementType != null ) { if ( TypeMap . isAnonymousType ( elementType ) ) elementType = CUtils . sanitizeString ( elementType ) ; if ( WSDL2Ws . c_veryVerbose ) System . out . println ( "    Array element type " + type . getElementType ( ) + " normalized to " + elementType ) ; QName elementQname = new QName ( qname . getNamespaceURI ( ) , elementType ) ; Type currentType = wscontext . getTypemap ( ) . getType ( elementQname ) ; if ( currentType != null ) if ( currentType . isSimpleType ( ) ) { if ( WSDL2Ws . c_veryVerbose ) System . out . println ( "    Array writer not called - element type is simple" ) ; continue ; } } ArrayParamHeaderWriter writer = ( new ArrayParamHeaderWriter ( wscontext , type ) ) ; if ( ! writer . isSimpleTypeArray ( ) ) { if ( WSDL2Ws . c_veryVerbose ) System . out . println ( "    Array writer called......" ) ; writer . writeSource ( ) ; ( new ArrayParamWriter ( wscontext , type ) ) . writeSource ( ) ; } } else { if ( WSDL2Ws . c_veryVerbose ) System . out . println ( "\nstruct writer called for......" + type . getName ( ) ) ; ( new BeanParamWriter ( wscontext , type ) ) . writeSource ( ) ; ( new ParmHeaderFileWriter ( wscontext , type ) ) . writeSource ( ) ; } } catch ( Exception e ) { System . out . println ( "Error occurred generating code for " + type . getName ( ) + ". Other classes will continue to be generated." ) ; e . printStackTrace ( ) ; } } }
genarate all the wrappets for custom complex types.
genarate all the wrappets for custom complex types .