Top Description Fields Constructors Methods
org.springframework.aot.hint.predicate

public abstract Class RuntimeHintsPredicates

extends Object
Class Inheritance
Imports
org.springframework.aot.hint.ProxyHints, .ReflectionHints, .ResourceHints, .RuntimeHints, .RuntimeHintsRegistrar, .SerializationHints

Static generator of predicates that test whether the given RuntimeHints instance matches the expected behavior for reflection, resource, serialization, or proxy generation.

This utility class can be used by RuntimeHintsRegistrar to conditionally register hints depending on what's present already. This can also be used as a testing utility for checking proper registration of hints:

Predicate<RuntimeHints> predicate = RuntimeHintsPredicates.reflection().onMethod(MyClass.class, "someMethod").invoke();
assertThat(predicate).accepts(runtimeHints);
Authors
Brian Clozel, Stephane Nicoll
Since
6.0

Field Summary

Modifier and TypeField and Description
private static final ProxyHintsPredicates
private static final ReflectionHintsPredicates
private static final ResourceHintsPredicates
private static final SerializationHintsPredicates

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public static ProxyHintsPredicates

Returns:

the predicate generator
proxies
()

Return a predicate generator for proxy hints.

public static ReflectionHintsPredicates

Returns:

the predicate generator
reflection
()

Return a predicate generator for reflection hints.

public static ResourceHintsPredicates

Returns:

the predicate generator
resource
()

Return a predicate generator for resource hints.

public static SerializationHintsPredicates

Returns:

the predicate generator
serialization
()

Return a predicate generator for serialization hints.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

proxiesback to summary
private static final ProxyHintsPredicates proxies
reflectionback to summary
private static final ReflectionHintsPredicates reflection
resourceback to summary
private static final ResourceHintsPredicates resource
serializationback to summary
private static final SerializationHintsPredicates serialization

Constructor Detail

RuntimeHintsPredicatesback to summary
private RuntimeHintsPredicates()

Method Detail

proxiesback to summary
public static ProxyHintsPredicates proxies()

Return a predicate generator for proxy hints.

Returns:ProxyHintsPredicates

the predicate generator

reflectionback to summary
public static ReflectionHintsPredicates reflection()

Return a predicate generator for reflection hints.

Returns:ReflectionHintsPredicates

the predicate generator

resourceback to summary
public static ResourceHintsPredicates resource()

Return a predicate generator for resource hints.

Returns:ResourceHintsPredicates

the predicate generator

serializationback to summary
public static SerializationHintsPredicates serialization()

Return a predicate generator for serialization hints.

Returns:SerializationHintsPredicates

the predicate generator