C# Programming :: Attributes
-
Which of the following CANNOT be a target for a custom attribute?
-
Once applied which of the following CANNOT inspect the applied attribute?
-
Which of the following is the correct way to apply an attribute to an Assembly?
-
Which of the following is the correct way of applying the custom attribute called Tested which receives two-arguments - name of the tester and the testgrade?
- Custom attribute cannot be applied to an assembly.
- [assembly: Tested("Sachin", testgrade.Good)]
- [Tested("Virat", testgrade.Excellent)]
class customer { /* .... */ } - Custom attribute cannot be applied to a method.
- Custom attribute cannot be applied to a class.
-
Attributes can be applied to
- Method
- Class
- Assembly
- Namespace
- Enum
A.
[ AssemblyDescription("DCube Component Library") ]
|
B.
[ assembly : AssemblyDescription("DCube Component Library") ]
|
C.
[ Assemblylnfo : AssemblyDescription("DCube Component Library") ]
|
D.
< Assembly: AssemblyDescription("DCube Component Library") >
|
E.
(Assembly: AssemblyDescription("DCube Component Library"))
|