Show / Hide Table of Contents

Interface IHighlightAlgorithmFactory<TVertex, TEdge, TGraph>

Represents a factory of highlight algorithms.

Namespace: GraphShape.Algorithms.Highlight
Assembly: GraphShape.dll
Syntax
public interface IHighlightAlgorithmFactory<TVertex, TEdge, in TGraph>
    where TEdge : IEdge<TVertex> where TGraph : class, IBidirectionalGraph<TVertex, TEdge>
Type Parameters
Name Description
TVertex

Vertex type.

TEdge

Edge type.

TGraph

Graph type.

Properties

| Improve this Doc View Source

HighlightModes

Highlight modes.

Declaration
IEnumerable<string> HighlightModes { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<System.String>

Methods

| Improve this Doc View Source

CreateAlgorithm(String, IHighlightContext<TVertex, TEdge, TGraph>, IHighlightController<TVertex, TEdge, TGraph>, IHighlightParameters)

Creates an algorithm corresponding using given highlightMode, context, controller and parameters.

Declaration
IHighlightAlgorithm<TVertex, TEdge> CreateAlgorithm(string highlightMode, IHighlightContext<TVertex, TEdge, TGraph> context, IHighlightController<TVertex, TEdge, TGraph> controller, IHighlightParameters parameters)
Parameters
Type Name Description
System.String highlightMode

Highlight mode.

IHighlightContext<TVertex, TEdge, TGraph> context

Creation context.

IHighlightController<TVertex, TEdge, TGraph> controller

Highlight controller.

IHighlightParameters parameters

Algorithm parameters.

Returns
Type Description
IHighlightAlgorithm<TVertex, TEdge>

Created algorithm.

Exceptions
Type Condition
System.ArgumentNullException

highlightMode is null.

System.ArgumentNullException

context is null.

System.ArgumentNullException

controller is null.

| Improve this Doc View Source

CreateParameters(String, IHighlightParameters)

Creates algorithm parameters for an algorithm using given highlightMode and parameters.

Declaration
IHighlightParameters CreateParameters(string highlightMode, IHighlightParameters parameters)
Parameters
Type Name Description
System.String highlightMode

Highlight mode.

IHighlightParameters parameters

Algorithm parameters.

Returns
Type Description
IHighlightParameters

Parameters for the algorithm.

Exceptions
Type Condition
System.ArgumentNullException

highlightMode is null.

| Improve this Doc View Source

GetHighlightMode(IHighlightAlgorithm<TVertex, TEdge>)

Gets the algorithm highlight mode from a given algorithm.

Declaration
string GetHighlightMode(IHighlightAlgorithm<TVertex, TEdge> algorithm)
Parameters
Type Name Description
IHighlightAlgorithm<TVertex, TEdge> algorithm

Algorithm from which getting highlight mode.

Returns
Type Description
System.String

Highlight mode.

Exceptions
Type Condition
System.ArgumentNullException

algorithm is null.

| Improve this Doc View Source

IsValidMode(String)

Checks if the given mode is a valid one.

Declaration
bool IsValidMode(string mode)
Parameters
Type Name Description
System.String mode

Highlight mode.

Returns
Type Description
System.Boolean

True if the highlight mode is valid, false otherwise.

Extension Methods

GraphHelpers.GetDistances<TVertex, TEdge, TGraph>(TGraph)
GraphHelpers.GetDiameter<TVertex, TEdge, TGraph>(TGraph)
GraphHelpers.GetDiameter<TVertex, TEdge, TGraph>(TGraph, out Double[,])
  • Improve this Doc
  • View Source
In This Article
Back to top GraphShape