Class ElementView
An instance of a model element (Person, Software System, Container or Component) in a View.
[DataContract]
public sealed class ElementView : IEquatable<ElementView>
- Inheritance
-
ElementView
- Implements
- Inherited Members
Properties
Element
References the model element represented by this view node.
public Element Element { get; set; }
Property Value
Id
The ID of the element.
[DataMember(Name = "id", EmitDefaultValue = false)]
public string Id { get; set; }
Property Value
X
The horizontal position of the element when rendered.
[DataMember(Name = "x", EmitDefaultValue = true)]
public int X { get; set; }
Property Value
Y
The vertical position of the element when rendered.
[DataMember(Name = "y", EmitDefaultValue = true)]
public int Y { get; set; }
Property Value
Methods
Equals(ElementView)
Determines whether another element view represents the same element ID.
public bool Equals(ElementView elementView)
Parameters
elementViewElementViewThe element view to compare.
Returns
Equals(object)
Determines whether another object represents the same element view.
public override bool Equals(object obj)
Parameters
objobjectThe object to compare.
Returns
- bool
true when the object is an equivalent ElementView; otherwise, false.
GetHashCode()
Returns a hash code based on the element identifier.
public override int GetHashCode()
Returns
- int
A hash code for this element view.
ToString()
Returns the wrapped element text when available, otherwise the serialized identifier.
public override string ToString()
Returns
- string
A human-readable representation of the element view.