Class DefaultEndpointResolver<EndpointType extends Endpoint>

Type Parameters:
EndpointType - type of endpoint
All Implemented Interfaces:
Component, DestructableComponent, IdentifiedComponent, InitializableComponent, Resolver<EndpointType,​CriteriaSet>, EndpointResolver<EndpointType>

public class DefaultEndpointResolver<EndpointType extends Endpoint>
extends AbstractEndpointResolver<EndpointType>
Default implementation that performs additional endpoint validation.

The supported Criterion types and their use follows:

Requires that the candidate endpoint's various attributes match the attributes found in the criterion.
Requires that the candidate endpoint's Binding attribute is among the bindings included in the criterion.
  • Field Details

    • log

      @Nonnull private org.slf4j.Logger log
      Class logger.
  • Constructor Details

    • DefaultEndpointResolver

      public DefaultEndpointResolver()
  • Method Details

    • doCheckEndpoint

      protected boolean doCheckEndpoint​(@Nonnull CriteriaSet criteria, @Nonnull EndpointType endpoint)
      Apply the supplied criteria to a candidate endpoint to determine its suitability.
      doCheckEndpoint in class AbstractEndpointResolver<EndpointType extends Endpoint>
      criteria - input criteria set
      endpoint - candidate endpoint
      true iff the endpoint meets the supplied criteria
    • checkBindingCriterion

      private boolean checkBindingCriterion​(@Nonnull BindingCriterion bindings, @Nonnull EndpointType endpoint)
      Verify the candidate's Binding attribute, if set, is among the set in the supplied criterion.
      bindings - the bindings to allow
      endpoint - the candidate endpoint
      true iff the candidate has no Binding, or its Binding is permitted
    • checkEndpointCriterion

      private boolean checkEndpointCriterion​(@Nonnull EndpointCriterion<EndpointType> comparison, @Nonnull EndpointType endpoint)
      Verify the candidate's attributes match any attributes supplied in the criterion.
      comparison - the endpoint to compare against
      endpoint - the candidate endpoint
      true iff the candidate's attributes match those of the criterion