Search in sources :

Example 1 with SetMbusUserKeyByChannelRequestData

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

the class SetMbusUserKeyByChannelRequestDataFactory method fromParameterMap.

public static SetMbusUserKeyByChannelRequestData fromParameterMap(final Map<String, String> requestParameters) {
    final SetMbusUserKeyByChannelRequestData setMbusUserKeyByChannelRequestData = new SetMbusUserKeyByChannelRequestData();
    if (!requestParameters.containsKey(PlatformSmartmeteringKeys.CHANNEL)) {
        throw new AssertionError("A value for key '" + PlatformSmartmeteringKeys.CHANNEL + "' must be set in the step data.");
    }
    setMbusUserKeyByChannelRequestData.setChannel(getShort(requestParameters, PlatformSmartmeteringKeys.CHANNEL));
    return setMbusUserKeyByChannelRequestData;
}
Also used : SetMbusUserKeyByChannelRequestData(org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.SetMbusUserKeyByChannelRequestData)

Example 2 with SetMbusUserKeyByChannelRequestData

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

the class SetMbusUserKeyByChannelRequestFactory method fromParameterMap.

public static SetMbusUserKeyByChannelRequest fromParameterMap(final Map<String, String> requestParameters) {
    final SetMbusUserKeyByChannelRequest setMbusUserKeyByChannelRequest = new SetMbusUserKeyByChannelRequest();
    setMbusUserKeyByChannelRequest.setDeviceIdentification(requestParameters.get(PlatformSmartmeteringKeys.KEY_DEVICE_IDENTIFICATION));
    final SetMbusUserKeyByChannelRequestData setMbusUserKeyByChannelRequestData = SetMbusUserKeyByChannelRequestDataFactory.fromParameterMap(requestParameters);
    setMbusUserKeyByChannelRequest.setSetMbusUserKeyByChannelRequestData(setMbusUserKeyByChannelRequestData);
    return setMbusUserKeyByChannelRequest;
}
Also used : SetMbusUserKeyByChannelRequestData(org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.SetMbusUserKeyByChannelRequestData) SetMbusUserKeyByChannelRequest(org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.SetMbusUserKeyByChannelRequest)

Aggregations

SetMbusUserKeyByChannelRequestData (org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.SetMbusUserKeyByChannelRequestData)2 SetMbusUserKeyByChannelRequest (org.opensmartgridplatform.adapter.ws.schema.smartmetering.configuration.SetMbusUserKeyByChannelRequest)1