Class DateValidator

java.lang.Object
com.portal.web.fmt.DateValidator
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
EventSearchValidator

public class DateValidator extends Object implements Serializable
Performs date validation on input date ranges. If errors occur, it throws a RemoteException with the error. If no errors occur, it calls the appropriate method in the controller and sets the input data, specifically, the start time and end time.
See Also:
  • Constructor Details

    • DateValidator

      public DateValidator()
  • Method Details

    • setStartYear

      public void setStartYear(String sYear)
      Sets the input data "start year."
      Parameters:
      sStartYear - a String with the start year value
    • setEndYear

      public void setEndYear(String sYear)
      Sets the input data "end year."
      Parameters:
      sEndYear - a String with the end year value
    • setStartMonth

      public void setStartMonth(String sMonth)
      Sets the input data "start month."
      Parameters:
      sStartMonth - a String with the start month value
    • setEndMonth

      public void setEndMonth(String sMonth)
      Sets the input data "end month."
      Parameters:
      sEndMonth - a String with the end month value
    • setStartDay

      public void setStartDay(String sDay)
      Sets the optional input data "start day."
      Parameters:
      sStartDay - a String with the start day value
    • setEndDay

      public void setEndDay(String sDay)
      Sets the input data "end day."
      Parameters:
      sEndDay - a String with the end day value
    • setStartDate

      public void setStartDate(String sDate)
      Sets the input data "start date."
      Parameters:
      sStartDate - a String with the start date value
    • setEndDate

      public void setEndDate(String sDate)
      Sets the input data "end date."
      Parameters:
      sEndDate - a String with the end date value
    • validate

      public void validate(ResourceBundle bundle, PControllerBean cb) throws RemoteException
      Validates the dates.
      Parameters:
      bundle - the resource bundle
      cb - the controller bean
      Throws:
      RemoteException - thrown for errors
    • validate

      public void validate(ResourceBundle bundle, PControllerBean cb, javax.servlet.http.HttpSession session) throws RemoteException
      Validates the dates from an HTTP session.
      Parameters:
      bundle - the resource bundle
      cb - the controller bean
      session - the HTTP session
      Throws:
      RemoteException - thrown if the date format is invalid or if start time is greater than the end time