Class DefaultProviderSelection
java.lang.Object
org.jdrupes.builder.core.DefaultProviderSelection
- All Implemented Interfaces:
ProviderSelection
The Class DefaultBoundResourceQuery.
-
Method Summary
Modifier and TypeMethodDescriptionfilter(Predicate<ResourceProvider> filter) Only include theResourceProviders for which the filter evaluates totrue.onBeforeUse(Consumer<ResourceProvider> hook) Register a callback for logging the provider invocation.resources(ResourceRequest<T> requested) Returns the requested resources using the providers with the requested intents from the project passed to constructor and the defined filters.Returns the providers with the requested intents from the project matching the defined filters.without(Class<? extends ResourceProvider> providerType) Exclude providers of the given type when fetching resources.without(ResourceProvider provider) Exclude the given provider when fetching resources.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ProviderSelection
select
-
Method Details
-
filter
Description copied from interface:ProviderSelectionOnly include theResourceProviders for which the filter evaluates totrue.- Specified by:
filterin interfaceProviderSelection- Parameters:
filter- the filter- Returns:
- the provider selection
-
without
Description copied from interface:ProviderSelectionExclude the given provider when fetching resources.- Specified by:
withoutin interfaceProviderSelection- Parameters:
provider- the provider- Returns:
- the bound resource query
-
without
Description copied from interface:ProviderSelectionExclude providers of the given type when fetching resources.- Specified by:
withoutin interfaceProviderSelection- Parameters:
providerType- the provider type- Returns:
- the bound resource query
-
onBeforeUse
Description copied from interface:ProviderSelectionRegister a callback for logging the provider invocation.- Specified by:
onBeforeUsein interfaceProviderSelection- Parameters:
hook- the hook- Returns:
- the bound resource query
-
select
Description copied from interface:ProviderSelectionReturns the providers with the requested intents from the project matching the defined filters.- Specified by:
selectin interfaceProviderSelection- Parameters:
intents- the intents- Returns:
- the stream
-
resources
Description copied from interface:ProviderSelectionReturns the requested resources using the providers with the requested intents from the project passed to constructor and the defined filters.- Specified by:
resourcesin interfaceProviderSelection- Type Parameters:
T- the requested resource type- Parameters:
requested- the resource request- Returns:
- the stream
-