|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opensha.commons.eq.cat.CatTools
public class CatTools
Catalog utilities.
| Field Summary | |
|---|---|
static double |
MAG_MAX
Maximum earthquake magnitude value (10) used for range checking. |
static double |
MAG_MIN
Minimum earthquake magnitude value (-2) used for range checking. |
| Constructor Summary | |
|---|---|
CatTools()
|
|
| Method Summary | |
|---|---|
static String |
toJSON(Catalog catalog)
Returns a JSON string containing data arrays for the following data [TIME, LONGITUDE, LATITUDE, DEPTH, MAGNITUDE] |
static void |
validateMag(double mag)
Verifies that a magnitude value falls within range of MAG_MIN and MAG_MAX (inclusive). |
static void |
validateMags(double[] mags)
Verifies that a set of magnitude values fall within range of MAG_MIN and MAG_MAX (inclusive). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final double MAG_MIN
public static final double MAG_MAX
| Constructor Detail |
|---|
public CatTools()
| Method Detail |
|---|
public static final void validateMags(double[] mags)
MAG_MIN and MAG_MAX (inclusive).
mags - magnitudes to validate
IllegalArgumentException - if a data value is out of rangepublic static final void validateMag(double mag)
MAG_MIN and MAG_MAX (inclusive).
mag - magnitude to validate
IllegalArgumentException - if data value is out of rangepublic static final String toJSON(Catalog catalog)
catalog - to process
String
IllegalArgumentException - if catalog does not contain
the required output data types
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||