Class ExternalPreferredListener

    • Field Detail

      • PREFERRED_ACTION_ARGUMENT

        public static final java.lang.String PREFERRED_ACTION_ARGUMENT
        Argument for Preferred action
        See Also:
        Constant Field Values
    • Constructor Detail

      • ExternalPreferredListener

        public ExternalPreferredListener()
    • Method Detail

      • accept

        public boolean accept​(IndexerEvent event)
        Skip parent class processing, except autoArchiving.
        Overrides:
        accept in class DefaultIndexerListener
        Parameters:
        event - the indexer event that has occurred
        Returns:
        whether this external indexer listener handles this product type
      • getIndexerChangePreferredActions

        public static java.util.Map<ProductSummary,​ExternalPreferredListener.PreferredAction> getIndexerChangePreferredActions​(IndexerChange change)
        Compare preferred products before/after IndexerChange was applied.
        Parameters:
        change - indexer change to evaluate.
        Returns:
        map of preferred products that were changed.
      • getPreferredProducts

        public static java.util.Map<java.lang.String,​ProductSummary> getPreferredProducts​(Event event)
        Get a map of preferred products from an event.
        Parameters:
        event - the event.
        Returns:
        preferred products, or empty hashmap if event is null.