org.displaytag.export
Class ExportViewFactory

java.lang.Object
  extended by org.displaytag.export.ExportViewFactory

public final class ExportViewFactory
extends java.lang.Object

Factory for export views.

Version:
$Revision: 1081 $ ($Author: fgiust $)
Author:
Fabrizio Giustina

Method Summary
static ExportViewFactory getInstance()
          Returns the simgleton for this class.
 ExportView getView(MediaTypeEnum exportType, TableModel tableModel, boolean exportFullList, boolean includeHeader, boolean decorateValues)
          returns an instance of export view associated with the given export type.
 void registerExportView(java.lang.String name, java.lang.String viewClassName)
          Register a new Export View, associated with a Media Type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static ExportViewFactory getInstance()
Returns the simgleton for this class.

Returns:
ExportViewFactory instance

registerExportView

public void registerExportView(java.lang.String name,
                               java.lang.String viewClassName)
Register a new Export View, associated with a Media Type. If another export view is currently associated with the given media type it's replaced.

Parameters:
name - media name
viewClassName - export view class name

getView

public ExportView getView(MediaTypeEnum exportType,
                          TableModel tableModel,
                          boolean exportFullList,
                          boolean includeHeader,
                          boolean decorateValues)
returns an instance of export view associated with the given export type.

Parameters:
exportType - MediaTypeEnum
tableModel - table model containing data to render
exportFullList - should the complete list be exported?
includeHeader - should header be included in export?
decorateValues - should ouput be decorated?
Returns:
specialized instance of BaseExportView


Copyright © 2002-2007 the Displaytag team. All Rights Reserved.