if (requiresRedo(loggable, page)) {
if (ph.getLsn() != Page.NO_PAGE && requiresRedo(loggable, page)) {
    protected void redoInsertValue(InsertValueLoggable loggable) {        DOMPage page = getCurrentPage(loggable.pageNum);        DOMFilePageHeader ph = page.getPageHeader();        if (requiresRedo(loggable, page)) {            int dataLen = page.getPageHeader().getDataLength();            int offset = loggable.offset;            // insert in the middle of the page?            if (offset < dataLen) {                int end = offset + loggable.value.length + 4;                try {                System.arraycopy(page.data, offset, page.data, end,                        dataLen - offset);                } catch(ArrayIndexOutOfBoundsException e) {                    SanityCheck.TRACE("Error while copying data on page " + page.getPageNum() +                            "; tid: " + loggable.tid +                            "; offset: " + offset + "; end: " + end + "; len: " + (dataLen - offset));                }            }            // writing tid            ByteConversion.shortToByte((short) loggable.tid, page.data, offset);            offset += 2;            // writing value length            ByteConversion.shortToByte(loggable.isOverflow() ? 0 : (short) loggable.value.length,                    page.data, offset);            offset += 2;            // writing data            System.arraycopy(loggable.value, 0, page.data, offset, loggable.value.length);            offset += loggable.value.length;            page.getPageHeader().incRecordCount();            page.len += loggable.value.length + 4;            ph.setDataLength(page.len);            ph.setNextTID(loggable.tid);            page.setDirty(true);            dataCache.add(page);        }    }