2using System.Xml.Serialization;
18[XmlType(TypeName =
"workCenterReference")]
22 private int _workCenterId;
56 [XmlAttribute(
"plantId")]
65 throw new ArgumentOutOfRangeException(
68 "The plant identifier cannot be negative.");
72 SetProperty(ref _plantId, value);
79 [XmlAttribute(
"workCenterId")]
88 throw new ArgumentOutOfRangeException(
91 "The work-center identifier cannot be negative.");
95 SetProperty(ref _workCenterId, value);
107 return other is not
null
117 return $
"Plant:{PlantId}/WorkCenter:{WorkCenterId}";
Base class for model objects that notify listeners when one of their properties changes.
int PlantId
Gets or sets the identifier of the plant owning the referenced work center.
WorkCenterReference(int plantId, int workCenterId)
Initializes a work-center reference.
override string ToString()
Returns a readable representation of the reference.
bool RefersToSameWorkCenter(WorkCenterReference? other)
Determines whether this reference identifies the same work center as another reference.
WorkCenterReference()
Initializes an empty work-center reference.
int WorkCenterId
Gets or sets the identifier of the referenced work center.