Package org.jboss.ws.core

Examples of org.jboss.ws.core.MessageAbstraction


   public SOAPMessage callOneWay(SOAPMessage reqMessage, Object endpoint) throws SOAPException
   {
      if (reqMessage == null)
         throw new IllegalArgumentException("Given SOAPMessage cannot be null");

      MessageAbstraction resMessage = callInternal((SOAPMessageImpl)reqMessage, endpoint, true);
      return (SOAPMessage)resMessage;
   }
View Full Code Here


   private MessageAbstraction callInternal(SOAPMessage reqMessage, Object endpoint, boolean oneway) throws SOAPException
   {
      try
      {
         MessageAbstraction resMessage = remotingConnection.invoke((SOAPMessageImpl)reqMessage, endpoint, oneway);
         return resMessage;
      }   
      catch (Exception ex)
      {
         Throwable cause = ex.getCause();
View Full Code Here

      log.debug("callResponseHandlerChain: " + type);
      HandlerChainExecutor executor =  getExecutor(type);
      MessageContext msgContext = (MessageContext)MessageContextAssociation.peekMessageContext();
      boolean status = (executor != null ? executor.handleMessage(msgContext) : true);

      MessageAbstraction msg = ((CommonMessageContext)msgContext).getMessageAbstraction();
      if (type == HandlerType.ENDPOINT && (msg instanceof SOAPMessage))
         XOPContext.visitAndRestoreXOPData();
     
      return status;
   }
View Full Code Here

      log.debug("callFaultHandlerChain: " + type);
      HandlerChainExecutor executor =  getExecutor(type);
      MessageContext msgContext = (MessageContext)MessageContextAssociation.peekMessageContext();
      boolean status = (executor != null ? executor.handleFault(msgContext, ex) : true);

      MessageAbstraction msg = ((CommonMessageContext)msgContext).getMessageAbstraction();
      if (type == HandlerType.ENDPOINT && (msg instanceof SOAPMessage))
         XOPContext.visitAndRestoreXOPData();
                 
      return status;
   }
View Full Code Here

    * This transformation is done after RMSender have finished his job.
    */
   public static MessageAbstraction convertRMSourceToMessage(RMMessage rmRequest, RMMessage rmResponse, RMMetadata rmMetadata) throws Throwable
   {
      boolean oneWay = RMTransportHelper.isOneWayOperation(rmRequest);
      MessageAbstraction response = null;
      if (false == oneWay)
      {
         byte[] payload = rmResponse.getPayload();
         InputStream in = (payload == null) ? null : new ByteArrayInputStream(rmResponse.getPayload());
         UnMarshaller unmarshaller = (UnMarshaller)rmMetadata.getContext(SERIALIZATION_CONTEXT).get(UNMARSHALLER);
View Full Code Here

         handlerPass = handlerPass && callRequestHandlerChain(portName, handlerType[2]);

         // Handlers might have replaced the message
         reqMsg = (SOAPMessageImpl)msgContext.getSOAPMessage();

         MessageAbstraction resMsg = null;
         if (handlerPass)
         {
            Map<String, Object> callProps = new HashMap<String, Object>(getRequestContext());
            if (callProps.containsKey(BindingProvider.ENDPOINT_ADDRESS_PROPERTY)) {
               targetAddress = (String) callProps.get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
View Full Code Here

      return retObj;
   }

   private Object invokeInternalNonSOAP(Object obj) throws IOException
   {
      MessageAbstraction reqMsg = getRequestMessage(obj);
      String targetAddress = epMetaData.getEndpointAddress();
      Map<String, Object> callProps = new HashMap<String, Object>(getRequestContext());
      if (callProps.containsKey(BindingProvider.ENDPOINT_ADDRESS_PROPERTY)) {
         targetAddress = (String) callProps.get(BindingProvider.ENDPOINT_ADDRESS_PROPERTY);
      }
      MessageAbstraction resMsg = getRemotingConnection().invoke(reqMsg, targetAddress, false);
      Object retObj = getReturnObject(resMsg);
      return retObj;
   }
View Full Code Here

      CommonMessageContext msgContext = new SOAPMessageContextJAXWS();
      MessageContextAssociation.pushMessageContext(msgContext);
      msgContext.setEndpointMetaData(epMetaData);
      try
      {
         MessageAbstraction reqMsg = getRequestMessage(msg);
         String targetAddress = epMetaData.getEndpointAddress();
         getRemotingConnection().invoke(reqMsg, targetAddress, true);
      }
      catch (Exception ex)
      {
View Full Code Here

      String bindingID = ((Binding21)bindingProvider.getBinding()).getBindingID();
      if (EndpointMetaData.SUPPORTED_BINDINGS.contains(bindingID) == false)
         throw new IllegalStateException("Unsupported binding: " + bindingID);

      MessageAbstraction message;
      if (HTTPBinding.HTTP_BINDING.equals(bindingID))
      {
         DispatchHTTPBinding helper = new DispatchHTTPBinding(mode, type, jaxbContext);
         ((ConfigurationProvider)epMetaData).configure(helper);
         message = helper.getRequestMessage(obj);
View Full Code Here

          log.debug("Remoting metadata: " + metadata);

        // debug the outgoing message
        MessageTrace.traceMessage("Outgoing Request Message", reqMessage);

        MessageAbstraction resMessage = null;

        if (oneway == true)
        {
          client.invokeOneway(reqMessage, metadata, false);
        }
View Full Code Here

TOP

Related Classes of org.jboss.ws.core.MessageAbstraction

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.