Package org.alfresco.util
Class RuntimeSystemPropertiesSetter
- java.lang.Object
-
- org.alfresco.util.RuntimeSystemPropertiesSetter
-
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.beans.factory.config.BeanFactoryPostProcessor,org.springframework.context.ApplicationContextAware,org.springframework.core.Ordered,org.springframework.core.PriorityOrdered
public class RuntimeSystemPropertiesSetter extends java.lang.Object implements org.springframework.beans.factory.config.BeanFactoryPostProcessor, org.springframework.context.ApplicationContextAware, org.springframework.core.PriorityOrderedSets runtime JVM system properties for Spring Framework.This class is used by the Spring framework to inject system properties into the runtime environment (e.g.: alfresco.jmx.dir). The motivation for this is that certain values must be set within spring must be computed in advance for org.springframework.beans.factory.config.PropertyPlaceholderConfigurer to work properly.
- Author:
- Jon Cox
- See Also:
setJvmProperties(Map)
-
-
Constructor Summary
Constructors Constructor Description RuntimeSystemPropertiesSetter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetOrder()voidpostProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory)voidsetApplicationContext(org.springframework.context.ApplicationContext applicationContext)voidsetJvmProperties(java.util.Map<java.lang.String,java.lang.String> jvmProperties)Set the properties that will get pushed into the JVM system properties.voidsetOrder(int order)
-
-
-
Method Detail
-
setJvmProperties
public void setJvmProperties(java.util.Map<java.lang.String,java.lang.String> jvmProperties)
Set the properties that will get pushed into the JVM system properties. This will be akin to running the JVM with the -Dprop=value. Existing system JVM properties will not be overwritten.- Parameters:
jvmProperties- properties to set if they are not already present in the VM
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException- Specified by:
setApplicationContextin interfaceorg.springframework.context.ApplicationContextAware- Throws:
org.springframework.beans.BeansException
-
postProcessBeanFactory
public void postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory) throws org.springframework.beans.BeansException- Specified by:
postProcessBeanFactoryin interfaceorg.springframework.beans.factory.config.BeanFactoryPostProcessor- Throws:
org.springframework.beans.BeansException
-
setOrder
public void setOrder(int order)
-
getOrder
public int getOrder()
- Specified by:
getOrderin interfaceorg.springframework.core.Ordered
-
-