init
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
using System.Collections.Generic;
|
||||
using DTS.Common.ICommunication;
|
||||
|
||||
namespace DTS.DASLib.Command.SLICE.MulticastCommands
|
||||
{
|
||||
public class MulticastSetSubnetAddress : MulticastCommandBase
|
||||
{
|
||||
private const int COMMAND_PAYLOAD_SIZE = DOUBLE_MAC_ADDR_SIZE + IP_ADDR_SIZE;
|
||||
|
||||
protected override Commands Command => Commands.SetSubnetAddress;
|
||||
|
||||
private string _subnet;
|
||||
public string Subnet { set { _subnet = value; command.SetParameter(FIRST_PARAMETER_OFFSET, _subnet); } }
|
||||
|
||||
public MulticastSetSubnetAddress(DTS.Common.Interface.DASFactory.ICommunication sock)
|
||||
: base(sock)
|
||||
{
|
||||
command.Parameter = new byte[COMMAND_PAYLOAD_SIZE];
|
||||
}
|
||||
|
||||
public MulticastSetSubnetAddress(DTS.Common.Interface.DASFactory.ICommunication sock, int timeoutMillisec)
|
||||
: base(sock, timeoutMillisec)
|
||||
{
|
||||
command.Parameter = new byte[COMMAND_PAYLOAD_SIZE];
|
||||
}
|
||||
|
||||
public override void CommandToString(ref List<List<string>> lines)
|
||||
{
|
||||
base.CommandToString(ref lines);
|
||||
lines.Add(new List<string> { $"MAC: {CommandClientMac} Subnet: {_subnet}" });
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user