uk.ac.starlink.table

## Class StreamStarTableWriter

- java.lang.Object
- - uk.ac.starlink.table.StreamStarTableWriter

- All Implemented Interfaces:
    StarTableWriter
  Direct Known Subclasses:
    AbstractFitsTableWriter

      public abstract class StreamStarTableWriter
      extends java.lang.Object
      implements StarTableWriter

  Partial implementation of `StarTableWriter` which can be subclassed by writers which just write to output streams.
  Since:
    8 Dec 2004

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `StreamStarTableWriter()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `writeStarTable(StarTable startab, java.lang.String location, StarTableOutput sto)` Gets an output stream from `location` with reference to `sto` and writes to it using this writer's `StarTableWriter.writeStarTable(uk.ac.starlink.table.StarTable, java.io.OutputStream)` method.
    `static void` | `writeStarTable(StarTableWriter writer, StarTable startab, java.lang.String location, StarTableOutput sto)` Utility method that writes a table to a location using a given output handler.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface uk.ac.starlink.table.StarTableWriter

      `getFormatName, getMimeType, looksLikeFile, writeStarTable`

- - ### Constructor Detail

    - #### StreamStarTableWriter

          public StreamStarTableWriter()

  - ### Method Detail

    - #### writeStarTable

          public void writeStarTable(StarTable startab,
                                     java.lang.String location,
                                     StarTableOutput sto)
                              throws TableFormatException,
                                     java.io.IOException

      Gets an output stream from `location` with reference to `sto` and writes to it using this writer's `StarTableWriter.writeStarTable(uk.ac.starlink.table.StarTable, java.io.OutputStream)` method.

      This method just invokes the static utility method of the same name.

      Specified by:
        `writeStarTable` in interface `StarTableWriter`
      Parameters:
        `startab` - table to write
        `location` - table destination
        `sto` - StarTableOutput
      Throws:
        `TableFormatException` - if `startab` cannot be written to `location`
        `java.io.IOException` - if there is some I/O error

    - #### writeStarTable

          public static void writeStarTable(StarTableWriter writer,
                                            StarTable startab,
                                            java.lang.String location,
                                            StarTableOutput sto)
                                     throws java.io.IOException

      Utility method that writes a table to a location using a given output handler.
      Parameters:
        `writer` - output handler
        `startab` - table to write
        `location` - destination
        `sto` - output controller
      Throws:
        `java.io.IOException`