Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## uchicago.src.sim.parameter
Class NumericParameter

    java.lang.Object
      uchicago.src.sim.parameter.Parameter
          uchicago.src.sim.parameter.NumericParameter

    public class NumericParameter

extends Parameter

A numeric batch run parameter. `NumericParameter`s are created by a `ParameterReader` for use by a ``BatchController`. Consequently, a user should never need to create one.`

A numeric parameter like contains a starting value, an ending value, and an increment value. At the start of a batch run, the current value of a NumericParameter is the starting value. At the beginning of the next run, this starting value is incremented by the increment amount until the current amount is greater than the ending amount. The parameter space defined by a NumericParameter is thus inclusive of both the starting and ending values.

Version:
  $Revision: 1.6 $ $Date: 2004/11/03 19:51:04 $
Author:
  Nick Collier
See Also:
  `BatchController`, `SimInit`

Field Summary

Fields inherited from class uchicago.src.sim.parameter.Parameter
`CONSTANT, INCREMENT, incrementer, list, LIST, listIndex, name, numRuns, numRunsIndex, parent, subParams, subRuns`

Constructor Summary
`NumericParameter()`

Method Summary
`java.lang.Object` | `getEnd()`
`java.lang.Object` | `getIncr()`
`java.lang.Object` | `getStart()`
`java.lang.String` | `getStringValue()` Returns the current value
`java.lang.Object` | `getValue()` Gets the current value of this parameter as an Object.
`boolean` | `increment()` Increments this parameter according to the increment value
`boolean` | `isComplete()` Is this parameter complete?
`void` | `setEnd(double end)` Sets the ending value of this parameter.
`void` | `setEnd(java.lang.Object o)` Sets the ending value to the specified value.
`void` | `setIncr(double incr)` Sets the increment value of this parameter.
`void` | `setIncr(java.lang.Object o)` Sets the increment value to the specified value.
`void` | `setList(java.util.Vector v)`
`void` | `setStart(double start)` Sets the start value of this parameter.
`void` | `setStart(java.lang.Object o)` Sets the starting value to the specified value.

Methods inherited from class uchicago.src.sim.parameter.Parameter
`addChild, getChildren, getList, getName, getNumRuns, getParameterType, getParent, getSubRuns, getValAsParameterSet, hasChildren, isConstant, isIncrement, isInput, isList, removeChild, setConstVal, setInput, setName, setNumRuns, setParameterType, setParent, setSubRuns`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### NumericParameter

    public NumericParameter()

Method Detail

### setStart

    public void setStart(double start)

  Sets the start value of this parameter.

  Parameters:
    `start` - the starting value

### setEnd

    public void setEnd(double end)

  Sets the ending value of this parameter.

  Parameters:
    `end` - the ending value

### setIncr

    public void setIncr(double incr)

  Sets the increment value of this parameter.

  Parameters:
    `incr` - the increment value

### setStart

    public void setStart(java.lang.Object o)

  Sets the starting value to the specified value. Note: the specified object must be a Double.

  Specified by:
    `setStart` in class `Parameter`
  Parameters:
    `o` - the starting Double value

### setEnd

    public void setEnd(java.lang.Object o)

  Sets the ending value to the specified value. Note: the specified object must be a Double.

  Specified by:
    `setEnd` in class `Parameter`
  Parameters:
    `o` - the ending Double value

### setIncr

    public void setIncr(java.lang.Object o)

  Sets the increment value to the specified value. Note: the specified object must be a Double.

  Specified by:
    `setIncr` in class `Parameter`
  Parameters:
    `o` - the increment Double value

### setList

    public void setList(java.util.Vector v)

  Overrides:
    `setList` in class `Parameter`

### isComplete

    public boolean isComplete()

  Is this parameter complete? Does it have start, end, and increment set.

  Specified by:
    `isComplete` in class `Parameter`
  Returns:
    true if complete, otherwise false

### increment

    public boolean increment()

  Increments this parameter according to the increment value

  Specified by:
    `increment` in class `Parameter`
  Returns:
    true if value after incrementing is <= end value, otherwise false

### getStringValue

    public java.lang.String getStringValue()

  Returns the current value

  Specified by:
    `getStringValue` in class `Parameter`
  Returns:
    the current value of this parameter

### getValue

    public java.lang.Object getValue()

  Description copied from class: `Parameter`
  Gets the current value of this parameter as an Object. Used to write a run's parameters to a file, and set the model to the current parameter.

  Specified by:
    `getValue` in class `Parameter`
  Returns:
  See Also:
    `Parameter.getValue()`

### getStart

    public java.lang.Object getStart()

  Specified by:
    `getStart` in class `Parameter`

### getEnd

    public java.lang.Object getEnd()

  Specified by:
    `getEnd` in class `Parameter`

### getIncr

    public java.lang.Object getIncr()

  Specified by:
    `getIncr` in class `Parameter`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD