expectedZero

public static ValueMismatch expectedZero(int actual, int newValue, int version)

Creates ValueMismatch for the case of discovering not zero value, when a zero amount was expected by a command.

Return

new ValueMismatch instance

Parameters

actual

the value discovered instead of zero

newValue

the new value requested in the command

version

the version of the entity in which the mismatch is discovered