Search in sources :

Example 1 with UpdateFirmwareRequest

use of org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareRequest in project open-smart-grid-platform by OSGP.

the class UpdateFirmwareRequestFactory method fromParameterMap.

public static UpdateFirmwareRequest fromParameterMap(final Map<String, String> parameters) {
    final UpdateFirmwareRequest updateFirmwareRequest = new UpdateFirmwareRequest();
    updateFirmwareRequest.setDeviceIdentification(getString(parameters, PlatformSmartmeteringKeys.DEVICE_IDENTIFICATION, PlatformSmartmeteringDefaults.DEVICE_IDENTIFICATION));
    updateFirmwareRequest.setFirmwareIdentification(parameters.get(PlatformSmartmeteringKeys.FIRMWARE_FILE_IDENTIFICATION));
    return updateFirmwareRequest;
}
Also used : UpdateFirmwareRequest(org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareRequest)

Example 2 with UpdateFirmwareRequest

use of org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareRequest in project open-smart-grid-platform by OSGP.

the class UpdateFirmware method theRequestForAFirmwareUpgradeIsReceived.

@When("^the request for a firmware upgrade is received$")
public void theRequestForAFirmwareUpgradeIsReceived(final Map<String, String> settings) throws Throwable {
    final UpdateFirmwareRequest request = UpdateFirmwareRequestFactory.fromParameterMap(settings);
    final UpdateFirmwareAsyncResponse asyncResponse = this.client.updateFirmware(request);
    assertThat(asyncResponse).as("asyncResponse should not be null").isNotNull();
    ScenarioContextHelper.saveAsyncResponse(asyncResponse);
}
Also used : UpdateFirmwareRequest(org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareRequest) UpdateFirmwareAsyncResponse(org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareAsyncResponse) When(io.cucumber.java.en.When)

Aggregations

UpdateFirmwareRequest (org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareRequest)2 When (io.cucumber.java.en.When)1 UpdateFirmwareAsyncResponse (org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.UpdateFirmwareAsyncResponse)1