Merge pull request #496 from nicolas-raoul/unit-test-for-issue2907
[mono.git] / mcs / class / corlib / System.Security.Permissions / SecurityPermissionFlag.cs
old mode 100755 (executable)
new mode 100644 (file)
index fab1bbd..9e5517b
@@ -1,74 +1,81 @@
-// SecurityPermissionFlag.cs\r
-//\r
-// This code was automatically generated from\r
-// ECMA CLI XML Library Specification.\r
-// Generator: libgen.xsl\r
-// Source file: AllTypes.xml\r
-// URL: http://msdn.microsoft.com/net/ecma/AllTypes.xml\r
-//\r
-// (C) 2001 Ximian, Inc.  http://www.ximian.com\r
-\r
-\r
-namespace System.Security.Permissions {\r
-\r
-\r
-       /// <summary>\r
-       /// <para>Specifies a set of security permissions applied to a\r
-       ///    <see cref="T:System.Security.Permissions.SecurityPermission" /> instance.</para>\r
-       /// </summary>\r
-       /// <remarks>\r
-       /// <para>This enumeration is used by <see cref="T:System.Security.Permissions.SecurityPermission" />.</para>\r
-       /// <para>\r
-       /// <see cref="T:System.Security.Permissions.SecurityPermissionFlag" /> is a bitfield. Specify\r
-       /// multiple values of this enumeration using the bit-wise OR\r
-       /// operator.</para>\r
-       /// <para>\r
-       /// <block subset="ECMAOnly" type="ECMA Only">For more information on security, see Partition \r
-       ///    II of the CLI Specification.</block>\r
-       /// </para>\r
-       /// <para>\r
-       /// <block subset="none" type="note">Many of these flags are powerful and\r
-       ///    should only be granted to highly trusted code. </block>\r
-       /// </para>\r
-       /// </remarks>\r
-       [Flags]\r
-       public enum SecurityPermissionFlag {\r
-\r
-               /// <summary><para> Specifies that none of the permissions in this \r
-               ///       enumeration are available.</para></summary>\r
-               NoFlags = 0x00000000,\r
-\r
-               /// <summary><para> Specifies the ability to assert<see langword=" " />\r
-               /// that all of this code's\r
-               /// callers have one\r
-               /// or more permissions.</para></summary>\r
-               Assertion = 0x00000001,\r
-\r
-               /// <summary><para> Specifies the ability to call unmanaged code.</para><block subset="none" type="note"><para> \r
-               ///          Because unmanaged code potentially allows other permissions to be bypassed,\r
-               ///          this permission should be used with caution. It is used for applications calling native\r
-               ///          code using PInvoke.</para></block></summary>\r
-               UnmanagedCode = 0x00000002,\r
-\r
-               /// <summary><para>Specifies the ability to skip verification of code in an assembly.</para><para><block subset="none" type="note">Code that is unverifiable can execute if \r
-               ///       this permission is granted.</block></para></summary>\r
-               SkipVerification = 0x00000004,\r
-\r
-               /// <summary><para> Specifies permission for the code to run. Without this\r
-               ///  permission managed code cannot execute.</para></summary>\r
-               Execution = 0x00000008,\r
-\r
-               /// <summary><para> Specifies the ability to use advanced operations on \r
-               ///       threads. These operations include <see cref="M:System.Threading.Thread.Abort(System.Object)" />\r
-               ///       and <see cref="M:System.Threading.Thread.ResetAbort" /> .</para></summary>\r
-               ControlThread = 0x00000010,\r
-\r
-               /// <summary><para>Specifies all of the permissions defined by this\r
-               ///       enumeration.</para><para><block subset="ECMAOnly" type="ECMA Only">The value of this constant is equal to the\r
-               ///       values of this enumeration combined with a bitwise-OR operation. The higher-order bits in\r
-               ///       this constant that are not specified in the CLI have been reserved for implementation-specific\r
-               ///       use.</block></para></summary>\r
-               AllFlags = Assertion | UnmanagedCode | SkipVerification | Execution | ControlThread,\r
-       } // SecurityPermissionFlag\r
-\r
-} // System.Security.Permissions\r
+// SecurityPermissionFlag.cs
+//
+// This code was automatically generated from
+// ECMA CLI XML Library Specification.
+// Generator: libgen.xsl [1.0; (C) Sergey Chaban (serge@wildwestsoftware.com)]
+// Created: Wed, 5 Sep 2001 06:30:18 UTC
+// Source file: AllTypes.xml
+// URL: http://msdn.microsoft.com/net/ecma/AllTypes.xml
+//
+// (C) 2001 Ximian, Inc.  http://www.ximian.com
+// Copyright (C) 2004-2005 Novell, Inc (http://www.novell.com)
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+// 
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+// 
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+
+using System.Runtime.InteropServices;
+
+namespace System.Security.Permissions {
+
+#if NET_2_1 && !MONOTOUCH
+       [Obsolete ("CAS support is not available with Silverlight applications.")]
+#endif
+       [ComVisible (true)]
+       [Flags]
+       [Serializable]
+       public enum SecurityPermissionFlag {
+
+               NoFlags = 0x00000000,
+
+               Assertion = 0x00000001,
+
+               UnmanagedCode = 0x00000002,
+
+               SkipVerification = 0x00000004,
+
+               Execution = 0x00000008,
+
+               ControlThread = 0x00000010,
+
+               ControlEvidence = 0x00000020,
+
+               ControlPolicy = 0x00000040,
+
+               SerializationFormatter = 0x00000080,
+
+               ControlDomainPolicy = 0x00000100,
+
+               ControlPrincipal = 0x00000200,
+
+               ControlAppDomain = 0x00000400,
+
+               RemotingConfiguration = 0x00000800,
+
+               Infrastructure = 0x00001000,
+
+               BindingRedirects = 0x00002000,
+
+               AllFlags = Assertion | UnmanagedCode | SkipVerification | Execution | ControlThread
+                       | ControlAppDomain | ControlDomainPolicy | ControlEvidence | ControlPolicy
+                       | ControlPrincipal | Infrastructure | RemotingConfiguration | SerializationFormatter
+                       | BindingRedirects
+       } // SecurityPermissionFlag
+
+} // System.Security.Permissions