Package javax.xml.ws.handler

Examples of javax.xml.ws.handler.PortInfo


        ServiceDescription serviceDesc = DescriptionFactory.createServiceDescription(RoleBasedMUServiceImpl.class);
        HandlerResolverImpl handlerResolver1 = new HandlerResolverImpl(serviceDesc);
        HandlerResolverImpl handlerResolver2 = new HandlerResolverImpl(serviceDesc);

        EndpointDescription epDesc = serviceDesc.getEndpointDescriptions()[0];
        PortInfo portInfo = epDesc.getPortInfo();
       
        List<String> roles1 = handlerResolver1.getRoles(portInfo);
        List<String> roles2 = handlerResolver2.getRoles(portInfo);
        assertNotNull(roles1);
        assertNotNull(roles2);
View Full Code Here


        ServiceDescription serviceDesc = DescriptionFactory.createServiceDescription(RoleBasedMUServiceImpl.class);
        HandlerResolverImpl handlerResolver1 = new HandlerResolverImpl(serviceDesc, "sd1");
        HandlerResolverImpl handlerResolver2 = new HandlerResolverImpl(serviceDesc, "sd2");

        EndpointDescription epDesc = serviceDesc.getEndpointDescriptions()[0];
        PortInfo portInfo = epDesc.getPortInfo();
       
        List<String> roles1 = handlerResolver1.getRoles(portInfo);
        List<String> roles2 = handlerResolver2.getRoles(portInfo);
        assertNotNull(roles1);
        assertNotNull(roles2);
View Full Code Here

        String addedRole = soapRoles.get(0).getValue();
        assertEquals(roleHandlerAdded, addedRole);
       
        // Now verify the role information in the handler config file correctly affects the
        // roles played returned from the Resolver
        PortInfo portInfo = epDesc.getPortInfo();

        List<String> handlerRoles = handlerResolver.getRoles(portInfo);
        assertNotNull(handlerRoles);
        assertEquals(1, handlerRoles.size());
        assertEquals(roleHandlerAdded, handlerRoles.get(0));
View Full Code Here

        assertTrue(checkRoles.contains(roleHandlerAdded));
        assertTrue(checkRoles.contains(roleHandlerAdded2));

        // Now verify the role information in the handler config file correctly affects the
        // roles played returned from the Resolver
        PortInfo portInfo = epDesc.getPortInfo();

        List<String> handlerRoles = handlerResolver.getRoles(portInfo);
        assertNotNull(handlerRoles);
        assertEquals(2, handlerRoles.size());
        ArrayList<String> checkResolverRoles = new ArrayList<String>();
View Full Code Here

            if (eic.getHandlers() == null) {
                if (log.isDebugEnabled()) {
                    log.debug("No handlers found on the InvocationContext, initializing handler list.");
                }
                HandlerResolverImpl hri = new HandlerResolverImpl(endpointDesc.getServiceDescription());
                PortInfo portInfo = endpointDesc.getPortInfo();
                eic.setHandlers(hri.getHandlerChain(portInfo));
                handlerRoles = hri.getRoles(portInfo);
            }
           
            //  Get the service instance.  This will run the @PostConstruct code.
View Full Code Here

    public void testHandlerResolver() {
        String path = "/configuration/handlers/handler.xml";
        File file = new File(testResourceDir, path);
        HandlerResolver resolver = new HandlerResolverImpl(file);
        PortInfo pi = new DummyPortInfo();
        List<Handler> list = resolver.getHandlerChain(pi);
        assertEquals(2, list.size());
    }
View Full Code Here

     * @return True if they match, and false if they do not or
     * if the object passed in is not a PortInfo.
     */
    public boolean equals(Object obj) {
        if (obj instanceof PortInfo) {
            PortInfo info = (PortInfo) obj;
            if (bindingId.toString().equals(info.getBindingID()) &&
                portName.equals(info.getPortName()) &&
                serviceName.equals(info.getServiceName())) {
                return true;
            }
        }
        return false;
    }
View Full Code Here

      return (executor != null ? executor.handleFault(msgContext, ex) : true);
   }

   private List<Handler> getHandlerChain(EndpointMetaData epMetaData, HandlerType type)
   {
      PortInfo info = getPortInfo(epMetaData);
      return resolver.getHandlerChain(info, type);
   }
View Full Code Here

   private PortInfo getPortInfo(EndpointMetaData epMetaData)
   {
      QName serviceName = epMetaData.getServiceMetaData().getServiceName();
      QName portName = epMetaData.getPortName();
      String bindingId = epMetaData.getBindingId();
      PortInfo info = new PortInfoImpl(serviceName, portName, bindingId);
      return info;
   }
View Full Code Here

    */
   private void initBindingHandlerChain(boolean clearExistingHandlers)
   {
      BindingExt binding = (BindingExt)getBindingProvider().getBinding();

    PortInfo portInfo = getPortInfo(epMetaData);

    if (handlerResolver != null)
    {

      boolean jbossHandlerResolver = handlerResolver instanceof HandlerResolverImpl;
View Full Code Here

TOP

Related Classes of javax.xml.ws.handler.PortInfo

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.