Interface RelatedItemsCollector

All Known Implementing Classes:
DefaultRelatedItemsCollector

public interface RelatedItemsCollector
An interface represents collector that gathers relevant items for a given theSource.

Note:
Please see ItemVisitorRegistry ItemVisitor for more information

  • Field Details

  • Method Details

    • collect

      <T extends ItemModel> List<ItemModel> collect(T theSource, Map<String,Object> ctx)
      Travers given theSource item against best matching ItemVisitor and returns all collected relatives. Note:
      Type Parameters:
      T - specific model class derived from ItemModel
      Parameters:
      theSource - given item
      ctx - ctx given context
      Returns:
      all relatives for a given theSource item
    • collect

      <T extends ItemModel> List<ItemModel> collect(T theSource, ItemVisitor<T> theStrategy, Map<String,Object> ctx)
      Travers given theSource item against given ItemVisitor and returns all collected relatives.
      Type Parameters:
      T - specific model class derived from ItemModel
      Parameters:
      theSource - given item
      theStrategy - given ItemVisitor
      ctx - given context
      Returns:
      all relatives for a given theSource item and given theStrategy