FileDocCategorySizeDatePackage
PipeBase.javaAPI DocExample5566Tue May 29 16:56:42 BST 2007com.sun.xml.ws.rm.jaxws.runtime

PipeBase

public abstract class PipeBase extends Object implements com.sun.xml.ws.api.pipe.Pipe
BaseClass for RMClientPipe and RMServerPipe. Pipe methods are implemented in the subclasses. The base class contains common code used by the JAX-WS runtime to communicate with the RM Providers.

Fields Summary
public PROVIDER
provider
Either RMSource or RMDestination
protected com.sun.xml.ws.api.pipe.Pipe
nextPipe
Next Pipe in pipeline
protected Marshaller
marshaller
protected Unmarshaller
unmarshaller
protected com.sun.xml.ws.rm.jaxws.util.ProcessingFilter
filter
Constructors Summary
protected PipeBase(PROVIDER provider, com.sun.xml.ws.api.pipe.Pipe nextPipe)

        
        this.provider = provider;
        this.nextPipe = nextPipe;
        this.filter = provider.getProcessingFilter();

       /* marshaller = RMConstants.createMarshaller();
        unmarshaller = RMConstants.createUnmarshaller();*/
    
Methods Summary
public abstract com.sun.xml.ws.api.pipe.Pipecopy(com.sun.xml.ws.api.pipe.PipeCloner cloner)

protected com.sun.xml.ws.rm.MessagehandleInboundMessage(com.sun.xml.ws.api.message.Packet packet)
Use methods of RMProvider field to store and write headers to inbound message.

param
packet Packet containing Outbound message
return
The wrapped message


        Message message = packet.getMessage();
        com.sun.xml.ws.rm.Message msg =
                new com.sun.xml.ws.rm.Message(message);

        provider.processInboundMessage(msg, marshaller, unmarshaller);
        return msg;
    
protected com.sun.xml.ws.rm.MessagehandleOutboundMessage(OUTBOUND outboundSequence, com.sun.xml.ws.api.message.Packet packet)
Use methods of OutboundSequence field to store and write headers to outbound message.

param
packet Packet containing Outbound message
return
The wrapped message

             
        Message message = packet.getMessage();
        com.sun.xml.ws.rm.Message msg = 
                new com.sun.xml.ws.rm.Message(message);
        
        Object mn = packet.invocationProperties.get(Constants.messageNumberProperty);
        Object oneWayResponse = packet.invocationProperties.get("onewayresponse");
        
        if (oneWayResponse != null) {
            //don't want to add this message to a sequence.
            msg.isOneWayResponse = true;
        }
        
        if (mn instanceof Integer) {
            msg.setMessageNumber((Integer)mn);
        }
        
        outboundSequence.processOutboundMessage(msg, marshaller);
      
        return msg;
    
public abstract voidpreDestroy()

public abstract com.sun.xml.ws.api.message.Packetprocess(com.sun.xml.ws.api.message.Packet packet)