Package org.apache.axis2.wsdl.codegen

Examples of org.apache.axis2.wsdl.codegen.CommandLineOption


                             String selectedLanguage,
                             String outputLocation) {
        Map optionMap = new HashMap();
        //WSDL file name
        optionMap.put(CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                        getStringArray(WSDLFileName)));

        //Async only
        if (isAyncOnly) {
            optionMap.put(CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                    new CommandLineOption(
                            CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                            new String[0]));
        }
        //sync only
        if (isSyncOnly) {
            optionMap.put(CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                    new CommandLineOption(
                            CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                            new String[0]));
        }
        //serverside
        if (isServerSide) {
            optionMap.put(CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                    new CommandLineOption(
                            CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                            new String[0]));
            //server xml
            if (isServerXML) {
                optionMap.put(
                        CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION,
                        new CommandLineOption(
                                CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION,
                                new String[0]));
            }
        }
        //test case
        if (isTestCase) {
            optionMap.put(CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                    new CommandLineOption(
                            CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                            new String[0]));
        }
        //package name
        optionMap.put(CommandLineOptionConstants.PACKAGE_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.PACKAGE_OPTION,
                        getStringArray(packageName)));
        //selected language
        optionMap.put(CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                        getStringArray(selectedLanguage)));
        //output location
        optionMap.put(CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                        getStringArray(outputLocation)));

       optionMap.put(CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, new CommandLineOption(
               CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, getStringArray(0+"")));
        return optionMap;
    }
View Full Code Here


    private Map fillOptionMap() {
        Map optionMap = new HashMap();

        optionMap.put(
            CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                getStringArray(WSDLFileName)));

        if (asyncOnly) {
            optionMap.put(
                CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                    new String[0]));
        }
        if (syncOnly) {
            optionMap.put(
                CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                    new String[0]));
        }
        optionMap.put(
            CommandLineOptionConstants.PACKAGE_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.PACKAGE_OPTION,
                getStringArray(packageName)));
        optionMap.put(
            CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                getStringArray(language)));
        optionMap.put(
            CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                getStringArray(output)));
        if (serverSide) {
            optionMap.put(
                CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                    new String[0]));

            if (generateServerXml) {
                optionMap.put(
                    CommandLineOptionConstants
                        .GENERATE_SERVICE_DESCRIPTION_OPTION,
                    new CommandLineOption(
                        CommandLineOptionConstants
                            .GENERATE_SERVICE_DESCRIPTION_OPTION,
                        new String[0]));
            }
        }
        if (testcase) {
            optionMap.put(
                CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                    new String[0]));
        }
        return optionMap;
    }
View Full Code Here

                  String outputLocation
                  )
    {
       Map optionMap = new HashMap();
       //WSDL file name
       optionMap.put(CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION, new CommandLineOption(
          CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION, getStringArray(WSDLURI)));
      
       //Async only
       if (isAyncOnly)
       {
          optionMap.put(CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION, new CommandLineOption(
             CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION, new String[0]));
       }
       //sync only
       if (isSyncOnly)
       {
          optionMap.put(CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION, new CommandLineOption(
             CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION, new String[0]));
       }
       //serverside
       if (isServerSide)
       {
          optionMap.put(CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION, new CommandLineOption(
             CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION, new String[0]));
          //server xml
          if (isServerXML)
          {
             optionMap.put(CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION, new CommandLineOption(
                CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION, new String[0]));
          }
       }
       //test case
       if (isTestCase)
       {
          optionMap.put(CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION, new CommandLineOption(
             CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION, new String[0]));
       }
       //package name
       optionMap.put(CommandLineOptionConstants.PACKAGE_OPTION, new CommandLineOption(
          CommandLineOptionConstants.PACKAGE_OPTION, getStringArray(packageName)));
       //selected language
       optionMap.put(CommandLineOptionConstants.STUB_LANGUAGE_OPTION, new CommandLineOption(
          CommandLineOptionConstants.STUB_LANGUAGE_OPTION, getStringArray(mapLanguagesWithCombo(selectedLanguage))));
       //output location
       optionMap.put(CommandLineOptionConstants.OUTPUT_LOCATION_OPTION, new CommandLineOption(
          CommandLineOptionConstants.OUTPUT_LOCATION_OPTION, getStringArray(outputLocation)));
      
       //data binding constant
       // #########################################################################################
       // This is set to the default NONE option since eclipse cannot load the XBeans thingy
       //###########################################################################################
       optionMap.put(CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, new CommandLineOption(
               CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, getStringArray("none")));
       return optionMap;
    }
