com.atlassian.jira.config.properties
Class ApplicationPropertiesImpl

java.lang.Object
  extended by com.atlassian.jira.config.properties.ApplicationPropertiesImpl
All Implemented Interfaces:
ApplicationProperties

public class ApplicationPropertiesImpl
extends Object
implements ApplicationProperties

A class to manage the interface with a single property set, used for application properties


Constructor Summary
ApplicationPropertiesImpl()
           
 
Method Summary
 boolean equals(Object o)
           
 boolean exists(String key)
          Whether the specified key is present in the backing PropertySet.
 String getContentType()
           
 String getDefaultBackedString(String name)
          Get the property from the application properties, but if not found, try to get from the default properties file.
 String getDefaultBackedText(String name)
          Get the property from the application properties, but if not found, try to get from the default properties file.
 Locale getDefaultLocale()
           
 String getDefaultString(String name)
          Get the default property (if the property is not set)
 String getEncoding()
          Convenience method to get the content type for an application
 Collection getKeys()
           
 String getMailEncoding()
          Convenience method to get the email encoding
 boolean getOption(String key)
          Get the option from the application properties, but if not found, try to get from the default properties file.
 String getString(String name)
           
 Collection getStringsWithPrefix(String prefix)
           
 String getText(String name)
           
 int hashCode()
           
 void refresh()
          Refresh application properties object by refreshing the PropertiesManager
 void setOption(String key, boolean value)
           
 void setString(String name, String value)
           
 void setText(String name, String value)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ApplicationPropertiesImpl

public ApplicationPropertiesImpl()
Method Detail

getText

public String getText(String name)
Specified by:
getText in interface ApplicationProperties

setText

public void setText(String name,
                    String value)
Specified by:
setText in interface ApplicationProperties

getString

public String getString(String name)
Specified by:
getString in interface ApplicationProperties

getDefaultBackedString

public String getDefaultBackedString(String name)
Get the property from the application properties, but if not found, try to get from the default properties file.

Specified by:
getDefaultBackedString in interface ApplicationProperties

getDefaultBackedText

public String getDefaultBackedText(String name)
Get the property from the application properties, but if not found, try to get from the default properties file.

Specified by:
getDefaultBackedText in interface ApplicationProperties

getDefaultString

public String getDefaultString(String name)
Get the default property (if the property is not set)

Specified by:
getDefaultString in interface ApplicationProperties
Parameters:
name - the name of the property.

setString

public void setString(String name,
                      String value)
Specified by:
setString in interface ApplicationProperties

exists

public final boolean exists(String key)
Whether the specified key is present in the backing PropertySet. Typically called before getOption(String)

Specified by:
exists in interface ApplicationProperties

getOption

public boolean getOption(String key)
Get the option from the application properties, but if not found, try to get from the default properties file.

Specified by:
getOption in interface ApplicationProperties

getKeys

public Collection getKeys()
Specified by:
getKeys in interface ApplicationProperties

setOption

public void setOption(String key,
                      boolean value)
Specified by:
setOption in interface ApplicationProperties

getEncoding

public String getEncoding()
Convenience method to get the content type for an application

Specified by:
getEncoding in interface ApplicationProperties

getMailEncoding

public String getMailEncoding()
Convenience method to get the email encoding

Specified by:
getMailEncoding in interface ApplicationProperties

getContentType

public String getContentType()
Specified by:
getContentType in interface ApplicationProperties

refresh

public void refresh()
Refresh application properties object by refreshing the PropertiesManager

Specified by:
refresh in interface ApplicationProperties

toString

public String toString()
Overrides:
toString in class Object

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

getDefaultLocale

public Locale getDefaultLocale()
Specified by:
getDefaultLocale in interface ApplicationProperties

getStringsWithPrefix

public Collection getStringsWithPrefix(String prefix)
Specified by:
getStringsWithPrefix in interface ApplicationProperties


Copyright © 2002-2009 Atlassian. All Rights Reserved.