36 lines
1.1 KiB
C#
36 lines
1.1 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Runtime.InteropServices;
|
|
using System.Text;
|
|
|
|
namespace bts.utils
|
|
{
|
|
internal static class BTSNativeMethods
|
|
{
|
|
[DllImport("libspark")]
|
|
public static extern void provide_command_line(
|
|
[MarshalAs(UnmanagedType.LPArray, ArraySubType = UnmanagedType.LPStr)] string[] argv, int argc);
|
|
|
|
[DllImport("libspark")]
|
|
public static extern int get_random_port();
|
|
|
|
[DllImport("libspark")]
|
|
public static extern void init_spark_lib();
|
|
[DllImport("libspark")]
|
|
public static extern void finit_spark_lib();
|
|
|
|
[DllImport("libspark")]
|
|
public static extern UInt64 ll_now();
|
|
|
|
[DllImport("kernel32.dll")]
|
|
public static extern bool SetConsoleTitle(string lpConsoleTitle);
|
|
|
|
[DllImport("libspark")]
|
|
public static extern bool initialize_nothrow(StringBuilder buffer, int length);
|
|
|
|
//public static string bts_data_path()
|
|
//use mbts.config.Configuration.get<bts.config.System>().data_path;
|
|
}
|
|
}
|