forked from libgit2/libgit2sharp
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathGitWriteStream.cs
More file actions
27 lines (21 loc) · 781 Bytes
/
GitWriteStream.cs
File metadata and controls
27 lines (21 loc) · 781 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
using System;
using System.Runtime.InteropServices;
namespace LibGit2Sharp.Core
{
[StructLayout(LayoutKind.Sequential)]
internal struct GitWriteStream
{
[MarshalAs(UnmanagedType.FunctionPtr)]
public write_fn write;
[MarshalAs(UnmanagedType.FunctionPtr)]
public close_fn close;
[MarshalAs(UnmanagedType.FunctionPtr)]
public free_fn free;
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
public delegate int write_fn(IntPtr stream, IntPtr buffer, UIntPtr len);
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
public delegate int close_fn(IntPtr stream);
[UnmanagedFunctionPointer(CallingConvention.Cdecl)]
public delegate void free_fn(IntPtr stream);
}
}