GraphLinksModelLinkData
A simple representation of link data that supports property change notification, copying, and undo via the INotifyPropertyChanged, ICloneable, and IChangeDataValue interfaces.
実装: INotifyPropertyChanged, IChangeDataValue, ICloneable
コンストラクター
GraphLinksModelLinkData()
The default constructor produces an empty object with no references to nodes.
GraphLinksModelLinkData(T, T, T, T)
This constructor initializes the From and To properties.
- from
- a node key identifying the node data from which the link comes
- fromport
- an optional value identifying which port on the "from" node the link is connected to
- to
- a node key identify the node data to which the link goes
- toport
- an optional value identifying which port on the "to" node the link is connected to
プロパティ
From : T
Gets or sets the key value of the node from which this link comes.
FromPort : T
Gets or sets the optional parameter information for the From node's port.
LabelNode : T
Gets or sets the key value of the node which is on this link acting as if it were a label.
Points : IEnumerable<Point>
Gets or sets a collection of Points used to define the path of the link.
To : T
Gets or sets the key value of the node to which this link goes.
ToPort : T
Gets or sets the optional parameter information for the To node's port.
メソッド
ChangeDataValue(ModelChangedEventArgs, bool)
This method implements the IChangeDataValue interface, used to perform state changes for undo and redo.
- e
- an edit describing the change to be performed
- undo
- true if undoing; false if redoing
ConvertNodeKeyToString(T) : string
Convert a key value to a string.
- key
戻り値: a String from which String) can recover the original key value
ConvertPortKeyToString(T) : string
Convert a key value to a string.
- key
戻り値: a String from which String) can recover the original key value
LoadFromXElement(XElement)
Initialize this link data with data held in a Linq for XML XElement.
- e
- the XElement
MakeXElement(XName) : XElement
Constructs a Linq for XML XElement holding the data of this link.
- n
- the name of the new XElement
戻り値: an initialized XElement
RaisePropertyChanged(string, object, object)
Call this method from property setters to raise the PropertyChanged event.
- pname
- the property name
- oldval
- the value before the property was set
- newval
- the new value
イベント
PropertyChanged : PropertyChangedEventHandler
This event implements the INotifyPropertyChanged interface, so that both the model and the dependency object system can be informed of changes to property values.