com.sun.resolver
Class CatalogManager

java.lang.Object
  extended bycom.sun.resolver.CatalogManager

public class CatalogManager
extends java.lang.Object

CatalogManager provides an interface to the catalog properties.

Properties can come from two places: from system properties or from a CatalogManager.properties file. This class provides a transparent interface to both, with system properties preferred over property file values.

The following table summarizes the properties:

System Property CatalogManager.properties
Property
Description
xml.catalog.ignoreMissing   If true, a missing CatalogManager.properties file or missing properties within that file will not generate warning messages. See also the ignoreMissingProperties method.
xml.catalog.files catalogs The semicolon-delimited list of catalog files.
  relative-catalogs If false, relative catalog URIs are made absolute with respect to the base URI of the CatalogManager.properties file. This setting only applies to catalog URIs obtained from the catalogs property in the CatalogManager.properties file
xml.catalog.verbosity verbosity If non-zero, the Catalog classes will print informative and debugging messages. The higher the number, the more messages.
xml.catalog.prefer prefer Which identifier is preferred, "public" or "system"?
xml.catalog.staticCatalog static-catalog Should a single catalog be constructed for all parsing, or should a different catalog be created for each parser?
xml.catalog.allowPI allow-oasis-xml-catalog-pi If the source document contains "oasis-xml-catalog" processing instructions, should they be used?
xml.catalog.className catalog-class-name If you're using the convenience classes com.sun.resolver.tools.*), this setting allows you to specify an alternate class name to use for the underlying catalog.

Copyright © 2000, 2001 Sun Microsystems, Inc. All Rights Reserved. This software is the proprietary information of Sun Microsystems, Inc. Use is subject to license terms.

Version:
1.0
Author:
Norman Walsh Norman.Walsh@Sun.COM
See Also:
Catalog

Constructor Summary
CatalogManager()
           
 
Method Summary
static boolean allowOasisXMLCatalogPI()
          Obtain the oasisXMLCatalogPI setting from the properties.
static java.lang.String catalogClassName()
          Obtain the Catalog class name setting from the properties.
static java.util.Vector catalogFiles()
          Obtain the list of catalog files from the properties.
static void ignoreMissingProperties(boolean ignore)
          Tell the CatalogManager how to handle missing properties If ignore is true, missing or unreadable property files will not be reported.
static boolean preferPublic()
          Obtain the preferPublic setting from the properties.
static boolean relativeCatalogs()
          Obtain the relativeCatalogs setting from the properties.
static boolean staticCatalog()
          Obtain the static-catalog setting from the properties.
static int verbosity()
          Obtain the verbosity setting from the properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CatalogManager

public CatalogManager()
Method Detail

ignoreMissingProperties

public static void ignoreMissingProperties(boolean ignore)

Tell the CatalogManager how to handle missing properties

If ignore is true, missing or unreadable property files will not be reported. Otherwise, a message will be sent to System.err.


verbosity

public static int verbosity()

Obtain the verbosity setting from the properties.


relativeCatalogs

public static boolean relativeCatalogs()

Obtain the relativeCatalogs setting from the properties.

This property is used when the catalogFiles property is interrogated. If true, then relative catalog entry file names are returned. If false, relative catalog entry file names are made absolute with respect to the properties file before returning them.

This property only applies when the catalog files come from a properties file. If they come from a system property or the default list, they are never considered relative. (What would they be relative to?)

In the properties, a value of 'yes', 'true', or '1' is considered true, anything else is false.


catalogFiles

public static java.util.Vector catalogFiles()

Obtain the list of catalog files from the properties.

Note that the list of catalog files is always a semicolon delimited list, even on Unix systems where a colon delimited list might be considered more natural.


preferPublic

public static boolean preferPublic()

Obtain the preferPublic setting from the properties.

In the properties, a value of 'public' is true, anything else is false.


staticCatalog

public static boolean staticCatalog()

Obtain the static-catalog setting from the properties.

In the properties, a value of 'yes', 'true', or '1' is considered true, anything else is false.


allowOasisXMLCatalogPI

public static boolean allowOasisXMLCatalogPI()

Obtain the oasisXMLCatalogPI setting from the properties.

In the properties, a value of 'yes', 'true', or '1' is considered true, anything else is false.


catalogClassName

public static java.lang.String catalogClassName()

Obtain the Catalog class name setting from the properties.