FileIOPermission Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The FileIOPermission class controls the ability to access files and folders.
public ref class FileIOPermission : Microsoft::Dynamics::Ax::Xpp::CodeAccessPermission
[Microsoft.Dynamics.Ax.Xpp.KernelClass]
[Microsoft.Dynamics.BusinessPlatform.SharedTypes.InternalUseOnly]
public class FileIOPermission : Microsoft.Dynamics.Ax.Xpp.CodeAccessPermission
[<Microsoft.Dynamics.Ax.Xpp.KernelClass>]
[<Microsoft.Dynamics.BusinessPlatform.SharedTypes.InternalUseOnly>]
type FileIOPermission = class
inherit CodeAccessPermission
Public Class FileIOPermission
Inherits CodeAccessPermission
- Inheritance
- Attributes
-
KernelClassAttribute Microsoft.Dynamics.BusinessPlatform.SharedTypes.InternalUseOnlyAttribute
Remarks
The FileIoPermission class is designed to check permissions for specific APIs. For a list of all APIs that are protected by permissions, see Secured APIs. Before the protected API is run, you must call the assert method on the same tier, usually the server tier, that the corresponding CodeAccessPermission::demand method is called on. Call a method on the server tier from one of the following:
- A server static method
- A class instance method that is set to run on the server by using the RunOn class property
The following code example shows a new instance of the FileIoPermission class that specifies read access for the File.txt file. The assert method is called to declare that the code can then call the AsciiIo.new method.
server static void main(Args args)
{
FileIoPermission _perm;
AsciiIo a;
_perm = new FileIoPermission("c:\\File.txt",'r');
_perm.assert();
// Invoke the protected API.
a = new AsciiIo("c:\\File.txt",'r');
}
Constructors
FileIOPermission() | |
FileIOPermission(IntPtr) | |
FileIOPermission(String, String) |
Fields
__k_FileIOPermissionId | |
kernelClass | (Inherited from XppObjectBase) |
Methods
__shouldCallNew(Type) | |
addXppProxyReference(Type, Object) | (Inherited from XppObjectBase) |
assert() |
Declares that the calling code can invoke an API that is protected by a permission. (Inherited from CodeAccessPermission) |
Call(String, Object[], Type[], Object[]) | (Inherited from XppObjectBase) |
cancelTimeOut(Int32) | (Inherited from XppObjectBase) |
Copy() |
Creates and returns a copy of the current permission class object. |
createKernelClass(Object[], Type[], Object[]) | (Inherited from XppObjectBase) |
demand() |
Checks the call stack to determine whether the permission that is required to invoke an API has been granted to the calling code. (Inherited from CodeAccessPermission) |
equal(XppObjectBase) | (Inherited from XppObjectBase) |
finalize() | (Inherited from XppObjectBase) |
GetIntPtr() | (Inherited from XppObjectBase) |
GetKernelInstanceUniqueId() | (Inherited from XppObjectBase) |
getTimeOutTimerHandle() | (Inherited from XppObjectBase) |
getXppProxyReference(Type) | (Inherited from XppObjectBase) |
handle() | |
IsManagedValid() | (Inherited from XppObjectBase) |
Issubsetof(CodeAccessPermission) |
Determines whether the current permission is a subset of a specified permission. |
kernelhandle() | |
KernelInstanceDisposed() | (Inherited from XppObjectBase) |
MakeReflectionCall(String, Object[]) | (Inherited from XppObjectBase) |
newmethod() |
Initializes a new instance of the CodeAccessPermission class. (Inherited from CodeAccessPermission) |
newmethod(String, String) |
Initializes a new instance of the CodeAccessPermission class. |
notify() | (Inherited from XppObjectBase) |
notifyAll() | (Inherited from XppObjectBase) |
objectOnServer() |
Obsolete.
(Inherited from XppObjectBase)
|
setTimeOut(String, Int32, Boolean) |
Obsolete.
(Inherited from XppObjectBase)
|
setTimeOut(String, Int32) |
Obsolete.
(Inherited from XppObjectBase)
|
usageCount() | (Inherited from XppObjectBase) |
VerifyKernelClass() | (Inherited from XppObjectBase) |
wait() | (Inherited from XppObjectBase) |
Xml() | (Inherited from XppObjectBase) |
Xml(Int32) | (Inherited from XppObjectBase) |