Record Class KeyedParameterResolver.Resolution<M>
java.lang.Object
java.lang.Record
io.fluxzero.common.handling.KeyedParameterResolver.Resolution<M>
- Type Parameters:
M- message type- Record Components:
matched- whether this resolver claims the parameterresolver- reusable current-message value resolver;nullfor unmatched or rejected outcomes
- Enclosing interface:
KeyedParameterResolver<M>
public static record KeyedParameterResolver.Resolution<M>(boolean matched, Function<? super M, Object> resolver)
extends Record
Cached outcome of evaluating one resolver for one handler parameter.
An unmatched resolution allows the next resolver to be considered. A rejected resolution claims the parameter but makes the handler inapplicable. A resolved outcome supplies a reusable value resolver.
-
Constructor Summary
ConstructorsConstructorDescriptionResolution(boolean matched, Function<? super M, Object> resolver) Creates an instance of aResolutionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanmatched()Returns the value of thematchedrecord component.static <M> KeyedParameterResolver.Resolution<M> rejected()Returns an outcome that rejects the handler without considering later resolvers.static <M> KeyedParameterResolver.Resolution<M> Returns an outcome backed by a reusable current-message value resolver.resolver()Returns the value of theresolverrecord component.final StringtoString()Returns a string representation of this record class.static <M> KeyedParameterResolver.Resolution<M> Returns an outcome that allows the next parameter resolver to be considered.
-
Constructor Details
-
Resolution
-
-
Method Details
-
unmatched
Returns an outcome that allows the next parameter resolver to be considered. -
rejected
Returns an outcome that rejects the handler without considering later resolvers. -
resolved
public static <M> KeyedParameterResolver.Resolution<M> resolved(Function<? super M, Object> resolver) Returns an outcome backed by a reusable current-message value resolver. -
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
matched
-
resolver
-