Skip to content
Snippets Groups Projects
Commit c9ab9a9c authored by Clayton, Brandon Scott's avatar Clayton, Brandon Scott
Browse files

add compare to

parent fd44a6af
No related branches found
No related tags found
2 merge requests!128Production Release | nshmp-ws-static,!127Resolves - Handle Multiple NetCDF Files for AASHTO Service
......@@ -18,7 +18,7 @@ import gov.usgs.earthquake.nshmp.netcdf.reader.Reader;
*
* @author U.S. Geological Survey
*/
public abstract class Netcdf<T> {
public abstract class Netcdf<T> implements Comparable<Netcdf<T>> {
protected final Path netcdfPath;
protected final NetcdfData netcdfData;
......@@ -84,5 +84,11 @@ public abstract class Netcdf<T> {
*/
public abstract T staticData(Location site, NehrpSiteClass siteClass);
@Override
public int compareTo(Netcdf<T> that) {
return this.netcdfData().scienceBaseMetadata().label
.compareTo(that.netcdfData().scienceBaseMetadata().label);
}
abstract Reader getNetcdfData(Path netcdfPath);
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment