/* * Connects this {@code PipedReader} to a {@link PipedWriter}. Any data * written to the writer becomes readable in this reader. * * @param src * the writer to connect to. * @throws IOException * if this reader is closed or already connected, or if {@code * src} is already connected. */ public void connect(PipedWriter src) {// throws IOException { lock (lockJ) { src.connect(this); } }
/** * Connects this {@code PipedReader} to a {@link PipedWriter}. Any data * written to the writer becomes readable in this reader. * * @param src * the writer to connect to. * @throws IOException * if this reader is closed or already connected, or if {@code * src} is already connected. */ public void connect(PipedWriter src) { // throws IOException { lock (lockJ){ src.connect(this); } }
//throws IOException { /** * Constructs a new {@code PipedReader} connected to the {@link PipedWriter} * {@code out}. Any data written to the writer can be read from the this * reader. * * @param out * the {@code PipedWriter} to connect to. * @throws IOException * if {@code out} is already connected. */ public PipedReader(PipedWriter outJ) : this() { connect(outJ); }
//throws IOException { /** * Constructs a new PipedReader connected to the PipedWriter * <code>out</code> and the buffer size is specified. Any data written to the writer can be read from the * this reader. * * @param out * the PipedWriter to connect to. * @param pipeSize * the size of the buffer. * @throws IOException * if IO errors occur * @throws IllegalArgumentException * if pipeSize is less than or equal to zero. * @since 1.6 */ public PipedReader(PipedWriter outJ, int pipeSize) : this(pipeSize) { connect(outJ); }
/* * Constructs a new {@code PipedReader} connected to the {@link PipedWriter} * {@code out}. Any data written to the writer can be read from the this * reader. * * @param out * the {@code PipedWriter} to connect to. * @throws IOException * if {@code out} is already connected. */ public PipedReader(PipedWriter outJ) ://throws IOException { this() { connect(outJ); }
/* * Constructs a new PipedReader connected to the PipedWriter * <code>out</code> and the buffer size is specified. Any data written to the writer can be read from the * this reader. * * @param out * the PipedWriter to connect to. * @param pipeSize * the size of the buffer. * @throws IOException * if IO errors occur * @throws IllegalArgumentException * if pipeSize is less than or equal to zero. * @since 1.6 */ public PipedReader(PipedWriter outJ, int pipeSize) ://throws IOException { this(pipeSize) { connect(outJ); }