EndpointResolverFactory<Endpoint> resolverFactory =
(EndpointResolverFactory<Endpoint>)endpointResolverFactories.getEndpointResolverFactory(endpoint.getClass());
if (resolverFactory != null) {
@SuppressWarnings("unchecked")
EndpointResolver endpointResolver =
resolverFactory.createEndpointResolver(endpoint, null);
if (endpointResolver != null) {
((RuntimeComponentReference)reference).setEndpointResolver(endpoint, endpointResolver);
}