Search in sources :

Example 1 with VariableNotFoundException

use of io.automatiko.engine.api.workflow.VariableNotFoundException in project automatiko-engine by automatiko-io.

the class VariableNotFoundExceptionMapper method toResponse.

@Override
public Response toResponse(VariableNotFoundException ex) {
    VariableNotFoundException exception = (VariableNotFoundException) ex;
    Map<String, String> response = new HashMap<>();
    response.put(MESSAGE, exception.getMessage());
    response.put(PROCESS_INSTANCE_ID, exception.getProcessInstanceId());
    response.put(VARIABLE, exception.getName());
    return notFound(response);
}
Also used : HashMap(java.util.HashMap) VariableNotFoundException(io.automatiko.engine.api.workflow.VariableNotFoundException)

Aggregations

VariableNotFoundException (io.automatiko.engine.api.workflow.VariableNotFoundException)1 HashMap (java.util.HashMap)1