CalendarForm (Hyperic HQ Plugin API)
Keywords: org.hyperic.hq.ui.action.CalendarForm class

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.hyperic.hq.ui.action
Class CalendarForm

    java.lang.Object
      org.apache.struts.action.ActionForm
          org.apache.struts.validator.ValidatorForm
              org.hyperic.hq.ui.action.BaseValidatorForm
                  org.hyperic.hq.ui.action.CalendarForm

All Implemented Interfaces:
  java.io.Serializable

Direct Known Subclasses:
  MetricDisplayRangeForm, ScheduleForm

    public class CalendarForm

extends BaseValidatorForm

A subclass of `BaseValidatorForm` that contains all of the properties for a start and end date.

See Also:
  Serialized Form

Field Summary
`static java.lang.String` | `AM`
`static java.lang.String` | `PM`

Fields inherited from class org.apache.struts.validator.ValidatorForm
`page, validatorResults`

Fields inherited from class org.apache.struts.action.ActionForm
`multipartRequestHandler, servlet`

Constructor Summary
`CalendarForm()`

Method Summary
`protected int` | `calcHour(java.lang.String hour, java.lang.String ampm)`
`java.lang.String` | `getEndAmPm()` Getter for property endAmPm.
`java.util.Date` | `getEndDate()` Utility method that converts the fields associated with the the end time into a date.
`java.lang.Integer` | `getEndDay()` Getter for property endDay.
`java.lang.String` | `getEndHour()` Getter for property endHour.
`java.lang.String` | `getEndMin()` Getter for property endMin.
`java.lang.Integer` | `getEndMonth()` Getter for property endMonth.
`java.lang.Integer` | `getEndYear()` Getter for property endYear.
`protected java.util.Calendar` | `getInitStartTime()`
`java.lang.String` | `getStartAmPm()` Getter for property startAmPm.
`java.util.Date` | `getStartDate()` Utility method that converts the fields associated with the the start time into a date.
`java.lang.Integer` | `getStartDay()` Getter for property startDay.
`java.lang.String` | `getStartHour()` Getter for property startHour.
`java.lang.String` | `getStartMin()` Getter for property startMin.
`java.lang.Integer` | `getStartMonth()` Getter for property startMonth.
`java.lang.Integer` | `getStartYear()` Getter for property startYear.
`boolean` | `getWantEndDate()` A flag indicating whether or not end date should be checked.
`java.util.Collection` | `getYearOptions()`
`void` | `populateEndDate(java.util.Date d, java.util.Locale userLocale)` Populates the form's end date fields with a date.
`void` | `populateStartDate(java.util.Date startDate, java.util.Locale userLocale)` Utility method that populates fields associated with the the start date.
`void` | `reset(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)`
`void` | `setEndAmPm(java.lang.String endAmPm)` Setter for property endAmPm.
`void` | `setEndDay(java.lang.Integer endDay)` Setter for property endDay.
`void` | `setEndHour(java.lang.String endHour)` Setter for property endHour.
`void` | `setEndMin(java.lang.String endMin)` Setter for property endMin.
`void` | `setEndMonth(java.lang.Integer endMonth)` Setter for property endMonth.
`void` | `setEndYear(java.lang.Integer endYear)` Setter for property endYear.
`void` | `setStartAmPm(java.lang.String startAmPm)` Setter for property startAmPm.
`void` | `setStartDay(java.lang.Integer startDay)` Setter for property startDay.
`void` | `setStartHour(java.lang.String startHour)` Setter for property startHour.
`void` | `setStartMin(java.lang.String startMin)` Setter for property startMin.
`void` | `setStartMonth(java.lang.Integer startMonth)` Setter for property startMonth.
`void` | `setStartYear(java.lang.Integer startYear)` Setter for property startYear.
`void` | `setWantEndDate(boolean b)`
`protected boolean` | `shouldValidateDateRange()`
`java.lang.String` | `toString()`
`org.apache.struts.action.ActionErrors` | `validate(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request)` Only validate if 1) the form's ok or okassign button was clicked and 2) the mapping specifies an input form to return to.
`protected void` | `validateDateRange(org.apache.struts.action.ActionMapping mapping, javax.servlet.http.HttpServletRequest request, org.apache.struts.action.ActionErrors errs)`

