public class ConfigurationPropertiesHierarchyBuilder extends Object
ConfigurationPropertiesResolver with the full hierarchy, considering the properties to be used. The
hierarchy to consider is:
| Constructor and Description |
|---|
ConfigurationPropertiesHierarchyBuilder() |
| Modifier and Type | Method and Description |
|---|---|
ConfigurationPropertiesResolver |
build() |
ConfigurationPropertiesHierarchyBuilder |
withApplicationProperties(org.mule.runtime.properties.api.ConfigurationPropertiesProvider provider)
Sets a
ConfigurationPropertiesProvider to use as application property, gotten from a custom provider (such as the
Secure Configuration Properties) or properties set with the configuration-properties tag. |
ConfigurationPropertiesHierarchyBuilder |
withDeploymentProperties(Map<String,String> properties) |
ConfigurationPropertiesHierarchyBuilder |
withDomainPropertiesResolver(org.mule.runtime.api.component.ConfigurationProperties domainProperties)
Sets to consider the domain properties in the hierarchy, setting a previously resolved
ConfigurationProperty to
reoslve. |
ConfigurationPropertiesHierarchyBuilder |
withEnvironmentProperties()
Sets that environment properties (from OS) should be considered in the hierarchy.
|
ConfigurationPropertiesHierarchyBuilder |
withGlobalPropertiesSupplier(Supplier<Map<String,org.mule.runtime.properties.api.ConfigurationProperty>> globalPropertiesSupplier)
Sets a supplier to retrieve the Global Properties from.
|
ConfigurationPropertiesHierarchyBuilder |
withoutFailuresIfPropertyNotPresent()
Set that the
ConfigurationPropertiesResolver to be built won't fail in case of resolving a property doesn't exist. |
ConfigurationPropertiesHierarchyBuilder |
withPropertiesFile(org.mule.runtime.properties.api.ResourceProvider resourceProvider)
Sets an external resource provider to get the file content to then use a File Configuration Property.
|
ConfigurationPropertiesHierarchyBuilder |
withSystemProperties()
Sets that system properties added to the JVM are considered in the hierarchy.
|
public ConfigurationPropertiesHierarchyBuilder()
public ConfigurationPropertiesHierarchyBuilder withDeploymentProperties(Map<String,String> properties)
properties - the deployment properties to consider, as a map.public ConfigurationPropertiesHierarchyBuilder withSystemProperties()
public ConfigurationPropertiesHierarchyBuilder withEnvironmentProperties()
public ConfigurationPropertiesHierarchyBuilder withPropertiesFile(org.mule.runtime.properties.api.ResourceProvider resourceProvider)
resourceProvider - the ResourceProvider to use to read the files to use when resolving a file-value property.public ConfigurationPropertiesHierarchyBuilder withApplicationProperties(org.mule.runtime.properties.api.ConfigurationPropertiesProvider provider)
ConfigurationPropertiesProvider to use as application property, gotten from a custom provider (such as the
Secure Configuration Properties) or properties set with the configuration-properties tag.provider - the ConfigurationPropertiesProvider to add to the hierarchy as Application Properties.public ConfigurationPropertiesHierarchyBuilder withGlobalPropertiesSupplier(Supplier<Map<String,org.mule.runtime.properties.api.ConfigurationProperty>> globalPropertiesSupplier)
public ConfigurationPropertiesHierarchyBuilder withDomainPropertiesResolver(org.mule.runtime.api.component.ConfigurationProperties domainProperties)
ConfigurationProperty to
reoslve.domainProperties - the ConfigurationProperties previously generated for the domain, to be used in this
hierarchy.public ConfigurationPropertiesHierarchyBuilder withoutFailuresIfPropertyNotPresent()
ConfigurationPropertiesResolver to be built won't fail in case of resolving a property doesn't exist.
Instead of throwing a PropertyNotFoundException, it will return
null.public ConfigurationPropertiesResolver build()
ConfigurationPropertiesResolver that includes the complete hierarchy with the defined resolvers.Copyright © 2003–2022 MuleSoft, Inc.. All rights reserved.