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

This session defines methods for retrieving contacts.

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 address book view: All contact methods in this session operate, retrieve and pertain to contacts defined explicitly in the current address book. Using an isolated view is useful for managing contacts with the ContactAdminSession.
  • federated address book view: All contact lookup methods in this session operate, retrieve and pertain to all contacts defined in this address book and any other address books implicitly available in this address book through address book inheritence.
  • effective contact view: All contact lookup methods return contacts where the current dates falls in between the effective dates inclusive.
  • any effective contact view: Contacts of any effective date are returned.

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

MethodgetAddressBookId
Description

Gets the AddressBook Id associated with this session.

Returnosid.id.Idthe AddressBook Id associated with this session
CompliancemandatoryThis method must be implemented.
MethodgetAddressBook
Description

Gets the AddressBook associated with this session.

Returnosid.contact.AddressBookthe address book
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodcanLookupContacts
Description

Tests if this user can lookup contacts. 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.

Returnboolean false if contact lookup methods are not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethoduseComparativeContactView
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.
MethodusePlenaryContactView
Description

A complete view of the Contact 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.
MethoduseFederatedAddressBookView
Description

Federates the view for methods in this session. A federated view will include contacts in address books which are children of this address book in the address book hierarchy.

CompliancemandatoryThis method is must be implemented.
MethoduseIsolatedAddressBookView
Description

Isolates the view for methods in this session. An isolated view restricts retrievals to this address book only.

CompliancemandatoryThis method is must be implemented.
MethoduseEffectiveContactView
Description

Only contacts whose effective dates are current are returned by methods in this session.

CompliancemandatoryThis method is must be implemented.
MethoduseAnyEffectiveContactView
Description

All contacts of any effective dates are returned by all methods in this session.

CompliancemandatoryThis method is must be implemented.
MethodgetContact
Description

Gets the Contact specified by its Id.

In plenary mode, the exact Id is found or a NOT_FOUND results. Otherwise, the returned Contact may have a different Id than requested, such as the case where a duplicate Id was assigned to a Contact and retained for compatibility.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdcontactIdthe Id of the Contact to retrieve
Returnosid.contact.Contactthe returned Contact
ErrorsNOT_FOUNDno Contact found with the given Id
NULL_ARGUMENT contactId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByIds
Description

Gets a ContactList corresponding to the given IdList.

In plenary mode, the returned list contains all of the contacts 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 contacts may be omitted from the list and may present the elements in any order including returning a unique set.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdListcontactIdsthe list of Ids to retrieve
Returnosid.contact.ContactListthe returned Contact list
ErrorsNOT_FOUNDan Id was not found
NULL_ARGUMENT contactIds is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusType
Description

Gets a ContactList corresponding to the given contact genus Type which does not include contacts of genus types derived from the specified Type.

In plenary mode, the returned list contains all of the contacts 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 contacts may be omitted from the list and may present the elements in any order including returning a unique set.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.type.TypecontactGenusTypea contact genus type
Returnosid.contact.ContactListthe returned Contact list
ErrorsNULL_ARGUMENT contactGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByParentGenusType
Description

Gets a ContactList corresponding to the given contact genus Type and include any additional contacts with genus types derived from the specified Type.

In plenary mode, the returned list contains all of the contacts 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 contacts may be omitted from the list and may present the elements in any order including returning a unique set.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.type.TypecontactGenusTypea contact genus type
Returnosid.contact.ContactListthe returned Contact list
ErrorsNULL_ARGUMENT contactGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByRecordType
Description

Gets a ContactList containing the given contact record Type.

In plenary mode, the returned list contains all of the contacts 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 contacts may be omitted from the list and may present the elements in any order including returning a unique set.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.type.TypecontactRecordTypea contact record type
Returnosid.contact.ContactListthe returned Contact list
ErrorsNULL_ARGUMENT contactRecordType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsOnDate
Description

Gets a list of contacts with an effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.calendaring.DateTimefromthe starting date
osid.calendaring.DateTimetothe ending date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT from is greater than to
NULL_ARGUMENT from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeOnDate
Description

Gets a list of contacts of a genus type and with an effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.type.TypecontactGenusTypea contact genus type
osid.calendaring.DateTimefromthe starting date
osid.calendaring.DateTimetothe ending date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT from is greater than to
NULL_ARGUMENT contactGenusType, from, or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsForReference
Description

