|
FreeHEP API Version current |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthep.graphics.heprep1.xml.XMLHepRepReader
Field Summary | |
protected InputStream |
input
|
protected String |
name
|
protected ZipFile |
zipFile
|
Constructor Summary | |
XMLHepRepReader(InputStream input)
|
|
XMLHepRepReader(String name)
|
Method Summary | |
void |
close()
Closes the reader and its underlying stream. |
String |
entryName()
Returns the current entry name (random acces only). |
List |
entryNames()
Returns a list of names of available entries (random rccess only). |
boolean |
hasNext()
Is there a next heprep. |
boolean |
hasRandomAccess()
Allows random access. |
boolean |
hasSequentialAccess()
Allows for sequential access. |
HepRep |
next()
Reads the next HepRep from the Reader. |
HepRep |
read(String name)
Reads a HepRep by name (random access only). |
protected HepRep |
readHepRep(InputStream stream)
|
void |
reset()
Resets a sequential HepRep reader. |
int |
size()
Returns the (estimated) number of HepReps in the reader. |
int |
skip(int n)
Skips a number of HepReps in the reader. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected InputStream input
protected String name
protected ZipFile zipFile
Constructor Detail |
public XMLHepRepReader(InputStream input) throws IOException
public XMLHepRepReader(String name) throws IOException
Method Detail |
protected HepRep readHepRep(InputStream stream) throws IOException
IOException
public void close() throws IOException
HepRepReader
close
in interface HepRepReader
IOException
- in case of a stream problem.public boolean hasSequentialAccess() throws IOException
HepRepReader
hasSequentialAccess
in interface HepRepReader
IOException
- in case of a stream problem.public void reset() throws IOException, UnsupportedOperationException
HepRepReader
reset
in interface HepRepReader
UnsupportedOperationException
- if the reader does not support sequential access.
IOException
- in case of a stream problem.public int size()
HepRepReader
size
in interface HepRepReader
public int skip(int n) throws UnsupportedOperationException
HepRepReader
skip
in interface HepRepReader
n
- number of HepReps to be skipped.
UnsupportedOperationException
- if the reader does not support sequential access.public boolean hasNext() throws IOException, UnsupportedOperationException
HepRepReader
hasNext
in interface HepRepReader
IOException
- in case of a stream problem.
UnsupportedOperationException
- if the reader does not support sequential access.public HepRep next() throws IOException, UnsupportedOperationException, NoSuchElementException
HepRepReader
next
in interface HepRepReader
IOException
- in case of a stream problem.
NoSuchElementException
- if the heprep is not available, or EOF.
UnsupportedOperationException
- if the reader does not support sequential access.public boolean hasRandomAccess()
HepRepReader
hasRandomAccess
in interface HepRepReader
public HepRep read(String name) throws IOException, UnsupportedOperationException, NoSuchElementException
HepRepReader
read
in interface HepRepReader
name
- for the heprep to be read.
UnsupportedOperationException
- if the reader does not support random access.
IOException
- in case of a stream problem.
NoSuchElementException
- if the heprep is not available.public String entryName()
HepRepReader
entryName
in interface HepRepReader
public List entryNames()
HepRepReader
entryNames
in interface HepRepReader
|
FreeHEP API Version current |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |