POJO class keeping information on a LWT operation.
The "
public Operation operation()" method returns the type of LWT operation. Possibles
values are
LWTResultListener.LWTResult.LWTOperation.INSERT
and
LWTResultListener.LWTResult.LWTOperation.UPDATE
The "
public TypedMap currentValues()" method returns a
TypedMap
of current value for each column involved in the LWT operation
Below is an example of usage for LWTResult
LWTResultListener LWTListener = new LWTResultListener() {
public void onSuccess() {
// Do something on success
}
public void onError(LWTResult lwtResult) {
//Get type of LWT operation that fails
LWTResult.Operation operation = lwtResult.operation();
// Print out current values
TypedMap currentValues = lwtResult.currentValues();
currentValues
.entrySet()
.forEach(entry -> System.out.println(String.format("%s = %s",entry.getKey(), entry.getValue())));
}
}