Click or drag to resize

IDatabaseRepositoryCheckAuthorization Method (AuthorizedItemType, String, String, Int32)

Checks if the user has the required authorization for the item and otherwise throws an exception.

Namespace:  PDTec.IceNet.Core.Database
Assembly:  PDTec.IceNet.Core (in PDTec.IceNet.Core.dll) Version: 7.2.0.0 (7.2.7583.15464)
Syntax
C#
void CheckAuthorization(
	AuthorizedItemType itemType,
	string itemId,
	string userName,
	int authLevelRequired
)

Parameters

itemType
Type: PDTec.IceNet.Core.DatabaseAuthorizedItemType
Type of the item.
itemId
Type: SystemString
The item id.
userName
Type: SystemString
The user name.
authLevelRequired
Type: SystemInt32
The auth level required.
Exceptions
ExceptionCondition
AuthorizationExceptionThis is the base class of all exceptions thrown when the user does not have the required authorization level.
FolderAuthorizationExceptionThrown when the item is a folder and the user does not have the required authorization level.
ObjectAuthorizationExceptionThrown when the item is an object and the user does not have the required authorization level.
PackageAuthorizationExceptionThrown when the item is a package and the user does not have the required authorization level.
PartyAuthorizationExceptionThrown when the item is a party and the user does not have the required authorization level.
ProfileAuthorizationExceptionThrown when the item is a profile and the user does not have the required authorization level.
Remarks
This method recognizes authorization derived by group/role membership and from profile "System.All".
See Also