Class PluggableRendererDemo.VertexShapeSizeAspect<V,​E>

  • All Implemented Interfaces:
    com.google.common.base.Function<V,​java.awt.Shape>, SettableVertexShapeTransformer<V>, java.util.function.Function<V,​java.awt.Shape>
    Enclosing class:
    PluggableRendererDemo

    private static final class PluggableRendererDemo.VertexShapeSizeAspect<V,​E>
    extends AbstractVertexShapeTransformer<V>
    implements com.google.common.base.Function<V,​java.awt.Shape>
    Controls the shape, size, and aspect ratio for each vertex.
    • Field Detail

      • stretch

        protected boolean stretch
      • scale

        protected boolean scale
      • funny_shapes

        protected boolean funny_shapes
      • voltages

        protected com.google.common.base.Function<V,​java.lang.Double> voltages
      • graph

        protected Graph<V,​E> graph
    • Constructor Detail

      • VertexShapeSizeAspect

        public VertexShapeSizeAspect​(Graph<V,​E> graphIn,
                                     com.google.common.base.Function<V,​java.lang.Double> voltagesIn)
    • Method Detail

      • setStretching

        public void setStretching​(boolean stretch)
      • setScaling

        public void setScaling​(boolean scale)
      • useFunnyShapes

        public void useFunnyShapes​(boolean use)
      • apply

        public java.awt.Shape 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>