Package javax.xml.rpc

Examples of javax.xml.rpc.Service


    * Get a handle to the MeridioMetaCarta Web Service
    *================================================================*/
    if (meridioManifoldCFWSUrl != null)
    {
      MetaCartaLocator meridioMCWS = new MetaCartaLocator(engineConfiguration);
      Service McWsService = null;
      MetaCartaSoapStub meridioMetaCartaWebService = new MetaCartaSoapStub(meridioManifoldCFWSUrl, McWsService);

      meridioMetaCartaWebService.setPortName(meridioMCWS.getMetaCartaSoapWSDDServiceName());
      meridioMetaCartaWebService.setUsername(userName);
      meridioMetaCartaWebService.setPassword(password);
View Full Code Here


            Document doc = XMLUtils.newDocument(new URL(url).toString());
            WSDLReader reader = WSDLFactory.newInstance().newWSDLReader();
            reader.setFeature("javax.wsdl.verbose", false);
            wsdl = reader.readWSDL(null, doc);

            Service service = new org.apache.axis.client.
                Service(new URL(url), getServiceQName());

            call = (org.apache.axis.client.Call)service.
                createCall(getPortQName(wsdl), OPQN);
           
            call.registerTypeMapping(List.class,
                                     LISTQN,
                                     BeanSerializerFactory.class,
View Full Code Here

    * Get a handle to the MeridioMetaCarta Web Service
    *================================================================*/
    if (meridioManifoldCFWSUrl != null)
    {
      MetaCartaLocator meridioMCWS = new MetaCartaLocator(engineConfiguration);
      Service McWsService = null;
      MetaCartaSoapStub meridioMetaCartaWebService = new MetaCartaSoapStub(meridioManifoldCFWSUrl, McWsService);

      meridioMetaCartaWebService.setPortName(meridioMCWS.getMetaCartaSoapWSDDServiceName());
      meridioMetaCartaWebService.setUsername(userName);
      meridioMetaCartaWebService.setPassword(password);
View Full Code Here

        //location of wsdl file
        String wsdlLocation = "http://" + thisHost + ":" + thisPort + "/axis/services/AddressBookNoImplSEI?WSDL";
        URL orgWsdlUrl = new URL(wsdlLocation);

        ServiceFactory serviceFactory = ServiceFactory.newInstance();
        Service addressBookService =
                serviceFactory.createService(orgWsdlUrl,
                        new QName(nameSpaceUri, serviceName));

        // Add the typemapping entries
        TypeMappingRegistry registry = addressBookService.getTypeMappingRegistry();
        TypeMapping map = registry.getDefaultTypeMapping();
        map.register(test.wsdl.addrNoImplSEI.Address.class,
                new QName("urn:AddrNoImplSEI", "Address"),
                new org.apache.axis.encoding.ser.BeanSerializerFactory(test.wsdl.addrNoImplSEI.Address.class, new QName("urn:AddrNoImplSEI", "Address")),
                new org.apache.axis.encoding.ser.BeanDeserializerFactory(test.wsdl.addrNoImplSEI.Address.class, new QName("urn:AddrNoImplSEI", "Address")));
        map.register(test.wsdl.addrNoImplSEI._Phone.class,
                new QName("urn:AddrNoImplSEI", "_Phone"),
                new org.apache.axis.encoding.ser.BeanSerializerFactory(test.wsdl.addrNoImplSEI._Phone.class, new QName("urn:AddrNoImplSEI", "_Phone")),
                new org.apache.axis.encoding.ser.BeanDeserializerFactory(test.wsdl.addrNoImplSEI._Phone.class, new QName("urn:AddrNoImplSEI", "_Phone")));
        map.register(test.wsdl.addrNoImplSEI.StateType.class,
                new QName("urn:AddrNoImplSEI", "StateType"),
                new org.apache.axis.encoding.ser.EnumSerializerFactory(test.wsdl.addrNoImplSEI.StateType.class, new QName("urn:AddrNoImplSEI", "StateType")),
                new org.apache.axis.encoding.ser.EnumDeserializerFactory(test.wsdl.addrNoImplSEI.StateType.class, new QName("urn:AddrNoImplSEI", "StateType")));

        AddressBookNoImplSEI myProxy = (AddressBookNoImplSEI) addressBookService.getPort(AddressBookNoImplSEI.class);
       
        // Set session on.
        ((Stub) myProxy)._setProperty(Stub.SESSION_MAINTAIN_PROPERTY, Boolean.TRUE);

        String name1;
View Full Code Here

    public Object getObject()
    {
        try
        {
            final Service service = ( wsdlUrl == null ?
                                      ServiceFactory.newInstance().createService( getServiceQName() ) : ServiceFactory
                    .newInstance().createService( new URL( wsdlUrl ), getServiceQName() ) );
            final QName portQName = getPortQName();
            return portQName == null ? service.getPort( serviceInterface ) :
                   service.getPort( portQName, serviceInterface );
        }
        catch( ServiceException e )
        {
            throw new ObjectProviderException( "Unable to create JAX-RPC service proxy.", e );
        }
View Full Code Here

        super(name);
    }

    private TypeTest getProxyWithWSDL() {
        try {
            Service service = ServiceFactory.newInstance().createService(
                new URL("file", "", "test/wsdl/types/ComprehensiveTypes.wsdl"),
                new QName("urn:comprehensive-service.types.wsdl.test",
                        "TypeTestService"));
            return (TypeTest) service.getPort(
                new QName("", "TypeTest"), TypeTest.class);
        }
        catch (MalformedURLException mue) {
            throw new AssertionFailedError(
                    "MalformedURLException caught: " + mue);
View Full Code Here

        }
    } // getProxyWithWSDL

    private TypeTest getProxy() {
        try {
            Service service = ServiceFactory.newInstance().createService(null);
            Stub binding = (Stub) service.getPort(TypeTest.class);
            binding._setProperty(Stub.ENDPOINT_ADDRESS_PROPERTY,
                    "http://localhost:8080/axis/services/TypeTest");
            throw new AssertionFailedError("Should not get a binding");
        }
        catch (ServiceException jre) {
View Full Code Here

            fail("unexpected failure:  " + se);
        }
    } // testDoublePortService2

    public void testGetPorts() {
        Service service = null;
        try {
            service = new EmptyLocator();
            verifyNumberOfPorts("Empty", service.getPorts(), 0);
        }
        catch (ServiceException se) {
            fail("EmptyLocator.getPorts() should not have failed:  " + se);
        }
        try {
            service = new ServiceALocator();
            verifyNumberOfPorts("ServiceA", service.getPorts(), 3);
        }
        catch (ServiceException se) {
            fail("ServiceA.getPorts() should not have failed:  " + se);
        }
        try {
            service = new ServiceBLocator();
            verifyNumberOfPorts("ServiceB", service.getPorts(), 3);
        }
        catch (ServiceException se) {
            fail("ServiceB.getPorts() should not have failed:  " + se);
        }
        try {
            service = new ServiceCLocator();
            verifyNumberOfPorts("ServiceC", service.getPorts(), 3);
        }
        catch (ServiceException se) {
            fail("ServiceC.getPorts() should not have failed:  " + se);
        }
    } // testGetPorts
View Full Code Here

    * Get a handle to the MeridioMetaCarta Web Service
    *================================================================*/
    if (meridioManifoldCFWSUrl != null)
    {
      MetaCartaLocator meridioMCWS = new MetaCartaLocator(engineConfiguration);
      Service McWsService = null;
      MetaCartaSoapStub meridioMetaCartaWebService = new MetaCartaSoapStub(meridioManifoldCFWSUrl, McWsService);

      meridioMetaCartaWebService.setPortName(meridioMCWS.getMetaCartaSoapWSDDServiceName());
      meridioMetaCartaWebService.setUsername(userName);
      meridioMetaCartaWebService.setPassword(password);
View Full Code Here

        super(name);
    }

    private TypeTest getProxyWithWSDL() {
        try {
            Service service = ServiceFactory.newInstance().createService(
                new URL("file", "", "test/wsdl/types/ComprehensiveTypes.wsdl"),
                new QName("urn:comprehensive-service.types.wsdl.test",
                        "TypeTestService"));
            return (TypeTest) service.getPort(
                new QName("", "TypeTest"), TypeTest.class);
        }
        catch (MalformedURLException mue) {
            throw new AssertionFailedError(
                    "MalformedURLException caught: " + mue);
View Full Code Here

TOP

Related Classes of javax.xml.rpc.Service

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.