summaryrefslogtreecommitdiff
path: root/nejdb/Ejdb.DB/EJDB.cs
diff options
context:
space:
mode:
authoradam <adamansky@gmail.com>2013-08-15 22:05:19 +0700
committeradam <adamansky@gmail.com>2013-08-15 22:05:19 +0700
commitb4766cf74b719e34b7f85c430f95062dabfa4611 (patch)
treed5f28a80da0ee1e6c8f07cd05e1909f83766cfed /nejdb/Ejdb.DB/EJDB.cs
parent721691e20a05e34922a8d40909d162a9bf94a59b (diff)
downloadejdb-b4766cf74b719e34b7f85c430f95062dabfa4611.tar.gz
ejdb-b4766cf74b719e34b7f85c430f95062dabfa4611.tar.bz2
ejdb-b4766cf74b719e34b7f85c430f95062dabfa4611.zip
#92
Diffstat (limited to 'nejdb/Ejdb.DB/EJDB.cs')
-rw-r--r--nejdb/Ejdb.DB/EJDB.cs52
1 files changed, 26 insertions, 26 deletions
diff --git a/nejdb/Ejdb.DB/EJDB.cs b/nejdb/Ejdb.DB/EJDB.cs
index 01b1253..c19a6c7 100644
--- a/nejdb/Ejdb.DB/EJDB.cs
+++ b/nejdb/Ejdb.DB/EJDB.cs
@@ -153,13 +153,13 @@ namespace Ejdb.DB {
// Native functions refs
//.//////////////////////////////////////////////////////////////////
#region NativeRefs
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbnew")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbnew", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbnew();
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbdel")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbdel", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbdel([In] IntPtr db);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbopen")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbopen", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbopen([In] IntPtr db, [In] IntPtr path, int mode);
internal static bool _ejdbopen(IntPtr db, string path, int mode) {
@@ -171,19 +171,19 @@ namespace Ejdb.DB {
}
}
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbclose")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbclose", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbclose([In] IntPtr db);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbisopen")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbisopen", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbisopen([In] IntPtr db);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbecode")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbecode", CallingConvention = CallingConvention.Cdecl)]
internal static extern int _ejdbecode([In] IntPtr db);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdberrmsg")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdberrmsg", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdberrmsg(int ecode);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbgetcoll")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbgetcoll", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbgetcoll([In] IntPtr db, [In] IntPtr cname);
internal static IntPtr _ejdbgetcoll(IntPtr db, string cname) {
@@ -195,10 +195,10 @@ namespace Ejdb.DB {
}
}
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbcreatecoll")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbcreatecoll", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbcreatecoll([In] IntPtr db, [In] IntPtr cname, IntPtr opts);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbcreatecoll")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbcreatecoll", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbcreatecoll([In] IntPtr db, [In] IntPtr cname, ref EJDBCollectionOptionsN opts);
internal static IntPtr _ejdbcreatecoll(IntPtr db, String cname, EJDBCollectionOptionsN? opts) {
@@ -215,7 +215,7 @@ namespace Ejdb.DB {
}
}
//EJDB_EXPORT bool ejdbrmcoll(EJDB *jb, const char *colname, bool unlinkfile);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbrmcoll")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbrmcoll", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbrmcoll([In] IntPtr db, [In] IntPtr cname, bool unlink);
internal static bool _ejdbrmcoll(IntPtr db, string cname, bool unlink) {
@@ -227,49 +227,49 @@ namespace Ejdb.DB {
}
}
//EJDB_EXPORT bson* ejdbcommand(EJDB *jb, bson *cmd);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbcommand2")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbcommand2", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbcommand([In] IntPtr db, [In] byte[] cmd);
//EJDB_EXPORT bool ejdbsavebson3(EJCOLL *jcoll, void *bsdata, bson_oid_t *oid, bool merge);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbsavebson3")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbsavebson3", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbsavebson([In] IntPtr coll, [In] byte[] bsdata, [Out] byte[] oid, [In] bool merge);
//EJDB_EXPORT bson* ejdbloadbson(EJCOLL *coll, const bson_oid_t *oid);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbloadbson")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbloadbson", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbloadbson([In] IntPtr coll, [In] byte[] oid);
//EJDB_EXPORT const char* bson_data2(const bson *b, int *bsize);
- [DllImport(EJDB_LIB_NAME, EntryPoint="bson_data2")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "bson_data2", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _bson_data2([In] IntPtr bsptr, out int size);
//EJDB_EXPORT void bson_del(bson *b);
- [DllImport(EJDB_LIB_NAME, EntryPoint="bson_del")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "bson_del", CallingConvention = CallingConvention.Cdecl)]
internal static extern void _bson_del([In] IntPtr bsptr);
//EJDB_EXPORT bool ejdbrmbson(EJCOLL *coll, bson_oid_t *oid);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbrmbson")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbrmbson", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbrmbson([In] IntPtr cptr, [In] byte[] oid);
//EJDB_EXPORT bool ejdbsyncdb(EJDB *jb)
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbsyncdb")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbsyncdb", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbsyncdb([In] IntPtr db);
//EJDB_EXPORT bool ejdbsyncoll(EJDB *jb)
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbsyncoll")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbsyncoll", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbsyncoll([In] IntPtr coll);
//EJDB_EXPORT bool ejdbsetindex(EJCOLL *coll, const char *ipath, int flags);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbsetindex")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbsetindex", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbsetindex([In] IntPtr coll, [In] IntPtr ipathptr, int flags);
//EJDB_EXPORT bson* ejdbmeta(EJDB *jb)
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbmeta")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbmeta", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbmeta([In] IntPtr db);
//EJDB_EXPORT bool ejdbtranbegin(EJCOLL *coll);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbtranbegin")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbtranbegin", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbtranbegin([In] IntPtr coll);
//EJDB_EXPORT bool ejdbtrancommit(EJCOLL *coll);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbtrancommit")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbtrancommit", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbtrancommit([In] IntPtr coll);
//EJDB_EXPORT bool ejdbtranabort(EJCOLL *coll);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbtranabort")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbtranabort", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbtranabort([In] IntPtr coll);
//EJDB_EXPORT bool ejdbtranstatus(EJCOLL *jcoll, bool *txactive);
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbtranstatus")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbtranstatus", CallingConvention = CallingConvention.Cdecl)]
internal static extern bool _ejdbtranstatus([In] IntPtr coll, out bool txactive);
//EJDB_EXPORT const char *ejdbversion();
- [DllImport(EJDB_LIB_NAME, EntryPoint="ejdbversion")]
+ [DllImport(EJDB_LIB_NAME, EntryPoint = "ejdbversion", CallingConvention = CallingConvention.Cdecl)]
internal static extern IntPtr _ejdbversion();
internal static bool _ejdbsetindex(IntPtr coll, string ipath, int flags) {