# ImageWriterFactory (Slick - The 2D Library)
Date: 2013-06-03

## org.newdawn.slick.imageout
Class ImageWriterFactory

    java.lang.Object
      org.newdawn.slick.imageout.ImageWriterFactory

    public class ImageWriterFactory

extends java.lang.Object

A factory to produce image writers based on format names

Author:
  kevin

Constructor Summary
`ImageWriterFactory()`

Method Summary
`static java.lang.String[]` `getSupportedFormats()` Get the list of support format strings for this factory
`static ImageWriter` `getWriterForFormat(java.lang.String format)` Get a Slick image writer for the given format
`static void` `registerWriter(java.lang.String format, ImageWriter writer)` Register an image writer with the factory.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ImageWriterFactory

    public ImageWriterFactory()

Method Detail

### registerWriter

    public static void registerWriter(java.lang.String format,
                                      ImageWriter writer)

  Register an image writer with the factory. This will allow users to use it to write out the explicit format

  Parameters:
    `format` - The format (usually extension) of the files that will be written out
    `writer` - The writer to use for the given format

### getSupportedFormats

    public static java.lang.String[] getSupportedFormats()

  Get the list of support format strings for this factory

  Returns:
    The list of support format strings for this factory

### getWriterForFormat

    public static ImageWriter getWriterForFormat(java.lang.String format)
                                          throws SlickException

  Get a Slick image writer for the given format

  Parameters:
    `format` - The format of the image to write
  Returns:
    The image write to use to produce these images
  Throws:
    `SlickException`

Copyright © 2006 New Dawn Software. All Rights Reserved.