AnonymousIdentificationEventArgsとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > AnonymousIdentificationEventArgsの意味・解説 

AnonymousIdentificationEventArgs クラス

メモ : このクラスは、.NET Framework version 2.0 で新しく追加されたものです。

AnonymousIdentification_Creating イベントのデータを提供します。このクラスは継承できません。

名前空間: System.Web.Security
アセンブリ: System.Web (system.web.dll 内)
構文構文

Public NotInheritable Class
 AnonymousIdentificationEventArgs
    Inherits EventArgs
Dim instance As AnonymousIdentificationEventArgs
public sealed class AnonymousIdentificationEventArgs
 : EventArgs
public ref class AnonymousIdentificationEventArgs
 sealed : public EventArgs
public final class AnonymousIdentificationEventArgs
 extends EventArgs
public final class AnonymousIdentificationEventArgs
 extends EventArgs
解説解説

AnonymousIdentificationEventArgs クラスは Creating イベントにイベント値を指定し、現在の要求に対するカスタムの Windows ID を指定できるようにするために使用されます。AnonymousIdentificationModule クラスの Creating イベントには、ASP.NET アプリケーションの Global.asax ファイルに、AnonymousIdentification_Creating というサブルーチンを指定することによってアクセスできます。

AnonymousIdentificationModule は、現在の HttpContext を使用して AnonymousIdentificationEventArgs オブジェクトを生成し、それを AnonymousIdentification_Creating イベントに渡します。

AnonymousIdentification_Creating イベントに渡した AnonymousIdentificationEventArgs オブジェクトの AnonymousId プロパティを使用して、匿名 ID をカスタム値に設定できます。AnonymousIdentification_Creating イベント時に AnonymousId プロパティに値を設定しなかった場合は、Guid が使用されます。

AnonymousIdentification_Creating イベントは、匿名 ID が Enabled の場合にだけ発生します。

使用例使用例

AnonymousIdentification_Creating イベントを使用して、匿名 ID をカスタム値に設定するコード例を次に示します。

Public Sub AnonymousIdentification_Creating(sender
 As Object,  _
                                            args As AnonymousIdentificationEventArgs)
  args.AnonymousID = Samples.AspNet.Security.MyIdClass.GetAnonymousId()
  Samples.AspNet.Security.MyIdClass.LogAnonymousId(args.AnonymousId)
End Sub
public void AnonymousIdentification_Creating(object
 sender, 
                                             AnonymousIdentificationEventArgs args)
{
  args.AnonymousID = Samples.AspNet.Security.MyIdClass.GetAnonymousId();
  Samples.AspNet.Security.MyIdClass.LogAnonymousId(args.AnonymousID);
}
.NET Framework のセキュリティ.NET Framework のセキュリティ
継承階層継承階層
System.Object
   System.EventArgs
    System.Web.Security.AnonymousIdentificationEventArgs
スレッド セーフスレッド セーフ
この型の public static (Visual Basic では Shared) メンバはすべて、スレッド セーフです。インスタンス メンバの場合は、スレッド セーフであるとは限りません。
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
AnonymousIdentificationEventArgs メンバ
System.Web.Security 名前空間
その他の技術情報
anonymousIdentification 要素 (ASP.NET 設定スキーマ)
Global.asax 構文

AnonymousIdentificationEventArgs コンストラクタ

メモ : このコンストラクタは、.NET Framework version 2.0 で新しく追加されたものです。

AnonymousIdentificationEventArgs クラスの新しいインスタンスを初期化します。

名前空間: System.Web.Security
アセンブリ: System.Web (system.web.dll 内)
構文構文

Public Sub New ( _
    context As HttpContext _
)
Dim context As HttpContext

Dim instance As New AnonymousIdentificationEventArgs(context)
public AnonymousIdentificationEventArgs (
    HttpContext context
)
public:
AnonymousIdentificationEventArgs (
    HttpContext^ context
)
public AnonymousIdentificationEventArgs (
    HttpContext context
)
public function AnonymousIdentificationEventArgs
 (
    context : HttpContext
)

パラメータ

context

イベントのコンテキスト。

解説解説

AnonymousIdentificationModule は、現在の HttpContext を使用して AnonymousIdentificationEventArgs オブジェクトを構築します。そして、AnonymousIdentificationEventArgs オブジェクトを AnonymousIdentification_Creating イベントに渡します。

プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
AnonymousIdentificationEventArgs クラス
AnonymousIdentificationEventArgs メンバ
System.Web.Security 名前空間
その他の技術情報
anonymousIdentification 要素 (ASP.NET 設定スキーマ)

AnonymousIdentificationEventArgs プロパティ


パブリック プロパティパブリック プロパティ

  名前 説明
パブリック プロパティ AnonymousID  
パブリック プロパティ Context 現在の HTTP 要求に対する HttpContext オブジェクトを取得します。
参照参照

関連項目

AnonymousIdentificationEventArgs クラス
System.Web.Security 名前空間

その他の技術情報

anonymousIdentification 要素 (ASP.NET 設定スキーマ)
Global.asax 構文

AnonymousIdentificationEventArgs メソッド


AnonymousIdentificationEventArgs メンバ

AnonymousIdentification_Creating イベントのデータを提供します。このクラスは継承できません。

AnonymousIdentificationEventArgs データ型で公開されるメンバを以下の表に示します。


パブリック コンストラクタパブリック コンストラクタ
  名前 説明
パブリック メソッド AnonymousIdentificationEventArgs AnonymousIdentificationEventArgs クラスの新しいインスタンスを初期化します。
パブリック プロパティパブリック プロパティ
  名前 説明
パブリック プロパティ AnonymousID  
パブリック プロパティ Context 現在の HTTP 要求に対する HttpContext オブジェクトを取得します。
パブリック メソッドパブリック メソッド
プロテクト メソッドプロテクト メソッド
参照参照

関連項目

AnonymousIdentificationEventArgs クラス
System.Web.Security 名前空間

その他の技術情報

anonymousIdentification 要素 (ASP.NET 設定スキーマ)
Global.asax 構文



英和和英テキスト翻訳

英語⇒日本語日本語⇒英語

辞書ショートカット

すべての辞書の索引

「AnonymousIdentificationEventArgs」の関連用語

AnonymousIdentificationEventArgsのお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



AnonymousIdentificationEventArgsのページの著作権

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2026 Microsoft.All rights reserved.

©2026 GRAS Group, Inc.RSS