public interface AuthorizationNotificationSession extends OsidSession
This session defines methods to receive asynchronous notifications on
adds/changes to Authorizations.
This session is intended
for consumers needing to synchronize their state with this service without
the use of polling. Notifications are cancelled when this session is
closed.
The views defined in this session correspond to the views in the
AuthorizationLookupSession.
Modifier and Type | Method and Description |
---|---|
void |
acknowledgeAuthorizationNotification(Id notificationId)
Acknowledge an authorization notification.
|
boolean |
canRegisterForAuthorizationNotifications()
Tests if this user can register for
Authorization
notifications. |
Vault |
getVault()
Gets the
Vault associated with this session. |
Id |
getVaultId()
Gets the
Vault Id associated with this
session. |
void |
registerForChangedAuthorization(Id authorizationId)
Registers for notification of an updated authorization.
|
void |
registerForChangedAuthorizations()
Registers for notification of updated authorizations.
|
void |
registerForChangedAuthorizationsForFunction(Id functionId)
Registers for notification of updated authorizations for the given
function.
|
void |
registerForChangedAuthorizationsForResource(Id resourceId)
Registers for notification of updated authorizations for the given
resource including any authorizations related to the resource through
an agent.
|
void |
registerForDeletedAuthorization(Id authorizationId)
Registers for notification of a deleted authorization.
|
void |
registerForDeletedAuthorizations()
Registers for notification of deleted authorizations.
|
void |
registerForDeletedAuthorizationsForFunction(Id functionId)
Registers for notification of deleted authorizations for the given
function.
|
void |
registerForDeletedAuthorizationsForResource(Id resourceId)
Registers for notification of deleted authorizations for the given
resource including any authorizations related to the resource through
an agent.
|
void |
registerForNewAuthorizations()
Register for notifications of new authorizations.
|
void |
registerForNewAuthorizationsForFunction(Id functionId)
Register for notifications of new authorizations for the given
function.
|
void |
registerForNewAuthorizationsForResource(Id resourceId)
Registers for notification of new authorizations for the given
resource including any authorizations related to the resource through
an agent.
|
void |
reliableAuthorizationNotifications()
Reliable notifications are desired.
|
void |
unreliableAuthorizationNotifications()
Unreliable notifications are desired.
|
void |
useExplicitAuthorizationView()
Sets the view for methods in this session to explicit authorizations.
|
void |
useFederatedVaultView()
Federates the view for methods in this session.
|
void |
useImplicitAuthorizationView()
Sets the view for methods in this session to implicit authorizations.
|
void |
useIsolatedVaultView()
Isolates the view for methods in this session.
|
getAuthenticatedAgent, getAuthenticatedAgentId, getClockRate, getDate, getEffectiveAgent, getEffectiveAgentId, getFormatType, getLocale, isAuthenticated, startTransaction, supportsTransactions
close
Id getVaultId()
Vault
Id
associated with this
session. Vault Id
associated with this sessionmandatory
- This method must be implemented. Vault getVault() throws OperationFailedException, PermissionDeniedException
Vault
associated with this session. Vault
associated with this sessionOperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. boolean canRegisterForAuthorizationNotifications()
Authorization
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 useFederatedVaultView()
mandatory
- This method is must be implemented. void useIsolatedVaultView()
mandatory
- This method is must be implemented. void reliableAuthorizationNotifications()
acknowledgeAuthorizationNotification()
.mandatory
- This method is must be implemented. void unreliableAuthorizationNotifications()
mandatory
- This method is must be implemented. void acknowledgeAuthorizationNotification(Id notificationId) throws OperationFailedException, PermissionDeniedException
notificationId
- the Id
of the notificationOperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void useImplicitAuthorizationView()
Qualifier,
Function
or Resource
hierarchies. This method
is the opposite of explicitAuthorizationView().
mandatory
- This method is must be implemented. void useExplicitAuthorizationView()
implicitAuthorizationView().
mandatory
- This method is must be implemented. void registerForNewAuthorizations() throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.newAuthorizations()
is invoked when a
new Authorization
appears in this vault.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewAuthorizationsForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.newAuthorizations()
is
invoked when an authorization appears in this vault.resourceId
- the Id
of the Resource
to monitorNullArgumentException
- resourceId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForNewAuthorizationsForFunction(Id functionId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.newAuthorizations()
is
invoked when a new Authorization
appears in this vault.functionId
- the Id
of the Function
to monitorNullArgumentException
- functionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedAuthorizations() throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.changedAuthorizations()
is invoked when
an authorization in this vault is changed.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedAuthorizationsForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.changedAuthorizations()
is invoked when an authorization in this vault is changed.resourceId
- the Id
of the Resource
to monitorNullArgumentException
- resourceId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedAuthorizationsForFunction(Id functionId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.changedAuthorizations()
is invoked when an authorization in this vault is changed.functionId
- the Id
of the Function
to monitorNullArgumentException
- functionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForChangedAuthorization(Id authorizationId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.changedAuthorizations()
is invoked when
the specified authorization in this vault is changed.authorizationId
- the Id
of the
Authorization
to monitorNullArgumentException
- authorizationId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedAuthorizations() throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.deletedAuthorizations()
is invoked when
an authorization is removed from this vault.OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedAuthorizationsForResource(Id resourceId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.deletedAuthorizations()
is invoked when an authorization is removed from this vault.resourceId
- the Id
of the Resource
to monitorNullArgumentException
- resourceId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedAuthorizationsForFunction(Id functionId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.deletedAuthorizations()
is invoked when an authorization is removed from this vault.functionId
- the Id
of the Function
to monitorNullArgumentException
- functionId
is
null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented. void registerForDeletedAuthorization(Id authorizationId) throws OperationFailedException, PermissionDeniedException
AuthorizationReceiver.deletedAuthorizations()
is invoked when
the specified authorization is removed from this vault.authorizationId
- the Id
of the
Authorization
to monitorNullArgumentException
- authorizationId
is null
OperationFailedException
- unable to complete requestPermissionDeniedException
- authorization failuremandatory
- This method must be implemented.