Methods inherited from class org.hyperic.hq.ui.action.BaseValidatorForm
`getAdd, getCancel, getCreate, getDelete, getEnable, getOk, getOkassign, getPn, getPs, getRemove, getReset, getUserset, isAddClicked, isCancelClicked, isCreateClicked, isDeleteClicked, isEnableClicked, isOkAssignClicked, isOkClicked, isRemoveClicked, isResetClicked, isUsersetClicked, setAdd, setCancel, setCreate, setDelete, setEnable, setOk, setOkassign, setPn, setPs, setRemove, setReset, setUserset, shouldValidate`

Methods inherited from class org.apache.struts.validator.ValidatorForm
`getPage, getResultValueMap, getValidationKey, getValidatorResults, setPage, setValidatorResults`

Methods inherited from class org.apache.struts.action.ActionForm
`getMultipartRequestHandler, getServlet, getServletWrapper, reset, setMultipartRequestHandler, setServlet, validate`

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

Field Detail

### AM

    public static final java.lang.String AM

See Also:
  Constant Field Values

### PM

    public static final java.lang.String PM

See Also:
  Constant Field Values

Constructor Detail

### CalendarForm

    public CalendarForm()

Method Detail

### getEndDate

    public java.util.Date getEndDate()

  Utility method that converts the fields associated with the the end time into a date.

  Returns:
    A java.util.Date that represents the end date.

### populateEndDate

    public void populateEndDate(java.util.Date d,
                                java.util.Locale userLocale)

  Populates the form's end date fields with a date.

  Parameters:
    `date` - A java.util.Date that represents the end date.

### getStartDate

    public java.util.Date getStartDate()

  Utility method that converts the fields associated with the the start time into a date.

  Returns:
    A java.util.Date that represents the start date.

### calcHour

    protected int calcHour(java.lang.String hour,
                           java.lang.String ampm)
                    throws java.lang.NumberFormatException

  Throws:
    `java.lang.NumberFormatException`

### populateStartDate

    public void populateStartDate(java.util.Date startDate,
                                  java.util.Locale userLocale)

  Utility method that populates fields associated with the the start date.

  Parameters:
    `d` - A java.util.Date that represents the start date.

### getInitStartTime

    protected java.util.Calendar getInitStartTime()

  Returns:
    an initial current time

### reset

    public void reset(org.apache.struts.action.ActionMapping mapping,
                      javax.servlet.http.HttpServletRequest request)

  Overrides:
    `reset` in class `BaseValidatorForm`

### validate

    public org.apache.struts.action.ActionErrors validate(org.apache.struts.action.ActionMapping mapping,
                                                          javax.servlet.http.HttpServletRequest request)

  Description copied from class: `BaseValidatorForm`
  Only validate if 1) the form's ok or okassign button was clicked and 2) the mapping specifies an input form to return to. condition #2 can be false when a form has failed validation and has forwarded to the input page; the ok button request parameter will still be userset, but the prepare action for the input page will not have (another) input page specified.

  Overrides:
    `validate` in class `BaseValidatorForm`

### shouldValidateDateRange

    protected boolean shouldValidateDateRange()

### validateDateRange

    protected final void validateDateRange(org.apache.struts.action.ActionMapping mapping,
                                           javax.servlet.http.HttpServletRequest request,
                                           org.apache.struts.action.ActionErrors errs)

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `BaseValidatorForm`

### getWantEndDate

    public boolean getWantEndDate()

  A flag indicating whether or not end date should be checked.

