private void checkState ( ) { Preconditions . checkNotNull ( logs ) ; if ( ! contiguous ) return ; RemoteEditLog prev = null ; for ( RemoteEditLog log : logs ) { if ( prev != null ) { if ( log . getStartTxId ( ) <= prev . getEndTxId ( ) ) { throw new IllegalStateException ( "Invalid log manifest:" + this ) ; } } prev = log ; } }
Check that the logs are contiguous and non - overlapping sequences of transactions in sorted order