C# 클래스 Geta.Security.ActiveDirectoryRoleProvider

ASP.NET 2.0 Role provider for Microsofts Active Directory.
This role provider is designed to work together with the default Systwm.Web.Security.ActiveDirectoryMembershipProvider, although there are no hard dependencies.
상속: System.Web.Security.RoleProvider
파일 보기 프로젝트 열기: Geta/ActiveDirectoryRoleProvider

공개 메소드들

메소드 설명
AddUsersToRoles ( string usernames, string roleNames ) : void

Adds the specified user names to the specified roles for the configured applicationName.

This method is not supported in this provider.

CreateRole ( string roleName ) : void

Adds a new role to the data source for the configured applicationName.

This method is not supported in this provider.

DeleteRole ( string roleName, bool throwOnPopulatedRole ) : bool

Removes a role from the data source for the configured applicationName.

This method is not supported in this provider.

FindUsersInRole ( string roleName, string usernameToMatch ) : string[]

Gets an array of user names in a role where the user name contains the specified user name to match.

GetAllRoles ( ) : string[]

Gets a list of all the roles for the configured applicationName.

GetRolesForUser ( string username ) : string[]

Gets a list of the roles that a specified user is in for the configured applicationName.

GetUsersInRole ( string roleName ) : string[]

Gets a list of users in the specified role for the configured applicationName.

Initialize ( string name, NameValueCollection config ) : void

Initializes the provider.

IsUserInRole ( string userName, string roleName ) : bool

Gets a value indicating whether the specified user is in the specified role for the configured applicationName.

RemoveUsersFromRoles ( string usernames, string roleNames ) : void

Removes the specified user names from the specified roles for the configured applicationName.

This method is not supported in this provider.

RoleExists ( string roleName ) : bool

Gets a value indicating whether the specified role name already exists in the role data source for the configured applicationName.

보호된 메소드들

메소드 설명
NormalizeUserName ( string userName ) : string

비공개 메소드들

메소드 설명
GetRole ( string roleName ) : DirectoryData
GetRolesForUserRecursive ( DirectoryData entry ) : List
GetUser ( string userName ) : DirectoryData
IsUserInRoleRecursive ( string distinguishedUserName, DirectoryData roleEntry ) : bool
TryGetDestructive ( NameValueCollection config, string name, string &value ) : bool

메소드 상세

AddUsersToRoles() 공개 메소드

Adds the specified user names to the specified roles for the configured applicationName.
This method is not supported in this provider.
public AddUsersToRoles ( string usernames, string roleNames ) : void
usernames string A string array of user names to be added to the specified roles.
roleNames string A string array of the role names to add the specified user names to.
리턴 void

CreateRole() 공개 메소드

Adds a new role to the data source for the configured applicationName.
This method is not supported in this provider.
public CreateRole ( string roleName ) : void
roleName string The name of the role to create.
리턴 void

DeleteRole() 공개 메소드

Removes a role from the data source for the configured applicationName.
This method is not supported in this provider.
public DeleteRole ( string roleName, bool throwOnPopulatedRole ) : bool
roleName string The name of the role to delete.
throwOnPopulatedRole bool If true, throw an exception if roleName has one or more members and do not delete roleName.
리턴 bool

FindUsersInRole() 공개 메소드

Gets an array of user names in a role where the user name contains the specified user name to match.
public FindUsersInRole ( string roleName, string usernameToMatch ) : string[]
roleName string The role to search in.
usernameToMatch string The user name to search for.
리턴 string[]

GetAllRoles() 공개 메소드

Gets a list of all the roles for the configured applicationName.
public GetAllRoles ( ) : string[]
리턴 string[]

GetRolesForUser() 공개 메소드

Gets a list of the roles that a specified user is in for the configured applicationName.
public GetRolesForUser ( string username ) : string[]
username string The user to return a list of roles for.
리턴 string[]

GetUsersInRole() 공개 메소드

Gets a list of users in the specified role for the configured applicationName.
public GetUsersInRole ( string roleName ) : string[]
roleName string The name of the role to get the list of users for.
리턴 string[]

Initialize() 공개 메소드

Initializes the provider.
The name of the provider is null. An attempt is made to call /// /// on a provider after the provider has already been initialized. The name of the provider has a length of zero.
public Initialize ( string name, NameValueCollection config ) : void
name string The friendly name of the provider.
config System.Collections.Specialized.NameValueCollection A collection of the name/value pairs representing the provider-specific attributes specified in the configuration for this provider.
리턴 void

IsUserInRole() 공개 메소드

Gets a value indicating whether the specified user is in the specified role for the configured applicationName.
public IsUserInRole ( string userName, string roleName ) : bool
userName string
roleName string The role to search in.
리턴 bool

NormalizeUserName() 보호된 메소드

protected NormalizeUserName ( string userName ) : string
userName string
리턴 string

RemoveUsersFromRoles() 공개 메소드

Removes the specified user names from the specified roles for the configured applicationName.
This method is not supported in this provider.
public RemoveUsersFromRoles ( string usernames, string roleNames ) : void
usernames string A string array of user names to be removed from the specified roles.
roleNames string A string array of role names to remove the specified user names from.
리턴 void

RoleExists() 공개 메소드

Gets a value indicating whether the specified role name already exists in the role data source for the configured applicationName.
public RoleExists ( string roleName ) : bool
roleName string The name of the role to search for in the data source.
리턴 bool