Package org.apache.axis.wsdl.gen

Examples of org.apache.axis.wsdl.gen.Parser


            throws ServiceException {
        this.serviceName = serviceName;
        this.wsdlLocation = wsdlLocation;
        engine = getAxisClient();
        // Start by reading in the WSDL using Parser
        Parser parser = null;
        if (cachingWSDL &&
                (parser = (Parser) cachedWSDL.get(wsdlLocation)) != null) {
            initService(parser, serviceName);
        } else {
            initService(wsdlLocation, serviceName);
View Full Code Here


     */
    private void initService(String url, QName serviceName)
            throws ServiceException {
        try {
            // Start by reading in the WSDL using Parser
            Parser parser = new Parser();
            parser.run(url);

            if (cachingWSDL && this.wsdlLocation != null)
                cachedWSDL.put(url, parser);

            initService(parser, serviceName);
View Full Code Here

     */
    private void initService(String context, Document doc, QName serviceName)
            throws ServiceException {
        try {
            // Start by reading in the WSDL using Parser
            Parser parser = new Parser();
            parser.run(context, doc);

            initService(parser, serviceName);
        } catch (Exception exp) {
            throw new ServiceException(
                    Messages.getMessage("wsdlError00", "" + "", "\n" + exp));
View Full Code Here

    public WSDL2Ws(CLArgParser cmdLineArgs) throws WrapperFault
    {
        try
        {
            Parser wsdlParser = new Parser();
            // set timeout
            String timeout = cmdLineArgs.getOptionBykey("t");
            if (timeout != null)
                wsdlParser.setTimeout(Long.parseLong(timeout));

            //get the commandline arguments
            String wsdlfile = cmdLineArgs.getArgument(0);
            wsdlParser.run(wsdlfile);

            symbolTable = wsdlParser.getSymbolTable();

            //get the target namespace
            targetNameSpaceOfWSDL =
                symbolTable.getDefinition().getTargetNamespace();
        }
View Full Code Here

    protected Service createService(MuleEvent event) throws Exception
    {
        String wsdlUrl = endpoint.getEndpointURI().getAddress();
        // Parse the wsdl
        Parser parser = new Parser();
        if (endpoint.getEndpointURI().getUserInfo() != null)
        {
            parser.setUsername(endpoint.getEndpointURI().getUser());
            parser.setPassword(endpoint.getEndpointURI().getPassword());
        }
        parser.run(wsdlUrl);
        // Retrieves the defined services
        Map<?, ?> map = parser.getSymbolTable().getHashMap();
        List<Object> entries = new ArrayList<Object>();
        for (Iterator<?> it = map.entrySet().iterator(); it.hasNext();)
        {
            Map.Entry<?, ?> entry = (Map.Entry<?, ?>)it.next();
            Vector<?> v = (Vector<?>)entry.getValue();
            for (Iterator<?> it2 = v.iterator(); it2.hasNext();)
            {
                SymTabEntry e = (SymTabEntry)it2.next();
                if (ServiceEntry.class.isInstance(e))
                {
                    entries.add(entry.getKey());
                }
            }
        }
        // Currently, only one service should be defined
        if (entries.size() != 1)
        {
            throw new Exception("Need one and only one service entry, found " + entries.size());
        }
        // Create the axis service
        Service axisService = new Service(parser, (QName)entries.get(0));

        axisService.setEngineConfiguration(clientConfig);
        axisService.setEngine(new AxisClient(clientConfig));

        // Really the Axis Client service should set this stuff
        event.getMessage().setOutboundProperty(SoapConstants.METHOD_NAMESPACE_PROPERTY,
                                               parser.getCurrentDefinition().getTargetNamespace());
        // Todo how can we autogenerate the named params from the WSDL?
        return axisService;
    }
View Full Code Here

    public WSDL2Ws(CLArgParser cmdLineArgs) throws WrapperFault
    {
        try
        {
            Parser wsdlParser = new Parser();
            //get the commandline arguments
            String wsdlfile = cmdLineArgs.getArgument(0);
            wsdlParser.run(wsdlfile);

            symbolTable = wsdlParser.getSymbolTable();

            //get the target namespace
            targetNameSpaceOfWSDL =
                symbolTable.getDefinition().getTargetNamespace();
        }
View Full Code Here

     */
    public Service(URL wsdlDoc, QName serviceName) throws ServiceException {
        this.serviceName = serviceName;
        engine = getAxisClient();
        wsdlLocation = wsdlDoc.toString();
        Parser parser = null ;

        if ( cachingWSDL &&
             (parser = (Parser) cachedWSDL.get(this.wsdlLocation.toString())) != null ){
          initService( parser, serviceName );
        }
View Full Code Here

                           throws ServiceException {
        this.serviceName = serviceName;
        this.wsdlLocation = wsdlLocation;
        engine = getAxisClient();
        // Start by reading in the WSDL using Parser
        Parser parser = null ;
        if ( cachingWSDL &&
             (parser = (Parser) cachedWSDL.get(wsdlLocation)) != null ) {
          initService( parser, serviceName );
        }
        else {
View Full Code Here

     */
    private void initService(Document doc, QName serviceName)
            throws ServiceException {
        try {
            // Start by reading in the WSDL using Parser
            Parser parser = new Parser();
            parser.run(this.wsdlLocation.toString());

            if ( cachingWSDL && this.wsdlLocation != null )
              cachedWSDL.put( this.wsdlLocation.toString(), parser );

            initService( parser, serviceName );
View Full Code Here

     */
    public Service(URL wsdlDoc, QName serviceName) throws ServiceException {
        this.serviceName = serviceName;
        engine = getAxisClient();
        wsdlLocation = wsdlDoc.toString();
        Parser parser = null;

        if (cachingWSDL &&
                (parser = (Parser) cachedWSDL.get(this.wsdlLocation.toString())) != null) {
            initService(parser, serviceName);
        } else {
View Full Code Here

TOP

Related Classes of org.apache.axis.wsdl.gen.Parser

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.