MulticastAttributes Enumeration |
Attributes of elements to which multicast custom attributes (MulticastAttribute)
apply.
Namespace: PostSharp.Extensibility
Assembly: PostSharp (in PostSharp.dll) Version: 4.3.48.0 (4.3.48.0)
C#
[FlagsAttribute] public enum MulticastAttributes
Member name | Value | Description | |
---|---|---|---|
Default | 0 | Specifies that the set of target attributes is inherited from the parent custom attribute. | |
Private | 2 | Private (visible inside the current type). | |
Protected | 4 | Protected (visible inside derived types). | |
Internal | 8 | Internal (visible inside the current assembly). | |
InternalAndProtected | 16 | Internal and protected (visible inside derived types that are defined in the current assembly). | |
InternalOrProtected | 32 | Internal or protected (visible inside all derived types and in the current assembly). | |
Public | 64 | Public (visible everywhere). | |
AnyVisibility | 126 | Any visibility. | |
Static | 128 | Static scope. | |
Instance | 256 | Instance scope. | |
AnyScope | 384 | Any scope (Static | Instance). | |
Abstract | 512 | Abstract methods. | |
NonAbstract | 1024 | Concrete (non-abstract) methods. | |
AnyAbstraction | 1536 | Any abstraction (Abstract | NonAbstract). | |
Virtual | 2048 | Virtual methods. | |
NonVirtual | 4096 | Non-virtual methods. | |
AnyVirtuality | 6144 | Any virtuality (Virtual | NonVirtual). | |
Managed | 8192 | Managed code implementation. | |
NonManaged | 16384 | Non-managed code implementation (external or system). | |
AnyImplementation | 24576 | Any implementation (Managed | NonManaged). | |
Literal | 32768 | Literal fields. | |
NonLiteral | 65536 | Non-literal fields. | |
AnyLiterality | 98304 | Any field literality (Literal | NonLiteral). | |
InParameter | 131072 | Input parameters. | |
CompilerGenerated | 262144 | Compiler-generated code (for instance closure types of anonymous method, iterator type, ...). | |
UserGenerated | 524288 | User-generated code (anything expected CompilerGenerated). | |
AnyGeneration | 786432 | Any code generation (CompilerGenerated | UserGenerated)l | |
OutParameter | 1048576 | Output (out in C#) parameters. | |
RefParameter | 2097152 | Input/Output (ref in C#) parameters. | |
AnyParameter | 3276800 | Any kind of parameter passing (InParameter | OutParameter | RefParameter). | |
All | 4194302 | All members. |
When specifying attributes of target members or types, do not forget to provide
all categories of flags, not only the category on which you want to put
a restriction. If you want to limit, for instance, a custom attribute to be
applied on public members, a good practice is to set
TargetMemberAttributes = MulticastAttributes.Public | ~MulticastAttributes.AnyVisibility,
unless the parent is more restrictive, in which case you should specify attributes
explicitly.