use of org.ovirt.engine.core.vdsbroker.vdsbroker.NetworkQosMapper in project ovirt-engine by oVirt.
the class VmInfoBuildUtils method addQosForDevice.
private void addQosForDevice(Map<String, Object> struct, VnicProfile vnicProfile) {
Guid qosId = vnicProfile.getNetworkQosId();
@SuppressWarnings("unchecked") Map<String, Object> specParams = (Map<String, Object>) struct.get(VdsProperties.SpecParams);
if (specParams == null) {
specParams = new HashMap<>();
struct.put(VdsProperties.SpecParams, specParams);
}
NetworkQoS networkQoS = (qosId == null) ? new NetworkQoS() : networkQosDao.get(qosId);
NetworkQosMapper qosMapper = new NetworkQosMapper(specParams, VdsProperties.QOS_INBOUND, VdsProperties.QOS_OUTBOUND);
qosMapper.serialize(networkQoS);
}
Aggregations