com.atlassian.jira.util.system
Class ExtendedSystemInfoUtilsImpl

java.lang.Object
  extended by com.atlassian.jira.util.system.ExtendedSystemInfoUtilsImpl
All Implemented Interfaces:
ExtendedSystemInfoUtils

public class ExtendedSystemInfoUtilsImpl
extends Object
implements ExtendedSystemInfoUtils

Implementation for the ExtendedSystemInfoUtils interface.

Since:
v3.13

Constructor Summary
  ExtendedSystemInfoUtilsImpl(I18nHelper i18nHelper)
           
protected ExtendedSystemInfoUtilsImpl(SystemInfoUtils systemInfoUtils, ServiceManager serviceManager, com.atlassian.plugin.PluginAccessor pluginAccessor, ApplicationProperties applicationProperties, TrustedApplicationService trustedAppService, org.ofbiz.core.entity.GenericDelegator delegator, I18nHelper i18nHelper, UserUtil userUtil, HashRegistryCache registry)
           
 
Method Summary
 String getBaseUrl()
           
 Map getBuildStats()
           
 String getDefaultLanguage()
           
 String getEntityEngineXmlPath()
           
 String getIndexLocation()
           
 Set getIPMatches(TrustedApplicationInfo info)
           
 Map getJvmStats()
           
 Map getLicenseInfo()
           
 Collection getListeners()
           
 String getLogPath()
           
 long getMillisecondsToMinutes(long ms)
           
 Collection getPlugins()
           
 Map getProps()
          Default is to hide sensitive system information (for the 500 page, etc.)
 Map getProps(boolean showSensitiveInfo)
           
 Map getServicePropertyMap(JiraServiceContainer serviceContainer)
           
 Collection getServices()
           
 SystemInfoUtils getSystemInfoUtils()
           
 Map getSystemPropertiesFormatted(String suffix)
          For each system properties, display the key and its value.
 Set getTrustedApplications(JiraServiceContext jiraServiceContext)
           
 Set getUrlMatches(TrustedApplicationInfo info)
           
 Map getUsageStats()
           
 boolean isJvmJava5OrGreater()
           
 boolean isPluginEnabled(com.atlassian.plugin.Plugin plugin)
           
 boolean isUsingSystemLocale()
          Checks whether the default locale has been set or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExtendedSystemInfoUtilsImpl

protected ExtendedSystemInfoUtilsImpl(SystemInfoUtils systemInfoUtils,
                                      ServiceManager serviceManager,
                                      com.atlassian.plugin.PluginAccessor pluginAccessor,
                                      ApplicationProperties applicationProperties,
                                      TrustedApplicationService trustedAppService,
                                      org.ofbiz.core.entity.GenericDelegator delegator,
                                      I18nHelper i18nHelper,
                                      UserUtil userUtil,
                                      HashRegistryCache registry)

ExtendedSystemInfoUtilsImpl

public ExtendedSystemInfoUtilsImpl(I18nHelper i18nHelper)
Method Detail

getSystemInfoUtils

public SystemInfoUtils getSystemInfoUtils()
Specified by:
getSystemInfoUtils in interface ExtendedSystemInfoUtils
Returns:
the SystemInfoUtils object

getProps

public Map getProps()
Description copied from interface: ExtendedSystemInfoUtils
Default is to hide sensitive system information (for the 500 page, etc.)

Specified by:
getProps in interface ExtendedSystemInfoUtils
Returns:
an ordered map of system properties

getProps

public Map getProps(boolean showSensitiveInfo)
Specified by:
getProps in interface ExtendedSystemInfoUtils
Parameters:
showSensitiveInfo - Whether to include sensitive system information (e.g. database URL)
Returns:
an ordered map of system properties

getSystemPropertiesFormatted

public Map getSystemPropertiesFormatted(String suffix)
Description copied from interface: ExtendedSystemInfoUtils
For each system properties, display the key and its value. If the value is a path, then break the paths at semi colons ';' (For non-windows operatin systems, breaks on colon ':' as well). The break is accomplished by replacing the ';' or ':' with the suffix string argument

Specified by:
getSystemPropertiesFormatted in interface ExtendedSystemInfoUtils
Parameters:
suffix - the string to add to the suffix of ';' and/or ':'
Returns:
Map of system property keys to its value

