Class FastInfosetDataContentHandler

  • All Implemented Interfaces:
    javax.activation.DataContentHandler

    public class FastInfosetDataContentHandler
    extends Object
    implements javax.activation.DataContentHandler
    JAF data handler for Fast Infoset content
    Author:
    Santiago Pericas-Geertsen
    • Constructor Detail

      • FastInfosetDataContentHandler

        public FastInfosetDataContentHandler()
    • Method Detail

      • getTransferDataFlavors

        public DataFlavor[] getTransferDataFlavors()
        Return the DataFlavors for this DataContentHandler
        Specified by:
        getTransferDataFlavors in interface javax.activation.DataContentHandler
        Returns:
        The DataFlavors.
      • getTransferData

        public Object getTransferData​(DataFlavor flavor,
                                      javax.activation.DataSource dataSource)
                               throws IOException
        Return the Transfer Data of type DataFlavor from InputStream
        Specified by:
        getTransferData in interface javax.activation.DataContentHandler
        Parameters:
        flavor - The DataFlavor.
        dataSource - DataSource.
        Returns:
        The constructed Object.
        Throws:
        IOException - in case of an I/O error
      • getContent

        public Object getContent​(javax.activation.DataSource dataSource)
                          throws IOException
        Specified by:
        getContent in interface javax.activation.DataContentHandler
        Throws:
        IOException
      • writeTo

        public void writeTo​(Object obj,
                            String mimeType,
                            OutputStream os)
                     throws IOException
        Construct an object from a byte stream (similar semantically to previous method, we are deciding which one to support)
        Specified by:
        writeTo in interface javax.activation.DataContentHandler
        Throws:
        IOException