code: public int read(final byte[] buffer) throws IOException {
      // Note that GWT will throw a JavascriptException rather than a NullPointerException if we
      // skip this check and the buffer array is null. This way we ensure that this implementation
      // behaves in the same way as the classes that are emulated.
      if (buffer == null) {
        throw new NullPointerException();
      }
      return this.read(buffer, 0, buffer.length);
    }
docs: Equivalent to {@code read(buffer, 0, buffer.length)}.