Table of Contents

Class Node

Namespace
H.Controls.Diagram
Assembly
H.Controls.Diagram.dll

节点

public class Node : Part, IAnimatable, ISupportInitialize, IFrameworkInputElement, IInputElement, IQueryAmbient, INode
Inheritance
Node
Implements
Derived
Inherited Members
Extension Methods

Fields

IsDraggingProperty

正在拖动

public static readonly DependencyProperty IsDraggingProperty

Field Value

DependencyProperty

LocationProperty

public static readonly DependencyProperty LocationProperty

Field Value

DependencyProperty

PositionProperty

说明

public static readonly DependencyProperty PositionProperty

Field Value

DependencyProperty

Properties

关系

public List<Link> ConnectLinks { get; set; }

Property Value

List<Link>

DefaultKey

public static ComponentResourceKey DefaultKey { get; }

Property Value

ComponentResourceKey

Id

public string Id { get; }

Property Value

string

LinksInto

扇入

public List<Link> LinksInto { get; set; }

Property Value

List<Link>

LinksOutOf

扇出

public List<Link> LinksOutOf { get; set; }

Property Value

List<Link>

Location

public Point Location { get; set; }

Property Value

Point

VisualChildrenCount

Gets the number of visual child elements within this element.

protected override int VisualChildrenCount { get; }

Property Value

int

The number of visual child elements for this element.

Methods

AddPort(Port)

public void AddPort(Port port)

Parameters

port Port

Aligment()

public void Aligment()

ArrangeOverride(Size)

Positions the single child element and determines the content of a ContentPresenter object.

protected override Size ArrangeOverride(Size finalSize)

Parameters

finalSize Size

Returns

Size

The actual size needed by the element.

Clear()

清理逻辑关系

public override void Clear()

Delete()

删除图层上的元素

public override void Delete()
public IEnumerable<Link> GetAllLinks()

Returns

IEnumerable<Link>

GetAllParts(Func<Part, bool>)

public IEnumerable<Part> GetAllParts(Func<Part, bool> filter = null)

Parameters

filter Func<Part, bool>

Returns

IEnumerable<Part>

GetFromNodes(Func<Node, bool>)

public List<Node> GetFromNodes(Func<Node, bool> filter = null)

Parameters

filter Func<Node, bool>

Returns

List<Node>

GetIsDragging(DependencyObject)

public static bool GetIsDragging(DependencyObject d)

Parameters

d DependencyObject

Returns

bool

GetNext()

public override Part GetNext()

Returns

Part

GetParts(Func<Part, bool>)

public IEnumerable<Part> GetParts(Func<Part, bool> filter = null)

Parameters

filter Func<Part, bool>

Returns

IEnumerable<Part>

GetPorts(Func<Port, bool>)

public List<Port> GetPorts(Func<Port, bool> predicate = null)

Parameters

predicate Func<Port, bool>

Returns

List<Port>

GetPosition(DependencyObject)

public static Point GetPosition(DependencyObject d)

Parameters

d DependencyObject

Returns

Point

GetPrevious()

public override Part GetPrevious()

Returns

Part

GetToNodes(Func<Node, bool>)

public List<Node> GetToNodes(Func<Node, bool> filter = null)

Parameters

filter Func<Node, bool>

Returns

List<Node>

GetVisiblity()

protected virtual bool GetVisiblity()

Returns

bool

GetVisualChild(int)

Overrides GetVisualChild(int), and returns a child at the specified index from a collection of child elements.

protected override Visual GetVisualChild(int index)

Parameters

index int

The zero-based index of the requested child element in the collection.

Returns

Visual

The requested child element. This should not return null; if the provided index is out of range, an exception is thrown.

OnRender(DrawingContext)

When overridden in a derived class, participates in rendering operations that are directed by the layout system. The rendering instructions for this element are not used directly when this method is invoked, and are instead preserved for later asynchronous use by layout and drawing.

protected override void OnRender(DrawingContext drawingContext)

Parameters

drawingContext DrawingContext

The drawing instructions for a specific element. This context is provided to the layout system.

RemovePort(Port)

public void RemovePort(Port port)

Parameters

port Port

SetIsDragging(DependencyObject, bool)

public static void SetIsDragging(DependencyObject obj, bool value)

Parameters

obj DependencyObject
value bool

SetPosition(DependencyObject, Point)

public static void SetPosition(DependencyObject obj, Point value)

Parameters

obj DependencyObject
value Point
public Task<bool?> StartLink(Action<Part> builder = null)

Parameters

builder Action<Part>

Returns

Task<bool?>

StartNode(Action<Node>)

public Task<bool?> StartNode(Action<Node> builder = null)

Parameters

builder Action<Node>

Returns

Task<bool?>

StartPort(Action<Part>)

public Task<bool?> StartPort(Action<Part> builder = null)

Parameters

builder Action<Part>

Returns

Task<bool?>

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.