Class ResourceHintsPredicates
java.lang.Object
org.springframework.aot.hint.predicate.ResourceHintsPredicates
Generator of 
ResourceHints predicates, testing whether the given hints
 match the expected behavior for resources.- Since:
 - 6.0
 - Author:
 - Brian Clozel, Stephane Nicoll, Sam Brannen
 
- 
Method Summary
Modifier and TypeMethodDescriptionReturn a predicate that checks whether a resource hint is registered for the given bundle name.forResource(String resourceName) Return a predicate that checks whether a resource hint is registered for the given resource name.forResource(TypeReference type, String resourceName) Return a predicate that checks whether a resource hint is registered for the given resource name, located in the given type's package. 
- 
Method Details
- 
forBundle
Return a predicate that checks whether a resource hint is registered for the given bundle name.- Parameters:
 bundleName- the resource bundle name- Returns:
 - the 
RuntimeHintspredicate 
 - 
forResource
Return a predicate that checks whether a resource hint is registered for the given resource name, located in the given type's package.For example,
forResource(org.example.MyClass, "myResource.txt")will match against"org/example/myResource.txt".If the given resource name is an absolute path (i.e., starts with a leading slash), the supplied type will be ignored. For example,
forResource(org.example.MyClass, "/myResource.txt")will match against"myResource.txt".- Parameters:
 type- the type's package where to look for the resourceresourceName- the resource name- Returns:
 - the 
RuntimeHintspredicate 
 - 
forResource
Return a predicate that checks whether a resource hint is registered for the given resource name.A leading slash will be removed.
- Parameters:
 resourceName- the absolute resource name- Returns:
 - the 
RuntimeHintspredicate 
 
 -