ignore the result or throw an ArrayIndexOutOfBound exception
776689
@GuardedBy("lock")
    protected int computeIndex(long seqno) {
        int diff=(int)(seqno - offset);
        if(diff < 0)
            return diff;
        return diff & (elements_per_row - 1); // same as mod, but (apparently, I'm told) more efficient
    }
968826
private static <T> void _logResult(T result, int level, int indentSize, StringBuilder info) {
        if(result instanceof Map) {
            level += 1;
            int finalLevel = level;
            ((Map)result).forEach((k, v) -> {
                info.append("\n");
                info.append(getTabBasedOnLevel(finalLevel, indentSize))
                        .append(k.toString())
                        .append(":");
                _logResult(v, finalLevel, indentSize, info);
            });
        } else if(result instanceof List) {
            int finalLevel = level;
            ((List)result).forEach(element -> _logResult(element, finalLevel, indentSize, info));
        } else if(result instanceof String) {
            info.append(" ").append(result);
        } else if(result != null) {
            try {
                logger.warn(getTabBasedOnLevel(level, indentSize) + "{}", result);
            } catch (Exception e) {
                logger.error("Cannot handle this type: {}", result.getClass().getTypeName());
            }
        }
    }
1154947
protected void setArrayValue(final PreparedStatement statement, final int i, Connection connection, Object[] array)
            throws SQLException {
        if (array == null || (isEmptyStoredAsNull() && array.length == 0)) {
            statement.setNull(i, Types.ARRAY);
        } else {
            statement.setArray(i, connection.createArrayOf(getDialectPrimitiveName(), array));
        }
    }
1169366
public static void checkIndex(final int from, final int until, final int size) {
		if (from < 0) {
			throw new ArrayIndexOutOfBoundsException("fromIndex = " + from);
		}
		if (until > size) {
			throw new ArrayIndexOutOfBoundsException(format(
				"Invalid index range: [%d, %s)", from, until
			));
		}
		if (from > until) {
			throw new IllegalArgumentException(format(
				"fromIndex(%d) > toIndex(%d)", from, until
			));
		}
	}
752432
private void readPacket(Results results) throws SQLException {
    Buffer buffer;
    try {
      buffer = reader.getPacket(true);
    } catch (IOException e) {
      throw handleIoException(e);
    }

    switch (buffer.getByteAt(0)) {

      //*********************************************************************************************************
      //* OK response
      //*********************************************************************************************************
      case OK:
        readOkPacket(buffer, results);
        break;

      //*********************************************************************************************************
      //* ERROR response
      //*********************************************************************************************************
      case ERROR:
        throw readErrorPacket(buffer, results);

        //*********************************************************************************************************
        //* LOCAL INFILE response
        //*********************************************************************************************************
      case LOCAL_INFILE:
        readLocalInfilePacket(buffer, results);
        break;

      //*********************************************************************************************************
      //* ResultSet
      //*********************************************************************************************************
      default:
        readResultSet(buffer, results);
        break;

    }

  }
1294023
@Override
	public void updateArray(final int columnIndex, final Array x) throws SQLException {
		wrapped.updateArray(columnIndex, x);
	}
321717
protected void assertArrayHasLengthAndAllElementsNotNull(final Object[] array, final Integer length) throws ArgumentCountException, ArgumentNullException {

		if (array.length != length) {
			throw ArgumentCountException.notEqual(array.length, length);
		}

		for (final Object element : array) {

			if (element == null) {
				throw new ArgumentNullException();
			}
		}
	}
244573
private void skip() throws IOException, KriptonRuntimeException {
		while (position < limit || fillBuffer(1)) {
			int c = buffer[position];
			if (c > ' ') {
				break;
			}
			position++;
		}
	}
283290
private void executeResult() throws Exception {
		result = createResult();

		String timerKey = "executeResult: " + getResultCode();
		try {
			UtilTimerStack.push(timerKey);
			if (result != null) {
				result.execute(this);
			} else if (resultCode != null && !Action.NONE.equals(resultCode)) {
				throw new ConfigurationException("No result defined for action " + getAction().getClass().getName()
						+ " and result " + getResultCode(), proxy.getConfig());
			} else {
				if (LOG.isDebugEnabled()) {
					LOG.debug("No result returned for action " + getAction().getClass().getName() + " at "
							+ proxy.getConfig().getLocation());
				}
			}
		} finally {
			UtilTimerStack.pop(timerKey);
		}
	}
