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.transport.email
Class DefaultDataContentHandlerFactory

    java.lang.Object
      org.mule.transport.email.DefaultDataContentHandlerFactory

All Implemented Interfaces:
  DataContentHandlerFactory

    public class DefaultDataContentHandlerFactory

extends Object
implements DataContentHandlerFactory

This is a default registry for mapping MimeTypes to DataHandlers

Method Summary
`DataContentHandler` | `createDataContentHandler(String contentType)`
`String` | `getContentType(Class clazz)`
`DataContentHandler` | `getDataContentHandler(Class clazz)`
`static DefaultDataContentHandlerFactory` | `getInstance()`
`void` | `register(DataContentHandler handler)` Registers a `DataContentHandler` for use with certain mime types.
`void` | `register(String contentType, Class clazz, DataContentHandler handler)` Register a DataContentHandler for a particular MIME type.

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

Method Detail

### getInstance

    public static DefaultDataContentHandlerFactory getInstance()

### createDataContentHandler

    public DataContentHandler createDataContentHandler(String contentType)

  Specified by:
    `createDataContentHandler` in interface `DataContentHandlerFactory`

### getDataContentHandler

    public DataContentHandler getDataContentHandler(Class clazz)

### getContentType

    public String getContentType(Class clazz)

### register

    public void register(String contentType,
                         Class clazz,
                         DataContentHandler handler)

  Register a DataContentHandler for a particular MIME type.

  Parameters:
    `contentType` - The Content Type.
    `handler` - The DataContentHandler.

### register

    public void register(DataContentHandler handler)

  Registers a `DataContentHandler` for use with certain mime types. To use this registration method the DataHandler has to be implmented correctly. This method uses the DataFalvour of the DataHandler to obtain the mimeType and DefaultRepresentation class. If there is more than one DataFlavour on the DataHandler, then each flavour will be registered seperately.

  Parameters:
    `handler` -

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-2010 MuleSoft, Inc.. All Rights Reserved.