View Full Code Here

    private Map fillOptionMap() {
        Map optionMap = new HashMap();

        optionMap.put(
            CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                getStringArray(WSDLFileName)));

        if (asyncOnly) {
            optionMap.put(
                CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                    new String[0]));
        }
        if (syncOnly) {
            optionMap.put(
                CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                    new String[0]));
        }
        optionMap.put(
            CommandLineOptionConstants.PACKAGE_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.PACKAGE_OPTION,
                getStringArray(packageName)));
        optionMap.put(
            CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                getStringArray(language)));
        optionMap.put(
            CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                getStringArray(output)));
        if (serverSide) {
            optionMap.put(
                CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                    new String[0]));

            if (generateServerXml) {
                optionMap.put(
                    CommandLineOptionConstants
                        .GENERATE_SERVICE_DESCRIPTION_OPTION,
                    new CommandLineOption(
                        CommandLineOptionConstants
                            .GENERATE_SERVICE_DESCRIPTION_OPTION,
                        new String[0]));
            }
        }
        if (testcase) {
            optionMap.put(
                CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                    new String[0]));
        }
        return optionMap;
    }
View Full Code Here

     */
    private Map fillOptionMap(String wsdlFileName,String outputLocation) {
        Map optionMap = new HashMap();
        optionMap.put(
                CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                        new String[]{wsdlFileName}));

        //use default sync option - No option is given
        //use default async option - No option is given
        //use default language option - No option is given
        //output location - code_gen_output

        optionMap.put(
                CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                        new String[]{outputLocation}));
        //server side option is on
        optionMap.put(
                CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                        new String[0]));
        // descriptor option is on
        optionMap.put(
                CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION,
                new CommandLineOption(CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION,
                        new String[0]));

        //todo Make this work
        //test case option is on
//        optionMap.put(
View Full Code Here

                  String outputLocation
                  )
    {
       Map optionMap = new HashMap();
       //WSDL file name
       optionMap.put(CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION, new CommandLineOption(
          CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION, getStringArray(WSDLURI)));
      
       //Async only
       if (isAyncOnly)
       {
          optionMap.put(CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION, new CommandLineOption(
             CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION, new String[0]));
       }
       //sync only
       if (isSyncOnly)
       {
          optionMap.put(CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION, new CommandLineOption(
             CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION, new String[0]));
       }
       //serverside
       if (isServerSide)
       {
          optionMap.put(CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION, new CommandLineOption(
             CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION, new String[0]));
          //server xml
          if (isServerXML)
          {
             optionMap.put(CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION, new CommandLineOption(
                CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION, new String[0]));
          }
       }
       //test case
       if (isTestCase)
       {
          optionMap.put(CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION, new CommandLineOption(
             CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION, new String[0]));
       }
       //package name
       optionMap.put(CommandLineOptionConstants.PACKAGE_OPTION, new CommandLineOption(
          CommandLineOptionConstants.PACKAGE_OPTION, getStringArray(packageName)));
       //selected language
       optionMap.put(CommandLineOptionConstants.STUB_LANGUAGE_OPTION, new CommandLineOption(
          CommandLineOptionConstants.STUB_LANGUAGE_OPTION, getStringArray(mapLanguagesWithCombo(selectedLanguage))));
       //output location
       optionMap.put(CommandLineOptionConstants.OUTPUT_LOCATION_OPTION, new CommandLineOption(
          CommandLineOptionConstants.OUTPUT_LOCATION_OPTION, getStringArray(outputLocation)));
      
       //data binding constant
       // #########################################################################################
       // This is set to the default NONE option since eclipse cannot load the XBeans thingy
       //###########################################################################################
       optionMap.put(CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, new CommandLineOption(
               CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, getStringArray("none")));
       return optionMap;
    }
View Full Code Here

     */
    private Map fillOptionMap() {
        Map optionMap = new HashMap();

        optionMap.put(CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                        getStringArray(WSDLFileName)));

        if (asyncOnly) {
            optionMap
                    .put(
                            CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                            new CommandLineOption(
                                    CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                                    new String[0]));
        }
        if (syncOnly) {
            optionMap
                    .put(
                            CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                            new CommandLineOption(
                                    CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                                    new String[0]));
        }
        optionMap.put(CommandLineOptionConstants.PACKAGE_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.PACKAGE_OPTION,
                        getStringArray(packageName)));
        optionMap.put(CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                        getStringArray(language)));
        optionMap.put(CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                new CommandLineOption(
                        CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                        getStringArray(output)));
        if (serverSide) {
            optionMap.put(CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                    new CommandLineOption(
                            CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                            new String[0]));

            if (generateServerXml) {
                optionMap.put(
                        CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION,
                        new CommandLineOption(
                                CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION,
                                new String[0]));
            }
        }
        if (testcase){
            optionMap
                    .put(
                            CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                            new CommandLineOption(
                                    CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                                    new String[0]));
        }
        //System.out.println(page3.getOutputLocation());
        return optionMap;
View Full Code Here

  }

  public void engage() {
    Map allOptions = this.configuration.getParser().getAllOptions();
        CommandLineOption packageOption = (CommandLineOption)(allOptions.get(CommandLineOptionConstants.PACKAGE_OPTION));
        String packageName = packageOption==null?null:packageOption.getOptionValue();

    if (packageName == null) {
      WSDLBinding binding = configuration.getWom().getBinding(AxisBindingBuilder.AXIS_BINDING_QNAME);
      String temp = binding.getBoundInterface().getName().getNamespaceURI();
      packageName = URLProcessor.getNameSpaceFromURL(temp);
View Full Code Here

                  String outputLocation
                  )
    {
       Map optionMap = new HashMap();
       //WSDL file name
       optionMap.put(CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION, new CommandLineOption(
          CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION, getStringArray(WSDLFileName)));
      
       //Async only
       if (isAyncOnly)
       {
          optionMap.put(CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION, new CommandLineOption(
             CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION, new String[0]));
       }
       //sync only
       if (isSyncOnly)
       {
          optionMap.put(CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION, new CommandLineOption(
             CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION, new String[0]));
       }
       //serverside
       if (isServerSide)
       {
          optionMap.put(CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION, new CommandLineOption(
             CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION, new String[0]));
          //server xml
          if (isServerXML)
          {
             optionMap.put(CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION, new CommandLineOption(
                CommandLineOptionConstants.GENERATE_SERVICE_DESCRIPTION_OPTION, new String[0]));
          }
       }
       //test case
       if (isTestCase)
       {
          optionMap.put(CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION, new CommandLineOption(
             CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION, new String[0]));
       }
       //package name
       optionMap.put(CommandLineOptionConstants.PACKAGE_OPTION, new CommandLineOption(
          CommandLineOptionConstants.PACKAGE_OPTION, getStringArray(packageName)));
       //selected language
       optionMap.put(CommandLineOptionConstants.STUB_LANGUAGE_OPTION, new CommandLineOption(
          CommandLineOptionConstants.STUB_LANGUAGE_OPTION, getStringArray(mapLanguagesWithCombo(selectedLanguage))));
       //output location
       optionMap.put(CommandLineOptionConstants.OUTPUT_LOCATION_OPTION, new CommandLineOption(
          CommandLineOptionConstants.OUTPUT_LOCATION_OPTION, getStringArray(outputLocation)));
      
       //data binding constant
       // #########################################################################################
       // This is set to the default NONE option since eclipse cannot load the XBeans thingy
       //###########################################################################################
       optionMap.put(CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, new CommandLineOption(
               CommandLineOptionConstants.DATA_BINDING_TYPE_OPTION, getStringArray(0+"")));
       return optionMap;
    }
View Full Code Here

    private Map fillOptionMap() {
        Map optionMap = new HashMap();

        optionMap.put(
            CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.WSDL_LOCATION_URI_OPTION,
                getStringArray(WSDLFileName)));

        if (asyncOnly) {
            optionMap.put(
                CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.CODEGEN_ASYNC_ONLY_OPTION,
                    new String[0]));
        }
        if (syncOnly) {
            optionMap.put(
                CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.CODEGEN_SYNC_ONLY_OPTION,
                    new String[0]));
        }
        optionMap.put(
            CommandLineOptionConstants.PACKAGE_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.PACKAGE_OPTION,
                getStringArray(packageName)));
        optionMap.put(
            CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.STUB_LANGUAGE_OPTION,
                getStringArray(language)));
        optionMap.put(
            CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
            new CommandLineOption(
                CommandLineOptionConstants.OUTPUT_LOCATION_OPTION,
                getStringArray(output)));
        if (serverSide) {
            optionMap.put(
                CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.SERVER_SIDE_CODE_OPTION,
                    new String[0]));

            if (generateServerXml) {
                optionMap.put(
                    CommandLineOptionConstants
                        .GENERATE_SERVICE_DESCRIPTION_OPTION,
                    new CommandLineOption(
                        CommandLineOptionConstants
                            .GENERATE_SERVICE_DESCRIPTION_OPTION,
                        new String[0]));
            }
        }
        if (testcase) {
            optionMap.put(
                CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                new CommandLineOption(
                    CommandLineOptionConstants.GENERATE_TEST_CASE_OPTION,
                    new String[0]));
        }
        //System.out.println(page3.getOutputLocation());
        return optionMap;
View Full Code Here

TOP

Related Classes of org.apache.axis2.wsdl.codegen.CommandLineOption

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.