C# Класс Test.CustomerExample.BO.AuthorisationStub

This class is a very simple stub implementation of IBusinessObjectAuthorisation. It is not intended to represent how a read authorisation policy would be implemented by is instead used only for testing.
Наследование: IBusinessObjectAuthorisation
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AddAuthorisedRole ( string role, BusinessObjectActions actionToPerform ) : void

This is a public method to be used for setting up tests.

IsAuthorised ( BusinessObjectActions actionToPerform ) : bool

Whether the user is authorised to perform this action or not. This is an implementation of the IBusinessObjectAuthorisation method.

Описание методов

AddAuthorisedRole() публичный Метод

This is a public method to be used for setting up tests.
public AddAuthorisedRole ( string role, BusinessObjectActions actionToPerform ) : void
role string the role that the user must be a member of
actionToPerform BusinessObjectActions The action that can be performed by a user of this role
Результат void

IsAuthorised() публичный Метод

Whether the user is authorised to perform this action or not. This is an implementation of the IBusinessObjectAuthorisation method.
public IsAuthorised ( BusinessObjectActions actionToPerform ) : bool
actionToPerform BusinessObjectActions
Результат bool