Interface TodoLookupSession

All Superinterfaces:
AutoCloseable, Closeable, OsidSession, OsidSession

public interface TodoLookupSession extends OsidSession

This session defines methods for retrieving todos.

This lookup session defines several views:

  • comparative view: elements may be silently omitted or re-ordered
  • plenary view: provides a complete result set or is an error condition
  • isolated checklist view: All todo methods in this session operate, retrieve and pertain to todos defined explicitly in the current checklist. Using an isolated view is useful for managing todos with the TodoAdminSession .
  • federated checklist view: All todo lookup methods in this session operate, retrieve and pertain to all todos defined in this checklist and any other checklists implicitly available in this checklist through checklist inheritence.
  • effective todo view: All todo lookup methods return todos where the current dates falls in between the effective dates inclusive.
  • any effective todo view: Todos of any effective date are returned.
  • sequestered todo viiew: All event methods suppress sequestered todos.
  • unsequestered todo view: All event methods return all todos.

The methods useFederatedChecklistView() and useIsolatedChecklistView() behave as a radio group and one should be selected before invoking any lookup methods.

  • Method Details

    • getChecklistId

      Id getChecklistId()
      Gets the Checklist Id associated with this session.
      Returns:
      the Checklist Id associated with this session
      Compliance:
      mandatory - This method must be implemented.
    • getChecklist

      Gets the Checklist associated with this session.
      Returns:
      the checklist
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • canLookupTodos

      boolean canLookupTodos()
      Tests if this user can examine this checklist. A return of true does not guarantee successful authorization. A return of false indicates that it is known all methods in this session will result in a PERMISSION_DENIED . This is intended as a hint to an application that may opt not to offer these operations.
      Returns:
      false if checklist reading methods are not authorized, true otherwise
      Compliance:
      mandatory - This method must be implemented.
    • useComparativeTodoView

      void useComparativeTodoView()
      The returns from the lookup methods may omit or translate elements based on this session, such as authorization, and not result in an error. This view is used when greater interoperability is desired at the expense of precision.
      Compliance:
      mandatory - This method is must be implemented.
    • usePlenaryTodoView

      void usePlenaryTodoView()
      A complete view of the Todo returns is desired. Methods will return what is requested or result in an error. This view is used when greater precision is desired at the expense of interoperability.
      Compliance:
      mandatory - This method is must be implemented.
    • useFederatedChecklistView

      void useFederatedChecklistView()
      Federates the view for methods in this session. A federated view will include todos in checklists which are children of this checklist in the checklist hierarchy.
      Compliance:
      mandatory - This method is must be implemented.
    • useIsolatedChecklistView

      void useIsolatedChecklistView()
      Isolates the view for methods in this session. An isolated view restricts retrievals to this checklist only.
      Compliance:
      mandatory - This method is must be implemented.
    • useEffectiveTodoView

      void useEffectiveTodoView()
      Only todos whose effective dates are current are returned by methods in this session.
      Compliance:
      mandatory - This method is must be implemented.
    • useAnyEffectiveTodoView

      void useAnyEffectiveTodoView()
      All todos of any effective dates are returned by all methods in this session.
      Compliance:
      mandatory - This method is must be implemented.
    • useSequesteredTodoView

      void useSequesteredTodoView()
      The returns from the lookup methods omit sequestered todos.
      Compliance:
      mandatory - This method is must be implemented.
    • useUnsequesteredTodoView

      void useUnsequesteredTodoView()
      All todos are returned including sequestered todos.
      Compliance:
      mandatory - This method is must be implemented.
    • getTodo

      Gets the Todo specified by its Id . In plenary mode, the exact Id is found or a NOT_FOUND results. Otherwise, the returned Todo may have a different Id than requested, such as the case where a duplicate Id was assigned to a Todo and retained for compatibility. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      todoId - the Id of the Todo to retrieve
      Returns:
      the returned Todo
      Throws:
      NotFoundException - no Todo found with the given Id
      NullArgumentException - todoId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByIds

      Gets a TodoList corresponding to the given IdList . In plenary mode, the returned list contains all of the todos specified in the Id list, in the order of the list, including duplicates, or an error results if an Id in the supplied list is not found or inaccessible. Otherwise, inaccessible todos may be omitted from the list and may present the elements in any order including returning a unique set. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      todoIds - the list of Ids to retrieve
      Returns:
      the returned Todo list
      Throws:
      NotFoundException - an Id was not found
      NullArgumentException - todoIds is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByGenusType

      TodoList getTodosByGenusType(Type todoGenusType) throws OperationFailedException, PermissionDeniedException
      Gets a TodoList corresponding to the given todo genus Type which does not include todos of genus types derived from the specified Type . In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      todoGenusType - a todo genus type
      Returns:
      the returned Todo list
      Throws:
      NullArgumentException - todoGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByParentGenusType

      TodoList getTodosByParentGenusType(Type todoGenusType) throws OperationFailedException, PermissionDeniedException
      Gets a TodoList corresponding to the given todo genus Type and include any additional todos with genus types derived from the specified Type . In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      todoGenusType - a todo genus type
      Returns:
      the returned Todo list
      Throws:
      NullArgumentException - todoGenusType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByRecordType

      TodoList getTodosByRecordType(Type todoRecordType) throws OperationFailedException, PermissionDeniedException
      Gets a TodoList containing the given todo record Type . In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned.
      Parameters:
      todoRecordType - a todo record type
      Returns:
      the returned Todo list
      Throws:
      NullArgumentException - todoRecordType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosOnDate

      Gets a TodoList with starting effective during the entire given date range inclusive but not confined to the date range. This method return sthe same results in either effective status mode. In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      from - starting date
      to - ending date
      Returns:
      the returned Todo list
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByPriority

      TodoList getTodosByPriority(Type priorityType) throws OperationFailedException, PermissionDeniedException
      Gets a TodoList at the given priority Type or higher. In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned.
      Parameters:
      priorityType - a priority type
      Returns:
      the returned Todo list
      Throws:
      NullArgumentException - priorityType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByDueDate

      Gets a TodoList with a due date within the given date range inclusive. In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      from - starting date
      to - ending date
      Returns:
      the returned Todo list
      Throws:
      InvalidArgumentException - from is greater than to
      NullArgumentException - from or to is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodosByDependency

      TodoList getTodosByDependency(Id dependencyTodoId) throws OperationFailedException, PermissionDeniedException
      Gets a TodoList of todos dependent upon the given todo. In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Parameters:
      dependencyTodoId - a todo
      Returns:
      the returned Todo list
      Throws:
      NullArgumentException - dependencyTodoId is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.
    • getTodos

      Gets all todos. In plenary mode, the returned list contains all known todos or an error results. Otherwise, the returned list may contain only those todos that are accessible through this session. In effective mode, todos are returned that are currently effective. In any effective mode, effective todos and those currently expired are returned. In sequestered mode, no sequestered todos are returned. In unsequestered mode, all todos are returned.
      Returns:
      a list of todos
      Throws:
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure
      Compliance:
      mandatory - This method must be implemented.