Add NB.DoActions functions for Replace, ReplaceUPS, and PowerOff

This commit is contained in:
Tim Young 2018-05-17 16:10:20 -05:00
parent 291f1d0b1c
commit 136b7b1ab7

View File

@ -1506,7 +1506,36 @@ namespace EduNetworkBuilder
RegisterAction(AC); RegisterAction(AC);
AC.DoAction(); AC.DoAction();
}
public static void DoActionReplaceDevice(int HostID)
{
ActionClass AC = new ActionClass();
AC.Action = NBAction.replace;
AC.SourceID = HostID;
RegisterAction(AC);
AC.DoAction();
}
public static void DoActionReplaceDeviceUPS(int HostID)
{
ActionClass AC = new ActionClass();
AC.Action = NBAction.replaceUPS;
AC.SourceID = HostID;
RegisterAction(AC);
AC.DoAction();
}
public static void DoActionPowerOff(int HostID)
{
ActionClass AC = new ActionClass();
AC.Action = NBAction.poweroff;
AC.SourceID = HostID;
RegisterAction(AC);
AC.DoAction();
} }
public static void DoActionDeleteComponent(int HostID) public static void DoActionDeleteComponent(int HostID)
{ {