Class CalendarAPI


  • public class CalendarAPI
    extends BaseAPI
    The calendar is used to get the calendar for a user. The calendar includes items with a date field in the interval and tasks with a due date in the interval.

    Calendar entries are always sorted by date.

    • Constructor Detail

    • Method Detail

      • getApp

        public List<Event> getApp​(int appId,
                                  org.joda.time.LocalDate dateFrom,
                                  org.joda.time.LocalDate dateTo,
                                  ReferenceType... types)
        Returns the items and tasks that are related to the given app.
        Parameters:
        appId - The id of the app
        dateFrom - The from date
        dateTo - The to date
        types - The types of events that should be returned. Leave out to get all types of events.
        Returns:
        The events in the calendar
      • getSpace

        public List<Event> getSpace​(int spaceId,
                                    org.joda.time.LocalDate dateFrom,
                                    org.joda.time.LocalDate dateTo,
                                    ReferenceType... types)
        Returns all items and tasks that the user have access to in the given space. Tasks with reference to other spaces are not returned or tasks with no reference.
        Parameters:
        spaceId - The id of the space
        dateFrom - The from date
        dateTo - The to date
        types - The types of events that should be returned. Leave out to get all types of events.
        Returns:
        The events in the calendar
      • getGlobal

        public List<Event> getGlobal​(org.joda.time.LocalDate dateFrom,
                                     org.joda.time.LocalDate dateTo,
                                     List<Integer> spaceIds,
                                     ReferenceType... types)
        Returns all items that the user have access to and all tasks that are assigned to the user. The items and tasks can be filtered by a list of space ids, but tasks without a reference will always be returned.
        Parameters:
        dateFrom - The from date
        dateTo - The to date
        types - The types of events that should be returned. Leave out to get all types of events.
        Returns:
        The events in the calendar