// TODO how to react to failure status of DCEVStatus of cableCheckReq?
/*
                         * TODO we need a timeout mechanism here so that a response can be sent within 2s
                         * the DCEVSEStatus should be generated according to already available values
                         * (if EVSEProcessing == ONGOING, maybe because of EVSE_IsolationMonitoringActive,
                         * within a certain timeout, then the status must be different)
                         */
@Override
	public ReactionToIncomingMessage processIncomingMessage(Object message) {
		if (isIncomingMessageValid(message, CableCheckReqType.class, cableCheckRes)) {
			V2GMessage v2gMessageReq = (V2GMessage) message;
			CableCheckReqType cableCheckReq = 
					(CableCheckReqType) v2gMessageReq.getBody().getBodyElement().getValue();
			// TODO how to react to failure status of DCEVStatus of cableCheckReq?
			/*
			 * TODO we need a timeout mechanism here so that a response can be sent within 2s
			 * the DCEVSEStatus should be generated according to already available values
			 * (if EVSEProcessing == ONGOING, maybe because of EVSE_IsolationMonitoringActive,
			 * within a certain timeout, then the status must be different)
			 */
			setEvseProcessingFinished(true);
			if (isEvseProcessingFinished()) {
				cableCheckRes.setEVSEProcessing(EVSEProcessingType.FINISHED);
				cableCheckRes.setDCEVSEStatus(
						((IDCEVSEController) getCommSessionContext().getDCEvseController()).getDCEVSEStatus(EVSENotificationType.NONE)
						);
				return getSendMessage(cableCheckRes, V2GMessages.PRE_CHARGE_REQ);
			} else {
				cableCheckRes.setEVSEProcessing(EVSEProcessingType.ONGOING);
				return getSendMessage(cableCheckRes, V2GMessages.CABLE_CHECK_REQ);
			}
		} else {
			setMandatoryFieldsForFailedRes();
		}
		return getSendMessage(cableCheckRes, V2GMessages.NONE);
	}
CableCheckReqType cableCheckReq =
(CableCheckReqType) v2gMessageReq.getBody().getBodyElement().getValue();
// TODO how to react to failure status of DCEVStatus of cableCheckReq?
/*
* TODO we need a timeout mechanism here so that a response can be sent within 2s
* the DCEVSEStatus should be generated according to already available values
* (if EVSEProcessing == ONGOING, maybe because of EVSE_IsolationMonitoringActive,
* within a certain timeout, then the status must be different)
*/
setEvseProcessingFinished(true);
if (isEvseProcessingFinished()) {
@Override
public ReactionToIncomingMessage processIncomingMessage(Object message) {
if (isIncomingMessageValid(message, CableCheckReqType.class, cableCheckRes)) {
V2GMessage v2gMessageReq = (V2GMessage) message;
CableCheckReqType cableCheckReq =
(CableCheckReqType) v2gMessageReq.getBody().getBodyElement().getValue();
// TODO how to react to failure status of DCEVStatus of cableCheckReq?
/*
* TODO we need a timeout mechanism here so that a response can be sent within 2s
* the DCEVSEStatus should be generated according to already available values
* (if EVSEProcessing == ONGOING, maybe because of EVSE_IsolationMonitoringActive,
* within a certain timeout, then the status must be different)
*/
setEvseProcessingFinished(true);
if (isEvseProcessingFinished()) {
cableCheckRes.setEVSEProcessing(EVSEProcessingType.FINISHED);
cableCheckRes.setDCEVSEStatus(
((IDCEVSEController) getCommSessionContext().getDCEvseController()).getDCEVSEStatus(EVSENotificationType.NONE)
);
return getSendMessage(cableCheckRes, V2GMessages.PRE_CHARGE_REQ);
} else {
cableCheckRes.setEVSEProcessing(EVSEProcessingType.ONGOING);
return getSendMessage(cableCheckRes, V2GMessages.CABLE_CHECK_REQ);
@Override
public ReactionToIncomingMessage processIncomingMessage(Object message) {
if (isIncomingMessageValid(message, CableCheckReqType.class, cableCheckRes)) {
V2GMessage v2gMessageReq = (V2GMessage) message;
CableCheckReqType cableCheckReq =
(CableCheckReqType) v2gMessageReq.getBody().getBodyElement().getValue();
// TODO how to react to failure status of DCEVStatus of cableCheckReq?
/*
* TODO we need a timeout mechanism here so that a response can be sent within 2s
* the DCEVSEStatus should be generated according to already available values
* (if EVSEProcessing == ONGOING, maybe because of EVSE_IsolationMonitoringActive,
* within a certain timeout, then the status must be different)
*/
setEvseProcessingFinished(true);
if (isEvseProcessingFinished()) {
cableCheckRes.setEVSEProcessing(EVSEProcessingType.FINISHED);
cableCheckRes.setDCEVSEStatus(
((IDCEVSEController) getCommSessionContext().getDCEvseController()).getDCEVSEStatus(EVSENotificationType.NONE)
);
return getSendMessage(cableCheckRes, V2GMessages.PRE_CHARGE_REQ);
} else {
cableCheckRes.setEVSEProcessing(EVSEProcessingType.ONGOING);
return getSendMessage(cableCheckRes, V2GMessages.CABLE_CHECK_REQ);
}
} else {
setMandatoryFieldsForFailedRes();
}
return getSendMessage(cableCheckRes, V2GMessages.NONE);
}