com.google.gdata.wireformats.output
Class DualModeGenerator<T>

java.lang.Object
  extended by com.google.gdata.wireformats.output.CharacterGenerator<T>
      extended by com.google.gdata.wireformats.output.WireFormatOutputGenerator<T>
          extended by com.google.gdata.wireformats.output.DualModeGenerator<T>
Type Parameters:
T - expected source object type
All Implemented Interfaces:
OutputGenerator<T>
Direct Known Subclasses:
AtomDualGenerator, AtomServiceDualGenerator, RssDualGenerator

public abstract class DualModeGenerator<T>
extends WireFormatOutputGenerator<T>

A bridge between old and new data models for output generators.


Constructor Summary
protected DualModeGenerator(CharacterGenerator<T> oldGen)
           
 
Method Summary
 void generate(java.io.Writer contentWriter, OutputProperties outProps, T source)
          Generates content to the writer based upon the provided request/response.
 
Methods inherited from class com.google.gdata.wireformats.output.WireFormatOutputGenerator
getWireFormat
 
Methods inherited from class com.google.gdata.wireformats.output.CharacterGenerator
generate, getCharsetEncoding, getContentWriter, usePrettyPrint
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.google.gdata.wireformats.output.OutputGenerator
getAltFormat, getSourceType
 

Constructor Detail

DualModeGenerator

protected DualModeGenerator(CharacterGenerator<T> oldGen)
Method Detail

generate

public void generate(java.io.Writer contentWriter,
                     OutputProperties outProps,
                     T source)
              throws java.io.IOException
Description copied from class: WireFormatOutputGenerator
Generates content to the writer based upon the provided request/response.

Overrides:
generate in class WireFormatOutputGenerator<T>
Parameters:
contentWriter - output writer.
outProps - output properties for the generated output.
source - source object for the generated output.
Throws:
java.io.IOException