다음을 통해 공유


RoleManagerSection.CookieName 속성

정의

역할 이름을 캐시하는 데 사용되는 쿠키의 이름을 가져오거나 설정합니다.

public:
 property System::String ^ CookieName { System::String ^ get(); void set(System::String ^ value); };
[System.ComponentModel.TypeConverter(typeof(System.Configuration.WhiteSpaceTrimStringConverter))]
[System.Configuration.ConfigurationProperty("cookieName", DefaultValue=".ASPXROLES")]
[System.Configuration.StringValidator(MinLength=1)]
public string CookieName { get; set; }
[<System.ComponentModel.TypeConverter(typeof(System.Configuration.WhiteSpaceTrimStringConverter))>]
[<System.Configuration.ConfigurationProperty("cookieName", DefaultValue=".ASPXROLES")>]
[<System.Configuration.StringValidator(MinLength=1)>]
member this.CookieName : string with get, set
Public Property CookieName As String

속성 값

역할 이름을 캐시하는 데 사용되는 쿠키의 이름입니다. 기본값은 "입니다. ASPXROLES".

특성

예제

다음 코드 예제에서는 속성을 사용 하는 방법을 보여 줍니다 CookieName . 이 코드 예제는 클래스에 제공된 더 큰 예제의 RoleManagerSection 일부입니다.

// Display CookieName property.
Console.WriteLine("CookieName: {0}", configSection.CookieName);
' Display CookieName property.
Console.WriteLine("CookieName: {0}", configSection.CookieName)

설명

이 속성은 CookieName 역할 이름을 캐시하는 데 사용되는 쿠키의 이름을 반환합니다. ASP.NET 애플리케이션에 대한 Web.config 파일의 특성을 설정 cookieName 하여 애플리케이션에 대한 역할이 캐시되는 쿠키의 이름을 지정할 수 있습니다. 이는 애플리케이션의 쿠키를 고유하게 식별하려는 경우 또는 쿠키가 여러 애플리케이션에서 공유되는 경우에 유용합니다.

적용 대상