Class PermissionsQueryStringHandler<T>
Abstract base class providing common functionality for authorization checks based on querystrings.
Inheritance
System.Object
Microsoft.AspNetCore.Authorization.AuthorizationHandler<T>
Namespace: Umbraco.Cms.Web.BackOffice.Authorization
Assembly: Umbraco.Web.BackOffice.dll
Syntax
public abstract class PermissionsQueryStringHandler<T> : MustSatisfyRequirementAuthorizationHandler<T>, IAuthorizationHandler where T : IAuthorizationRequirement
Type Parameters
Name | Description |
---|---|
T | Authorization requirement |
Constructors
View SourcePermissionsQueryStringHandler(IBackOfficeSecurityAccessor, IHttpContextAccessor, IEntityService)
Initializes a new instance of the PermissionsQueryStringHandler<T> class.
Declaration
public PermissionsQueryStringHandler(IBackOfficeSecurityAccessor backOfficeSecurityAccessor, IHttpContextAccessor httpContextAccessor, IEntityService entityService)
Parameters
Type | Name | Description |
---|---|---|
IBackOfficeSecurityAccessor | backOfficeSecurityAccessor | Accessor for back-office security. |
Microsoft.AspNetCore.Http.IHttpContextAccessor | httpContextAccessor | Accessor for the HTTP context of the current request. |
IEntityService | entityService | Service for entity operations. |
Properties
View SourceBackOfficeSecurityAccessor
Gets or sets the
Declaration
protected IBackOfficeSecurityAccessor BackOfficeSecurityAccessor { get; set; }
Property Value
Type | Description |
---|---|
IBackOfficeSecurityAccessor |
EntityService
Gets or sets the
Declaration
protected IEntityService EntityService { get; set; }
Property Value
Type | Description |
---|---|
IEntityService |
HttpContextAccessor
Gets or sets the Microsoft.AspNetCore.Http.IHttpContextAccessor instance.
Declaration
protected IHttpContextAccessor HttpContextAccessor { get; set; }
Property Value
Type | Description |
---|---|
Microsoft.AspNetCore.Http.IHttpContextAccessor |
Methods
View SourceTryParseNodeId(String, out Int32)
Attempts to parse a node ID from a string representation found in a querystring value.
Declaration
protected bool TryParseNodeId(string argument, out int nodeId)
Parameters
Type | Name | Description |
---|---|---|
System.String | argument | Querystring value. |
System.Int32 | nodeId | Output parsed Id. |
Returns
Type | Description |
---|---|
System.Boolean | True of node ID could be parased, false it not. |