// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
//
-using System;
-using System.Security;
-
namespace System.Security.Permissions {
- [System.AttributeUsage(
- System.AttributeTargets.Assembly
- | System.AttributeTargets.Class
- | System.AttributeTargets.Struct
- | System.AttributeTargets.Constructor
- | System.AttributeTargets.Method,
+
+ [AttributeUsage(
+ AttributeTargets.Assembly
+ | AttributeTargets.Class
+ | AttributeTargets.Struct
+ | AttributeTargets.Constructor
+ | AttributeTargets.Method,
AllowMultiple=true,
Inherited=false)
]
-
[Serializable]
public abstract class SecurityAttribute : Attribute {
public abstract IPermission CreatePermission ();
public bool Unrestricted {
- get {
- return m_Unrestricted;
- }
- set {
- m_Unrestricted = value;
- }
+ get { return m_Unrestricted; }
+ set { m_Unrestricted = value; }
}
public SecurityAction Action {
- get {
- return m_Action;
- }
- set {
- if (!SecurityAction.IsDefined(typeof(SecurityAction), value)) {
- throw new System.ArgumentException();
- }
- m_Action = value;
- }
+ get { return m_Action; }
+ set { m_Action = value; }
}
- } // public abstract class SecurityAttribute
-} // namespace System.Security.Permissions
+ }
+}