242293
public void throwIfNotEmpty() {
        synchronized (nested) {
            if (nested.isEmpty()) {
                // Do nothing
            } else if (nested.size() == 1) {
                Throwable t = nested.get(0);
                TigerThrower.sneakyThrow(t);
            } else {
                throw this;
            }
        }
    }
870165
private void skip() {
        try {
            int blockSize;
            do {
                blockSize = read();
                rawData.position(rawData.position() + blockSize);
            } while (blockSize > 0);
        } catch (IllegalArgumentException ex) {
        }
    }
7217
void handleGet(
    Object value,
    MatchSpaceKey msg,
    EvalCache cache,
    Object contextValue,
    SearchResults result)
    throws MatchingException, BadMessageFormatMatchingException
  {
    if (tc.isEntryEnabled())
      tc.entry(
        this,
        cclass,
        "handleGet",
        "value: "
          + value
          + "msg: "
          + msg
          + ", context: "
          + contextValue
          + ", result: "
          + result);

    if (!(value instanceof String))
      return;
    char[] chars = ((String) value).toCharArray();
    subTree.get(chars, 0, chars.length, false, msg, cache, contextValue, result);
    if (haveEqualityMatches())
      handleEqualityGet(value, msg, cache, contextValue, result);
    if (tc.isEntryEnabled())
      tc.exit(this,cclass, "handleGet");
  }
864280
public Object getArrayElement(Object o, int index) throws IndexOutOfBoundsException {
        if (o instanceof List)
            return ((List)o).get(index);
        return Array.get(o,index);
    }
565183
private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException {
        in.defaultReadObject();
        if (choiceLimits.length != choiceFormats.length) {
            throw new InvalidObjectException(
                    "limits and format arrays of different length.");
        }
    }
51234
public void throwIfReached() throws IOException {
    if (Thread.interrupted()) {
      throw new InterruptedIOException("thread interrupted");
    }

    if (hasDeadline && deadlineNanoTime - System.nanoTime() <= 0) {
      throw new InterruptedIOException("deadline reached");
    }
  }
852560
void handlePut(
    SimpleTest test,
    Conjunction selector,
    MatchTarget object,
    InternTable subExpr)
    throws MatchingException
  {
    if (tc.isEntryEnabled())
      tc.entry(
        this,
        cclass,
        "handlePut",
        new Object[] { test, selector, object, subExpr });
    Object value = test.getValue();
    if (value != null)
      handleEqualityPut(value, selector, object, subExpr);
    else {
      Pattern pattern = ((LikeOperatorImpl) test.getTests()[0]).getInternalPattern();
      subTree.put(new PatternWrapper(pattern), selector, object, subExpr);
    }

    if (tc.isEntryEnabled())
      tc.exit(this,cclass, "handlePut");
  }
624424
private static void filterThrowable(Throwable t) {

        // Now we want to remove the superfluous lines of stack trace from the
        // exception (those that have been inserted as a result of the way we
        // created the exception.
        StackTraceElement[] stackLines = t.getStackTrace();

        // If there is definitely something to work with.
        if ((stackLines != null) && (stackLines.length > 1)) {
            Vector v = new Vector();

            // Look at each stack line in turn until we reach the JmsErrorUtils
            // class stuff, then copy them over starting with the first line after
            // JmsErrorUtils finishes.
            boolean euStarted = false;

            // First read up to the point where the JmsErrorUtils entries start.
            int index = 0;
            for (index = 0; index < stackLines.length; index++) {
                StackTraceElement ste = stackLines[index];

                // See if this is the errorUtils
                if (className.equals(ste.getClassName())) {
                    // We have found an error utils line
                    euStarted = true;
                }
                else {
                    if (euStarted) {
                        // This indicates that we have now left the ErrorUtils lines,
                        // and everything left in the stack should be copied across.
                        v.add(ste);
                    }
                }
            }

            // Now we take the filtered stack trace and set it back into the
            // exception we originally got it from.
            if (v.size() != 0) {
                StackTraceElement[] filteredSTE = new StackTraceElement[v.size()];
                for (int i = 0; i < filteredSTE.length; i++) {
                    filteredSTE[i] = (StackTraceElement) v.elementAt(i);
                }
                t.setStackTrace(filteredSTE);
            }
        }
    }