extension/src/main/java/org/justinnk/masonssa/extension/ssa/OptimizedDirectMethod.java
/**
   * Initialise an action by calculating its rate and adding it to the sum of rates (if applicable).
   *
   * @param action The action to initialise.
   * @return the current rate of the action if its precondition is met, Double.NEGATIVE_INFINITY
   *     otherwise.
   */
Initialise an action by calculating its rate and adding it to the sum of rates (if applicable).
@param action The action to initialise.
@return the current rate of the action if its precondition is met, Double.NEGATIVE_INFINITY
otherwise.
Initialise an action by calculating its rate and adding it to the sum of rates ( if applicable ) . @param action The action to initialise . @return the current rate of the action if its precondition is met Double . NEGATIVE_INFINITY otherwise .
public double initAction(Action action) {
    double rate;
    if (action.evaluateCondition()) {
      rate = action.calculateRate();
      return rate;
    }
    return Double.NEGATIVE_INFINITY;
  }
public double initAction ( Action action ) { double rate ; if ( action . evaluateCondition ( ) ) { rate = action . calculateRate ( ) ; return rate ; } return Double . NEGATIVE_INFINITY ; }
Initialise an action by calculating its rate and adding it to the sum of rates (if applicable).
Initialise an action by calculating its rate and adding it to the sum of rates ( if applicable ) .