All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class sdsu.io.ChunkEnumerator

java.lang.Object
   |
   +----sdsu.io.ChunkEnumerator

public class ChunkEnumerator
extends Object
implements Enumeration
Note: ChunkEnumerator is deprecated. Use ChunkReader

Deprecated use ChunkReader.

Version:
0.5 21 August 1997
Author:
Roger Whitney (whitney@cs.sdsu.edu)
See Also:
ChunkReader

Constructor Index

 o ChunkEnumerator(Reader, String)
Create a ChunkEnumerator object with a Reader as an input and the given separator.
 o ChunkEnumerator(String, String)
Create a ChunkEnumerator object with a String as an input and the given separator.

Method Index

 o fromFile(String, String)
Create a ChunkEnumerator object with a file as an input and the given separator.
 o hasMoreElements()
Returns true if there are more blocks of data in the input.
 o nextElement()
Returns the next block of data.
 o setSeparator(String)

Constructors

 o ChunkEnumerator
 public ChunkEnumerator(Reader in,
                        String separator)
Create a ChunkEnumerator object with a Reader as an input and the given separator. This class does not buffer the reader for you.

 o ChunkEnumerator
 public ChunkEnumerator(String input,
                        String separator)
Create a ChunkEnumerator object with a String as an input and the given separator.

Methods

 o fromFile
 public static ChunkEnumerator fromFile(String fileName,
                                        String separator) throws FileNotFoundException
Create a ChunkEnumerator object with a file as an input and the given separator. File IO will be buffered for you.

Throws: FileNotFoundException
thrown if fileName is not valid file name.
 o setSeparator
 public void setSeparator(String newSeparator)
 o hasMoreElements
 public boolean hasMoreElements()
Returns true if there are more blocks of data in the input.

 o nextElement
 public Object nextElement()
Returns the next block of data.

Throws: NoSuchElementException
if there are no blocks of data left.

All Packages  Class Hierarchy  This Package  Previous  Next  Index