public interface AllocationStrategy
AllocationStrategy
defines an interface of resource allocation strategies.Modifier and Type | Method and Description |
---|---|
<T> T |
next(java.util.Collection<T> domain,
java.util.Collection<T> exclude,
java.util.Collection<T> used,
java.util.Map<java.lang.String,java.lang.String> attributes)
Chooses an object.
|
<T> T |
next(Supplier<T> supplier,
java.util.Collection<T> exclude,
java.util.Collection<T> used,
java.util.Map<java.lang.String,java.lang.String> attributes)
Generates an object.
|
<T> T next(java.util.Collection<T> domain, java.util.Collection<T> exclude, java.util.Collection<T> used, java.util.Map<java.lang.String,java.lang.String> attributes)
T
- type of objects.domain
- the set of all available objects.exclude
- the set of objects to be excluded.used
- the of used objects.attributes
- the allocation parameters.null
.<T> T next(Supplier<T> supplier, java.util.Collection<T> exclude, java.util.Collection<T> used, java.util.Map<java.lang.String,java.lang.String> attributes)
T
- type of objects.supplier
- the object generator.exclude
- the set of objects to be excluded.used
- the set of used objects.attributes
- the allocation parameters parameters.null
.