ReflectionPermissionAttribute クラス

定義

注意事項

Code Access Security is not supported or honored by the runtime.

ReflectionPermission のセキュリティ アクションを、宣言セキュリティを使用してコードに適用できるようにします。

public ref class ReflectionPermissionAttribute sealed : System::Security::Permissions::CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
public sealed class ReflectionPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")]
public sealed class ReflectionPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Serializable]
public sealed class ReflectionPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)]
[System.Serializable]
[System.Runtime.InteropServices.ComVisible(true)]
public sealed class ReflectionPermissionAttribute : System.Security.Permissions.CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
type ReflectionPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Obsolete("Code Access Security is not supported or honored by the runtime.", DiagnosticId="SYSLIB0003", UrlFormat="https://aka.ms/dotnet-warnings/{0}")>]
type ReflectionPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Serializable>]
type ReflectionPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
[<System.AttributeUsage(System.AttributeTargets.Assembly | System.AttributeTargets.Class | System.AttributeTargets.Constructor | System.AttributeTargets.Method | System.AttributeTargets.Struct, AllowMultiple=true, Inherited=false)>]
[<System.Serializable>]
[<System.Runtime.InteropServices.ComVisible(true)>]
type ReflectionPermissionAttribute = class
    inherit CodeAccessSecurityAttribute
Public NotInheritable Class ReflectionPermissionAttribute
Inherits CodeAccessSecurityAttribute
継承
属性

注釈

注意事項

コード アクセス セキュリティ (CAS) は、.NET Framework と .NET のすべてのバージョンで非推奨になりました。 最近のバージョンの .NET では、CAS 関連の API が使われている場合、CAS の注釈は使われず、エラーが発生します。 開発者は、代わりの手段を見つけてセキュリティ タスクを実現する必要があります。

許可される宣言のスコープは、使用される によって SecurityAction 異なります。

セキュリティ属性によって宣言されたセキュリティ情報は、属性ターゲットのメタデータに格納され、実行時にシステムによってアクセスされます。 セキュリティ属性は、宣言型セキュリティにのみ使用されます。 命令型セキュリティの場合は、対応するアクセス許可クラスを使用します。

コンストラクター

ReflectionPermissionAttribute(SecurityAction)
互換性のために残されています。

ReflectionPermissionAttribute を指定して、SecurityAction クラスの新しいインスタンスを初期化します。

プロパティ

Action
互換性のために残されています。

セキュリティ アクションを取得または設定します。

(継承元 SecurityAttribute)
Flags
互換性のために残されています。

現在使用できるリフレクションを取得または設定します。

MemberAccess
互換性のために残されています。

非パブリック メンバーに対して操作を呼び出すことができるかどうかを示す値を取得または設定します。

ReflectionEmit
互換性のために残されています。
互換性のために残されています。
互換性のために残されています。

System.Reflection.Emit の特定の機能 (デバッグ記号の出力など) を使用できるかどうかを示す値を取得または設定します。

RestrictedMemberAccess
互換性のために残されています。

非パブリック メンバーの制限付き呼び出しが可能かどうかを示す値を取得または設定します。 制限付き呼び出しでは、呼び出される非パブリック メンバーを格納しているアセンブリの許可セットが、呼び出し元アセンブリの許可セットと同じか、またはそのサブセットであることが必要です。

TypeId
互換性のために残されています。

派生クラスで実装されると、この Attribute の一意の識別子を取得します。

(継承元 Attribute)
TypeInformation
互換性のために残されています。
互換性のために残されています。
互換性のために残されています。
互換性のために残されています。

表示されていないメンバーに対してリフレクションを使用できるかどうかを示す値を取得または設定します。

Unrestricted
互換性のために残されています。

属性によって保護されているリソースに対して完全な (無制限の) アクセス許可が宣言されているかどうかを示す値を取得または設定します。

(継承元 SecurityAttribute)

メソッド

CreatePermission()
互換性のために残されています。

新しい ReflectionPermission を作成して返します。

Equals(Object)
互換性のために残されています。

このインスタンスが、指定されたオブジェクトと等価であるかどうかを示す値を返します。

(継承元 Attribute)
GetHashCode()
互換性のために残されています。

このインスタンスのハッシュ コードを返します。

(継承元 Attribute)
GetType()
互換性のために残されています。

現在のインスタンスの Type を取得します。

(継承元 Object)
IsDefaultAttribute()
互換性のために残されています。

派生クラスでオーバーライドされるとき、このインスタンスの値が派生クラスの既定値であるかどうかを示します。

(継承元 Attribute)
Match(Object)
互換性のために残されています。

派生クラス内でオーバーライドされたときに、指定したオブジェクトとこのインスタンスが等しいかどうかを示す値を返します。

(継承元 Attribute)
MemberwiseClone()
互換性のために残されています。

現在の Object の簡易コピーを作成します。

(継承元 Object)
ToString()
互換性のために残されています。

現在のオブジェクトを表す文字列を返します。

(継承元 Object)

明示的なインターフェイスの実装

_Attribute.GetIDsOfNames(Guid, IntPtr, UInt32, UInt32, IntPtr)
互換性のために残されています。

一連の名前を対応する一連のディスパッチ識別子に割り当てます。

(継承元 Attribute)
_Attribute.GetTypeInfo(UInt32, UInt32, IntPtr)
互換性のために残されています。

オブジェクトの型情報を取得します。この情報はインターフェイスの型情報の取得に使用できます。

(継承元 Attribute)
_Attribute.GetTypeInfoCount(UInt32)
互換性のために残されています。

オブジェクトが提供する型情報インターフェイスの数 (0 または 1) を取得します。

(継承元 Attribute)
_Attribute.Invoke(UInt32, Guid, UInt32, Int16, IntPtr, IntPtr, IntPtr, IntPtr)
互換性のために残されています。

オブジェクトによって公開されたプロパティおよびメソッドへのアクセスを提供します。

(継承元 Attribute)

適用対象

こちらもご覧ください