/// <exception cref="System.Exception"></exception> public virtual void Test21() { DeleteBase("nullo"); NeoDatis.Odb.Test.Nullobject.GenericClass gc = new NeoDatis.Odb.Test.Nullobject.GenericClass (null); NeoDatis.Odb.ODB odb = Open("nullo"); odb.Store(gc); odb.Close(); odb = Open("nullo"); NeoDatis.Odb.Objects objects = odb.GetObjects(typeof(NeoDatis.Odb.Test.Nullobject.GenericClass )); NeoDatis.Odb.Test.Nullobject.GenericClass gc2 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); long[] longs = new long[] { System.Convert.ToInt64(1), System.Convert.ToInt64(2) }; gc2.SetObjects(longs); odb.Store(gc2); odb.Close(); odb = Open("nullo"); objects = odb.GetObjects(typeof(NeoDatis.Odb.Test.Nullobject.GenericClass)); AssertEquals(1, objects.Count); NeoDatis.Odb.Test.Nullobject.GenericClass gc3 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); long[] longs2 = (long[])gc3.GetObjects(); AssertEquals(2, longs2.Length); AssertEquals(System.Convert.ToInt64(1), longs2[0]); AssertEquals(System.Convert.ToInt64(2), longs2[1]); odb.Close(); }
public virtual void Test23() { DeleteBase("nullo"); NeoDatis.Odb.Test.Nullobject.GenericClass gc = new NeoDatis.Odb.Test.Nullobject.GenericClass (null); gc.GetObjects()[0] = new NeoDatis.Odb.Test.VO.Login.Function("f1"); NeoDatis.Odb.ODB odb = Open("nullo"); odb.Store(gc); odb.Close(); odb = Open("nullo"); NeoDatis.Odb.Objects objects = odb.GetObjects(typeof(NeoDatis.Odb.Test.Nullobject.GenericClass )); NeoDatis.Odb.Test.Nullobject.GenericClass gc2 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); gc2.GetObjects()[0] = System.Convert.ToInt64(1); gc2.GetObjects()[1] = System.Convert.ToInt64(2); odb.Store(gc2); odb.Close(); odb = Open("nullo"); objects = odb.GetObjects(typeof(NeoDatis.Odb.Test.Nullobject.GenericClass)); AssertEquals(1, objects.Count); NeoDatis.Odb.Test.Nullobject.GenericClass gc3 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); object[] longs2 = (object[])gc3.GetObjects(); AssertEquals(10, longs2.Length); AssertEquals(System.Convert.ToInt64(1), longs2[0]); AssertEquals(System.Convert.ToInt64(2), longs2[1]); odb.Close(); }
public virtual void Test4() { DeleteBase("nullo"); NeoDatis.Odb.Test.Nullobject.GenericClass gc = new NeoDatis.Odb.Test.Nullobject.GenericClass (null); string[] strings = new string[] { "OBJ1", "obj2" }; gc.SetObject(strings); NeoDatis.Odb.ODB odb = Open("nullo"); odb.Store(gc); odb.Close(); odb = Open("nullo"); NeoDatis.Odb.Objects objects = odb.GetObjects(typeof(NeoDatis.Odb.Test.Nullobject.GenericClass )); NeoDatis.Odb.Test.Nullobject.GenericClass gc2 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); gc2.SetObject("Ola"); odb.Store(gc2); odb.Close(); }
public virtual void Test2() { DeleteBase("nullo"); NeoDatis.Odb.Test.Nullobject.GenericClass gc = new NeoDatis.Odb.Test.Nullobject.GenericClass (null); NeoDatis.Odb.ODB odb = Open("nullo"); odb.Store(gc); odb.Close(); odb = Open("nullo"); NeoDatis.Odb.Objects<GenericClass> objects = odb.GetObjects<GenericClass>(); NeoDatis.Odb.Test.Nullobject.GenericClass gc2 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); gc2.SetObject("Ola"); odb.Store(gc2); odb.Close(); odb = Open("nullo"); objects = odb.GetObjects<GenericClass>(); AssertEquals(1, objects.Count); GenericClass gc3 = (GenericClass)objects.GetFirst(); AssertEquals("Ola", gc3.GetObject()); odb.Close(); }
public virtual void Test2() { DeleteBase("nullo"); NeoDatis.Odb.Test.Nullobject.GenericClass gc = new NeoDatis.Odb.Test.Nullobject.GenericClass (null); NeoDatis.Odb.ODB odb = Open("nullo"); odb.Store(gc); odb.Close(); odb = Open("nullo"); NeoDatis.Odb.Objects <GenericClass> objects = odb.GetObjects <GenericClass>(); NeoDatis.Odb.Test.Nullobject.GenericClass gc2 = (NeoDatis.Odb.Test.Nullobject.GenericClass )objects.GetFirst(); gc2.SetObject("Ola"); odb.Store(gc2); odb.Close(); odb = Open("nullo"); objects = odb.GetObjects <GenericClass>(); AssertEquals(1, objects.Count); GenericClass gc3 = (GenericClass)objects.GetFirst(); AssertEquals("Ola", gc3.GetObject()); odb.Close(); }