using System;
namespace Netron.Diagramming.Core {
///
/// Descriptor for derived classes (i.e. most of the simple drawing elements like the shape).
///
class ConnectionDescriptor : ConnectionBaseDescriptor {
///
/// Override this method to return the appropriate value corresponding to the property
///
///
///
protected override void GetValue(object sender, PropertyEventArgs e) {
switch (e.Name) {
case "Demo":
e.Value = 123456;
break;
default:
base.GetValue(sender, e);
break;
}
}
///
/// Override this method to set the appropriate value corresponding to the property
///
///
///
protected override void SetValue(object sender, PropertyEventArgs e) {
switch (e.Name) {
default:
base.SetValue(sender, e);
break;
}
}
///
/// Initializes a new instance of the class.
///
/// The provider.
/// The type.
public ConnectionDescriptor(ConnectionProvider provider, Type type)
: base(provider, type) {
this.AddProperty("Demo", typeof(int));
}
}
}