KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > mule > providers > soap > axis > extensions > WSDDFileProvider


1 /*
2  * $Id: WSDDFileProvider.java 3798 2006-11-04 04:07:14Z aperepel $
3  * --------------------------------------------------------------------------------------
4  * Copyright (c) MuleSource, Inc. All rights reserved. http://www.mulesource.com
5  *
6  * The software in this package is published under the terms of the MuleSource MPL
7  * license, a copy of which has been included with this distribution in the
8  * LICENSE.txt file.
9  */

10
11 package org.mule.providers.soap.axis.extensions;
12
13 import org.apache.axis.ConfigurationException;
14 import org.apache.axis.configuration.FileProvider;
15 import org.apache.axis.handlers.soap.SOAPService;
16
17 import javax.xml.namespace.QName JavaDoc;
18
19 /**
20  * Override the File provider to stop exceptions being thrown in Axis if the service
21  * does not exist. Mule adds services after the WSDD has been loaded.
22  *
23  * @author <a HREF="mailto:ross.mason@symphonysoft.com">Ross Mason</a>
24  * @version $Revision: 3798 $
25  */

26 public class WSDDFileProvider extends FileProvider
27 {
28     /**
29      * Constructor which accesses a file in the current directory of the engine or at
30      * an absolute path.
31      */

32     public WSDDFileProvider(String JavaDoc filename)
33     {
34         super(filename);
35     }
36
37     /**
38      * Constructor which accesses a file relative to a specific base path.
39      */

40     public WSDDFileProvider(String JavaDoc basepath, String JavaDoc filename) throws ConfigurationException
41     {
42         super(basepath, filename);
43     }
44
45     /**
46      * retrieve an instance of the named service
47      *
48      * @param qname the name of the service
49      * @return the service object or null if it doesn't exist
50      * @throws org.apache.axis.ConfigurationException
51      */

52     public SOAPService getService(QName JavaDoc qname) throws ConfigurationException
53     {
54         return getDeployment().getService(qname);
55     }
56 }
57
Popular Tags