Package nom.tam.fits
Class HeaderCardCountingArrayDataInput
- java.lang.Object
-
- nom.tam.fits.HeaderCardCountingArrayDataInput
-
public class HeaderCardCountingArrayDataInput extends java.lang.ObjectA helper class to keep track of the number of physical cards for a logical card.
-
-
Field Summary
Fields Modifier and Type Field Description private ArrayDataInputinputthe input stream.private intmarkedPhysicalCardsReadprivate intphysicalCardsReadthe number of 80 byte cards read.
-
Constructor Summary
Constructors Modifier Constructor Description protectedHeaderCardCountingArrayDataInput(ArrayDataInput input)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcardRead()report a readed card.protected intgetPhysicalCardsRead()protected ArrayDataInputin()voidmark()mark the current position in the stream.voidreset()reset the stream th the last marked prosition.
-
-
-
Field Detail
-
input
private final ArrayDataInput input
the input stream.
-
physicalCardsRead
private int physicalCardsRead
the number of 80 byte cards read.
-
markedPhysicalCardsRead
private int markedPhysicalCardsRead
-
-
Constructor Detail
-
HeaderCardCountingArrayDataInput
protected HeaderCardCountingArrayDataInput(ArrayDataInput input)
-
-
Method Detail
-
getPhysicalCardsRead
protected int getPhysicalCardsRead()
- Returns:
- the number of cards realy read form the stream
-
in
protected ArrayDataInput in()
- Returns:
- the stream to read the cards from
-
cardRead
public void cardRead()
report a readed card.
-
mark
public void mark() throws java.io.IOExceptionmark the current position in the stream.- Throws:
java.io.IOException- if the underlaying stream does not allow the mark.
-
reset
public void reset() throws java.io.IOExceptionreset the stream th the last marked prosition.- Throws:
java.io.IOException- if the underlaying stream does not allow the mark.
-
-