Class ObservableCachingLayout<V,​E>

    • Field Detail

      • locations

        protected com.google.common.cache.LoadingCache<V,​java.awt.geom.Point2D> locations
    • Constructor Detail

      • ObservableCachingLayout

        public ObservableCachingLayout​(Layout<V,​E> delegate)
    • Method Detail

      • initialize

        public void initialize()
        Description copied from interface: Layout
        Initializes fields in the node that may not have been set during the constructor. Must be called before the iterations begin.
        Specified by:
        initialize in interface Layout<V,​E>
        Overrides:
        initialize in class LayoutDecorator<V,​E>
      • done

        public boolean done()
        Specified by:
        done in interface IterativeContext
        Overrides:
        done in class LayoutDecorator<V,​E>
        Returns:
        true if this iterative process is finished, and false otherwise.
      • setLocation

        public void setLocation​(V v,
                                java.awt.geom.Point2D location)
        Description copied from interface: Layout
        Changes the layout coordinates of v to location.
        Specified by:
        setLocation in interface Layout<V,​E>
        Overrides:
        setLocation in class LayoutDecorator<V,​E>
        Parameters:
        v - the vertex whose location is to be specified
        location - the coordinates of the specified location
      • removeChangeListener

        public void removeChangeListener​(javax.swing.event.ChangeListener l)
        Description copied from interface: ChangeEventSupport
        Removes a ChangeListener.
        Specified by:
        removeChangeListener in interface ChangeEventSupport
        Parameters:
        l - the listener to be removed
      • getChangeListeners

        public javax.swing.event.ChangeListener[] getChangeListeners()
        Description copied from interface: ChangeEventSupport
        Returns an array of all the ChangeListeners added with addChangeListener().
        Specified by:
        getChangeListeners in interface ChangeEventSupport
        Returns:
        all of the ChangeListeners added or an empty array if no listeners have been added
      • clear

        public void clear()
        Description copied from interface: Caching
        clear cache
        Specified by:
        clear in interface Caching
      • init

        public void init()
        Description copied from interface: Caching
        ititialize resources for a cache
        Specified by:
        init in interface Caching
      • apply

        public java.awt.geom.Point2D apply​(V v)
        Specified by:
        apply in interface com.google.common.base.Function<V,​E>
        Specified by:
        apply in interface java.util.function.Function<V,​E>
      • fireLayoutChanged

        private void fireLayoutChanged​(V v)