org.compass.core.util.reader
Class MultiIOReader

java.lang.Object
  extended by java.io.Reader
      extended by org.compass.core.util.reader.MultiIOReader
All Implemented Interfaces:
Closeable, Readable

public class MultiIOReader
extends Reader

A Reader implementation which wraps several Readers and reads them sequentially.

Author:
kimchy

Field Summary
 
Fields inherited from class java.io.Reader
lock
 
Constructor Summary
MultiIOReader()
           
MultiIOReader(Reader reader)
           
MultiIOReader(Reader[] readers)
           
MultiIOReader(String[] names, Reader[] readers)
           
MultiIOReader(String name, Reader reader)
           
 
Method Summary
 void add(Reader reader)
           
 void add(String name, Reader reader)
           
 void close()
           
 int read()
           
 int read(char[] cbuf, int off, int len)
           
 String toString()
           
 
Methods inherited from class java.io.Reader
mark, markSupported, read, read, ready, reset, skip
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MultiIOReader

public MultiIOReader()

MultiIOReader

public MultiIOReader(Reader reader)

MultiIOReader

public MultiIOReader(String name,
                     Reader reader)

MultiIOReader

public MultiIOReader(Reader[] readers)

MultiIOReader

public MultiIOReader(String[] names,
                     Reader[] readers)
Method Detail

add

public void add(Reader reader)

add

public void add(String name,
                Reader reader)

read

public int read()
         throws IOException
Overrides:
read in class Reader
Throws:
IOException

read

public int read(char[] cbuf,
                int off,
                int len)
         throws IOException
Specified by:
read in class Reader
Throws:
IOException

close

public void close()
           throws IOException
Specified by:
close in interface Closeable
Specified by:
close in class Reader
Throws:
IOException

toString

public String toString()
Overrides:
toString in class Object


Copyright (c) 2004-2008 The Compass Project.