getLicenseInfo

public Map getLicenseInfo()
Specified by:
getLicenseInfo in interface ExtendedSystemInfoUtils
Returns:
details of the current license

getJvmStats

public Map getJvmStats()
Specified by:
getJvmStats in interface ExtendedSystemInfoUtils
Returns:
memory statistics for the JVM

getBuildStats

public Map getBuildStats()
Specified by:
getBuildStats in interface ExtendedSystemInfoUtils
Returns:
information about the current build of JIRA

getDefaultLanguage

public String getDefaultLanguage()
Specified by:
getDefaultLanguage in interface ExtendedSystemInfoUtils
Returns:
the default language set in the application's properties

getBaseUrl

public String getBaseUrl()
Specified by:
getBaseUrl in interface ExtendedSystemInfoUtils
Returns:
the base URL of the application

isUsingSystemLocale

public boolean isUsingSystemLocale()
Description copied from interface: ExtendedSystemInfoUtils
Checks whether the default locale has been set or not.

Specified by:
isUsingSystemLocale in interface ExtendedSystemInfoUtils
Returns:
true if default locale is set, false if using system locale

getUsageStats

public Map getUsageStats()
Specified by:
getUsageStats in interface ExtendedSystemInfoUtils
Returns:
usage statistics for the application (user counts, issue counts, etc)

getEntityEngineXmlPath

public String getEntityEngineXmlPath()
Specified by:
getEntityEngineXmlPath in interface ExtendedSystemInfoUtils
Returns:
the path to the entityengine.xml file

getLogPath

public String getLogPath()
Specified by:
getLogPath in interface ExtendedSystemInfoUtils
Returns:
the path to the atlassian-jira.log file

getIndexLocation

public String getIndexLocation()
Specified by:
getIndexLocation in interface ExtendedSystemInfoUtils
Returns:
the path to the application's index file

getListeners

public Collection getListeners()
Specified by:
getListeners in interface ExtendedSystemInfoUtils
Returns:
a collection of raw listener GVs

getServices

public Collection getServices()
Specified by:
getServices in interface ExtendedSystemInfoUtils
Returns:
a collection of JiraServiceContainers for each service

getServicePropertyMap

public Map getServicePropertyMap(JiraServiceContainer serviceContainer)
Specified by:
getServicePropertyMap in interface ExtendedSystemInfoUtils
Parameters:
serviceContainer - the service object to obtain properties for
Returns:
a map of properties relating to the service configuration

getMillisecondsToMinutes

public long getMillisecondsToMinutes(long ms)
Specified by:
getMillisecondsToMinutes in interface ExtendedSystemInfoUtils
Parameters:
ms - milliseconds
Returns:
the number of minutes represented by the specified number of milliseconds

getPlugins

public Collection getPlugins()
Specified by:
getPlugins in interface ExtendedSystemInfoUtils
Returns:
a collection of plugins

isPluginEnabled

public boolean isPluginEnabled(com.atlassian.plugin.Plugin plugin)
Specified by:
isPluginEnabled in interface ExtendedSystemInfoUtils
Parameters:
plugin - the plugin
Returns:
true if the plugin is currently enabled; false otherwise

getTrustedApplications

public Set getTrustedApplications(JiraServiceContext jiraServiceContext)
Specified by:
getTrustedApplications in interface ExtendedSystemInfoUtils
Parameters:
jiraServiceContext - the JIRA service context
Returns:
a set of TrustedApplicationInfo objects

getIPMatches

public Set getIPMatches(TrustedApplicationInfo info)
Specified by:
getIPMatches in interface ExtendedSystemInfoUtils
Parameters:
info - the trusted application
Returns:
the set of IP matches defined for this trusted app

getUrlMatches

public Set getUrlMatches(TrustedApplicationInfo info)
Specified by:
getUrlMatches in interface ExtendedSystemInfoUtils
Parameters:
info - the trusted application
Returns:
the set of URL matches defined for this trusted app

isJvmJava5OrGreater

public boolean isJvmJava5OrGreater()
Specified by:
isJvmJava5OrGreater in interface ExtendedSystemInfoUtils
Returns:
true if using a 1.5 or higher JVM, false otherwise.


Copyright © 2002-2009 Atlassian. All Rights Reserved.