Skip to content
Snippets Groups Projects
Commit 6bb69a5a authored by Powers, Peter M.'s avatar Powers, Peter M.
Browse files

removing public declaration from interfaces

parent 194f9fcf
No related branches found
No related tags found
1 merge request!20Propagating numerous changes to upstream
...@@ -14,6 +14,6 @@ public interface NamedLocation { ...@@ -14,6 +14,6 @@ public interface NamedLocation {
/** /**
* Return the location. * Return the location.
*/ */
public Location location(); Location location();
} }
...@@ -11,19 +11,19 @@ public interface XY_Point { ...@@ -11,19 +11,19 @@ public interface XY_Point {
* Return the x-value of this point. * Return the x-value of this point.
* @return x * @return x
*/ */
public double x(); double x();
/** /**
* Return the y-value of this point. * Return the y-value of this point.
* @return x * @return x
*/ */
public double y(); double y();
/** /**
* Set the y-value of this point. * Set the y-value of this point.
* @param y * @param y
*/ */
public void set(double y); void set(double y);
} }
...@@ -17,7 +17,7 @@ public interface XY_Sequence extends Iterable<XY_Point> { ...@@ -17,7 +17,7 @@ public interface XY_Sequence extends Iterable<XY_Point> {
* @throws IndexOutOfBoundsException if the index is out of range ( * @throws IndexOutOfBoundsException if the index is out of range (
* {@code index < 0 || index >= size()}) * {@code index < 0 || index >= size()})
*/ */
public double x(int index); double x(int index);
/** /**
* Returns the y-value at {@code index}. * Returns the y-value at {@code index}.
...@@ -26,7 +26,7 @@ public interface XY_Sequence extends Iterable<XY_Point> { ...@@ -26,7 +26,7 @@ public interface XY_Sequence extends Iterable<XY_Point> {
* @throws IndexOutOfBoundsException if the index is out of range ( * @throws IndexOutOfBoundsException if the index is out of range (
* {@code index < 0 || index >= size()}) * {@code index < 0 || index >= size()})
*/ */
public double y(int index); double y(int index);
/** /**
* Sets the y-{@code value} at {@code index}. * Sets the y-{@code value} at {@code index}.
...@@ -35,24 +35,24 @@ public interface XY_Sequence extends Iterable<XY_Point> { ...@@ -35,24 +35,24 @@ public interface XY_Sequence extends Iterable<XY_Point> {
* @throws IndexOutOfBoundsException if the index is out of range ( * @throws IndexOutOfBoundsException if the index is out of range (
* {@code index < 0 || index >= size()}) * {@code index < 0 || index >= size()})
*/ */
public void set(int index, double value); void set(int index, double value);
/** /**
* Returns the number or points in this sequence. * Returns the number or points in this sequence.
* @return the sequence size * @return the sequence size
*/ */
public int size(); int size();
/** /**
* Returns an immutable {@code List} of the sequence x-values. * Returns an immutable {@code List} of the sequence x-values.
* @return the {@code List} of x-values * @return the {@code List} of x-values
*/ */
public List<Double> xValues(); List<Double> xValues();
/** /**
* Returns an immutable {@code List} of the sequence y-values. * Returns an immutable {@code List} of the sequence y-values.
* @return the {@code List} of y-values * @return the {@code List} of y-values
*/ */
public List<Double> yValues(); List<Double> yValues();
} }
...@@ -3,11 +3,9 @@ package org.opensha2.eq.model; ...@@ -3,11 +3,9 @@ package org.opensha2.eq.model;
import static com.google.common.base.Preconditions.checkArgument; import static com.google.common.base.Preconditions.checkArgument;
import static com.google.common.base.Preconditions.checkNotNull; import static com.google.common.base.Preconditions.checkNotNull;
import static com.google.common.base.Preconditions.checkState; import static com.google.common.base.Preconditions.checkState;
import static org.opensha2.data.DataUtils.validateWeight;
import static org.opensha2.eq.Magnitudes.MAX_MAG; import static org.opensha2.eq.Magnitudes.MAX_MAG;
import static org.opensha2.eq.fault.Faults.validateStrike; import static org.opensha2.eq.fault.Faults.validateStrike;
import static org.opensha2.eq.model.PointSourceType.FIXED_STRIKE; import static org.opensha2.eq.model.PointSourceType.FIXED_STRIKE;
import static org.opensha2.util.TextUtils.validateName;
import java.util.Collections; import java.util.Collections;
import java.util.Iterator; import java.util.Iterator;
......
...@@ -25,6 +25,6 @@ public interface GroundMotionModel { ...@@ -25,6 +25,6 @@ public interface GroundMotionModel {
* @param args a ground motion model input argument container * @param args a ground motion model input argument container
* @return a scalar ground motion wrapper * @return a scalar ground motion wrapper
*/ */
public ScalarGroundMotion calc(GmmInput args); ScalarGroundMotion calc(GmmInput args);
} }
...@@ -11,12 +11,12 @@ public interface ScalarGroundMotion { ...@@ -11,12 +11,12 @@ public interface ScalarGroundMotion {
* Returns the mean (natural log of the median) ground motion. * Returns the mean (natural log of the median) ground motion.
* @return the mean * @return the mean
*/ */
public double mean(); double mean();
/** /**
* Returns the standard deviation in natural log units. * Returns the standard deviation in natural log units.
* @return the standard deviation * @return the standard deviation
*/ */
public double sigma(); double sigma();
} }
...@@ -77,6 +77,7 @@ public class HazardCurve { ...@@ -77,6 +77,7 @@ public class HazardCurve {
* example calculations</a> * example calculations</a>
*/ */
public static void main(String[] args) { public static void main(String[] args) {
// delegate to run which has a return value for testing
String status = run(args); String status = run(args);
if (status != null) { if (status != null) {
System.err.print(status); System.err.print(status);
...@@ -138,6 +139,7 @@ public class HazardCurve { ...@@ -138,6 +139,7 @@ public class HazardCurve {
.toString(); .toString();
} }
} }
private static final OpenOption[] WRITE_OPTIONS = new OpenOption[] {}; private static final OpenOption[] WRITE_OPTIONS = new OpenOption[] {};
private static final OpenOption[] APPEND_OPTIONS = new OpenOption[] { APPEND }; private static final OpenOption[] APPEND_OPTIONS = new OpenOption[] { APPEND };
...@@ -155,8 +157,8 @@ public class HazardCurve { ...@@ -155,8 +157,8 @@ public class HazardCurve {
Optional<Executor> executor = Optional.<Executor> of(execSvc); Optional<Executor> executor = Optional.<Executor> of(execSvc);
log.info("Hazard Curve: calculating ..."); log.info("Hazard Curve: calculating ...");
Stopwatch batchWatch = Stopwatch.createUnstarted(); Stopwatch batchWatch = Stopwatch.createStarted();
Stopwatch totalWatch = Stopwatch.createUnstarted(); Stopwatch totalWatch = Stopwatch.createStarted();
int count = 0; int count = 0;
List<HazardResult> results = new ArrayList<>(); List<HazardResult> results = new ArrayList<>();
...@@ -210,8 +212,6 @@ public class HazardCurve { ...@@ -210,8 +212,6 @@ public class HazardCurve {
Site site, Site site,
Optional<Executor> executor) { Optional<Executor> executor) {
// TODO does this even need to be public?
Executor ex = executor.or(createExecutor()); Executor ex = executor.or(createExecutor());
try { try {
......
...@@ -14,6 +14,6 @@ public interface Named { ...@@ -14,6 +14,6 @@ public interface Named {
* Returns an object's display name. * Returns an object's display name.
* @return the name * @return the name
*/ */
public String name(); String name();
} }
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