Gets a list of contacts corresponding to a reference Id.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIdthe Id of the reference
Returnosid.contact.ContactListthe returned ContactList
ErrorsNULL_ARGUMENT referenceId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsForReferenceOnDate
Description

Gets a list of all contacts corresponding to a reference Id and effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIda reference Id
osid.calendaring.DateTimefromfrom date
osid.calendaring.DateTimetoto date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT to is less than from
NULL_ARGUMENT referenceId, from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeForReference
Description

Gets a list of contacts of the given genus type corresponding to a reference Id.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIdthe Id of the reference
osid.type.TypecontactGenusTypethe genus type of the contact
Returnosid.contact.ContactListthe returned ContactList
ErrorsNULL_ARGUMENT referenceId or contactGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeForReferenceOnDate
Description

Gets a list of all contacts of the given genus type corresponding to a reference Id and effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIda reference Id
osid.type.TypecontactGenusTypethe genus type of the contact
osid.calendaring.DateTimefromfrom date
osid.calendaring.DateTimetoto date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT to is less than from
NULL_ARGUMENT referenceId, contactGenusType, from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsForAddress
Description

Gets a list of all contacts corresponding to an address Id.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdaddressIdthe Id of the address
Returnosid.contact.ContactListthe returned ContactList
ErrorsNULL_ARGUMENT addressId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsForAddressOnDate
Description

Gets a list of all contacts corresponding to an address Id and effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdaddressIdan address Id
osid.calendaring.DateTimefromfrom date
osid.calendaring.DateTimetoto date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT to is less than from
NULL_ARGUMENT addressId, from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeForAddress
Description

Gets a list of all contacts of the given genus type corresponding to an address Id.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdaddressIdthe Id of the address
osid.type.TypecontactGenusTypethe genus type of the contact
Returnosid.contact.ContactListthe returned ContactList
ErrorsNULL_ARGUMENT addressId or contactGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeForAddressOnDate
Description

Gets a list of all contacts of the given genus type corresponding to an address Id and effective during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdaddressIdan address Id
osid.type.TypecontactGenusTypethe genus type of the contact
osid.calendaring.DateTimefromfrom date
osid.calendaring.DateTimetoto date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT to is less than from
NULL_ARGUMENT addressId, contactGenusType, from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsForReferenceAndAddress
Description

Gets a list of all contacts corresponding to a reference and address Id.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIdthe Id of the reference
osid.id.IdaddressIdthe Id of the address
Returnosid.contact.ContactListthe returned ContactList
ErrorsNULL_ARGUMENT referenceId or addressId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsForReferenceAndAddressOnDate
Description

Gets a list of all contacts corresponding to a reference and address Id and effectiveduring the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIdthe Id of the reference
osid.id.IdaddressIdan address Id
osid.calendaring.DateTimefromfrom date
osid.calendaring.DateTimetoto date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT to is less than from
NULL_ARGUMENT referenceId, addressI, from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeForReferenceAndAddress
Description

Gets a list of all contacts with the given genus type corresponding to a reference and address Id.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIdthe Id of the reference
osid.id.IdaddressIdthe Id of the address
osid.type.TypecontactGenusTypethe genus type of the contact
Returnosid.contact.ContactListthe returned ContactList
ErrorsNULL_ARGUMENT referenceId, addressId or contactGenusType is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContactsByGenusTypeForReferenceAndAddressOnDate
Description

Gets a list of all contacts with the given genus type corresponding to a reference and address Id and during the entire given date range inclusive but not confined to the date range.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Parametersosid.id.IdreferenceIdthe Id of the reference
osid.id.IdaddressIdan address Id
osid.type.TypecontactGenusTypethe genus type of the contact
osid.calendaring.DateTimefromfrom date
osid.calendaring.DateTimetoto date
Returnosid.contact.ContactListthe returned ContactList
ErrorsINVALID_ARGUMENT to is less than from
NULL_ARGUMENT referenceId, addressId, contactGenusType, from or to is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodgetContacts
Description

Gets all contacts.

In plenary mode, the returned list contains all known contacts or an error results. Otherwise, the returned list may contain only those contacts that are accessible through this session.

In effective mode, contacts are returned that are currently effective. In any effective mode, effective contacts and those currently expired are returned.

Returnosid.contact.ContactLista list of contacts
ErrorsOPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.