OutputDecorator (Jackson-core 2.0.2 API)
Date: 2012-05-14

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.fasterxml.jackson.core.io
Class OutputDecorator

    java.lang.Object
      com.fasterxml.jackson.core.io.OutputDecorator

    public abstract class OutputDecorator

extends Object

Handler class that can be used to decorate output destinations. Typical use is to use a filter abstraction (filtered output stream, writer) around original output destination, and apply additional processing during write operations.

Constructor Summary
`OutputDecorator()`

Method Summary
`abstract OutputStream` | `decorate(IOContext ctxt, OutputStream out)` Method called by `JsonFactory` instance when creating generator for given `OutputStream`, when this decorator has been registered.
`abstract Writer` | `decorate(IOContext ctxt, Writer w)` Method called by `JsonFactory` instance when creating generator for given `Writer`, when this decorator has been registered.

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

Constructor Detail

### OutputDecorator

    public OutputDecorator()

Method Detail

### decorate

    public abstract OutputStream decorate(IOContext ctxt,
                                          OutputStream out)
                                   throws IOException

  Method called by `JsonFactory` instance when creating generator for given `OutputStream`, when this decorator has been registered.

  Parameters:
    `ctxt` - IO context in use (provides access to declared encoding)
    `out` - Original output destination
  Returns:
    OutputStream to use; either passed in argument, or something that calls it
  Throws:
    `IOException`

### decorate

    public abstract Writer decorate(IOContext ctxt,
                                    Writer w)
                             throws IOException

  Method called by `JsonFactory` instance when creating generator for given `Writer`, when this decorator has been registered.

  Parameters:
    `ctxt` - IO context in use (provides access to declared encoding)
    `w` - Original output writer
  Returns:
    Writer to use; either passed in argument, or something that calls it
  Throws:
    `IOException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2012 fasterxml.com. All Rights Reserved.