OSID Logo
OSID Specifications
contact package
Version 3.0.0
Release Candidate Preview
Interfaceosid.contact.ContactAddressBookSession
Implementsosid.OsidSession
Description

This session provides methods to retrieve Contact to AddressBook mappings. A Contact may appear in multiple AddressBooks. Each AddressBook may have its own authorizations governing who is allowed to look at it.

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
MethodcanLookupContactAddressBookMappings
Description

Tests if this user can perform lookups of contact/address book mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known lookup methods in this session will result in a PERMISSION_DENIED. This is intendedas a hint to an application that may opt not to offer lookup operations to unauthorized users.

Returnboolean false if looking up mappings is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoduseComparativeAddressBookView
Description

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.

CompliancemandatoryThis method is must be implemented.
MethodusePlenaryAddressBookView
Description

A complete view of the Contact and AddressBook 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.

CompliancemandatoryThis method is must be implemented.
MethodgetContactIdsByAddressBook
Description

Gets the list of Contact Ids associated with an AddressBook.

Parametersosid.id.IdaddressBookId Id of an AddressBook.
Returnosid.id.IdListlist of related contact Ids
ErrorsNOT_FOUND addressBookId is not found
NULL_ARGUMENT addressBookId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByAddressBook
Description

Gets the list of Contacts associated with an AddressBook.

Parametersosid.id.IdaddressBookId Id of an AddressBook
Returnosid.contact.ContactListlist of related contacts
ErrorsNOT_FOUND addressBookId is not found
NULL_ARGUMENT addressBookId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactIdsByAddressBooks
Description

Gets the list of Contact Ids corresponding to a list of AddressBook objects.

Parametersosid.id.IdListaddressBookIdslist of address book Ids
Returnosid.id.IdListlist of contact Ids
ErrorsNULL_ARGUMENT addressBookIds is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByAddressBooks
Description

Gets the list of Contacts corresponding to a list of AddressBooks.

Parametersosid.id.IdListaddressBookIdslist of address book Ids
Returnosid.contact.ContactListlist of contacts
ErrorsNULL_ARGUMENT addressBookIds is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetAddressBookIdsByContact
Description

Gets the list of AddressBook Ids mapped to a Contact.

Parametersosid.id.IdcontactId Id of a Contact
Returnosid.id.IdListlist of address book Ids
ErrorsNOT_FOUND contactId is not found
NULL_ARGUMENT contactId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetAddressBooksByContact
Description

Gets the list of AddressBook objects mapped to a Contact.

Parametersosid.id.IdcontactId Id of a Contact
Returnosid.contact.AddressBookListlist of address books
ErrorsNOT_FOUND contactId is not found
NULL_ARGUMENT contactId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.