Package org.springframework.aot.hint
Class ResourceHints
java.lang.Object
org.springframework.aot.hint.ResourceHints
Gather the need for resources available at runtime.
- Since:
- 6.0
- Author:
- Stephane Nicoll
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionregisterPattern
(String include) Register that the resources matching the specified pattern should be made available at runtime.registerPattern
(String include, Consumer<ResourcePatternHint.Builder> resourceHint) Register that the resources matching the specified pattern should be made available at runtime.registerResourceBundle
(String baseName) Register that the resource bundle with the specified base name should be made available at runtime.registerType
(Class<?> type) Register that the bytecode of the specified type should be made available at runtime.registerType
(TypeReference type) Register that the bytecode of the type defined by the specifiedTypeReference
should be made available at runtime.Return the resource bundles that should be made available at runtime.Return the resources that should be made available at runtime.
-
Constructor Details
-
ResourceHints
public ResourceHints()
-
-
Method Details
-
resourcePatterns
Return the resources that should be made available at runtime.- Returns:
- a stream of
ResourcePatternHint
-
resourceBundles
Return the resource bundles that should be made available at runtime.- Returns:
- a stream of
ResourceBundleHint
-
registerPattern
public ResourceHints registerPattern(String include, Consumer<ResourcePatternHint.Builder> resourceHint) Register that the resources matching the specified pattern should be made available at runtime.- Parameters:
include
- a pattern of the resources to includeresourceHint
- a builder to further customize the resource pattern- Returns:
this
, to facilitate method chaining
-
registerPattern
Register that the resources matching the specified pattern should be made available at runtime.- Parameters:
include
- a pattern of the resources to include- Returns:
this
, to facilitate method chaining
-
registerType
Register that the bytecode of the type defined by the specifiedTypeReference
should be made available at runtime.- Parameters:
type
- the type to include- Returns:
this
, to facilitate method chaining
-
registerType
Register that the bytecode of the specified type should be made available at runtime.- Parameters:
type
- the type to include- Returns:
this
, to facilitate method chaining
-
registerResourceBundle
Register that the resource bundle with the specified base name should be made available at runtime.- Parameters:
baseName
- the base name of the resource bundle- Returns:
this
, to facilitate method chaining
-