org.apache.xml.resolver.readers

Interface CatalogReader

public interface CatalogReader

The CatalogReader interface.

The Catalog class requires that classes implement this interface in order to be used to read catalogs. Examples of CatalogReaders include the TextCatalogReader, the SAXCatalogReader, and the DOMCatalogReader.

Version: 1.0

Author: Norman Walsh Norman.Walsh@Sun.COM

See Also:

Method Summary
voidreadCatalog(Catalog catalog, String fileUrl)

Read a catalog from a file

This class reads a catalog from a URL.

voidreadCatalog(Catalog catalog, InputStream is)

Read a catalog from an input stream

This class reads a catalog from an input stream.

Method Detail

readCatalog

public void readCatalog(Catalog catalog, String fileUrl)

Read a catalog from a file

This class reads a catalog from a URL.

Parameters: catalog The catalog for which this reader is called. fileUrl The URL of a document to be read.

Throws: MalformedURLException if the specified URL cannot be turned into a URL object. IOException if the URL cannot be read. UnknownCatalogFormatException if the catalog format is not recognized. UnparseableCatalogException if the catalog cannot be parsed. (For example, if it is supposed to be XML and isn't well-formed.)

readCatalog

public void readCatalog(Catalog catalog, InputStream is)

Read a catalog from an input stream

This class reads a catalog from an input stream.

Parameters: catalog The catalog for which this reader is called. is The input stream that is to be read.

Throws: IOException if the URL cannot be read. UnknownCatalogFormatException if the catalog format is not recognized. UnparseableCatalogException if the catalog cannot be parsed. (For example, if it is supposed to be XML and isn't well-formed.)

Copyright B) 2001 Apache. All Rights Reserved.