Class CmsPublishRelationFinder.ResourceMap

    • Nested Class Summary

      • Nested classes/interfaces inherited from class java.util.AbstractMap

        java.util.AbstractMap.SimpleEntry<K extends java.lang.Object,​V extends java.lang.Object>, java.util.AbstractMap.SimpleImmutableEntry<K extends java.lang.Object,​V extends java.lang.Object>
      • Nested classes/interfaces inherited from interface java.util.Map

        java.util.Map.Entry<K extends java.lang.Object,​V extends java.lang.Object>
    • Constructor Summary

      Constructors 
      Constructor Description
      ResourceMap()
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      CmsPublishRelationFinder.ResourceMap filter​(com.google.common.base.Predicate<CmsResource> pred)
      Creates a new resource map based on this instance while filtering some elements out.
      java.util.Set<CmsResource> get​(java.lang.Object res)  
      int totalSize()
      Returns the sum of all sizes of set values.
      • Methods inherited from class java.util.HashMap

        clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
      • Methods inherited from class java.util.AbstractMap

        equals, hashCode, toString
      • Methods inherited from class java.lang.Object

        finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Map

        equals, hashCode
    • Constructor Detail

    • Method Detail

      • filter

        public CmsPublishRelationFinder.ResourceMap filter​(com.google.common.base.Predicate<CmsResource> pred)
        Creates a new resource map based on this instance while filtering some elements out.

        The given predicate is used to check whether any single resource should be kept. If it returns false for a top-level resource (map key), the parent will be removed and all its children added as keys. If it returns false for a map value, the value will be removed for its key.

        Parameters:
        pred - predicate to check whether resources should be kept
        Returns:
        the new filtered resource map
      • totalSize

        public int totalSize()
        Returns the sum of all sizes of set values.

        Returns:
        the total size