You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
using Mirle.Component.MPLC.DataBlocks; using System.Collections.Generic;
namespace Mirle.Component.MPLC { /// <summary>
/// 控制器資訊
/// </summary>
public class PLCHostInfo { /// <summary>
/// 建構式
/// </summary>
/// <param name="hostID">控制器編號</param>
/// <param name="actLogicalStationNo">控制器站點編號</param>
/// <param name="blockInfos">區塊資訊</param>
public PLCHostInfo(string hostID, int actLogicalStationNo, IEnumerable<BlockInfo> blockInfos) { HostID = hostID; IPAddress = string.Empty; TcpPort = 0; ActLogicalStationNo = actLogicalStationNo; BlockInfos = blockInfos; } /// <summary>
/// 建構式
/// </summary>
/// <param name="hostID">控制器編號</param>
/// <param name="ipAddress">網路位址</param>
/// <param name="tcpPort">通訊埠口</param>
/// <param name="blockInfos">區塊資訊</param>
public PLCHostInfo(string hostID, string ipAddress, int tcpPort, IEnumerable<BlockInfo> blockInfos) { HostID = hostID; IPAddress = ipAddress; TcpPort = tcpPort; ActLogicalStationNo = 0; BlockInfos = blockInfos; } /// <summary>
/// 控制器編號
/// </summary>
public string HostID { get; } /// <summary>
/// 網路位址
/// </summary>
public string IPAddress { get; } /// <summary>
/// 通訊埠口
/// </summary>
public int TcpPort { get; } /// <summary>
/// 控制器站點編號
/// </summary>
public int ActLogicalStationNo { get; } /// <summary>
/// 區塊資訊
/// </summary>
public IEnumerable<BlockInfo> BlockInfos { get; } } }
|