Utility method to skip past data in an array until it runs out of space
or finds the target character.

@param data
@param start
@param target
@return int (return index, equals data.length if not found)
497436
static public int skipToChar(byte[] data, int start, byte target) {
        int index = start;
        while (index < data.length && target != data[index]) {
            index++;
        }
        return index;
    }
870165
private void skip() {
        try {
            int blockSize;
            do {
                blockSize = read();
                rawData.position(rawData.position() + blockSize);
            } while (blockSize > 0);
        } catch (IllegalArgumentException ex) {
        }
    }
708366
private int skipLineBreak(Source source, final int offset) {
        char p;
        char c;
        int index = offset;
        p = source.charAt(index);
        index++;
        if (index < source.length()) {
            c = source.charAt(index);
            if ((c == '\n' || c == '\r') && c != p) {
                index++;
            }
        }
        return index;
    }
278226
private int skipForward(char[] chars, int start, int length) {
    if (tc.isEntryEnabled())
      tc.entry(this,cclass, "skipForward", new Object[]{chars,new Integer(start),
        new Integer(length)});
    int ans = length;
    for (int i = 0; i < length; i++)
      if (chars[start+i] == MatchSpace.SUBTOPIC_SEPARATOR_CHAR) {
        ans = i;
        break;
      }
    if (tc.isEntryEnabled())
      tc.exit(this,cclass, "skipForward", new Integer(ans));
    return ans;
  }
1069035
private int find(UTF8String str, int start) {
    assert (str.numBytes > 0);
    while (start <= numBytes - str.numBytes) {
      if (ByteArrayMethods.arrayEquals(base, offset + start, str.base, str.offset, str.numBytes)) {
        return start;
      }
      start += 1;
    }
    return -1;
  }
241932
@Override
  public long skip (final long nBytes) throws IOException
  {
    ValueEnforcer.isGE0 (nBytes, "Bytes");

    _ensureOpen ();
    long nRest = nBytes;
    while (nRest > 0)
    {
      if (m_nNextCharIndex >= m_nChars)
        _fill ();
      if (m_nNextCharIndex >= m_nChars)
      {
        // EOF
        break;
      }
      if (m_bSkipLF)
      {
        m_bSkipLF = false;
        if (m_aBuf[m_nNextCharIndex] == '\n')
          m_nNextCharIndex++;
      }
      final int d = m_nChars - m_nNextCharIndex;
      if (nRest <= d)
      {
        m_nNextCharIndex += nRest;
        nRest = 0;
        break;
      }
      nRest -= d;
      m_nNextCharIndex = m_nChars;
    }
    return nBytes - nRest;
  }
1087572
private void skipPromotedIndex(final DataInput in) throws IOException {
        final int size = in.readInt();
        if (size <= 0) {
            return;
        }

        FileUtils.skipBytesFully(in, size);
    }
1306853
private int skipWhitespace(final int position) {
		int index = sql.length();
		for (int i = position; i < index; ++i) {
			char c = sql.charAt(i);
			if (!Character.isWhitespace(c)) {
				return i;
			}
		}
		return index;
	}
869680
private int read1(char[] cbuf, int off, int len) throws IOException {
        if (nextChar >= nChars) {
            /* If the requested length is at least as large as the buffer, and
               if there is no mark/reset activity, and if line feeds are not
               being skipped, do not bother to copy the characters into the
               local buffer.  In this way buffered streams will cascade
               harmlessly. */
            if (len >= cb.length && markedChar <= UNMARKED && !skipLF) {
                return in.read(cbuf, off, len);
            }
            fill();
        }
        if (nextChar >= nChars) return -1;
        if (skipLF) {
            skipLF = false;
            if (cb[nextChar] == '\n') {
                nextChar++;
                if (nextChar >= nChars)
                    fill();
                if (nextChar >= nChars)
                    return -1;
            }
        }
        int n = Math.min(len, nChars - nextChar);
        System.arraycopy(cb, nextChar, cbuf, off, n);
        nextChar += n;
        return n;
    }
257053
public void skipPast(String to) {
        this.myIndex = this.mySource.indexOf(to, this.myIndex);
        if (this.myIndex < 0) {
            this.myIndex = this.mySource.length();
        } else {
            this.myIndex += to.length();
        }
    }
717674
public void append(final byte[] data, final int start, final int len) {
		final int oldLength = this.bytes.length;
		setCapacity(this.bytes.length + len, true);
		System.arraycopy(data, start, this.bytes, oldLength, len);
	}
353413
public static int skipSpaces (final String sIn, final int nStart)
  {
    int pos = nStart;
    while (pos < sIn.length () && (sIn.charAt (pos) == ' ' || sIn.charAt (pos) == '\n'))
      pos++;
    return pos < sIn.length () ? pos : -1;
  }
776040
@Override
	public long skip(long n) throws IOException {
		long numskip = this.in.skip(n);
		if (numskip > 0) {
			this.inputBytesRead += numskip;
		}
		return numskip;
	}
655747
public int skipWhitespace() {
        for (int i = index; i < originalInput.length(); i++) {
            char ch = originalInput.charAt(i);
            if (Character.isSpaceChar(ch) ) {
                index++;
            } else {
                break;
            }
        }
        return index;
    }
404043
public Matcher matcher(char[] data, int start, int end) {
        Matcher m = new Matcher(this);
        m.setTarget(data, start, end);
        return m;
    }
1091234
public int skipWhitespace() {
        try {
            int readChar = 20;
            char c = SPACE;
            while (Character.isWhitespace(c)) {
                reader.mark(1);
                readChar = reader.read();
                c = (char) readChar;
            }
            reader.reset();
            return readChar;
        } catch (IOException ioe) {
            throw new JsonException("An IO exception occurred while reading the JSON payload", ioe);
        }
    }
637183
public static void skipIndex(DataInput in) throws IOException
    {
        /* read only the column index list */
        int columnIndexSize = in.readInt();
        /* skip the column index data */
        if (in instanceof FileDataInput)
        {
            FileUtils.skipBytesFully(in, columnIndexSize);
        }
        else
        {
            // skip bytes
            byte[] skip = new byte[columnIndexSize];
            in.readFully(skip);
        }
    }