/*
 * Licensed to the University of California, Berkeley under one or more contributor license
 * agreements. See the NOTICE file distributed with this work for additional information regarding
 * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance with the License. You may obtain a
 * copy of the License at
 *
 * http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software distributed under the License
 * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
 * or implied. See the License for the specific language governing permissions and limitations under
 * the License.
 */

package tachyon.client.next.block;

import java.io.IOException;
import java.io.InputStream;

/**
 * Provides a stream API to read a block from Tachyon. An instance of this extending class can be
 * obtained by calling {@link TachyonBS#getInStream}. Multiple BlockInStreams can be opened for a
 * block. This class is thread safe.
 *
 * The type of BlockInStream returned will depend on the data location and user configuration. A
 * {@link LocalBlockInStream} is returned if the data can be directly read from the local storage
 * of the machine the client is on and the user has enabled this optimization. Otherwise, a
 * {@link RemoteBlockInStream} will be returned which will read the data through a Tachyon worker.
 */
public abstract class BlockInStream extends InputStream {
  public abstract void seek(long pos) throws IOException;
}

@@ -1128,110 +1128,206 @@
 * Th
-e type of BlockInStream returned will depend on the data location and user configuration. A%0A *
+is class provides the same methods as a Java %7B@link InputStream%7D with an additional seek%0A * method. Currently the only implementation of this class which should be used by a client is%0A * the
  %7B@link 
 Loca
@@ -1326,13 +1326,14 @@
 ink 
-Local
+Client
 Bloc
@@ -1346,329 +1346,469 @@
 eam%7D
- is returned if the data can be directly read from
+.%0A */%0Apublic abstract class BlockInStream extends InputStream %7B%0A  /**%0A   * Moves the starting read position of
  the 
+b
 loc
-al storage%0A * of the machine the client is on and the user has enabled this optimization. Otherwise, a%0A * %7B@link RemoteBlockInStream%7D will
+k to the specified position which is relative to%0A   * the start of the block. Seeking to a position before the current read position is supported.%0A   *%0A   * @param pos The position to seek to, it must
  be 
-returned which will read the data through a Tachyon worker.%0A */%0Apublic abstract class BlockInStream extends InputStream %7B
+between 0 and the size of the block.%0A   * @throws IOException if the seek fails due to an error accessing the stream at the position%0A   */
 %0A  p

Update the javadoc of BlockInStream.