コード例 #1
0
  /**
   * Validates the data prior to its use in, for instance, a parameter file.
   *
   * @param oPop TreePopulation object
   * @throws ModelException if any of the following are not greater than zero:
   *     <ul>
   *       <li>m_iNumQuadratAltDiv
   *       <li>m_iNumQuadratAziDiv
   *       <li>m_fQuadratMinSunAngle
   *       <li>
   *     </ul>
   */
  public void validateSubData(TreePopulation oPop) throws ModelException {

    ValidationHelpers.makeSureGreaterThan(m_iNumQuadratAltDiv, 0);
    ValidationHelpers.makeSureGreaterThan(m_iNumQuadratAziDiv, 0);
    ValidationHelpers.makeSureGreaterThan(m_fQuadratMinSunAngle, 0);
    ValidationHelpers.makeSureGreaterThanEqualTo(m_fQuadratLightHeight, 0);
  }
コード例 #2
0
 /**
  * Validates the data.
  *
  * @param oPop TreePopulation object.
  * @throws ModelException if beta is 0.
  */
 public void validateData(TreePopulation oPop) throws ModelException {
   ValidationHelpers.makeSureAllNonZero(mp_fMMPhotGrowthBeta, getWhichSpeciesUsed(oPop));
 }