Package hec.rss.model

Class RateChangeLimitOpRule

All Implemented Interfaces:
AsciiSerializable, FieldAccessor, TSLocation, DemandRuleInf, AltInputReportInfc, RssModelVariableConstants, RssReturnStatusConstants, RssTSLocation, Serializable, Cloneable, Comparable, Observer, rma.lang.Modifiable

public class RateChangeLimitOpRule extends OpRule implements AsciiSerializable, Serializable, Cloneable, DemandRuleInf
class for flow rate of change limit rule
See Also:
  • Field Details

  • Constructor Details

    • RateChangeLimitOpRule

      public RateChangeLimitOpRule()
    • RateChangeLimitOpRule

      public RateChangeLimitOpRule(String name)
  • Method Details

    • getMaxROCSteps

      public int getMaxROCSteps(double refFlow, int dt)
    • getControllingRateOfChangeLimit

      public double getControllingRateOfChangeLimit()
    • evaluateLimits

      public void evaluateLimits(RunTimeStep rts, int iteration)
      calculates the limiting value for this rule for the given time step. as of 12/04
      Overrides:
      evaluateLimits in class OpRule
      Parameters:
      rts -
      iteration -
    • getOpValue

      public OpValue getOpValue(RunTimeStep rts)
      returns the operation value based on the previously computed rule limit. As of 12/04
      Overrides:
      getOpValue in class OpRule
      Parameters:
      rts -
      Returns:
    • getRuleLimitType

      public int getRuleLimitType()
      get the limit type of this rule should be implemented by all subclasses of OpRule
      Overrides:
      getRuleLimitType in class OpRule
    • initializeCompute

      public boolean initializeCompute()
      prep for compute
      Overrides:
      initializeCompute in class OpRule
    • isValid

      public boolean isValid()
      Check that rule data is valid and available for compute
      Overrides:
      isValid in class NamedType
    • getRateOfChangeLimit

      public double getRateOfChangeLimit(RunTimeStep rts)
    • getRateOfChangeLimit

      public double getRateOfChangeLimit(double release, double inflow, double elev)
    • evaluateRule

      public OpValue evaluateRule(RunTimeStep rts, double initialValue)
      compares the intial value to rule constraints and returns the adjusted value
      Overrides:
      evaluateRule in class OpRule
    • clone

      public Object clone()
      Description copied from class: RssTSLocationObject
      clone method
      Overrides:
      clone in class OpRule
    • setChangeLimitCurve

      public void setChangeLimitCurve(PairedValues pv)
    • getChangeLimitCurve

      public PairedValues getChangeLimitCurve()
    • getFunctionType

      public int getFunctionType()
    • setFunctionType

      public void setFunctionType(int functionType)
    • setInterpolationType

      public void setInterpolationType(int type)
    • getInterpolationType

      public int getInterpolationType()
    • setType

      public void setType(int type)
    • getType

      public int getType()
    • setMaxRateOfChange

      public void setMaxRateOfChange(hec.data.ParamDouble pd)
    • setMaxRateOfChange

      public void setMaxRateOfChange(double d)
    • getMaxRateOfChange

      public void getMaxRateOfChange(hec.data.ParamDouble pd)
    • getMaxRateOfChange

      public double getMaxRateOfChange()
    • getFieldObject

      public Object getFieldObject(Field fld)
      Description copied from interface: FieldAccessor
      This method allows access to java.lang.reflect.Field objects within the implementing class.
      Specified by:
      getFieldObject in interface FieldAccessor
      Overrides:
      getFieldObject in class OpRule
      Parameters:
      fld - The field to get.
      Returns:
      The data object that is stored in the given field
    • setFieldObject

      public boolean setFieldObject(Field fld, Object fobj)
      Description copied from interface: FieldAccessor
      This allows access to fields withing the implementing object to set there data.
      Specified by:
      setFieldObject in interface FieldAccessor
      Overrides:
      setFieldObject in class OpRule
      Parameters:
      fld - The java field object representing the member field to be set
      fobj - The data to set in that field
      Returns:
      returns true if successful
    • outputReport

      public void outputReport(AlternativeInputReport report, org.jdom.Element elem)
      Description copied from interface: AltInputReportInfc
      Alternative Input Report Interface for data.
      Specified by:
      outputReport in interface AltInputReportInfc
      Overrides:
      outputReport in class OpRule
    • getWaterAccount

      public WaterAccount getWaterAccount()
      Description copied from interface: DemandRuleInf
      Gets the water account.
      Specified by:
      getWaterAccount in interface DemandRuleInf
      Returns:
      the water account
    • setWaterAccount

      public void setWaterAccount(WaterAccount wa)
      Description copied from interface: DemandRuleInf
      Sets the water account.
      Specified by:
      setWaterAccount in interface DemandRuleInf
      Parameters:
      wa - the new water account