/// <summary>
/// Sample function ModifyQoS.
/// Modifies Container QoS settings.
/// </summary>
/// <param name="ve_eid">The Container Server ID.</param>
/// <param name="qos_id">QoS ID.</param>
/// <param name="hard">New hard limit value.</param>
/// <param name="soft">New soft limit value.</param>
/// <returns></returns>
public string ModifyQoS(string ve_eid, string qos_id, int hard, int soft)
{
try {
vzaenvmBinding env = (vzaenvmBinding)binder.InitBinding(typeof(vzaenvmBinding));
set2 set_input = new set2();
// Set the Container Server ID.
set_input.eid = ve_eid;
venv_configType1 veconfig = new venv_configType1();
// Set Container QoS.
veconfig.qos = new qosType[1];
veconfig.qos[0] = new qosType();
// Set QoS ID.
veconfig.qos[0].id = qos_id;
// Set hard limit
veconfig.qos[0].hardSpecified = true;
veconfig.qos[0].hard = hard;
// Set soft limit
veconfig.qos[0].softSpecified = true;
veconfig.qos[0].soft = soft;
// Modify the Container configuration.
set_input.config = veconfig;
env.set(set_input);
return "OK!";
}
catch (Exception e) {
return "Exception: " + e.Message;
}
}