/// Gets the <see cref="Ejdb.BSON.BSONDocument"/> with the specified key.
/// </summary>
/// <remarks>
- /// Hierarchical field paths are supported.
+ /// Getter for hierarchical field paths are supported.
/// </remarks>
/// <param name="key">Key.</param>
/// <returns>Key object </c> or <c>null</c> if the key is not exists or value type is either
doc2.SetNumber("0", 2);
Assert.AreEqual(1, doc2.KeysCount);
object ival = doc2["0"];
- Assert.IsInstanceOfType(typeof(int), ival);
+ Assert.IsInstanceOf(typeof(int), ival);
Assert.AreEqual(2, ival);
doc2.SetNumber("1", Int32.MaxValue);
//13-00-00-00
}
if (c == 2) {
Assert.AreEqual(BSONType.OID, bv.BSONType);
- Assert.IsInstanceOfType(typeof(BSONOid), bv.Value);
+ Assert.IsInstanceOf(typeof(BSONOid), bv.Value);
var oid = bv.Value as BSONOid;
Assert.AreEqual("51b9f3af98195c4600000000", oid.ToString());
}
bool rv = jb.Save("mycoll", doc);
Assert.IsTrue(rv);
Assert.IsNotNull(doc["_id"]);
- Assert.IsInstanceOfType(typeof(BSONOid), doc["_id"]);
+ Assert.IsInstanceOf(typeof(BSONOid), doc["_id"]);
rv = jb.Save("mycoll", doc);
Assert.IsTrue(rv);
namespace Ejdb.Utils {
/// <summary>
- /// Check if specified type if anonymous.
+ /// Check if specified type is anonymous.
/// </summary>
public static class TypeExtension {
public static bool IsAnonymousType(this Type type) {
<RootNamespace>Ejdb</RootNamespace>
<AssemblyName>nejdb</AssemblyName>
<Description>EJDB .Net binding (http://ejdb.org)</Description>
- <ReleaseVersion>1.0.0</ReleaseVersion>
<CodePage>65001</CodePage>
+ <ReleaseVersion>1.0.0</ReleaseVersion>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'DebugUnix|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<ConsolePause>false</ConsolePause>
+ <DefineConstants>DEBUG;</DefineConstants>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'DebugWindows|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<ConsolePause>false</ConsolePause>
- <DefineConstants>EJDBDLL</DefineConstants>
+ <DefineConstants>DEBUG;EJDBDLL;</DefineConstants>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
- <Reference Include="nunit.framework, Version=2.4.8.0, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77">
- <Private>False</Private>
- <SpecificVersion>False</SpecificVersion>
- </Reference>
<Reference Include="System.Core" />
<Reference Include="Mono.Posix" />
+ <Reference Include="nunit.framework, Version=2.6.0.12051, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77">
+ <Private>False</Private>
+ </Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="AssemblyInfo.cs" />
<Properties>
- <MonoDevelop.Ide.Workspace ActiveConfiguration="DebugUnix" />
- <MonoDevelop.Ide.Workbench ActiveDocument="sample/Program.cs">
+ <MonoDevelop.Ide.Workspace ActiveConfiguration="ReleaseUnix" />
+ <MonoDevelop.Ide.Workbench ActiveDocument="Ejdb.Tests/TestEJDB.cs">
<Files>
- <File FileName="sample/Program.cs" Line="59" Column="70" />
- <File FileName="Ejdb.BSON/BSONIterator.cs" Line="155" Column="24" />
- <File FileName="Ejdb.BSON/BSONDocument.cs" Line="148" Column="27" />
+ <File FileName="Ejdb.Tests/TestEJDB.cs" Line="153" Column="36" />
+ <File FileName="Ejdb.Tests/TestBSON.cs" Line="279" Column="31" />
+ <File FileName="Ejdb.DB/EJDB.cs" Line="5" Column="10" />
+ <File FileName="Ejdb.BSON/BSONDocument.cs" Line="279" Column="68" />
</Files>
<Pads>
<Pad Id="ProjectPad">
<State expanded="True">
- <Node name="nejdb" expanded="True">
+ <Node name="nejdb" expanded="True" selected="True">
+ <Node name="References" expanded="True" />
<Node name="Ejdb.BSON" expanded="True" />
+ <Node name="Ejdb.DB" expanded="True" />
+ <Node name="Ejdb.Tests" expanded="True" />
</Node>
- <Node name="sample" expanded="True">
- <Node name="Properties" expanded="True" />
- <Node name="Program.cs" selected="True" />
- </Node>
+ <Node name="sample" expanded="True" />
</State>
</Pad>
<Pad Id="ClassPad">
- <State expanded="True" selected="True">
- <Node name="nejdb" expanded="True" />
- </State>
+ <State expanded="True" selected="True" />
</Pad>
<Pad Id="MonoDevelop.Debugger.WatchPad">
<State>