Skip to content
This repository was archived by the owner on Nov 14, 2018. It is now read-only.

Commit 08c694e

Browse files
committed
c# binding now works with ejdb 1.2.x
1 parent 6d3d5e4 commit 08c694e

File tree

7 files changed

+16
-48
lines changed

7 files changed

+16
-48
lines changed

Ejdb.DB/EJDB.cs

+4-7
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// ============================================================================================
22
// .NET API for EJDB database library http://ejdb.org
3-
// Copyright (C) 2012-2013 Softmotions Ltd <[email protected]>
3+
// Copyright (C) 2012-2015 Softmotions Ltd <[email protected]>
44
//
55
// This file is part of EJDB.
66
// EJDB is free software; you can redistribute it and/or modify it under the terms of
@@ -139,9 +139,9 @@ public class EJDB : IDisposable {
139139
/// Name if EJDB library
140140
/// </summary>
141141
#if EJDBDLL
142-
public const string EJDB_LIB_NAME = "tcejdbdll";
143-
#else
144-
public const string EJDB_LIB_NAME = "tcejdb";
142+
public const string EJDB_LIB_NAME = "libejdb";
143+
#else
144+
public const string EJDB_LIB_NAME = "ejdb";
145145
#endif
146146
/// <summary>
147147
/// Pointer to the native EJDB instance.
@@ -419,9 +419,6 @@ public static long LibHexVersion {
419419
/// <param name="path">The main database file path.</param>
420420
/// <param name="omode">Open mode.</param>
421421
public EJDB(string path, int omode = DEFAULT_OPEN_MODE) {
422-
if (EJDB.LibHexVersion < 0x1113) {
423-
throw new EJDBException("EJDB library version must be at least '1.1.13' or greater");
424-
}
425422
bool rv;
426423
_db = _ejdbnew();
427424
if (_db == IntPtr.Zero) {

Ejdb.Tests/TestBSON.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// ============================================================================================
22
// .NET API for EJDB database library http://ejdb.org
3-
// Copyright (C) 2012-2013 Softmotions Ltd <[email protected]>
3+
// Copyright (C) 2012-2015 Softmotions Ltd <[email protected]>
44
//
55
// This file is part of EJDB.
66
// EJDB is free software; you can redistribute it and/or modify it under the terms of

nejdb.csproj

+2-4
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">DebugUnix</Configuration>
55
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
6-
<ProductVersion>10.0.0</ProductVersion>
6+
<ProductVersion>8.0.30703</ProductVersion>
77
<SchemaVersion>2.0</SchemaVersion>
88
<ProjectGuid>{A24C964C-771F-4359-8C93-4BFCBE451D8B}</ProjectGuid>
99
<OutputType>Library</OutputType>
1010
<RootNamespace>Ejdb</RootNamespace>
1111
<AssemblyName>nejdb</AssemblyName>
1212
<Description>EJDB .Net binding (http://ejdb.org)</Description>
1313
<CodePage>65001</CodePage>
14-
<ReleaseVersion>1.0.0</ReleaseVersion>
14+
<ReleaseVersion>1.1.0</ReleaseVersion>
1515
</PropertyGroup>
1616
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'DebugUnix|AnyCPU' ">
1717
<DebugSymbols>true</DebugSymbols>
@@ -39,7 +39,6 @@
3939
<ErrorReport>prompt</ErrorReport>
4040
<WarningLevel>4</WarningLevel>
4141
<ConsolePause>false</ConsolePause>
42-
<PlatformTarget>AnyCPU</PlatformTarget>
4342
</PropertyGroup>
4443
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'ReleaseWindows|AnyCPU' ">
4544
<DebugType>none</DebugType>
@@ -49,7 +48,6 @@
4948
<WarningLevel>4</WarningLevel>
5049
<ConsolePause>false</ConsolePause>
5150
<DefineConstants>EJDBDLL;</DefineConstants>
52-
<PlatformTarget>AnyCPU</PlatformTarget>
5351
</PropertyGroup>
5452
<ItemGroup>
5553
<Reference Include="nunit.framework">

nejdb.sln

+2-3
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,9 @@ Global
3838
GlobalSection(NestedProjects) = preSolution
3939
EndGlobalSection
4040
GlobalSection(MonoDevelopProperties) = preSolution
41-
StartupItem = nejdb.csproj
4241
Policies = $0
4342
$0.StandardHeader = $1
44-
$1.Text = @============================================================================================\n .NET API for EJDB database library http://ejdb.org\n Copyright (C) 2012-2013 Softmotions Ltd <[email protected]>\n\n This file is part of EJDB.\n EJDB is free software; you can redistribute it and/or modify it under the terms of\n the GNU Lesser General Public License as published by the Free Software Foundation; either\n version 2.1 of the License or any later version. EJDB is distributed in the hope\n that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of\n MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public\n License for more details.\n You should have received a copy of the GNU Lesser General Public License along with EJDB;\n if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330,\n Boston, MA 02111-1307 USA.\n============================================================================================
43+
$1.Text = @============================================================================================\n .NET API for EJDB database library http://ejdb.org\n Copyright (C) 2012-2015 Softmotions Ltd <[email protected]>\n\n This file is part of EJDB.\n EJDB is free software; you can redistribute it and/or modify it under the terms of\n the GNU Lesser General Public License as published by the Free Software Foundation; either\n version 2.1 of the License or any later version. EJDB is distributed in the hope\n that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of\n MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public\n License for more details.\n You should have received a copy of the GNU Lesser General Public License along with EJDB;\n if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330,\n Boston, MA 02111-1307 USA.\n============================================================================================
4544
$1.IncludeInNewFiles = True
4645
$0.DotNetNamingPolicy = $2
4746
$2.DirectoryNamespaceAssociation = Flat
@@ -238,6 +237,6 @@ Global
238237
$36.LineAlign = 0
239238
$35.inheritsSet = Mono
240239
description = " .NET API for EJDB database library http://ejdb.org"
241-
version = 1.0.0
240+
version = 1.1.0
242241
EndGlobalSection
243242
EndGlobal

nejdb.userprefs

+4-30
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,9 @@
1-
<Properties>
1+
<Properties StartupItem="nejdb.csproj">
22
<MonoDevelop.Ide.Workspace ActiveConfiguration="DebugUnix" />
3-
<MonoDevelop.Ide.Workbench ActiveDocument="Ejdb.DB/EJDB.cs">
3+
<MonoDevelop.Ide.Workbench ActiveDocument="Ejdb.Tests/TestBSON.cs">
44
<Files>
5-
<File FileName="Ejdb.DB/EJDB.cs" Line="1" Column="1" />
6-
<File FileName="Ejdb.DB/EJDBQuery.cs" Line="1" Column="1" />
7-
<File FileName="Ejdb.Utils/Native.cs" Line="1" Column="1" />
8-
<File FileName="Ejdb.BSON/BSONIterator.cs" Line="1" Column="1" />
5+
<File FileName="Ejdb.Tests/TestBSON.cs" Line="111" Column="33" />
96
</Files>
10-
<Pads>
11-
<Pad Id="ProjectPad">
12-
<State expanded="True" selected="True">
13-
<Node name="nejdb" expanded="True">
14-
<Node name="Ejdb.BSON" expanded="True" />
15-
<Node name="Ejdb.DB" expanded="True" />
16-
<Node name="Ejdb.Utils" expanded="True" />
17-
</Node>
18-
<Node name="sample" expanded="True" />
19-
</State>
20-
</Pad>
21-
<Pad Id="ClassPad">
22-
<State expanded="True" selected="True" />
23-
</Pad>
24-
<Pad Id="MonoDevelop.Debugger.WatchPad">
25-
<State />
26-
</Pad>
27-
<Pad Id="ConnectionManagerPad">
28-
<State selected="True" />
29-
</Pad>
30-
<Pad Id="MonoDevelop.NUnit.TestPad">
31-
<State expanded="True" selected="True" />
32-
</Pad>
33-
</Pads>
347
</MonoDevelop.Ide.Workbench>
358
<MonoDevelop.Ide.DebuggingService.Breakpoints>
369
<BreakpointStore>
@@ -39,4 +12,5 @@
3912
</BreakpointStore>
4013
</MonoDevelop.Ide.DebuggingService.Breakpoints>
4114
<MonoDevelop.Ide.DebuggingService.PinnedWatches />
15+
<AuthorInfo Name="Adamansky Anton" Email="[email protected]" Copyright="Copyright (C) 2012-2015 Softmotions Ltd &lt;[email protected]&gt;" Company="Softmotions Ltd" Trademark="" />
4216
</Properties>

sample/Program.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// ============================================================================================
22
// .NET API for EJDB database library http://ejdb.org
3-
// Copyright (C) 2012-2013 Softmotions Ltd <[email protected]>
3+
// Copyright (C) 2012-2015 Softmotions Ltd <[email protected]>
44
//
55
// This file is part of EJDB.
66
// EJDB is free software; you can redistribute it and/or modify it under the terms of

sample/sample.csproj

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">DebugWindows</Configuration>
55
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
6-
<ProductVersion>10.0.0</ProductVersion>
6+
<ProductVersion>8.0.30703</ProductVersion>
77
<SchemaVersion>2.0</SchemaVersion>
88
<ProjectGuid>{93049FBC-650E-432C-9F1D-156E621DB96C}</ProjectGuid>
99
<OutputType>Exe</OutputType>
1010
<RootNamespace>sample</RootNamespace>
1111
<AssemblyName>sample</AssemblyName>
12-
<ReleaseVersion>1.0.0</ReleaseVersion>
12+
<ReleaseVersion>1.1.0</ReleaseVersion>
1313
</PropertyGroup>
1414
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'DebugWindows|AnyCPU' ">
1515
<DebugSymbols>true</DebugSymbols>

0 commit comments

Comments
 (0)