use of com.sequenceiq.cloudbreak.api.endpoint.v4.util.responses.VmTypeMetaJson in project cloudbreak by hortonworks.
the class VmTypeToVmTypeV4ResponseConverter method convert.
public VmTypeV4Response convert(VmType source) {
VmTypeV4Response vmTypeV4Response = new VmTypeV4Response();
List<VolumeParameterConfigV4Response> configs = new ArrayList<>();
convertVolumeConfig(configs, source.getMetaData().getAutoAttachedConfig());
convertVolumeConfig(configs, source.getMetaData().getEphemeralConfig());
convertVolumeConfig(configs, source.getMetaData().getMagneticConfig());
convertVolumeConfig(configs, source.getMetaData().getSsdConfig());
convertVolumeConfig(configs, source.getMetaData().getSt1Config());
VmTypeMetaJson vmTypeMetaJson = new VmTypeMetaJson();
vmTypeMetaJson.setProperties(source.getMetaData().getProperties());
vmTypeMetaJson.setConfigs(configs);
vmTypeV4Response.setVmTypeMetaJson(vmTypeMetaJson);
vmTypeV4Response.setValue(source.value());
return vmTypeV4Response;
}
Aggregations