Package org.apache.axis.wsdl.symbolTable

Examples of org.apache.axis.wsdl.symbolTable.DefinedType


        while(typeIterator.hasNext())
        {
            Object highLevelType = typeIterator.next();
            if(!(highLevelType instanceof BaseType))
            {
                DefinedType type = (DefinedType)highLevelType;
                if(type.getQName().getLocalPart().toString().startsWith(">")&& !(type.getQName().getLocalPart().toString().lastIndexOf(">")>1))
                {
                    // this is an "inner" type that will not be exposed
                    // however, it needs to be if it is referenced in a message part.
                    // check all the messages
                  ArrayList methods = wsContext.getSerInfo().getMethods();
                  for(int i=0; i<methods.size(); i++)
                  {
                      MethodInfo method = (MethodInfo)methods.get(i);
                      Collection inputParameterTypes = method.getInputParameterTypes();
                      Iterator paramIterator = inputParameterTypes.iterator();
                      while(paramIterator.hasNext())
                      {
                          ParameterInfo parameterInfo =(ParameterInfo)paramIterator.next();
                          Type parameterType = parameterInfo.getType();
                          if(parameterType.getName().equals(type.getQName()))
                          {
                              QName oldName = parameterType.getName();
                              QName newTypeName = new QName(parameterType.getName().getNamespaceURI(), parameterType.getName().getLocalPart().substring(1));
                             
                              Type innerClassType =  wsContext.getTypemap().getType(parameterType.getName());
View Full Code Here


            while(typeIterator.hasNext())
            {
                Object highLevelType = typeIterator.next();
                if(!(highLevelType instanceof BaseType))
                {
                    DefinedType type = (DefinedType)highLevelType;
                    if(!type.getQName().getLocalPart().toString().startsWith(">"))
                    {
//                        System.out.println( "HERE "+type.getQName().getLocalPart());
                        HashSet nestedTypes = type.getNestedTypes(symbolTable, true);
                        Iterator iterator = nestedTypes.iterator();
                        while(iterator.hasNext())
                        {
                            Object nestedObjectType = iterator.next();
                            if(nestedObjectType instanceof DefinedType)
                            {
                                //System.out.println( "nestedname"+nestedObjectType);
                                DefinedType nestedType =(DefinedType) nestedObjectType;
                                // If the nested parts are complex inner/anonymous types then they need to be exposed as seperate classes
                                String name =nestedType.getQName().getLocalPart().toString();
                               // System.out.println( "iterator next = "+name);
                                if(name.startsWith(">") && name.lastIndexOf(">")>0)
                                {
                                  // then this type needs to be exposed !
                                  QName oldName = nestedType.getQName();
//                                  System.out.println( "Exposing nestedType "+oldName);
//                                  System.out.println( "nestobjecttype = "+nestedObjectType.getClass());
//                                  QName newTypeName = new QName(oldName.getNamespaceURI(), oldName.getLocalPart().substring(1));
                                  QName newTypeName =new QName(oldName.getNamespaceURI(), CUtils.sanitiseClassName(oldName.getLocalPart().toString()));
                                 
View Full Code Here

        while(typeIterator.hasNext())
        {
            Object highLevelType = typeIterator.next();
            if(!(highLevelType instanceof BaseType))
            {
                DefinedType type = (DefinedType)highLevelType;
               
                if(!type.getQName().getLocalPart().toString().startsWith(">"))
                {
                    // It's not an "inner" type so look for the refs (this might not be valid logic and refs might be acceptable for these types too !)
                    HashSet nestedTypes = type.getNestedTypes(symbolTable, true);
                    Iterator nestTypeIter = nestedTypes.iterator();
                    while(nestTypeIter.hasNext())
                    {
                        Object nestedType =nestTypeIter.next();
                        if(!(nestedType instanceof BaseType))
View Full Code Here

        Parser wsdlParser = new Parser();
        System.out.println("Reading WSDL document from '" + url + "?WSDL'");
        wsdlParser.run(url + "?WSDL");
        SymbolTable symbolTable = wsdlParser.getSymbolTable();
        Vector v = symbolTable.getSymbols(new QName("http://datatypes.cs.amdocs.com", "CSText"));
        DefinedType type = (DefinedType) v.get(0);
        assertNotNull(type);
        Vector v2 = SchemaUtils.getContainedElementDeclarations(
                type.getNode(), symbolTable);
        ElementDecl element = (ElementDecl) v2.get(0);
        assertNotNull(element);
        assertEquals(Constants.XSD_STRING, element.getType().getQName());
    }
View Full Code Here

TOP

Related Classes of org.apache.axis.wsdl.symbolTable.DefinedType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.