### setWantEndDate

    public void setWantEndDate(boolean b)

### getEndDay

    public java.lang.Integer getEndDay()

  Getter for property endDay.

  Returns:
    Value of property endDay.

### setEndDay

    public void setEndDay(java.lang.Integer endDay)

  Setter for property endDay.

  Parameters:
    `endDay` - New value of property endDay.

### getEndMonth

    public java.lang.Integer getEndMonth()

  Getter for property endMonth.

  Returns:
    Value of property endMonth.

### setEndMonth

    public void setEndMonth(java.lang.Integer endMonth)

  Setter for property endMonth.

  Parameters:
    `endMonth` - New value of property endMonth.

### getEndYear

    public java.lang.Integer getEndYear()

  Getter for property endYear.

  Returns:
    Value of property endYear.

### setEndYear

    public void setEndYear(java.lang.Integer endYear)

  Setter for property endYear.

  Parameters:
    `endYear` - New value of property endYear.

### getEndMin

    public java.lang.String getEndMin()

  Getter for property endMin.

  Returns:
    Value of property endMin.

### setEndMin

    public void setEndMin(java.lang.String endMin)

  Setter for property endMin.

  Parameters:
    `endMin` - New value of property endMin.

### getEndHour

    public java.lang.String getEndHour()

  Getter for property endHour.

  Returns:
    Value of property endHour.

### setEndHour

    public void setEndHour(java.lang.String endHour)

  Setter for property endHour.

  Parameters:
    `endHour` - New value of property endHour.

### getStartDay

    public java.lang.Integer getStartDay()

  Getter for property startDay.

  Returns:
    Value of property startDay.

### setStartDay

    public void setStartDay(java.lang.Integer startDay)

  Setter for property startDay.

  Parameters:
    `startDay` - New value of property startDay.

### getStartAmPm

    public java.lang.String getStartAmPm()

  Getter for property startAmPm.

  Returns:
    Value of property startAmPm.

### setStartAmPm

    public void setStartAmPm(java.lang.String startAmPm)

  Setter for property startAmPm.

  Parameters:
    `startAmPm` - New value of property startAmPm.

### getEndAmPm

    public java.lang.String getEndAmPm()

  Getter for property endAmPm.

  Returns:
    Value of property endAmPm.

### setEndAmPm

    public void setEndAmPm(java.lang.String endAmPm)

  Setter for property endAmPm.

  Parameters:
    `endAmPm` - New value of property endAmPm.

### getStartYear

    public java.lang.Integer getStartYear()

  Getter for property startYear.

  Returns:
    Value of property startYear.

### setStartYear

    public void setStartYear(java.lang.Integer startYear)

  Setter for property startYear.

  Parameters:
    `startYear` - New value of property startYear.

### getStartMin

    public java.lang.String getStartMin()

  Getter for property startMin.

  Returns:
    Value of property startMin.

### setStartMin

    public void setStartMin(java.lang.String startMin)

  Setter for property startMin.

  Parameters:
    `startMin` - New value of property startMin.

### getStartHour

    public java.lang.String getStartHour()

  Getter for property startHour.

  Returns:
    Value of property startHour.

### setStartHour

    public void setStartHour(java.lang.String startHour)

  Setter for property startHour.

  Parameters:
    `startHour` - New value of property startHour.

### getStartMonth

    public java.lang.Integer getStartMonth()

  Getter for property startMonth.

  Returns:
    Value of property startMonth.

### setStartMonth

    public void setStartMonth(java.lang.Integer startMonth)

  Setter for property startMonth.

  Parameters:
    `startMonth` - New value of property startMonth.

### getYearOptions

    public java.util.Collection getYearOptions()

Overview | Package | Class | Tree | Deprecated | Index | Help
| Hyperic HQ Plugin API v. 4.4.0.2
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004-2006 Hyperic, Inc. support@hyperic.net, All Rights Reserved.