Class DataHandlerUtils

java.lang.Object
org.mule.soapkit.soap.util.DataHandlerUtils

public class DataHandlerUtils extends Object
  • Constructor Details

    • DataHandlerUtils

      public DataHandlerUtils()
  • Method Details

    • toDataHandler

      public static javax.activation.DataHandler toDataHandler(String name, Object object, org.mule.runtime.api.metadata.MediaType contentType) throws IOException
      Transforms an Object into a DataHandler of its corresponding type.
      Parameters:
      name - the name of the attachment being handled
      object - the attachment to be handled
      contentType - the Content-Type of the attachment that is being handled
      Returns:
      a DataHandler of the corresponding attachment
      Throws:
      IOException - if the transformation fails.