
package org.cagrid.index.wsrf.stubs;

/**
 * Please modify this class to meet your needs
 * This class is not complete
 */

import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
import javax.xml.namespace.QName;
import org.cagrid.index.wsrf.service.BigIndexEntryService;
import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebResult;
import javax.jws.WebService;
import javax.jws.soap.SOAPBinding;
import javax.xml.bind.annotation.XmlSeeAlso;
import javax.xml.ws.RequestWrapper;
import javax.xml.ws.ResponseWrapper;

/**
 * This class was generated by Apache CXF 2.6.3
 * 2014-04-10T21:59:25.524-04:00
 * Generated source version: 2.6.3
 * 
 */
public final class BigIndexEntryPortType_BigIndexEntryPortTypePort_Client {

    private static final QName SERVICE_NAME = new QName("http://mds.globus.org/bigindex/2008/11/24/service", "BigIndexEntryService");

    private BigIndexEntryPortType_BigIndexEntryPortTypePort_Client() {
    }

    public static void main(String args[]) throws java.lang.Exception {
        URL wsdlURL = BigIndexEntryService.WSDL_LOCATION;
        if (args.length > 0 && args[0] != null && !"".equals(args[0])) { 
            File wsdlFile = new File(args[0]);
            try {
                if (wsdlFile.exists()) {
                    wsdlURL = wsdlFile.toURI().toURL();
                } else {
                    wsdlURL = new URL(args[0]);
                }
            } catch (MalformedURLException e) {
                e.printStackTrace();
            }
        }
      
        BigIndexEntryService ss = new BigIndexEntryService(wsdlURL, SERVICE_NAME);
        BigIndexEntryPortType port = ss.getBigIndexEntryPortTypePort();  
        
        {
        System.out.println("Invoking getMultipleResourceProperties...");
        org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01.GetMultipleResourceProperties _getMultipleResourceProperties_getMultipleResourcePropertiesRequest = null;
        try {
            org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01.GetMultipleResourcePropertiesResponse _getMultipleResourceProperties__return = port.getMultipleResourceProperties(_getMultipleResourceProperties_getMultipleResourcePropertiesRequest);
            System.out.println("getMultipleResourceProperties.result=" + _getMultipleResourceProperties__return);

        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.ResourceUnknownFault e) { 
            System.out.println("Expected exception: ResourceUnknownFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.InvalidResourcePropertyQNameFault e) { 
            System.out.println("Expected exception: InvalidResourcePropertyQNameFault has occurred.");
            System.out.println(e.toString());
        }
            }
        {
        System.out.println("Invoking getResourceProperty...");
        javax.xml.namespace.QName _getResourceProperty_getResourcePropertyRequest = new javax.xml.namespace.QName("", "");
        try {
            org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01.GetResourcePropertyResponse _getResourceProperty__return = port.getResourceProperty(_getResourceProperty_getResourcePropertyRequest);
            System.out.println("getResourceProperty.result=" + _getResourceProperty__return);

        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.ResourceUnknownFault e) { 
            System.out.println("Expected exception: ResourceUnknownFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.InvalidResourcePropertyQNameFault e) { 
            System.out.println("Expected exception: InvalidResourcePropertyQNameFault has occurred.");
            System.out.println(e.toString());
        }
            }
        {
        System.out.println("Invoking queryResourceProperties...");
        org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01.QueryResourceProperties _queryResourceProperties_queryResourcePropertiesRequest = null;
        try {
            org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01.QueryResourcePropertiesResponse _queryResourceProperties__return = port.queryResourceProperties(_queryResourceProperties_queryResourcePropertiesRequest);
            System.out.println("queryResourceProperties.result=" + _queryResourceProperties__return);

        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.UnknownQueryExpressionDialectFault e) { 
            System.out.println("Expected exception: UnknownQueryExpressionDialectFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.InvalidQueryExpressionFault e) { 
            System.out.println("Expected exception: InvalidQueryExpressionFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.QueryEvaluationErrorFault e) { 
            System.out.println("Expected exception: QueryEvaluationErrorFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.ResourceUnknownFault e) { 
            System.out.println("Expected exception: ResourceUnknownFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourceproperties_1_2_draft_01_wsdl.InvalidResourcePropertyQNameFault e) { 
            System.out.println("Expected exception: InvalidResourcePropertyQNameFault has occurred.");
            System.out.println(e.toString());
        }
            }
        {
        System.out.println("Invoking setTerminationTime...");
        java.util.Calendar _setTerminationTime_requestedTerminationTime = null;
        javax.xml.ws.Holder<java.util.Calendar> _setTerminationTime_newTerminationTime = new javax.xml.ws.Holder<java.util.Calendar>();
        javax.xml.ws.Holder<java.util.Calendar> _setTerminationTime_currentTime = new javax.xml.ws.Holder<java.util.Calendar>();
        try {
            port.setTerminationTime(_setTerminationTime_requestedTerminationTime, _setTerminationTime_newTerminationTime, _setTerminationTime_currentTime);

            System.out.println("setTerminationTime._setTerminationTime_newTerminationTime=" + _setTerminationTime_newTerminationTime.value);
            System.out.println("setTerminationTime._setTerminationTime_currentTime=" + _setTerminationTime_currentTime.value);
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourcelifetime_1_2_draft_01_wsdl.TerminationTimeChangeRejectedFault e) { 
            System.out.println("Expected exception: TerminationTimeChangeRejectedFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourcelifetime_1_2_draft_01_wsdl.ResourceUnknownFault e) { 
            System.out.println("Expected exception: ResourceUnknownFault has occurred.");
            System.out.println(e.toString());
        } catch (org.oasis_open.docs.wsrf._2004._06.wsrf_ws_resourcelifetime_1_2_draft_01_wsdl.UnableToSetTerminationTimeFault e) { 
            System.out.println("Expected exception: UnableToSetTerminationTimeFault has occurred.");
            System.out.println(e.toString());
        }
            }

        System.exit(0);
    }

}
