public class NumericalCutsImpl extends Object implements NumericalCuts
NumericalCuts
interface.NumericalCuts
Modifier and Type | Field and Description |
---|---|
(package private) double[] |
defaultValues |
(package private) String[] |
names |
(package private) double[] |
values |
Constructor and Description |
---|
NumericalCutsImpl(String[] names,
double[] defaultValues) |
Modifier and Type | Method and Description |
---|---|
double[] |
getDefaultValues()
Get the default cuts.
|
String[] |
getNames()
Get the names of the cuts.
|
double |
getValue(int index)
Get a cut value by index.
|
double |
getValue(String name)
Get a cut setting by name.
|
double[] |
getValues()
Get the cut values.
|
protected int |
indexFromName(String name)
Get the index of a cut from its name.
|
boolean |
isDefaultValues()
True if using the default cuts.
|
void |
setValue(int index,
double value)
Set the value of a cut by index.
|
void |
setValue(String name,
double value)
Set a cut value by name.
|
void |
setValues(double[] values)
Set all the cut values from an array.
|
void |
setValues(Map<String,Double> valueMap)
Set the cut values from a map of keys to values.
|
String[] names
double[] values
double[] defaultValues
public NumericalCutsImpl(String[] names, double[] defaultValues)
public void setValues(double[] values)
NumericalCuts
setValues
in interface NumericalCuts
values
- The cut values.public double[] getValues()
NumericalCuts
getValues
in interface NumericalCuts
public double getValue(String name)
NumericalCuts
getValue
in interface NumericalCuts
name
- The name of the cut.public double getValue(int index)
NumericalCuts
getValue
in interface NumericalCuts
index
- The index of the cut.public String[] getNames()
NumericalCuts
getNames
in interface NumericalCuts
public void setValue(int index, double value)
NumericalCuts
setValue
in interface NumericalCuts
index
- The index of the cut.value
- The value of the cut.public boolean isDefaultValues()
NumericalCuts
isDefaultValues
in interface NumericalCuts
public double[] getDefaultValues()
NumericalCuts
getDefaultValues
in interface NumericalCuts
public void setValue(String name, double value)
NumericalCuts
setValue
in interface NumericalCuts
name
- The name of the cut.value
- The value of the cut.public void setValues(Map<String,Double> valueMap)
NumericalCuts
setValues
in interface NumericalCuts
valueMap
- The cut values as a map.protected int indexFromName(String name)
name
- The name of the cut.Copyright © 2019. All rights reserved.