mirror of
https://github.com/winfsp/winfsp.git
synced 2025-07-03 09:22:57 -05:00
src: dotnet: WIP
This commit is contained in:
@ -149,6 +149,22 @@ namespace Fsp.Interop
|
||||
//internal unsafe fixed UInt16 FileNameBuf[];
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct StreamInfo
|
||||
{
|
||||
internal UInt16 Size;
|
||||
internal UInt64 StreamSize;
|
||||
internal UInt64 StreamAllocationSize;
|
||||
//internal unsafe fixed UInt16 StreamNameBuf[];
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
struct FullContext
|
||||
{
|
||||
internal UInt64 UserContext;
|
||||
internal UInt64 UserContext2;
|
||||
}
|
||||
|
||||
[StructLayout(LayoutKind.Sequential)]
|
||||
internal struct IoStatusBlock
|
||||
{
|
||||
@ -186,7 +202,7 @@ namespace Fsp.Interop
|
||||
UInt32 FileAttributes,
|
||||
IntPtr SecurityDescriptor,
|
||||
UInt64 AllocationSize,
|
||||
IntPtr PFileContext,
|
||||
out FullContext FullContext,
|
||||
out FileInfo FileInfo);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 Open(
|
||||
@ -194,12 +210,12 @@ namespace Fsp.Interop
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName,
|
||||
UInt32 CreateOptions,
|
||||
UInt32 GrantedAccess,
|
||||
IntPtr PFileContext,
|
||||
out FullContext FullContext,
|
||||
out FileInfo FileInfo);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 Overwrite(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
UInt32 FileAttributes,
|
||||
Boolean ReplaceFileAttributes,
|
||||
UInt64 AllocationSize,
|
||||
@ -207,17 +223,17 @@ namespace Fsp.Interop
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate void Cleanup(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName,
|
||||
UInt32 Flags);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate void Close(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext);
|
||||
ref FullContext FullContext);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 Read(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
IntPtr Buffer,
|
||||
UInt64 Offset,
|
||||
UInt32 Length,
|
||||
@ -225,7 +241,7 @@ namespace Fsp.Interop
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 Write(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
IntPtr Buffer,
|
||||
UInt64 Offset,
|
||||
UInt32 Length,
|
||||
@ -236,17 +252,17 @@ namespace Fsp.Interop
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 Flush(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
out FileInfo FileInfo);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 GetFileInfo(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
out FileInfo FileInfo);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 SetBasicInfo(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
UInt32 FileAttributes,
|
||||
UInt64 CreationTime,
|
||||
UInt64 LastAccessTime,
|
||||
@ -256,38 +272,38 @@ namespace Fsp.Interop
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 SetFileSize(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
UInt64 NewSize,
|
||||
Boolean SetAllocationSize,
|
||||
out FileInfo FileInfo);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 CanDelete(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 Rename(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String NewFileName,
|
||||
Boolean ReplaceIfExists);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 GetSecurity(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
IntPtr SecurityDescriptor,
|
||||
IntPtr PSecurityDescriptorSize);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 SetSecurity(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
UInt32 SecurityInformation,
|
||||
IntPtr ModificationDescriptor);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 ReadDirectory(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String Pattern,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String Marker,
|
||||
IntPtr Buffer,
|
||||
@ -305,28 +321,28 @@ namespace Fsp.Interop
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 GetReparsePoint(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName,
|
||||
IntPtr Buffer,
|
||||
out UIntPtr PSize);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 SetReparsePoint(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName,
|
||||
IntPtr Buffer,
|
||||
UIntPtr Size);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 DeleteReparsePoint(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
[MarshalAs(UnmanagedType.LPWStr)] String FileName,
|
||||
IntPtr Buffer,
|
||||
UIntPtr Size);
|
||||
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
|
||||
internal delegate Int32 GetStreamInfo(
|
||||
IntPtr FileSystem,
|
||||
IntPtr FileContext,
|
||||
ref FullContext FullContext,
|
||||
IntPtr Buffer,
|
||||
UInt32 Length,
|
||||
out UInt32 PBytesTransferred);
|
||||
|
Reference in New Issue
Block a user