org.mule.module.cxf
Class CxfInboundMessageProcessor

java.lang.Object
  extended by org.mule.processor.AbstractInterceptingMessageProcessorBase
      extended by org.mule.processor.AbstractInterceptingMessageProcessor
          extended by org.mule.module.cxf.CxfInboundMessageProcessor
All Implemented Interfaces:
AnnotatedObject, MuleContextAware, Disposable, Initialisable, Lifecycle, Startable, Stoppable, InterceptingMessageProcessor, MessageProcessor, MessageSource

public class CxfInboundMessageProcessor
extends AbstractInterceptingMessageProcessor
implements Lifecycle

The CxfInboundMessageProcessor performs inbound CXF processing, sending an event through the CXF service, then on to the next MessageProcessor. This processor gets built by a MessageProcessorBuilder which is responsible for configuring it and the Server that it dispatches to.


Field Summary
protected  org.apache.cxf.Bus bus
           
protected  Log logger
          logger used by this class
protected  org.apache.cxf.endpoint.Server server
           
protected  String transportClass
           
 
Fields inherited from class org.mule.processor.AbstractInterceptingMessageProcessorBase
muleContext, next, notificationHandler
 
Fields inherited from interface org.mule.api.lifecycle.Initialisable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Startable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Stoppable
PHASE_NAME
 
Fields inherited from interface org.mule.api.lifecycle.Disposable
PHASE_NAME
 
Fields inherited from interface org.mule.api.AnnotatedObject
PROPERTY_NAME
 
Constructor Summary
CxfInboundMessageProcessor()
           
 
Method Summary
 void dispose()
          A lifecycle method where implementor should free up any resources.
protected  MuleEvent generateWSDLOrXSD(MuleEvent event, String req)
           
 org.apache.cxf.Bus getBus()
           
protected  InputStream getMessageStream(MuleEvent context)
          Gets the stream representation of the current message.
protected  OutputHandler getRessponseOutputHandler(org.apache.cxf.message.MessageImpl m)
           
 org.apache.cxf.endpoint.Server getServer()
           
protected  String getSoapAction(MuleMessage message)
           
 void initialise()
          Method used to perform any initialisation work.
 boolean isProxy()
           
 MuleEvent process(MuleEvent event)
          Invokes the MessageProcessor.
 MuleEvent processNext(MuleEvent event)
           
protected  MuleEvent sendToDestination(MuleEvent event)
           
 void setBus(org.apache.cxf.Bus bus)
           
 void setProxy(boolean proxy)
           
 void setServer(org.apache.cxf.endpoint.Server server)
           
 void start()
           
 void stop()
           
 
Methods inherited from class org.mule.processor.AbstractInterceptingMessageProcessorBase
getAnnotation, getAnnotations, getListener, getMuleContext, isEventValid, setAnnotations, setListener, setMuleContext, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.mule.api.source.MessageSource
setListener
 

Field Detail

logger

protected transient Log logger
logger used by this class


bus

protected org.apache.cxf.Bus bus

transportClass

protected String transportClass

server

protected org.apache.cxf.endpoint.Server server
Constructor Detail

CxfInboundMessageProcessor

public CxfInboundMessageProcessor()
Method Detail

initialise

public void initialise()
                throws InitialisationException
Description copied from interface: Initialisable
Method used to perform any initialisation work. If a fatal error occurs during initialisation an InitialisationException should be thrown, causing the Mule instance to shutdown. If the error is recoverable, say by retrying to connect, a RecoverableException should be thrown. There is no guarantee that by throwing a Recoverable exception that the Mule instance will not shut down.

Specified by:
initialise in interface Initialisable
Throws:
InitialisationException - if a fatal error occurs causing the Mule instance to shutdown
RecoverableException - if an error occurs that can be recovered from

stop

public void stop()
          throws MuleException
Specified by:
stop in interface Stoppable
Throws:
MuleException

start

public void start()
           throws MuleException
Specified by:
start in interface Startable
Throws:
MuleException

dispose

public void dispose()
Description copied from interface: Disposable
A lifecycle method where implementor should free up any resources. If an exception is thrown it should just be logged and processing should continue. This method should not throw Runtime exceptions.

Specified by:
dispose in interface Disposable

process

public MuleEvent process(MuleEvent event)
                  throws MuleException
Description copied from interface: MessageProcessor
Invokes the MessageProcessor.

Specified by:
process in interface MessageProcessor
Parameters:
event - MuleEvent to be processed
Returns:
optional response MuleEvent
Throws:
MuleException

generateWSDLOrXSD

protected MuleEvent generateWSDLOrXSD(MuleEvent event,
                                      String req)
                               throws EndpointNotFoundException,
                                      IOException
Throws:
EndpointNotFoundException
IOException

sendToDestination

protected MuleEvent sendToDestination(MuleEvent event)
                               throws MuleException,
                                      IOException
Throws:
MuleException
IOException

processNext

public MuleEvent processNext(MuleEvent event)
                      throws MuleException
Overrides:
processNext in class AbstractInterceptingMessageProcessorBase
Throws:
MuleException

getRessponseOutputHandler

protected OutputHandler getRessponseOutputHandler(org.apache.cxf.message.MessageImpl m)

getMessageStream

protected InputStream getMessageStream(MuleEvent context)
                                throws MuleException
Gets the stream representation of the current message.

Parameters:
context - the event context
Returns:
The inputstream for the current message
Throws:
MuleException

getSoapAction

protected String getSoapAction(MuleMessage message)

getBus

public org.apache.cxf.Bus getBus()

setBus

public void setBus(org.apache.cxf.Bus bus)

getServer

public org.apache.cxf.endpoint.Server getServer()

setServer

public void setServer(org.apache.cxf.endpoint.Server server)

setProxy

public void setProxy(boolean proxy)

isProxy

public boolean isProxy()


Copyright © 2003-2012 MuleSoft, Inc.. All Rights Reserved.