Compoze Software, Inc.

com.compoze.calendar
Class CalendarSession


java.lang.Object

  |

  +--com.compoze.calendar.CalendarSession

All Implemented Interfaces:
java.io.Serializable

public class CalendarSession
extends java.lang.Object
implements java.io.Serializable

This class provides a session for managing calendar information, and is the entry point into the Calendar API. It collects together properties used by the Calendar API and is not subclassed.

An instance of the CalendarSession can be obtained by calling getSession() with an authenticated user. Once a session is obtained, there are several entry points into the rest of the API.

See Also:
Serialized Form

Method Summary
 Appointment getAppointment(long lAptID)
          Gets a appointment with the given appointment id.
 Appointment getAppointment(long lAptID, java.util.Date instanceDate)
          Gets a appointment with the given appointment id.
 Appointments getAppointments()
          Gets the appointments collection for all of the appointments the authenticated user has CalendarPermission.READ permission.
static CalendarSession getSession(User user)
          Gets the calendar session using the specified user.
 User getUser()
          Gets the authenticated user for this session.
 java.lang.String toString()
          Returns a string representation of the object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

getSession


public static CalendarSession getSession(User user)
Gets the calendar session using the specified user.
Parameters:
user - the authenticated user
Returns:
the new calendar session

getAppointment


public Appointment getAppointment(long lAptID)
                           throws java.security.AccessControlException
Gets a appointment with the given appointment id.
Parameters:
lAptID - the appointment id
Returns:
the appointment or null if not found
Throws:
java.security.AccessControlException - if the authenticated user is not allowed to read the appointment

getAppointment


public Appointment getAppointment(long lAptID,
                                  java.util.Date instanceDate)
                           throws java.security.AccessControlException
Gets a appointment with the given appointment id.
Parameters:
lAptID - the appointment id
instanceDate - the instance date (ignored if not recuring appointment)
Returns:
the appointment or null if not found
Throws:
java.security.AccessControlException - if the authenticated user is not allowed to read the appointment

getAppointments


public Appointments getAppointments()
Gets the appointments collection for all of the appointments the authenticated user has CalendarPermission.READ permission.
Returns:
the appointments collection

getUser


public User getUser()
Gets the authenticated user for this session.
Returns:
the authenticated user

toString


public java.lang.String toString()
Returns a string representation of the object.
Overrides:
toString in class java.lang.Object
Returns:
tthe string representation of the object

Compoze Software, Inc.

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