Assembly: mscorlib (in mscorlib.dll)
Obsolete.TypeInformation, MemberAccess, and ReflectionEmit are set.does not include .
Invocation operations on all members are allowed, regardless of grant set. If this flag is not set, invocation operations are allowed only on visible members.
Enumeration of types and members is allowed. Invocation operations are allowed on visible types and members.
Obsolete.Emitting debug symbols is allowed. Beginning with the .NET Framework 2.0 Service Pack 1, this flag is no longer required to emit code.
Restricted member access is provided for partially trusted code. Partially trusted code can access nonpublic types and members, but only if the grant set of the partially trusted code includes all permissions in the grant set of the assembly that contains the nonpublic types and members being accessed. This flag is new in the .NET Framework 2.0 SP1.
Obsolete.This flag is obsolete. No flags are necessary to enumerate types and members and to examine their metadata. Useinstead.
This enumeration is used by the ReflectionPermission and ReflectionPermissionAttribute classes. If no ReflectionPermission is granted, reflection is allowed on all types and members, but invocation operations are allowed only on visible types and members. For more information, see Security Considerations for Reflection.
Theflag is introduced in the .NET Framework 2.0 SP1. To use this flag, your application should target the .NET Framework 3.5 or later.
does not include the flag. To get a mask that includes all flags in this enumeration, you must use the combination of with .
Starting with the .NET Framework 2.0 SP1, theflag is no longer required to emit code, unless debug symbols are emitted. To use this feature, your application should target the .NET Framework 3.5 or later.
Starting with the .NET Framework 2.0, theflag is no longer required to reflect on nonpublic types and members; the flag has been marked obsolete.
The following example shows how to use the ReflectionPermission class that represents the right to perform restricted member access. This example is part of a larger example that is provided for the ReflectionPermission class.enumeration to initialize a new instance of the
For an example that shows how to use the Walkthrough: Emitting Code in Partial Trust Scenarios.flag with Internet code, see
Available since 1.1