Class ExportDescriptor


  • public class ExportDescriptor
    extends ImportExportDescriptor
    It represents a descriptor for the export of a resource into a writer or an output stream.

    It provides the writer or the output stream to use in the export, the MIME type of the format into which the resources have to be exported, and additional properties that can be required by an exporter.

    • Constructor Detail

      • ExportDescriptor

        public ExportDescriptor()
    • Method Detail

      • withWriter

        public static ExportDescriptor withWriter​(Writer writer)
        Creates and initializes a new descriptor on an export process with the specified writer. The output stream is initialized with the specified writer.
        Parameters:
        writer - the writer to use for exporting the serializable resources.
        Returns:
        an export descriptor.
      • withOutputStream

        public static ExportDescriptor withOutputStream​(OutputStream outputStream)
        Creates and initializes a new descriptor on an export process with the specified output stream. The writer is initialized with the specified output stream.
        Parameters:
        outputStream - the output stream to use for exporting the serializable resources.
        Returns:
        an export descriptor.
      • getWriter

        public Writer getWriter()
        Gets the writer with which the resources have to be exported.
        Returns:
        the writer.
      • getOutputStream

        public OutputStream getOutputStream()
        Gets the output stream with which the resources have to be exported.
        Returns:
        the output stream.