public static class CssiSpaceWeatherDataLoader.LineReader extends Object
Constructor and Description |
---|
LineReader(String name,
BufferedReader in)
Create a line reader.
|
Modifier and Type | Method and Description |
---|---|
String |
getLine()
Get the last line read from the stream.
|
long |
getLineNumber()
Get the line number of the last line read from the file.
|
String |
readLine()
Read a line from the input data stream.
|
String |
readLineOrThrow(Localizable message,
Object... args)
Read a line from the input data stream, or if the end of the stream has been
reached throw an exception.
|
OrekitException |
unableToParseLine(Throwable cause)
Annotate an exception with the file context.
|
public LineReader(String name, BufferedReader in)
name
- of the data source for error messages.in
- the input data stream.public String readLine() throws IOException
null
if the end of the stream has been reached.IOException
- if an I/O error occurs.BufferedReader.readLine()
public String readLineOrThrow(Localizable message, Object... args) throws IOException, OrekitException
message
- for the exception if the end of the stream is reached.args
- for the exception if the end of stream is reached.null
if the end of the stream has been reached.IOException
- if an I/O error occurs.OrekitException
- if a line could not be read because the end of the
stream has been reached.readLine()
public OrekitException unableToParseLine(Throwable cause)
cause
- the reason why the line could not be parsed.public String getLine()
null
if no lines have been read or the end of stream
has been reached.public long getLineNumber()
Copyright © 2002-2022 CS GROUP. All rights reserved.