Class FilteredIngredientCollectionLikeSingleClassifiedIterator<T,M,I,C,L extends IIngredientCollectionLike<T,M,I>>

java.lang.Object
org.cyclops.cyclopscore.ingredient.collection.FilteredIngredientCollectionLikeSingleClassifiedIterator<T,M,I,C,L>
Type Parameters:
T - The instance type.
M - The matching condition parameter.
I - The type that can be iterated over. This is typically just T.
C - A classifier type.
L - The collection-like type that is being used to store classified partitions.
All Implemented Interfaces:
Iterator<I>

public class FilteredIngredientCollectionLikeSingleClassifiedIterator<T,M,I,C,L extends IIngredientCollectionLike<T,M,I>> extends Object implements Iterator<I>
A filtered iterator over a collection that has the IIngredientCollectionLikeSingleClassifiedTrait trait.
  • Constructor Details

    • FilteredIngredientCollectionLikeSingleClassifiedIterator

      public FilteredIngredientCollectionLikeSingleClassifiedIterator(IIngredientCollectionLikeSingleClassifiedTrait<T,M,I,C,L> classifiedCollection, IIngredientMatcher<T,M> matcher, T instance, M matchCondition)
      Create a new instance.
      Parameters:
      classifiedCollection - The classified collection this iterator is created for.
      matcher - A matcher for the type of instances.
      instance - An instance to match.
      matchCondition - A match condition to filter by.
  • Method Details

    • findNext

      protected I findNext()
    • hasNext

      public boolean hasNext()
      Specified by:
      hasNext in interface Iterator<T>
    • next

      public I next()
      Specified by:
      next in interface Iterator<T>
    • remove

      public void remove()
      Specified by:
      remove in interface Iterator<T>