パッケージ org.springframework.boot
クラス DefaultPropertiesPropertySource
java.lang.ObjectSE
org.springframework.core.env.PropertySource<T>
org.springframework.core.env.EnumerablePropertySource<MapSE<StringSE,ObjectSE>>
org.springframework.core.env.MapPropertySource
org.springframework.boot.DefaultPropertiesPropertySource
デフォルトのプロパティを含む
MapPropertySource
は、SpringApplication
に直接貢献しました。慣例により、DefaultPropertiesPropertySource
は常に Environment
の最後のプロパティソースです。- 導入:
- 2.4.0
- 作成者:
- Phillip Webb
ネストされたクラスのサマリー
クラス org.springframework.core.env.PropertySource から継承されたネストクラス / インターフェース
PropertySource.StubPropertySource
フィールドのサマリー
フィールドクラス org.springframework.core.env.PropertySource から継承されたフィールド
logger, name, source
コンストラクターの概要
コンストラクターメソッドのサマリー
修飾子と型メソッド説明static void
addOrMerge
(MapSE<StringSE, ObjectSE> source, MutablePropertySources sources) 新しいDefaultPropertiesPropertySource
を追加するか、既存のDefaultPropertiesPropertySource
とマージします。static boolean
hasMatchingName
(PropertySource<?> propertySource) 指定されたソースの名前が "defaultProperties" の場合、true
を返します。static void
ifNotEmpty
(MapSE<StringSE, ObjectSE> source, ConsumerSE<DefaultPropertiesPropertySource> action) 提供されたソースが空でない場合は、新しいDefaultPropertiesPropertySource
インスタンスを作成します。static void
moveToEnd
(ConfigurableEnvironment environment) 'defaultProperties' プロパティソースを、指定されたConfigurableEnvironment
の最後のソースになるように移動します。static void
moveToEnd
(MutablePropertySources propertySources) 'defaultProperties' プロパティソースを、指定されたMutablePropertySources
の最後のソースになるように移動します。クラス org.springframework.core.env.MapPropertySource から継承されたメソッド
containsProperty, getProperty, getPropertyNames
フィールドの詳細
NAME
' デフォルトプロパティ ' プロパティソースの名前。- 関連事項:
コンストラクターの詳細
DefaultPropertiesPropertySource
指定されたMap
ソースを使用して新しいDefaultPropertiesPropertySource
を作成します。- パラメーター:
source
- ソースマップ
メソッドの詳細
hasMatchingName
指定されたソースの名前が "defaultProperties" の場合、true
を返します。- パラメーター:
propertySource
- チェックするプロパティソース- 戻り値:
- 名前が一致する場合は
true
ifNotEmpty
public static void ifNotEmpty(MapSE<StringSE, ObjectSE> source, ConsumerSE<DefaultPropertiesPropertySource> action) 提供されたソースが空でない場合は、新しいDefaultPropertiesPropertySource
インスタンスを作成します。- パラメーター:
source
-Map
ソースaction
-DefaultPropertiesPropertySource
を消費するために使用されるアクション
addOrMerge
新しいDefaultPropertiesPropertySource
を追加するか、既存のDefaultPropertiesPropertySource
とマージします。- パラメーター:
source
-Map
ソースsources
- 既存のソース- 導入:
- 2.4.4
moveToEnd
'defaultProperties' プロパティソースを、指定されたConfigurableEnvironment
の最後のソースになるように移動します。- パラメーター:
environment
- 更新する環境
moveToEnd
'defaultProperties' プロパティソースを、指定されたMutablePropertySources
の最後のソースになるように移動します。- パラメーター:
propertySources
- 更新するプロパティソース