Beispiel #1
0
 private void CreatePrimitiveArrayInObject(DoubleHandlerUpdateTestCase.ItemArrays
                                           item)
 {
     double[] arr = new double[data.Length];
     System.Array.Copy(data, 0, arr, 0, data.Length);
     item._primitiveArrayInObject = arr;
 }
Beispiel #2
0
 private void CreateTypedWrapperArray(DoubleHandlerUpdateTestCase.ItemArrays item)
 {
     item._typedWrapperArray = new double[data.Length + 1];
     for (int i = 0; i < data.Length; i++)
     {
         item._typedWrapperArray[i] = data[i];
     }
 }
Beispiel #3
0
 private void CreateWrapperArrayInObject(DoubleHandlerUpdateTestCase.ItemArrays item
                                         )
 {
     double[] arr = new double[data.Length + 1];
     for (int i = 0; i < data.Length; i++)
     {
         arr[i] = data[i];
     }
     item._wrapperArrayInObject = arr;
 }
Beispiel #4
0
 protected override void AssertArrays(IExtObjectContainer objectContainer, object
                                      obj)
 {
     DoubleHandlerUpdateTestCase.ItemArrays item = (DoubleHandlerUpdateTestCase.ItemArrays
                                                    )obj;
     AssertTypedPrimitiveArray(item);
     AssertTypedWrapperArray(item);
     // Will be removed for .NET by sharpen.
     AssertPrimitiveArrayInObject(item);
     AssertWrapperArrayInObject(item);
 }
Beispiel #5
0
 protected override object CreateArrays()
 {
     DoubleHandlerUpdateTestCase.ItemArrays item = new DoubleHandlerUpdateTestCase.ItemArrays
                                                       ();
     CreateTypedPrimitiveArray(item);
     CreateTypedWrapperArray(item);
     // Will be removed for .NET by sharpen.
     CreatePrimitiveArrayInObject(item);
     CreateWrapperArrayInObject(item);
     return(item);
 }
Beispiel #6
0
 private void AssertPrimitiveArrayInObject(DoubleHandlerUpdateTestCase.ItemArrays
                                           item)
 {
     if (Db4oHeaderVersion() == VersionServices.Header3040)
     {
         // Bug in the oldest format: It accidentally double[] arrays to Double[] arrays.
         AssertWrapperData((double[])item._primitiveArrayInObject);
     }
     else
     {
         AssertData((double[])item._primitiveArrayInObject);
     }
 }
Beispiel #7
0
 private void AssertWrapperArrayInObject(DoubleHandlerUpdateTestCase.ItemArrays item
                                         )
 {
     AssertWrapperData((double[])item._wrapperArrayInObject);
 }
Beispiel #8
0
 private void AssertTypedWrapperArray(DoubleHandlerUpdateTestCase.ItemArrays item)
 {
     AssertWrapperData(item._typedWrapperArray);
 }
Beispiel #9
0
 private void AssertTypedPrimitiveArray(DoubleHandlerUpdateTestCase.ItemArrays item
                                        )
 {
     AssertData(item._typedPrimitiveArray);
 }
Beispiel #10
0
 private void CreateTypedPrimitiveArray(DoubleHandlerUpdateTestCase.ItemArrays item
                                        )
 {
     item._typedPrimitiveArray = new double[data.Length];
     System.Array.Copy(data, 0, item._typedPrimitiveArray, 0, data.Length);
 }
		protected override object CreateArrays()
		{
			DoubleHandlerUpdateTestCase.ItemArrays item = new DoubleHandlerUpdateTestCase.ItemArrays
				();
			CreateTypedPrimitiveArray(item);
			CreateTypedWrapperArray(item);
			// Will be removed for .NET by sharpen.
			CreatePrimitiveArrayInObject(item);
			CreateWrapperArrayInObject(item);
			return item;
		}