ie.nuigalway.ecrg.jade.jmsmtp.common
Class JmsMtpConfig

java.lang.Object
  |
  +--ie.nuigalway.ecrg.jade.jmsmtp.common.JmsMtpConfig

public class JmsMtpConfig
extends java.lang.Object


Field Summary
static java.lang.String DEFAULT_BROKER_URL
          Description of the Field
static java.lang.String DEFAULT_MSG_PERSISTENCE
          Description of the Field
static java.lang.String DEFAULT_MSG_TYPE
          Description of the Field
static java.lang.String DEFAULT_PASSWORD
          Description of the Field
static java.lang.String DEFAULT_PROVIDER_TYPE
          Description of the Field
static java.lang.String DEFAULT_QUEUE_NAME
          Description of the Field
static java.lang.String DEFAULT_USERNAME
          Description of the Field
private static org.apache.log4j.Category log
           
static java.lang.String MSG_MAP
          Description of the Field
static java.lang.String MSG_NON_PERSISTENT
          Description of the Field
static java.lang.String MSG_PERSISTENT
          Description of the Field
static java.lang.String MSG_XML
          Description of the Field
private static java.lang.String packageName
          stores the packagename of use with keys in the propertyfile
private static java.util.Properties props
           
 
Constructor Summary
JmsMtpConfig()
          Constructor which loads in the configuration file
 
Method Summary
private static java.net.URL[] getDirList(java.lang.String lib)
          Reads a given directory and returns the contents as a URL []
static java.lang.String getProperty(java.lang.String key, java.lang.String defaultValue)
          Given a key return its value from the configfile
static java.net.URL[] getProviderLib(java.lang.String providerType)
          Reads a given directory and returns the contents as a URL []
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

props

private static java.util.Properties props

DEFAULT_MSG_PERSISTENCE

public static java.lang.String DEFAULT_MSG_PERSISTENCE
Description of the Field


DEFAULT_MSG_TYPE

public static java.lang.String DEFAULT_MSG_TYPE
Description of the Field


DEFAULT_PROVIDER_TYPE

public static java.lang.String DEFAULT_PROVIDER_TYPE
Description of the Field


DEFAULT_BROKER_URL

public static java.lang.String DEFAULT_BROKER_URL
Description of the Field


DEFAULT_QUEUE_NAME

public static java.lang.String DEFAULT_QUEUE_NAME
Description of the Field


DEFAULT_USERNAME

public static java.lang.String DEFAULT_USERNAME
Description of the Field


DEFAULT_PASSWORD

public static java.lang.String DEFAULT_PASSWORD
Description of the Field


MSG_XML

public static final java.lang.String MSG_XML
Description of the Field

See Also:
Constant Field Values

MSG_MAP

public static final java.lang.String MSG_MAP
Description of the Field

See Also:
Constant Field Values

MSG_PERSISTENT

public static final java.lang.String MSG_PERSISTENT
Description of the Field

See Also:
Constant Field Values

MSG_NON_PERSISTENT

public static final java.lang.String MSG_NON_PERSISTENT
Description of the Field

See Also:
Constant Field Values

log

private static org.apache.log4j.Category log

packageName

private static java.lang.String packageName
stores the packagename of use with keys in the propertyfile

Constructor Detail

JmsMtpConfig

public JmsMtpConfig()
Constructor which loads in the configuration file

Method Detail

getProviderLib

public static java.net.URL[] getProviderLib(java.lang.String providerType)
                                     throws java.lang.Exception
Reads a given directory and returns the contents as a URL []

Parameters:
providerType - JMS Provider Type to learn
Returns:
A URL [] of the contents of the directory
Throws:
java.lang.Exception - Error reading in Librarys

getDirList

private static java.net.URL[] getDirList(java.lang.String lib)
                                  throws java.lang.Exception
Reads a given directory and returns the contents as a URL []

Parameters:
lib - Location of Directory to Read in
Returns:
A URL [] of the contents of the directory
Throws:
java.lang.Exception - Specified location was not a directory

getProperty

public static java.lang.String getProperty(java.lang.String key,
                                           java.lang.String defaultValue)
Given a key return its value from the configfile

Parameters:
key - Key to search for in the prop file
defaultValue - Default value to use if not found
Returns:
Value from propfile or default value