Export (0) Print
Expand All

Roles Members

Manages user membership in roles for authorization checking in an ASP.NET application. This class cannot be inherited.

The following tables list the members exposed by the Roles type.

  Name Description
Public property Static ApplicationName Gets or sets the name of the application to store and retrieve role information for.
Public property Static CacheRolesInCookie Gets a value indicating whether the current user's roles are cached in a cookie.
Public property Static CookieName Gets the name of the cookie where role names are cached.
Public property Static CookiePath Gets the path for the cached role names cookie.
Public property Static CookieProtectionValue Gets a value that indicates how role names cached in a cookie are protected.
Public property Static CookieRequireSSL Gets a value indicating whether the role names cookie requires SSL in order to be returned to the server.
Public property Static CookieSlidingExpiration Indicates whether the role names cookie expiration date and time will be reset periodically.
Public property Static CookieTimeout Gets the number of minutes before the roles cookie expires.
Public property Static CreatePersistentCookie Gets a value indicating whether the role-names cookie is session-based or persistent.
Public property Static Domain Gets the value of the domain of the role-names cookie.
Public property Static Enabled Gets or sets a value indicating whether role management is enabled for the current Web application.
Public property Static MaxCachedResults Gets the maximum number of role names to be cached for a user.
Public property Static Provider Gets the default role provider for the application.
Public property Static Providers Gets a collection of the role providers for the ASP.NET application.
Top

(see also Protected Methods )
  Name Description
Public method Static AddUsersToRole Adds the specified users to the specified role.
Public method Static AddUsersToRoles Adds the specified users to the specified roles.
Public method Static AddUserToRole Adds the specified user to the specified role.
Public method Static AddUserToRoles Adds the specified user to the specified roles.
Public method Static CreateRole Adds a new role to the data source.
Public method Static DeleteCookie Deletes the cookie where role names are cached.
Public method Static DeleteRole Overloaded. Removes a role from the data source.
Public method Equals  Overloaded. Determines whether two Object instances are equal. (inherited from Object)
Public method Static FindUsersInRole Gets a list of users in a specified role where the user name contains the specified user name to match.
Public method Static GetAllRoles Gets a list of all the roles for the application.
Public method GetHashCode  Serves as a hash function for a particular type. (inherited from Object)
Public method Static GetRolesForUser Overloaded. Gets a list of the roles that a user is in.
Public method GetType  Gets the Type of the current instance. (inherited from Object)
Public method Static GetUsersInRole Gets a list of users in the specified role.
Public method Static IsUserInRole Overloaded. Gets a value indicating whether a user is in the specified role.
Public method Static ReferenceEquals  Determines whether the specified Object instances are the same instance. (inherited from Object)
Public method Static RemoveUserFromRole Removes the specified user from the specified role.
Public method Static RemoveUserFromRoles Removes the specified user from the specified roles.
Public method Static RemoveUsersFromRole Removes the specified users from the specified role.
Public method Static RemoveUsersFromRoles Removes the specified user names from the specified roles.
Public method Static RoleExists Gets a value indicating whether the specified role name already exists in the role data source.
Public method ToString  Returns a String that represents the current Object. (inherited from Object)
Top

  Name Description
Protected method Finalize  Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (inherited from Object)
Protected method MemberwiseClone  Creates a shallow copy of the current Object. (inherited from Object)
Top

Community Additions

ADD
Show:
© 2014 Microsoft