Class Functions<T>

    • Constructor Detail

      • Functions

        public Functions()
    • Method Detail

      • getLevelingFunction

        public Map<T,​Integer> getLevelingFunction()
        returns the ranking function
        Returns:
        ranking function
      • generatePreferenceOrder

        public abstract PreferenceOrder<T> generatePreferenceOrder()
        this method returns a preference order made out of an ranking function
        Returns:
        a preference order out of a given ranking function
      • get

        public Integer get​(Object key)
        returns the value to a given key
        Specified by:
        get in interface Map<T,​Integer>
        Overrides:
        get in class HashMap<T,​Integer>
        Returns:
        the value if present, null otherwise (but value.equals(null) is possible)
      • getElementsByValue

        public Set<Map.Entry<T,​Integer>> getElementsByValue​(int val)
        returns an entry set of all elements in this ranking function with the same rank (= value)
        Parameters:
        val - the rank of the elements searched
        Returns:
        an entry set of all elements in this ranking function with the same rank (= value)
      • getPredecessors

        public Set<Map.Entry<T,​Integer>> getPredecessors​(Map.Entry<T,​Integer> element)
        returns a set of predecessor elements for the given entry
        Parameters:
        element - the given entry
        Returns:
        a set of predecessor elements for the given entry
      • getSuccessors

        public Set<Map.Entry<T,​Integer>> getSuccessors​(Map.Entry<T,​Integer> element)
        returns a set of successor elements for the given entry
        Parameters:
        element - the given entry
        Returns:
        a set of successor elements for the given entry
      • weakenElement

        public abstract void weakenElement​(T element)
        weakens the given element in the function
        Parameters:
        element - the element being weakened
      • strengthenElement

        public abstract void strengthenElement​(T element)
        strengthens the given element in the function
        Parameters:
        element - the element being strengthened