HttpCookiesSectionとは何? わかりやすく解説 Weblio辞書 (original) (raw)
HttpCookiesSection クラス
メモ : このクラスは、.NET Framework version 2.0 で新しく追加されたものです。
Web アプリケーションによって使用される Cookie のプロパティを構成します。
名前空間: System.Web.Configuration
アセンブリ: System.Web (system.web.dll 内)
構文
Public NotInheritable Class HttpCookiesSection Inherits ConfigurationSection
既存の Web アプリケーションの構成ファイルから HttpCookiesSection オブジェクトを取得する方法を次のコード例に示します。
' Get the Web application configuration. Dim webConfig _ As System.Configuration.Configuration = _ WebConfigurationManager.OpenWebConfiguration("/aspnetTest")
' Get the section. Dim configPath As String _ = "system.web/httpCookies"
Dim httpCookiesSection _ As System.Web.Configuration.HttpCookiesSection = _ CType(webConfig.GetSection(configPath), _ System.Web.Configuration.HttpCookiesSection)
// Get the Web application configuration. System.Configuration.Configuration webConfig = WebConfigurationManager.OpenWebConfiguration("/aspnetTest");
// Get the section. string configPath = "system.web/httpCookies"; System.Web.Configuration.HttpCookiesSection httpCookiesSection = (System.Web.Configuration.HttpCookiesSection)webConfig.GetSection( configPath);
System.Object
System.Configuration.ConfigurationElement
System.Configuration.ConfigurationSection
System.Web.Configuration.HttpCookiesSection