//
using System.Runtime.InteropServices;
-\r
-namespace System.Security.Permissions {\r
-\r
-#if NET_2_0
+
+namespace System.Security.Permissions {
+
[ComVisible (true)]
-#endif
[AttributeUsage (AttributeTargets.Assembly | AttributeTargets.Class |
AttributeTargets.Struct | AttributeTargets.Constructor |
AttributeTargets.Method, AllowMultiple=true, Inherited=false)]
private string path;
private string read;
private string write;
-#if NET_2_0
private FileIOPermissionAccess allFiles;
private FileIOPermissionAccess allLocalFiles;
private string changeAccessControl;
private string viewAccessControl;
- private string viewAndModify;
-#endif
+ //private string viewAndModify;
// Constructor
public FileIOPermissionAttribute (SecurityAction action) : base (action)
}
// Properties
-#if NET_2_0
[Obsolete ("use newer properties")]
-#endif
public string All {
-#if NET_1_1
get { throw new NotSupportedException ("All"); }
-#endif
set {
append = value;
path = value;
set { write = value; }
}
-#if NET_2_0
public FileIOPermissionAccess AllFiles {
get { return allFiles; }
set { allFiles = value; }
write = value;
}
}
-#endif
-
// Methods
public override IPermission CreatePermission ()
{
+#if NET_2_1
+ return null;
+#else
FileIOPermission perm = null;
if (this.Unrestricted)
perm = new FileIOPermission (PermissionState.Unrestricted);
perm.AddPathList (FileIOPermissionAccess.Write, write);
}
return perm;
+#endif
}
}
}