public abstract class OceanTidesReader extends Object implements DataLoader
OceanTidesWave
Constructor and Description |
---|
OceanTidesReader(String supportedNames)
Simple constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addWaveCoefficients(int doodson,
int n,
int m,
double cPlus,
double sPlus,
double cMinus,
double sMinus,
int lineNumber,
String line)
Add parsed coefficients.
|
boolean |
canAdd(int n,
int m)
Check if coefficients can be added.
|
protected void |
endParse()
End parsing.
|
int |
getMaxParseDegree()
Get the degree limit for the next file parsing.
|
int |
getMaxParseOrder()
Get the order limit for the next file parsing.
|
String |
getSupportedNames()
Get the regular expression for supported files names.
|
List<OceanTidesWave> |
getWaves()
Get the loaded waves.
|
void |
setMaxParseDegree(int maxParseDegree)
Set the degree limit for the next file parsing.
|
void |
setMaxParseOrder(int maxParseOrder)
Set the order limit for the next file parsing.
|
protected void |
startParse(String fileName)
Start parsing.
|
boolean |
stillAcceptsData()
Check if the loader still accepts new data.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
loadData
public OceanTidesReader(String supportedNames)
supportedNames
- regular expression for supported files namespublic String getSupportedNames()
public void setMaxParseDegree(int maxParseDegree)
maxParseDegree
- maximal degree to parse (may be safely
set to Integer.MAX_VALUE
to parse all available coefficients)public int getMaxParseDegree()
public void setMaxParseOrder(int maxParseOrder)
maxParseOrder
- maximal order to parse (may be safely
set to Integer.MAX_VALUE
to parse all available coefficients)public int getMaxParseOrder()
public boolean stillAcceptsData()
This method is used to speed up data loading by interrupting crawling the data sets as soon as a loader has found the data it was waiting for. For loaders that can merge data from any number of sources (for example JPL ephemerides or Earth Orientation Parameters that are split among several files), this method should always return true to make sure no data is left over.
stillAcceptsData
in interface DataLoader
protected void startParse(String fileName)
This method must be called by subclasses when they start parsing a file
fileName
- name of the file (or zip entry)public boolean canAdd(int n, int m)
n
- degree of the coefficientsm
- order of the coefficientsprotected void addWaveCoefficients(int doodson, int n, int m, double cPlus, double sPlus, double cMinus, double sMinus, int lineNumber, String line)
doodson
- Doodson number of the current waven
- degree of the coefficientsm
- order of the coefficientscPlus
- C+(n,m)sPlus
- S+(n,m)cMinus
- C-(n,m)sMinus
- S-(n,m)lineNumber
- number of the parsed lineline
- text of the lineprotected void endParse()
This method must be called by subclasses when they end parsing a file
public List<OceanTidesWave> getWaves()
Copyright © 2002-2022 CS GROUP. All rights reserved.