private void checkForContextHeadRevision ( String contextId , UUID expectedHeadRevision ) throws EKBConcurrentException { if ( ! Objects . equal ( edbService . getLastRevisionNumberOfContext ( contextId ) , expectedHeadRevision ) ) { throw new EKBConcurrentException ( "The current revision of the context does not match the " + "expected one." ) ; } }
Tests if the head revision for the given context matches the given revision number . If this is not the case an EKBConcurrentException is thrown .