3using System.Threading.Tasks;
4using System.Windows.Controls;
35 if (this.designModel is not
null)
36 this.designModel.PropertyChanged += this.DesignModel_PropertyChanged;
44 get => this.role.Value;
45 set => this.role.Value = value;
53 get => this.index.Value;
57 throw new ArgumentOutOfRangeException(nameof(this.
Index),
"Role index must be positive.");
59 this.index.Value = value;
68 get => this.
property.
Value;
71 if (
string.IsNullOrEmpty(value))
72 throw new ArgumentOutOfRangeException(nameof(this.
Property),
"The property reference cannot be empty.");
74 this.property.Value = value;
83 get => this.required.Value;
84 set => this.required.Value = value;
90 public string[]
Roles => this.designModel.RoleNames;
92 private void DesignModel_PropertyChanged(
object sender, System.ComponentModel.PropertyChangedEventArgs e)
94 if (e.PropertyName == nameof(this.Roles))
101 throw new Exception(
"Role reference parameter cannot be set.");
110 return Task.CompletedTask;
void RemoveRoleReferenceParameter(RoleReferenceParameterInfo Parameter)
Removes a role reference parameter from the design
Contains information about a parameter
virtual object Value
Parameter value
Control Control
Generated control.
Contains information about a role reference parameter
RoleReferenceParameterInfo(Contract Contract, RoleParameter Parameter, Control Control, DesignModel DesignModel, Property< RoleReferenceParameterInfo[]> Parameters)
Contains information about a role reference parameter
bool Required
If property is required.
override void SetValue(string Value)
Sets the value.
string[] Roles
Available role names.
override Task ExecuteRemoveParameter()
Removes the parameter.
virtual void RaisePropertyChanged(string PropertyName)
Raises the PropertyChanged event.
Generic class for properties
virtual T Value
Current value of the property
Contains the definition of a contract
Abstract base class for contractual parameters
Role-reference contractual parameter
int Index
1-based Role index. 1=First signatory having the rolw, 2=second, etc.
bool Required
If parameter is required to exist for contract to be valid.