Class MethodDelegationBinder.AmbiguityResolver.Compound
- java.lang.Object
-
- net.bytebuddy.implementation.bind.MethodDelegationBinder.AmbiguityResolver.Compound
-
- All Implemented Interfaces:
MethodDelegationBinder.AmbiguityResolver
- Enclosing interface:
- MethodDelegationBinder.AmbiguityResolver
@Enhance public static class MethodDelegationBinder.AmbiguityResolver.Compound extends java.lang.Object implements MethodDelegationBinder.AmbiguityResolver
A chain ofMethodDelegationBinder.AmbiguityResolver
s that are applied in the given order until two bindings can be resolved.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.implementation.bind.MethodDelegationBinder.AmbiguityResolver
MethodDelegationBinder.AmbiguityResolver.Compound, MethodDelegationBinder.AmbiguityResolver.Directional, MethodDelegationBinder.AmbiguityResolver.NoOp, MethodDelegationBinder.AmbiguityResolver.Resolution
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<MethodDelegationBinder.AmbiguityResolver>
ambiguityResolvers
A list of ambiguity resolvers that are applied by this chain in their order of application.-
Fields inherited from interface net.bytebuddy.implementation.bind.MethodDelegationBinder.AmbiguityResolver
DEFAULT
-
-
Constructor Summary
Constructors Constructor Description Compound(java.util.List<? extends MethodDelegationBinder.AmbiguityResolver> ambiguityResolvers)
Creates an immutable chain of ambiguity resolvers.Compound(MethodDelegationBinder.AmbiguityResolver... ambiguityResolver)
Creates an immutable chain of ambiguity resolvers.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MethodDelegationBinder.AmbiguityResolver.Resolution
resolve(MethodDescription source, MethodDelegationBinder.MethodBinding left, MethodDelegationBinder.MethodBinding right)
Attempts to resolve to conflicting bindings.
-
-
-
Field Detail
-
ambiguityResolvers
private final java.util.List<MethodDelegationBinder.AmbiguityResolver> ambiguityResolvers
A list of ambiguity resolvers that are applied by this chain in their order of application.
-
-
Constructor Detail
-
Compound
public Compound(MethodDelegationBinder.AmbiguityResolver... ambiguityResolver)
Creates an immutable chain of ambiguity resolvers.- Parameters:
ambiguityResolver
- The ambiguity resolvers to chain in the order of their application.
-
Compound
public Compound(java.util.List<? extends MethodDelegationBinder.AmbiguityResolver> ambiguityResolvers)
Creates an immutable chain of ambiguity resolvers.- Parameters:
ambiguityResolvers
- The ambiguity resolvers to chain in the order of their application.
-
-
Method Detail
-
resolve
public MethodDelegationBinder.AmbiguityResolver.Resolution resolve(MethodDescription source, MethodDelegationBinder.MethodBinding left, MethodDelegationBinder.MethodBinding right)
Attempts to resolve to conflicting bindings.- Specified by:
resolve
in interfaceMethodDelegationBinder.AmbiguityResolver
- Parameters:
source
- The source method that was bound to both target methods.left
- The first successful binding of thesource
method.right
- The second successful binding of thesource
method.- Returns:
- The resolution state when resolving a conflicting binding where
MethodDelegationBinder.AmbiguityResolver.Resolution.LEFT
indicates a successful binding to theleft
binding whileMethodDelegationBinder.AmbiguityResolver.Resolution.RIGHT
indicates a successful binding to theright
binding.
-
-