Class FilteredCollection<A>
java.lang.Object
microsim.FilteredCollection<A>
-
Constructor Summary
ConstructorsConstructorDescriptionFilteredCollection(Supplier<? extends Collection<? extends A>> source, Predicate<? super A> predicate) Create a lazy filtered collection. -
Method Summary
Modifier and TypeMethodDescriptionCreate a new filtered collection derived from this one byand-ing both predicates.get()Apply the filtering.negate()Create a new filtered collection derived from this one by negating the predicate.once()Wrap theFilteredCollectionin aOncecache.oncePerSimTime(SimulationEngine engine) Wrap theFilteredCollectionin aOnceUntilcache that checks when the simulation time changes.Create a new filtered collection derived from this one byor-ing both predicates.
-
Constructor Details
-
FilteredCollection
public FilteredCollection(Supplier<? extends Collection<? extends A>> source, Predicate<? super A> predicate) Create a lazy filtered collection.
-
-
Method Details
-
and
Create a new filtered collection derived from this one byand-ing both predicates. -
or
Create a new filtered collection derived from this one byor-ing both predicates. -
negate
Create a new filtered collection derived from this one by negating the predicate. -
get
-
once
Wrap theFilteredCollectionin aOncecache. -
oncePerSimTime
Wrap theFilteredCollectionin aOnceUntilcache that checks when the simulation time changes.
-