Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
This will be called every time that a permission decision is being made and allows the implementor to override the preliminary decision. Note, if a PermissionEvaluationCallback is provided to the function, it will override this decision.
Namespace: Microsoft.TeamFoundation.Framework.Server
Assembly: Microsoft.TeamFoundation.Framework.Server (in Microsoft.TeamFoundation.Framework.Server.dll)
Syntax
'Declaration
Function HasPermission ( _
requestContext As TeamFoundationRequestContext, _
token As String, _
requestedPermissions As Integer, _
effectiveAllows As Integer, _
effectiveDenys As Integer, _
preliminaryDecision As Boolean _
) As Boolean
bool HasPermission(
TeamFoundationRequestContext requestContext,
string token,
int requestedPermissions,
int effectiveAllows,
int effectiveDenys,
bool preliminaryDecision
)
bool HasPermission(
TeamFoundationRequestContext^ requestContext,
String^ token,
int requestedPermissions,
int effectiveAllows,
int effectiveDenys,
bool preliminaryDecision
)
abstract HasPermission :
requestContext:TeamFoundationRequestContext *
token:string *
requestedPermissions:int *
effectiveAllows:int *
effectiveDenys:int *
preliminaryDecision:bool -> bool
function HasPermission(
requestContext : TeamFoundationRequestContext,
token : String,
requestedPermissions : int,
effectiveAllows : int,
effectiveDenys : int,
preliminaryDecision : boolean
) : boolean
Parameters
requestContext
Type: Microsoft.TeamFoundation.Framework.Server.TeamFoundationRequestContextThe request context we are evaluating permissions for.
token
Type: System.StringThe token the permissions are currently being evaluated on.
requestedPermissions
Type: System.Int32The permissions being requested.
effectiveAllows
Type: System.Int32The granted permissions the securityNamespace evaluated for this user on this token.
effectiveDenys
Type: System.Int32The permissions that were explicitly denied to the user due to a setting on the current token, a parent token or because of group membership.
preliminaryDecision
Type: System.BooleanThe answer we would provide if the callback were not used.
Return Value
Type: System.Boolean
True if the user should have the permission, false otherwise.
This value will always trump the premilinaryDecision.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.