Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.mule.transformer
Class AbstractMessageAwareTransformer

    java.lang.Object
      org.mule.transformer.AbstractTransformer
          org.mule.transformer.AbstractMessageAwareTransformer

All Implemented Interfaces:
  MuleContextAware, Initialisable, NamedObject, BaseTransformer, Transformer

Direct Known Subclasses:
  AbstractExpressionTransformer, AbstractJmsTransformer, AbstractJsonTransformer, AbstractXmlTransformer, AbstractXStreamTransformer, AutoTransformer, HttpRequestBodyToParamMap, HttpRequestToBook, HttpRequestToParameter, HttpRequestToParameterMap, HttpRequestToSoapRequest, MessagePropertiesTransformer, MuleMessageToByteArray, MuleMessageToHttpResponse, ObjectToHttpClientMethodRequest, ObjectToXmppPacket, RestRequestToCustomerRequest, ScriptTransformer, SetLendersAsRecipients, StringToEmailMessage, TransformerChain, TransformerTemplate, XmppPacketToObject

    public abstract class AbstractMessageAwareTransformer

extends AbstractTransformer

`AbstractMessageAwareTransformer` is a transformer that has a reference to the current message. This message can be used obtains properties associated with the current message useful to the transform. Note that when part of a transform chain, the Message payload reflects the pre-transform message state, unless there is no current event for this thread, then the message will be a new DefaultMuleMessage with the src as its payload. Transformers should always work on the src object not the message payload.

See Also:
  `MuleMessage`, `DefaultMuleMessage`

Field Summary

Fields inherited from class org.mule.transformer.AbstractTransformer
`DEFAULT_TRUNCATE_LENGTH, endpoint, logger, muleContext, name, returnClass, sourceTypes`

Fields inherited from interface org.mule.api.lifecycle.Initialisable
`PHASE_NAME`

Constructor Summary
`AbstractMessageAwareTransformer()`

Method Summary
`Object` | `doTransform(Object src, String encoding)`
`boolean` | `isSourceTypeSupported(Class aClass, boolean exactMatch)`
`abstract Object` | `transform(MuleMessage message, String outputEncoding)`

Methods inherited from class org.mule.transformer.AbstractTransformer
`checkReturnClass, generateTransformerName, getEncoding, getEndpoint, getName, getReturnClass, getSourceTypes, initialise, isAcceptNull, isConsumed, isIgnoreBadInput, isSourceTypeSupported, registerSourceType, setEndpoint, setIgnoreBadInput, setMuleContext, setName, setReturnClass, toString, transform, transform, unregisterSourceType`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### AbstractMessageAwareTransformer

    public AbstractMessageAwareTransformer()

Method Detail

### isSourceTypeSupported

    public boolean isSourceTypeSupported(Class aClass,
                                         boolean exactMatch)

  Overrides:
    `isSourceTypeSupported` in class `AbstractTransformer`

### doTransform

    public final Object doTransform(Object src,
                                    String encoding)
                             throws TransformerException

  Specified by:
    `doTransform` in class `AbstractTransformer`
  Throws:
    `TransformerException`

### transform

    public abstract Object transform(MuleMessage message,
                                     String outputEncoding)
                              throws TransformerException

  Throws:
    `TransformerException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2003-2009 MuleSource, Inc.. All Rights Reserved.