OSID Logo
OSID Specifications
messaging package
Version 3.0.0
Release Candidate Preview
Interfaceosid.messaging.MessageMailboxAssignmentSession
Implementsosid.OsidSession
Description

This session provides methods to re-assign Messages to Mailboxes. A Message may map to multiple Mailbox objects and removing the last reference to a Message is the equivalent of deleting it. Each Mailbox may have its own authorizations governing who is allowed to operate on it.

Moving or adding a reference of a Message to another Mailbox is not a copy operation (eg: does not change its Id ).

MethodcanAssignMessages
Description

Tests if this user can alter message/mailbox mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping 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 assignment operations to unauthorized users.

Returnboolean false if mapping is not authorized, true otherwise
CompliancemandatoryThis method must be implemented.
MethodcanAssignMessagesToMailbox
Description

Tests if this user can alter message/mailbox mappings. A return of true does not guarantee successful authorization. A return of false indicates that it is known mapping 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 assignment operations to unauthorized users.

Parametersosid.id.IdmailboxIdthe Id of the Mailbox
Returnboolean false if messaging is not authorized, true otherwise
ErrorsNULL_ARGUMENT mailboxId is null
CompliancemandatoryThis method must be implemented.
MethodgetAssignableMailboxIds
Description

Gets a list of mailboxes including and under the given mailbox node in which any message can be assigned.

Parametersosid.id.IdmailboxIdthe Id of the Mailbox
Returnosid.id.IdListlist of assignable mailbox Ids
ErrorsNULL_ARGUMENT mailboxId is null
OPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodgetAssignableMailboxIdsForMessage
Description

Gets a list of mailboxes including and under the given mailbox node in which a specific message can be assigned.

Parametersosid.id.IdmailboxIdthe Id of the Mailbox
osid.id.IdmessageIdthe Id of the Message
Returnosid.id.IdListlist of assignable mailbox Ids
ErrorsNULL_ARGUMENT mailboxId or messageId is null
OPERATION_FAILEDunable to complete request
CompliancemandatoryThis method must be implemented.
MethodassignMessageToMailbox
Description

Adds an existing Message to a Mailbox.

Parametersosid.id.IdmessageIdthe Id of the Message
osid.id.IdmailboxIdthe Id of the Mailbox
ErrorsALREADY_EXISTS messageId is already assigned to mailboxId
NOT_FOUND messageId or mailboxId not found
NULL_ARGUMENT messageId or mailboxId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.
MethodunassignMessageFromMailbox
Description

Removes a Message from a Mailbox.

Parametersosid.id.IdmessageIdthe Id of the Message
osid.id.IdmailboxIdthe Id of the Mailbox
ErrorsNOT_FOUND messageId or mailboxId or messageId not assigned to mailboxId
NULL_ARGUMENT messageId or mailboxId is null
OPERATION_FAILEDunable to complete request
PERMISSION_DENIEDauthorization failure
CompliancemandatoryThis method must be implemented.