use of org.ovirt.engine.api.v3.types.V3HardwareInformation in project ovirt-engine by oVirt.
the class V3HardwareInformationInAdapter method adapt.
@Override
public HardwareInformation adapt(V3HardwareInformation from) {
HardwareInformation to = new HardwareInformation();
if (from.isSetFamily()) {
to.setFamily(from.getFamily());
}
if (from.isSetManufacturer()) {
to.setManufacturer(from.getManufacturer());
}
if (from.isSetProductName()) {
to.setProductName(from.getProductName());
}
if (from.isSetSerialNumber()) {
to.setSerialNumber(from.getSerialNumber());
}
if (from.isSetSupportedRngSources()) {
to.setSupportedRngSources(new HardwareInformation.SupportedRngSourcesList());
to.getSupportedRngSources().getSupportedRngSources().addAll(adaptRngSources(from));
}
if (from.isSetUuid()) {
to.setUuid(from.getUuid());
}
if (from.isSetVersion()) {
to.setVersion(from.getVersion());
}
return to;
}
use of org.ovirt.engine.api.v3.types.V3HardwareInformation in project ovirt-engine by oVirt.
the class V3HardwareInformationOutAdapter method adapt.
@Override
public V3HardwareInformation adapt(HardwareInformation from) {
V3HardwareInformation to = new V3HardwareInformation();
if (from.isSetFamily()) {
to.setFamily(from.getFamily());
}
if (from.isSetManufacturer()) {
to.setManufacturer(from.getManufacturer());
}
if (from.isSetProductName()) {
to.setProductName(from.getProductName());
}
if (from.isSetSerialNumber()) {
to.setSerialNumber(from.getSerialNumber());
}
if (from.isSetSupportedRngSources()) {
to.setSupportedRngSources(new V3RngSources());
to.getSupportedRngSources().getRngSources().addAll(adaptRngSources(from));
}
if (from.isSetUuid()) {
to.setUuid(from.getUuid());
}
if (from.isSetVersion()) {
to.setVersion(from.getVersion());
}
return to;
}
Aggregations