|
FreeHEP API Version current |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The base interface that all record sources must implement.
Field Summary | |
static int |
UNKNOWN
A value that may be returned by getEstimatedSize |
Method Summary | |
void |
close()
Close the record source and free any associated resources |
Object |
getCurrentRecord()
Get the current record. |
long |
getEstimatedSize()
Returns the number of records in this record source, if known. |
Class |
getRecordClass()
Find out what type of records are returned by this record source. |
String |
getSourceName()
Get the (human readable) name of this record source. |
void |
next()
Go to the next record. |
void |
releaseRecord(Object record)
Releases any resources associated with the specified record. |
void |
rewind()
Repositions the record source before the first record. |
Field Detail |
public static final int UNKNOWN
Method Detail |
public long getEstimatedSize()
This is allowed to be an approximation (for example the number of events may be known but not the total number of records, or the expected number of records may be known, but the actual number may be different). The primary use of this method is for giving the user feedback on how much of a record source has been read, it should not be used as the limit for a for loop. Use hasNext() instead.
public Object getCurrentRecord() throws NoSuchRecordException, IOException, EndOfSourceException
null
if no current record.
NoSuchRecordException
IOException
EndOfSourceException
public void releaseRecord(Object record)
public void next() throws IOException
IOException
public Class getRecordClass()
public String getSourceName()
public void rewind() throws IOException
IOException
public void close() throws IOException
IOException
|
FreeHEP API Version current |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |