Package org.apache.cxf.tools.corba.processors.idl

Examples of org.apache.cxf.tools.corba.processors.idl.IDLToWSDLProcessor


            ProcessorEnvironment env = new ProcessorEnvironment();
            Map<String, Object> cfg = new HashMap<String, Object>();
            cfg.put(ToolCorbaConstants.CFG_IDLFILE, new File(idl.toURI()).getAbsolutePath());
            cfg.put(ToolCorbaConstants.CFG_WSDL_ENCODING, "UTF-16");
            env.setParameters(cfg);
            IDLToWSDLProcessor processor = new IDLToWSDLProcessor();
            processor.setEnvironment(env);
            Writer out = processor.getOutputWriter("Enum.wsdl", ".");                  
                                  
            if (out instanceof OutputStreamWriter) {
                OutputStreamWriter writer = (OutputStreamWriter)out;
                assertEquals("Encoding should be UTF-16", writer.getEncoding(),
                             "UTF-16");                
View Full Code Here


        arrayKeys.add(ToolCorbaConstants.CFG_INCLUDEDIR);
        return arrayKeys;
    }

    public void execute(boolean exitOnFinish) {
        IDLToWSDLProcessor idlProcessor = new IDLToWSDLProcessor();
        ProcessorEnvironment env = null;

        try {
            super.execute(exitOnFinish);
            if (!hasInfoOption()) {
                env = new ProcessorEnvironment();
                env.setParameters(getParametersMap(getArrayKeys()));
                if (isVerboseOn()) {
                    env.put(ToolConstants.CFG_VERBOSE, Boolean.TRUE);
                }
                env.put(ToolConstants.CFG_CMD_ARG, args);               
                initialise(env);
                validate(env);
                idlProcessor.setEnvironment(env);
                idlProcessor.process();
            }
        } catch (ToolException ex) {
            err.println("Error : " + ex.getMessage());
            if (ex.getCause() instanceof BadUsageException) {
                printUsageException(TOOL_NAME, (BadUsageException)ex.getCause());
View Full Code Here

    private Set getArrayKeys() {
        return new HashSet<String>();
    }

    public void execute(boolean exitOnFinish) {
        IDLToWSDLProcessor idlProcessor = new IDLToWSDLProcessor();
        ProcessorEnvironment env = null;

        try {
            super.execute(exitOnFinish);
            if (!hasInfoOption()) {
                env = new ProcessorEnvironment();
                env.setParameters(getParametersMap(getArrayKeys()));
                if (isVerboseOn()) {
                    env.put(ToolConstants.CFG_VERBOSE, Boolean.TRUE);
                }
                env.put(ToolConstants.CFG_CMD_ARG, args);               
                initialise(env);
                validate(env);
                idlProcessor.setEnvironment(env);
                idlProcessor.process();
            }
        } catch (ToolException ex) {
            System.err.println("Error : " + ex.getMessage());
            if (ex.getCause() instanceof BadUsageException) {
                printUsageException(TOOL_NAME, (BadUsageException)ex.getCause());
View Full Code Here

TOP

Related Classes of org.apache.cxf.tools.corba.processors.idl.IDLToWSDLProcessor

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.