Permalink
Browse files

Adds setAlarmStatus

This commit adds the ability to reset an alarm from red to green
using a hidden API call. This call should work similar to the
acknowledgeAlarm() call but requires an additional param of the
alarm color. To reset from red to green the alarm status passed
in should be that of "green".
  • Loading branch information...
michaelrice committed Oct 18, 2014
1 parent c619b4a commit 2b9ee84245822fe95f327a9272c4f3eef28615a8
@@ -59,6 +59,14 @@ public void acknowledgeAlarm(Alarm alarm, ManagedEntity entity) throws RuntimeFa
getVimService().acknowledgeAlarm(getMOR(), alarm.getMOR(), entity.getMOR());
}
/**
* @since 4.x
* added to yavija for 5.5b.07
*/
public void setAlarmStatus(Alarm alarm, ManagedEntity entity, String status) throws RuntimeFault, RemoteException {
getVimService().setAlarmStatus(getMOR(), alarm.getMOR(), entity.getMOR(), status);
}
/**
* @since 4.0
*/
@@ -32,6 +32,7 @@
import com.vmware.vim25.*;
import java.lang.reflect.InvocationTargetException;
import java.rmi.RemoteException;
import java.util.Calendar;
/**
@@ -2549,6 +2550,15 @@ public void acknowledgeAlarm(ManagedObjectReference _this, ManagedObjectReferenc
wsc.invoke("AcknowledgeAlarm", paras, null);
}
public void setAlarmStatus(ManagedObjectReference _this, ManagedObjectReference alarm, ManagedObjectReference entity, String status) throws RemoteException, RuntimeFault {
Argument[] params = new Argument[4];
params[0] = new Argument("_this", "ManagedObjectReference", _this);
params[1] = new Argument("alarm", "ManagedObjectReference", alarm);
params[2] = new Argument("entity", "ManagedObjectReference", entity);
params[3] = new Argument("status", "String", status);
wsc.invoke("SetAlarmStatus", params, null);
}
public ManagedObjectReference reconfigureDVPortgroup_Task(ManagedObjectReference _this, DVPortgroupConfigSpec spec) throws java.rmi.RemoteException, DvsFault, ConcurrentAccess, DuplicateName, InvalidName, RuntimeFault {
Argument[] paras = new Argument[2];
paras[0] = new Argument("_this", "ManagedObjectReference", _this);

0 comments on commit 2b9ee84

Please sign in to comment.