Show / Hide Table of Contents

Class PermissionFilter

Custom Filter to restrict access to an endpoint based on user permissions.

Inheritance
System.Object
PermissionFilter
Namespace: Celerik.NetCore.Web
Assembly: cs.temp.dll.dll
Syntax
public class PermissionFilter : IAuthorizationFilter

Constructors

PermissionFilter(String[])

Initializes a new instance of the class.

Declaration
public PermissionFilter(string[] permissions)
Parameters
Type Name Description
System.String[] permissions

List of permissions that grant access to the endpoint.

Methods

OnAuthorization(AuthorizationFilterContext)

Called early in the filter pipeline to confirm request is authorized.

Declaration
public void OnAuthorization(AuthorizationFilterContext context)
Parameters
Type Name Description
AuthorizationFilterContext context

The Microsoft.AspNetCore.Mvc.Filters.AuthorizationFilterContext.

ToString()

Returns a string that represents the current object.

Declaration
public override string ToString()
Returns
Type Description
System.String

A string that represents the current object.

In This Article
Back to top Generated by DocFX