Class LayoutModel.Builder<V,T extends DefaultLayoutModel<V>,B extends LayoutModel.Builder<V,T,B>>
- java.lang.Object
-
- org.jungrapht.visualization.layout.model.AbstractLayoutModel.Builder<V,T,B>
-
- org.jungrapht.visualization.layout.model.LayoutModel.Builder<V,T,B>
-
- Type Parameters:
V- the vertex typeT- the type of the superclass of the LayoutModel to be built
- Enclosing interface:
- LayoutModel<V>
public static class LayoutModel.Builder<V,T extends DefaultLayoutModel<V>,B extends LayoutModel.Builder<V,T,B>> extends AbstractLayoutModel.Builder<V,T,B>
a builder for LayoutModel instances
-
-
Field Summary
-
Fields inherited from class org.jungrapht.visualization.layout.model.AbstractLayoutModel.Builder
createVisRunnable, graph, height, initialDimensionFunction, width
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Tbuild()build an instance of the requested LayoutModel of type TBcreateVisRunnable(boolean createVisRunnable)Binitializer(Function<V,Point> initializer)sets the initializer to use for new verticesBlayoutModel(LayoutModel<V> layoutModel)set the LayoutModel to copy with this builder-
Methods inherited from class org.jungrapht.visualization.layout.model.AbstractLayoutModel.Builder
graph, height, initialDimensionFunction, size, width
-
-
-
-
Method Detail
-
layoutModel
public B layoutModel(LayoutModel<V> layoutModel)
set the LayoutModel to copy with this builder- Parameters:
layoutModel-- Returns:
- this builder for further use
-
initializer
public B initializer(Function<V,Point> initializer)
sets the initializer to use for new vertices- Parameters:
initializer-- Returns:
- the builder
-
createVisRunnable
public B createVisRunnable(boolean createVisRunnable)
- Overrides:
createVisRunnablein classAbstractLayoutModel.Builder<V,T extends DefaultLayoutModel<V>,B extends LayoutModel.Builder<V,T,B>>
-
build
public T build()
build an instance of the requested LayoutModel of type T- Returns:
-
-