| 12345678910111213141516171819202122232425262728293031323334353637383940 |
- using Prism.Mvvm;
- using System;
- namespace TeamAAS_VP.Models
- {
- /// <summary>
- /// Represent a PLC address entry mapping a variable name to its node/address string and type.
- /// </summary>
- public class PlcAddress : BindableBase
- {
- private string _Address;
- /// <summary>
- /// Address or node string used to access PLC (e.g. OP-UA node id or Modbus address)
- /// </summary>
- public string Address { get => _Address; set => SetProperty(ref _Address, value); }
- private string _DataType;
- /// <summary>
- /// Data type string (e.g. "Bool","Int32","Float","String")
- /// </summary>
- public string DataType { get => _DataType; set => SetProperty(ref _DataType, value); }
- private string _Description;
- public string Description { get => _Description; set => SetProperty(ref _Description, value); }
- public PlcAddress()
- {
- Address = string.Empty;
- DataType = "Float";
- Description = "PLCµØÖ·";
- }
- public PlcAddress(string address, string dataType, string description)
- {
- Address = address;
- DataType = dataType;
- Description = description;
- }
- }
- }
|