Class EnvironmentManager
java.lang.Object
org.springframework.cloud.context.environment.EnvironmentManager
- All Implemented Interfaces:
org.springframework.beans.factory.Aware, org.springframework.context.ApplicationEventPublisherAware
@Component
@ManagedResource
public class EnvironmentManager
extends Object
implements org.springframework.context.ApplicationEventPublisherAware
Entry point for making local (but volatile) changes to the
Environment of a
running application. Allows properties to be added and values changed, simply by adding
them to a high-priority property source in the existing Environment.- Author:
- Dave Syer
-
Constructor Summary
ConstructorsConstructorDescriptionEnvironmentManager(org.springframework.core.env.ConfigurableEnvironment environment) -
Method Summary
Modifier and TypeMethodDescriptiongetProperty(String name) reset()voidsetApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher publisher) voidsetProperty(String name, String value)
-
Constructor Details
-
EnvironmentManager
public EnvironmentManager(org.springframework.core.env.ConfigurableEnvironment environment)
-
-
Method Details
-
setApplicationEventPublisher
public void setApplicationEventPublisher(org.springframework.context.ApplicationEventPublisher publisher) - Specified by:
setApplicationEventPublisherin interfaceorg.springframework.context.ApplicationEventPublisherAware
-
reset
-
setProperty
-
getProperty
-