Extensions.ToGraphvizFile Method

Comuna.NET

ExtensionsToGraphvizFile Method

Saves the given Network to an image file.

Namespace:  Comuna.Graphviz
Assembly:  Comuna.Graphviz (in Comuna.Graphviz.dll) Version: 1.0.0
Syntax
C#
public static string ToGraphvizFile(
	this CommunityAlgorithm communityAlg,
	string basePath,
	string fileName,
	bool showLabels = true,
	GraphvizImageType imageType = GraphvizImageType.Pdf,
	PaletteGenerator paletteGenerator = null,
	int timeout = 2000
)
Request Example View Source

Parameters

communityAlg
Type: ComunaCommunityAlgorithm
The root node of the tree to be saved.
basePath
Type: SystemString
The path in which to save the given tree
fileName
Type: SystemString
The name of the image file to be saved (without extension)
showLabels (Optional)
Type: SystemBoolean
Whether to show nodes' labels.
imageType (Optional)
Type: GraphvizImageType
The type of image file in which to save the tree.
paletteGenerator (Optional)
Type: Comuna.GraphvizPaletteGenerator
The color palette generator used to represent the different communities.
timeout (Optional)
Type: SystemInt32
The maximum time to wait for Graphviz to create the image file.

Return Value

Type: String
The path to the file where the tree image file was saved.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type CommunityAlgorithm. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also