public interface ReceiptNotificationSession extends OsidSession
This session defines methods to receive notifications on new and
changed Receipts
in this Mailbox.
This also
includes existing receipts that may appear or disappear due to changes in
the Mailbox
hierarchy, This session is intended for
consumers needing to synchronize their receipts with this service without
the use of polling. Notifications are cancelled when this session is
closed.
The two views defined in this session correspond to the views in the
ReceiptLookupSession.
Modifier and Type | Method and Description |
---|---|
boolean |
canRegisterForReceiptNotifications()
Tests if this user can register for
Receipt
notifications. |
Mailbox |
getMailbox()
Gets the
Mailbox associated with this session. |
Id |
getMailboxId()
Gets the
Mailbox Id associated with this
session. |
void |
registerForChangedReceipt(Id receiptId)
Registers for notification of an updated receipt.
|
void |
registerForChangedReceipts()
Registers for notification of updated receipts.
|
void |
registerForChangedReceiptsByRecipient(Id recipientId)
Register for notifications of updated receipts for the specified
recipient.
|
void |
registerForChangedReceiptsForMessage(Id messageId)
Register for notifications of updated receipts for the specified
message.
|
void |
registerForDeletedReceipt(Id receiptId)
Registers for notification of a deleted receipt.
|
void |
registerForDeletedReceipts()
Registers for notification of receipts whose messages have been
deleted or removed from this mailbox.
|
void |
registerForDeletedReceiptsByRecipient(Id recipientId)
Register for notifications of deleted receipts for the specified
recipient.
|
void |
registerForDeletedReceiptsForMessage(Id messageId)
Register for notifications of deleted receipts for the specified
message.
|
void |
registerForNewReceipts()
Register for notifications of new receipts.
|
void |
registerForNewReceiptsByRecipient(Id recipientId)
Register for notifications of new receipts for the specified
recipient.
|
void |
registerForNewReceiptsForMessage(Id messageId)
Register for notifications of new receipts for the specified message.
|
void |
useFederatedMailboxView()
Federates the view for methods in this session.
|
void |
useIsolatedMailboxView()
Isolates the view for methods in this session.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getMailboxId()
Mailbox
Id
associated with this
session. Mailbox Id
associated with this sessionmandatory
- This method must be implemented. Mailbox getMailbox() throws OperationFailedException, PermissionDeniedException
Mailbox
associated with this session. Mailbox
associated with this sessionOperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canRegisterForReceiptNotifications()
Receipt
notifications. 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 notification operations. false
if notification methods are not
authorized, true
otherwisemandatory
- This method must be implemented. void useFederatedMailboxView()
mandatory
- This method is must be implemented. void useIsolatedMailboxView()
mandatory
- This method is must be implemented. void registerForNewReceipts() throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.newReceipts()
is invoked when a new
Receipt
is appears in this mailbox.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewReceiptsForMessage(Id messageId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.newReceipts()
is invoked when a new
Receipt
is appears in this mailbox.messageId
- the Id
of the Message
to monitorNullArgumentException
- messageId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewReceiptsByRecipient(Id recipientId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.newReceipst()
is invoked
when a new Receipt
is appears in this mailbox.recipientId
- the Id
of the Resource
to monitorNullArgumentException
- recipientId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedReceipts() throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.changedReceipts()
is invoked when a receipt in
this mailbox is changed.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedReceiptsForMessage(Id messageId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.changedReceipts()
is invoked
when a Receipt
in this mailbox is changed.messageId
- the Id
of the Message
to monitorNullArgumentException
- messageId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedReceiptsByRecipient(Id recipientId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.changedReceipts()
is invoked
when a Receipt
in this mailbox is changed.recipientId
- the Id
of the Resource
to monitorNullArgumentException
- recipientId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedReceipt(Id receiptId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.changedReceipt()
is invoked when the specified
receipt in this mailbox is changed.receiptId
- the Id
of the Receipt
to monitorNullArgumentException
- receiptId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedReceipts() throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.deletedReceipts()
is invoked when a receipt is
deleted or removed from this mailbox.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedReceiptsForMessage(Id messageId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.deletedReceipts()
is invoked
when a Receipt
in this mailbox is removed.messageId
- the Id
of the Message
to monitorNullArgumentException
- messageId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedReceiptsByRecipient(Id recipientId) throws OperationFailedException, PermissionDeniedException
ReceiptReceiver.deletedReceipts()
is invoked
when a Receipt
in this mailbox is removed.recipientId
- the Id
of the Resource
to monitorNullArgumentException
- recipientId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedReceipt(Id receiptId) throws OperationFailedException, PermissionDeniedException
MessageReceiver.deletedReceipts()
is invoked when the
specified receipt is deleted or removed from this mailbox.receiptId
- the Id
of the Receipt
to monitorNullArgumentException
- receiptId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.