VGAuthorizationStatus Enumeration
|
Defines all the authorization status
Namespace:
Novalys.VisualGuard.Security
Assembly:
Novalys.VisualGuard.Security (in Novalys.VisualGuard.Security.dll) Version: 2019.1.831.19 (2019.1.0831.19)
Syntax [FlagsAttribute]
public enum VGAuthorizationStatus
<FlagsAttribute>
Public Enumeration VGAuthorizationStatus
Members
| Member name | Value | Description |
---|
| Failure | 1 |
The authorization fails.
|
| UserNotFound | 2 |
The authorization fails. The user is not found in the repository
|
| UserNotAuthorized | 4 |
The authorization fails. The user does not have any granted role for the application.
|
| ProcessCanceled | 8 |
The authorization fails. The authorization process has been canceled by the user.
|
| Success | 16 |
The authorization succeeds.
|
| VersionNotCompatible | 32 |
The version of the permissions is not compatible with the application.
|
| GroupSelectionInvalid | 64 |
The group selection mode doesn't match or not exists.
|
| RoleSelectionInvalid | 128 |
The role selection mode doesn't match or not exists.
|
| InProgress | 256 |
Is in Progress if GroupSelection or RoleSelection is Invalid.
|
Remarks
Since Status can be a combination (bit-flag) of enum values, you can't use
the equality operator to compare them. To test if an authorization has failed, you must use this syntax:
if ((status & VGAuthorizationStatus.Failure) == VGAuthorizationStatus.Failure)
{
if ((status & VGAuthorizationStatus.UserNotFound) == VGAuthorizationStatus.UserNotFound)
{
}
}
if (status And VGAuthorizationStatus.Failure) = VGAuthorizationStatus.Failure Then
if (status And VGAuthorizationStatus.UserNotFound) = VGAuthorizationStatus.UserNotFound Then
End If
End If
See Also