Compoze Software, Inc.

portlets.compoze.groupware.model.calendar
Class CalendarViewModel

java.lang.Object
  extended byportlets.compoze.groupware.model.AbstractModel
      extended byportlets.compoze.groupware.model.calendar.CalendarModel
          extended byportlets.compoze.groupware.model.calendar.CalendarViewModel
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
DayViewModel, MonthViewModel, WeekViewModel, YearViewModel

public abstract class CalendarViewModel
extends CalendarModel
implements java.io.Serializable

This abstract class represents a base class for calendar views.

See Also:
Serialized Form

Constructor Summary
CalendarViewModel(portlets.compoze.groupware.controls.provider.Provider provider, FeatureGroup featureGroup, GroupwarePreferences groupwarePrefs, CalendarPreferences calendarPrefs, Accounts accounts)
          Constructor.
 
Method Summary
 Appointment[] getAppointments()
          Gets the appointments for the month view.
 java.lang.String getDateString(java.util.Date date)
          Gets the localized date string for the specified date.
abstract  java.util.Date getEndDate()
          Gets the end date.
 java.util.Date getGivenDate()
          Gets the given date.
 java.lang.String getGivenDateString()
          Gets the localized given date string.
abstract  java.util.Date getNextDate()
          Gets the next date.
abstract  java.util.Date getPreviousDate()
          Gets the previous date.
 portlets.compoze.groupware.controls.provider.Provider getProvider()
          Gets the provider.
abstract  java.util.Date getStartDate()
          Gets the start date.
 java.lang.String getTimeString(java.util.Date time)
          Gets the localized time string for the specified time.
 java.util.Date getToday()
          Gets the date for today.
 java.lang.String getTodayString()
          Gets the localized date string for today.
 java.lang.String getYearString(java.util.Date date)
          Gets the localized year string for the specified date.
 void setAppointments(Appointment[] appointments)
          Sets the appointments for the month view.
 void setGivenDate(java.util.Date givenDate)
          Sets the given date.
 
Methods inherited from class portlets.compoze.groupware.model.calendar.CalendarModel
getCalendarPreferences
 
Methods inherited from class portlets.compoze.groupware.model.AbstractModel
getAccounts, getActualTitle, getFeatureGroup, getGroupwarePreferences, getImAccount, getProviderCapabilities, getTitle, getTitleArgs, getTitleCrumbTrailKeys, isImAvailable, setActualTitle, setImAccount, setImAvailable, setTitle, setTitleArgs, setTitleCrumbTrailKeys
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CalendarViewModel

public CalendarViewModel(portlets.compoze.groupware.controls.provider.Provider provider,
                         FeatureGroup featureGroup,
                         GroupwarePreferences groupwarePrefs,
                         CalendarPreferences calendarPrefs,
                         Accounts accounts)
Constructor.

Parameters:
provider - the provider (may not be null)
featureGroup - the feature group (may not be null)
groupwarePrefs - the groupware preferences (may not be null)
calendarPrefs - the calendar preferences (may not be null)
Method Detail

getGivenDate

public java.util.Date getGivenDate()
Gets the given date.

Returns:
the given date

getProvider

public portlets.compoze.groupware.controls.provider.Provider getProvider()
Gets the provider.

Returns:
the provider

getGivenDateString

public java.lang.String getGivenDateString()
Gets the localized given date string.

Returns:
the localized given date string or an empty string

getTodayString

public java.lang.String getTodayString()
Gets the localized date string for today.

Returns:
the localized date string or an empty string

getDateString

public java.lang.String getDateString(java.util.Date date)
Gets the localized date string for the specified date.

Parameters:
date - the date
Returns:
the localized date string for the specified date

getTimeString

public java.lang.String getTimeString(java.util.Date time)
Gets the localized time string for the specified time.

Parameters:
time - the time
Returns:
the localized time string for the specified time

getYearString

public java.lang.String getYearString(java.util.Date date)
Gets the localized year string for the specified date.

Parameters:
date - the date
Returns:
the localized year string for the specified date

getToday

public java.util.Date getToday()
Gets the date for today.

Returns:
the date for today

setGivenDate

public void setGivenDate(java.util.Date givenDate)
Sets the given date.

Parameters:
givenDate - the given date (may not be null)

setAppointments

public void setAppointments(Appointment[] appointments)
Sets the appointments for the month view.

Parameters:
appointments - the appointments for the month view (may not be null)

getAppointments

public Appointment[] getAppointments()
Gets the appointments for the month view.

Returns:
the appointments for the month

getNextDate

public abstract java.util.Date getNextDate()
Gets the next date.

Returns:
the next date

getPreviousDate

public abstract java.util.Date getPreviousDate()
Gets the previous date.

Returns:
the previous date

getStartDate

public abstract java.util.Date getStartDate()
Gets the start date.

Returns:
the start date

getEndDate

public abstract java.util.Date getEndDate()
Gets the end date.

Returns:
the end date

Compoze Software, Inc.

Copyright ©1999-2003 Compoze Software, Inc. All rights reserved.