Class MessageDataSource

java.lang.Object
org.frankframework.util.MessageDataSource
All Implemented Interfaces:
jakarta.activation.DataSource, Closeable, AutoCloseable, javax.activation.DataSource

public class MessageDataSource extends Object implements javax.activation.DataSource, jakarta.activation.DataSource, Closeable
  • Constructor Details

  • Method Details

    • getContentType

      public String getContentType()
      Use content type application/octet-stream in case it cannot be determined. See http://docs.oracle.com/javase/7/docs/api/javax/activation/DataSource.html#getContentType(): This method returns the MIME type of the data in the form of a string. It should always return a valid type.
      Specified by:
      getContentType in interface jakarta.activation.DataSource
      Specified by:
      getContentType in interface javax.activation.DataSource
      Returns:
      "application/octet-stream" if the DataSource implementation can not determine the data type.
    • getInputStream

      public InputStream getInputStream() throws IOException
      Specified by:
      getInputStream in interface jakarta.activation.DataSource
      Specified by:
      getInputStream in interface javax.activation.DataSource
      Throws:
      IOException
    • getName

      public String getName()
      Specified by:
      getName in interface jakarta.activation.DataSource
      Specified by:
      getName in interface javax.activation.DataSource
    • getOutputStream

      public OutputStream getOutputStream() throws IOException
      Specified by:
      getOutputStream in interface jakarta.activation.DataSource
      Specified by:
      getOutputStream in interface javax.activation.DataSource
      Throws:
      IOException
    • close

      public void close() throws IOException
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Throws:
      IOException