Class BarnesHut.Builder
- java.lang.Object
-
- com.hybris.cockpitng.components.visjs.network.data.BarnesHut.Builder
-
- Enclosing class:
- BarnesHut
public static class BarnesHut.Builder extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BarnesHutbuild()BarnesHut.BuilderwithAvoidOverlap(java.lang.Double avoidOverlap)Accepted range [0..1].BarnesHut.BuilderwithCentralGravity(java.lang.Double centralGravity)Central gravity attractor to pull the network to center.BarnesHut.BuilderwithDamping(java.lang.Double damping)Accepted range [0..1].BarnesHut.BuilderwithGravitationalConstant(java.lang.Double gravitationalConstant)Gravity attracts.BarnesHut.BuilderwithSpringConstant(java.lang.Double springConstant)Indicates how strongly the spring is.BarnesHut.BuilderwithSpringLength(java.lang.Double springLength)Edge is represented by springs.
-
-
-
Method Detail
-
withGravitationalConstant
public BarnesHut.Builder withGravitationalConstant(java.lang.Double gravitationalConstant)
Gravity attracts. Notice that value should be negative. If you want the repulsion to be stronger, decrease the value. Default value is -2000
-
withCentralGravity
public BarnesHut.Builder withCentralGravity(java.lang.Double centralGravity)
Central gravity attractor to pull the network to center. Default value is 0.3
-
withSpringLength
public BarnesHut.Builder withSpringLength(java.lang.Double springLength)
Edge is represented by springs. THe springLength is the length of the spring. Default value is 95
-
withSpringConstant
public BarnesHut.Builder withSpringConstant(java.lang.Double springConstant)
Indicates how strongly the spring is. Default value is 0.04
-
withDamping
public BarnesHut.Builder withDamping(java.lang.Double damping)
Accepted range [0..1]. Indicates how much the previous physics simulation carries over the next iteration. Default value is 0.09
-
withAvoidOverlap
public BarnesHut.Builder withAvoidOverlap(java.lang.Double avoidOverlap)
Accepted range [0..1]. When provided value is larger than 0 then the size of a node is taken into account. Default value is 0
-
build
public BarnesHut build()
-
-