|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
RandomStream interface represen stream of data to be checked by the different tests. The interface will be implemented by real classes to read data from files, external devices, web urls or algorithms.
Method Summary | |
boolean |
closeInputStream()
close the input stream. |
String |
getFilename()
get the file name to be processed. this file is the raw data to be read, or the input file processed by algorithm. |
boolean |
isOpen()
check if RandomStream is open |
boolean |
openInputStream()
open the input stream. |
byte |
readByte()
read one byte from a file. |
int |
readInt()
Processing is similar to readByte. |
long |
readLong()
Processing is similar to readByte. |
void |
setFilename(String s)
set file name to be processed. this file is the raw data to be read, or the input file processed by algorithm. |
Method Detail |
public boolean isOpen()
public void setFilename(String s)
public String getFilename()
public boolean openInputStream() throws Exception
Exception
- -
Usually IOException.public boolean closeInputStream()
public byte readByte() throws Exception
first time ( if !isOpen() ) open file/stream, and return byte
at end of file close stream and returns -1
Exception
public int readInt() throws Exception
Exception
public long readLong() throws Exception
Exception
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |