Class ControlFlowNodeAdorner<TInstruction>
- Namespace
- Echo.ControlFlow.Serialization.Dot
- Assembly
- Echo.ControlFlow.dll
Represents an adorner that adds the string representation of the embedded instructions to a node in a graph.
public class ControlFlowNodeAdorner<TInstruction> : IDotNodeAdorner where TInstruction : notnull
Type Parameters
TInstructionThe type of instructions the nodes contain.
- Inheritance
-
ControlFlowNodeAdorner<TInstruction>
- Implements
- Inherited Members
Constructors
ControlFlowNodeAdorner()
Creates a new ControlFlowNodeAdorner<TInstruction> with the default formatter.
public ControlFlowNodeAdorner()
ControlFlowNodeAdorner(IInstructionFormatter<TInstruction>)
Creates a new ControlFlowNodeAdorner<TInstruction> with the specified IInstructionFormatter<TInstruction>.
public ControlFlowNodeAdorner(IInstructionFormatter<TInstruction> formatter)
Parameters
formatterIInstructionFormatter<TInstruction>The IInstructionFormatter<TInstruction> to format instructions with.
Properties
BlockHeaderFormat
Gets or sets a value indicating the format of block headers. This is a format string with one parameter containing the value of Offset.
public string BlockHeaderFormat { get; set; }
Property Value
IncludeBlockHeaders
Gets or sets a value indicating whether the adorner should add block headers to every node.
public bool IncludeBlockHeaders { get; set; }
Property Value
IncludeInstructions
Gets or sets a value indicating whether the adorner should add the block instructions to every node.
public bool IncludeInstructions { get; set; }
Property Value
InstructionFormatter
Gets or sets the formatter that will be used to format the instructions.
public IInstructionFormatter<TInstruction> InstructionFormatter { get; set; }
Property Value
- IInstructionFormatter<TInstruction>
NodeShape
Gets or sets the shape of the node.
public string NodeShape { get; set; }
Property Value
Methods
GetNodeAttributes(INode, long)
Obtains the adornments that should be added to the node.
public IDictionary<string, string>? GetNodeAttributes(INode node, long id)
Parameters
Returns
- IDictionary<string, string>
The adornments.