© 2002 BEA Systems, Inc.


com.beasys.commerce.ebusiness.catalog.util
Class CatalogSchemaManager

java.lang.Object
  |
  +--com.beasys.commerce.ebusiness.catalog.util.CatalogSchemaManager

public class CatalogSchemaManager
extends java.lang.Object

Utility class used for accessing named Product Catalog schema definition resources within a named ResourceBundle resource file.

By default, the wlcs-catalog resource file is used.

See Also:
ResourceBundle

Constructor Summary
CatalogSchemaManager(java.lang.String bundle)
          This is an abstract class.
 
Method Summary
 java.lang.Integer getInteger(java.lang.String key)
          Get an Integer resource referenced by a key.
 java.util.Enumeration getKeys()
          Get all the keys for the resource bundle.
 java.lang.Object getObject(java.lang.String key)
          Get an Object resource referenced by a key.
 java.sql.PreparedStatement getPreparedStatement(java.sql.Connection con, java.lang.String key)
          Create a PreparedStatemetn from a string resource referenced by a key.
 java.lang.String getString(java.lang.String key)
          Get a string resource referenced by a key.
 java.lang.String[] getStringArray(java.lang.String key)
          Get a string array resource referenced by a key.
protected  void loadResourceBundle()
          Load the resource bundle.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CatalogSchemaManager

public CatalogSchemaManager(java.lang.String bundle)
This is an abstract class.
Method Detail

loadResourceBundle

protected void loadResourceBundle()
                           throws java.util.MissingResourceException
Load the resource bundle.

Throws:
java.util.MissingResourceException - if the resource bundle could not be found

getString

public java.lang.String getString(java.lang.String key)
                           throws java.util.MissingResourceException
Get a string resource referenced by a key.

Parameters:
key - the name of the resource
Returns:
the resource as a String
Throws:
java.util.MissingResourceException - if the resource bundle could not be found

getInteger

public java.lang.Integer getInteger(java.lang.String key)
                             throws java.util.MissingResourceException,
                                    java.lang.NumberFormatException
Get an Integer resource referenced by a key.

Parameters:
key - the name of the resource
Returns:
the resource as an Integer
Throws:
java.util.MissingResourceException - if the resource bundle could not be found
java.lang.NumberFormatException - if the resource specified by the key is not valid

getPreparedStatement

public java.sql.PreparedStatement getPreparedStatement(java.sql.Connection con,
                                                       java.lang.String key)
                                                throws java.util.MissingResourceException,
                                                       java.sql.SQLException
Create a PreparedStatemetn from a string resource referenced by a key.

Parameters:
con - the Database Connection
key - the name of the resource
Returns:
the resource as a String
Throws:
java.util.MissingResourceException - if the resource bundle could not be found
java.sql.SQLException - on statement preparation error

getStringArray

public java.lang.String[] getStringArray(java.lang.String key)
                                  throws java.util.MissingResourceException
Get a string array resource referenced by a key.

Parameters:
key - the name of the resource
Returns:
the resource as a String[]
Throws:
java.util.MissingResourceException - if the resource bundle could not be found

getObject

public java.lang.Object getObject(java.lang.String key)
                           throws java.util.MissingResourceException
Get an Object resource referenced by a key.

Parameters:
key - the name of the resource
Returns:
the resource as an Object
Throws:
java.util.MissingResourceException - if the resource bundle could not be found

getKeys

public java.util.Enumeration getKeys()
                              throws java.util.MissingResourceException
Get all the keys for the resource bundle.

Returns:
the Enumeration of keys.
Throws:
java.util.MissingResourceException - if the resource bundle could not be found

© 2002 BEA Systems, Inc.

Copyright © 2002 BEA Systems, Inc. All Rights Reserved