IsAuthorized(String,IdentityType,IAuthorizationClass,Int64) Method
See Also 
SourceCode.Authorization.Client Namespace > AuthorizationClient Class > IsAuthorized Method : IsAuthorized(String,IdentityType,IAuthorizationClass,Int64) Method



identityName
The name of the identity.
identityType
classInstance
The authorization class instance.
rights
The rights to check for authorization.

Glossary Item Box

Checks if the identity is authorized to perform a set of actions (as a rights mask) on a class.

Syntax

Visual Basic (Declaration) 
Public Overloads Function IsAuthorized( _
   ByVal identityName As String, _
   ByVal identityType As SourceCode.Authorization.Interfaces.IdentityType, _
   ByVal classInstance As SourceCode.Authorization.Interfaces.IAuthorizationClass, _
   ByVal rights As Long _
) As Boolean
Visual Basic (Usage)Copy Code
Dim instance As AuthorizationClient
Dim identityName As String
Dim identityType As SourceCode.Authorization.Interfaces.IdentityType
Dim classInstance As SourceCode.Authorization.Interfaces.IAuthorizationClass
Dim rights As Long
Dim value As Boolean
 
value = instance.IsAuthorized(identityName, identityType, classInstance, rights)
C# 
public bool IsAuthorized( 
   string identityName,
   SourceCode.Authorization.Interfaces.IdentityType identityType,
   SourceCode.Authorization.Interfaces.IAuthorizationClass classInstance,
   long rights
)
C++/CLI 
public:
bool IsAuthorized( 
   String^ identityName,
   SourceCode.Authorization.Interfaces.IdentityType identityType,
   SourceCode.Authorization.Interfaces.IAuthorizationClass^ classInstance,
   int64 rights
) 

Parameters

identityName
The name of the identity.
identityType
classInstance
The authorization class instance.
rights
The rights to check for authorization.

Return Value

true if the identity is authorized for the specified rights on the class; otherwise false.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also