|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opensha.commons.param.AbstractParameter<String>
org.opensha.commons.param.impl.StringParameter
org.opensha.sha.param.MagDistStringParameter
public class MagDistStringParameter
| Field Summary | |
|---|---|
protected static String |
C
Class name for debugging. |
protected static boolean |
D
If true print out debug statements. |
| Fields inherited from class org.opensha.commons.param.AbstractParameter |
|---|
constraint, defaultValue, editable, independentParameters, info, metadataString, name, units, value, XML_COMPLEX_VAL_EL_NAME, XML_GROUP_METADATA_NAME, XML_METADATA_NAME, XML_NULL_VALUE |
| Fields inherited from interface org.opensha.commons.param.Parameter |
|---|
XML_INDEPENDENT_PARAMS_NAME |
| Constructor Summary | |
|---|---|
MagDistStringParameter(String name,
ArrayList strings)
|
|
MagDistStringParameter(String name,
ArrayList strings,
String value)
|
|
MagDistStringParameter(String name,
StringConstraint constraint)
|
|
MagDistStringParameter(String name,
StringConstraint constraint,
String value)
|
|
MagDistStringParameter(String name,
StringConstraint constraint,
String units,
String value)
|
|
| Method Summary | |
|---|---|
Object |
clone()
Returns a copy so you can't edit or damage the origial. |
int |
compareTo(Parameter<?> param)
Compares the values to if this is less than, equal to, or greater than the comparing objects. |
boolean |
equals(Object obj)
Compares the passed in MagDistStringParameter to see if it has the same name and value. |
ArrayList |
getAllowedStrings()
Returns a clone of the allowed strings of the constraint. |
ParameterEditor<String> |
getEditor()
Returns the Editor for this Parameter. |
String |
getType()
Gets the type attribute of the MagDistStringParameter object. |
void |
setConstraint(ParameterConstraint constraint)
Sets the constraint reference if it is a StringConstraint and the parameter is currently editable, else throws an exception. |
| Methods inherited from class org.opensha.commons.param.impl.StringParameter |
|---|
setIndividualParamValueFromXML |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final String C
protected static final boolean D
| Constructor Detail |
|---|
public MagDistStringParameter(String name,
ArrayList strings)
throws ConstraintException
name - strings -
ConstraintException
public MagDistStringParameter(String name,
StringConstraint constraint)
throws ConstraintException
name - constraint -
ConstraintException
public MagDistStringParameter(String name,
ArrayList strings,
String value)
throws ConstraintException
name - strings - value -
ConstraintException
public MagDistStringParameter(String name,
StringConstraint constraint,
String value)
throws ConstraintException
name - constraint - value -
ConstraintException
public MagDistStringParameter(String name,
StringConstraint constraint,
String units,
String value)
throws ConstraintException
name - constraint - units - value -
ConstraintException| Method Detail |
|---|
public void setConstraint(ParameterConstraint constraint)
throws ParameterException,
EditableException
setConstraint in interface Parameter<String>setConstraint in class StringParameterconstraint - to set
ParameterException
EditableExceptionpublic String getType()
getType in interface Parameter<String>getType in class StringParameterpublic ArrayList getAllowedStrings()
getAllowedStrings in class StringParameterpublic int compareTo(Parameter<?> param)
compareTo in interface Comparable<Parameter<?>>compareTo in class AbstractParameter<String>obj - The object to compare this to
ClassCastException - Is thrown if the comparing object is not
a MagDistStringParameter *Comparablepublic boolean equals(Object obj)
equals in interface Parameter<String>equals in class AbstractParameter<String>obj - The object to compare this to
ClassCastException - Is thrown if the comparing object is not
a MagDistStringParameterpublic Object clone()
clone in interface Parameter<String>clone in class StringParameterpublic ParameterEditor<String> getEditor()
ParameterEditor for this Parameter. It is
recommended that editors be lazily instantiated.
getEditor in interface Parameter<String>getEditor in class StringParameterEditor
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||