calendar.tex 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. \section{Calendar}
  2. \label{sec:calendar}
  3. The calendar is a new feature in \salespoint{} to manage appointments and events.
  4. Figure~\ref{calendar_overview} shows the UML model of the calendar.
  5. \begin{figure}[ht]
  6. \centering
  7. \includegraphics[width=1.0\textwidth]{images/Calendar_Overview.eps}
  8. \label{calendar_overview}
  9. \caption{Calendar - Class Overview}
  10. \end{figure}
  11. \code{Calendar} is an interface that provides simple functionality to store and retrieve \code{CalendarEntry}s.
  12. \code{CalendarEntry} is an interface to set, store and access information of a single appointment/event.
  13. Both interfaces are implemented by \code{PersistentCalendar} and \code{PersistentCalendarEntry}, respectively.
  14. \code{PersistentCalendarEntry} is a persistence entity containing all information and \code{PersistentCalendar} manages the JPA access.
  15. \\
  16. Every calendar entry is uniquely identified by a \code{CalendarEntryIdentifier}.
  17. This identifier also serves as primary key attribute when persisting an entry to the database.
  18. Additionally, a \code{PersistentCalendarEntry} must have an owner, a title, a start and an end date.
  19. The user who created the entry is known as the owner and identified by \code{ownerID} of the type \code{UserIdentifier}.
  20. \\
  21. The access of other users than the owner to a calendar entry is restricted by capabilities.
  22. For each calendar entry, a user identifier and a set of capabilities are stored.
  23. Possible capabilities are:
  24. \begin{itemize}
  25. \item \code{READ} - indicates if a user can read this entry
  26. \item \code{WRITE} - indicates if a user can change this entry
  27. \item \code{DELETE} - indicates if a user can delete this entry
  28. \item \code{SHARE} - indicates if a user can share this entry with other users
  29. \end{itemize}.
  30. Because \salespoint{} only implements the model of the MVC pattern (see Section~\ref{spring}), the developer has to check and enforce capabilities in the controller.
  31. \\
  32. Besides the minimum information of owner, title, start and end a calendar entry can also have a description, which may contain more information.
  33. Periodic appointments are also supported, by specifing the number of repetitions (\code{count} in Figure~\ref{calendar_overview}) and a time span between two appointments (\code{period} in Figure~\ref{calendar_overview}).
  34. \\
  35. There are some conditions for temporal attributes of an calendar entry:
  36. \begin{itemize}
  37. \item the start must not be after the end
  38. \item the time between two repetitions of an appointment need to be longer than the duration of the appointment, so that appointments do not overlap
  39. \end{itemize}
  40. %All attributes of the entry can be changed, except of the owner, who will be defined when the entry is created and then becomes immutable.