private void prepForAppend(int offset, int textLen) { if (tat[offset] > tat[offset + 1]) { // switch from null to zero length tat[offset + 1] = tat[offset]; } if (tat[offset + 1] + textLen >= tat[offset + 4]) { makeSpaceForAppend(offset, textLen); } }
public int appendTail(int offset, int nextLimit, byte value) { // setZeroLength was called first so no need to check for null if (tat[offset + 1] >= nextLimit) { // System.err.println("make space for "+offset); makeSpaceForAppend(offset, 1); nextLimit = tat[offset + 4]; } // everything is now ready to trim and copy. data[tat[offset + 1]++] = value; return nextLimit; }
public int appendTail(int offset, int nextLimit, byte value) { // setZeroLength was called first so no need to check for null if (tat[offset + 1] >= nextLimit) { // System.err.println("make space for "+offset); makeSpaceForAppend(offset, 1); nextLimit = tat[offset + 4]; } // everything is now ready to trim and copy. data[tat[offset + 1]++] = value; return nextLimit; }
private void prepForAppend(int offset, int textLen) { if (tat[offset] > tat[offset + 1]) { // switch from null to zero length tat[offset + 1] = tat[offset]; } if (tat[offset + 1] + textLen >= tat[offset + 4]) { makeSpaceForAppend(offset, textLen); } }
public static void appendTail(int idx, int trimTail, byte[] source, int sourceIdx, int sourceLen, int sourceMask, LocalHeap heap) { // if not room make room checking after first because thats where we // want to copy the tail. //System.arraycopy(source, sourceIdx, data, makeSpaceForAppend(idx, trimTail, sourceLen), sourceLen); int targetIdx = makeSpaceForAppend(idx,trimTail,sourceLen,heap); int i = sourceLen; while (--i>=0) { heap.data[targetIdx+i] = source[sourceMask&(sourceIdx+i)]; } }
public static void appendTail(int idx, int trimTail, byte[] source, int sourceIdx, int sourceLen, int sourceMask, LocalHeap heap) { // if not room make room checking after first because thats where we // want to copy the tail. //System.arraycopy(source, sourceIdx, data, makeSpaceForAppend(idx, trimTail, sourceLen), sourceLen); int targetIdx = makeSpaceForAppend(idx,trimTail,sourceLen,heap); int i = sourceLen; while (--i>=0) { heap.data[targetIdx+i] = source[sourceMask&(sourceIdx+i)]; } }
private void prepForAppend(int offset, int textLen) { if (tat[offset] > tat[offset + 1]) { // switch from null to zero length tat[offset + 1] = tat[offset]; } if (tat[offset + 1] + textLen >= tat[offset + 4]) { makeSpaceForAppend(offset, textLen); } }
public static void appendTail(int idx, int trimTail, byte[] source, int sourceIdx, int sourceLen, int sourceMask, LocalHeap heap) { // if not room make room checking after first because thats where we // want to copy the tail. //System.arraycopy(source, sourceIdx, data, makeSpaceForAppend(idx, trimTail, sourceLen), sourceLen); int targetIdx = makeSpaceForAppend(idx,trimTail,sourceLen,heap); int i = sourceLen; while (--i>=0) { heap.data[targetIdx+i] = source[sourceMask&(sourceIdx+i)]; } }
public int appendTail(int offset, int nextLimit, byte value) { // setZeroLength was called first so no need to check for null if (tat[offset + 1] >= nextLimit) { // System.err.println("make space for "+offset); makeSpaceForAppend(offset, 1); nextLimit = tat[offset + 4]; } // everything is now ready to trim and copy. data[tat[offset + 1]++] = value; return nextLimit; }