All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ma.vi.base.io.DataInputStream Maven / Gradle / Ivy

The newest version!
/*
 * Copyright (c) 2018 Vikash Madhow
 */

package ma.vi.base.io;

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

/**
 * Wraps a {@link DataInput} in an {@link InputStream}.
 *
 * @author [email protected]
 */
public class DataInputStream extends InputStream {
  public DataInputStream(DataInput input) {
    this.input = input;
  }

  @Override
  public int read() throws IOException {
    return input.readUnsignedByte();
  }

  /**
   * The underlying input.
   */
  private final DataInput input;
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy