sk.baka.xml.gene
Interface IExporterFactory

All Known Implementing Classes:
ImageExporterFactory

public interface IExporterFactory

Produces the IExporter instances.

Author:
Martin Vysny

Method Summary
 Set<ExporterInfo> getSupportedExporters()
          Returns set of information about all exporters that this factory can instantiate.
 Set<ExporterInfo> getWildcardExporter(String namespace)
          Returns a wildcard exporter.
 IExporter produce(String id)
          Produces an instance of exporter denoted by given ID.
 

Method Detail

produce

IExporter produce(String id)
                  throws ExportException,
                         IOException
Produces an instance of exporter denoted by given ID.

Parameters:
id - id of the exporter.
Returns:
exporter instance.
Throws:
ExportException - if error occurs during exporter creation.
IOException - if i/o error occurs.
IllegalArgumentException - if id is not known.

getSupportedExporters

Set<ExporterInfo> getSupportedExporters()
Returns set of information about all exporters that this factory can instantiate.

Returns:
set of exporter info objects. Factory should compute this set only once - it won't get modified.

getWildcardExporter

Set<ExporterInfo> getWildcardExporter(String namespace)
Returns a wildcard exporter. Wildcard exporter is an exporter that is able to process indefinite namespaces. Wildcard exporters are mostly exporters that simply prints out source document structure - element names, their attributes and contents. They are used only when user wishes so and only when a graph path composed of regular exporters cannot be constructed.

Parameters:
namespace - the namespace that the exporter will process.
Returns:
set of wildcard exporters that are able to process given namespace. Never null, may be empty.


Copyright © 2006 Martin Vysny - baka. All Rights Reserved.