Examples of toLongArray()


Examples of com.humaorie.dollar.ArrayWrapper.ByteArrayWrapper.toLongArray()

    @Test
    public void unboxByteArrayToLongArray() {
        Byte[] boxed = new Byte[]{42, 43, 44};
        ByteArrayWrapper arrayWrapper = new ByteArrayWrapper(boxed);
        Assert.assertArrayEquals(new long[]{42, 43, 44}, arrayWrapper.toLongArray());
    }

    @Test
    public void unboxByteArrayWithNulls() {
        Byte[] boxed = new Byte[3];
View Full Code Here

Examples of com.humaorie.dollar.ArrayWrapper.CharArrayWrapper.toLongArray()

    @Test
    public void unboxCharacterArrayToLongArray() {
        Character[] boxed = new Character[]{'f', 'o', 'o'};
        CharArrayWrapper arrayWrapper = new CharArrayWrapper(boxed);
        Assert.assertArrayEquals(new long[]{'f', 'o', 'o'}, arrayWrapper.toLongArray());
    }

    @Test
    public void unboxCharacterArrayWithNulls() {
        Character[] boxed = new Character[3];
View Full Code Here

Examples of com.humaorie.dollar.ArrayWrapper.IntegerArrayWrapper.toLongArray()

    @Test
    public void unboxIntegerArrayToLongArray() {
        final Integer[] boxed = {42};
        final long[] unboxed = {42};
        final IntegerArrayWrapper arrayWrapper = new IntegerArrayWrapper(boxed);
        Assert.assertArrayEquals(unboxed, arrayWrapper.toLongArray());
    }

    @Test
    public void unboxIntegerArrayToFloatArray() {
        final Integer[] boxed = { 42 };
View Full Code Here

Examples of com.humaorie.dollar.ArrayWrapper.LongArrayWrapper.toLongArray()

    @Test
    public void unboxLongArray() {
        final Long[] boxed = {null};
        final long[] unboxed = {0};
        final LongArrayWrapper arrayWrapper = new LongArrayWrapper(boxed);
        Assert.assertArrayEquals(unboxed, arrayWrapper.toLongArray());
    }

    @Test
    public void unboxLongArrayWithNulls() {
        final Long[] boxed = {null};
View Full Code Here

Examples of com.humaorie.dollar.ArrayWrapper.LongArrayWrapper.toLongArray()

    @Test
    public void unboxLongArrayWithNulls() {
        final Long[] boxed = {null};
        final long[] unboxed = {0};
        final LongArrayWrapper arrayWrapper = new LongArrayWrapper(boxed);
        Assert.assertArrayEquals(unboxed, arrayWrapper.toLongArray());
    }

    @Test
    public void unboxFloatArray() {
        final Float[] boxed = {42.0f};
View Full Code Here

Examples of com.humaorie.dollar.ArrayWrapper.ShortArrayWrapper.toLongArray()

    @Test
    public void unboxShortArrayToLongArray() {
        final Short[] boxed = {42};
        final long[] unboxed = {42};
        final ShortArrayWrapper arrayWrapper = new ShortArrayWrapper(boxed);
        Assert.assertArrayEquals(unboxed, arrayWrapper.toLongArray());
    }

    @Test
    public void unboxShortArrayWithNulls() {
        final Short[] boxed = {null};
View Full Code Here

Examples of com.jacob.com.SafeArray.toLongArray()

   */
  public void testLongSafeArray() {
    long sourceData[] = new long[] { 2L << 40, 3L << 41, 4L << 42 };
    SafeArray saUnderTest = new SafeArray(Variant.VariantVariant, 3);
    saUnderTest.fromLongArray(sourceData);
    long[] extractedFromSafeArray = saUnderTest.toLongArray();
    for (int i = 0; i < extractedFromSafeArray.length; i++) {
      assertEquals("" + i, sourceData[i], extractedFromSafeArray[i]);
    }
    assertEquals("single get failed: ", sourceData[2], saUnderTest
        .getLong(2));
View Full Code Here

Examples of it.unimi.dsi.fastutil.longs.LongArrayList.toLongArray()

      if (i == 2) {
        continue;
      }
      uidsToDelete.add(UID_BASE + i);
      if (i %1000 == 0) {
        compositeActivityValues.delete(uidsToDelete.toLongArray());
        uidsToDelete.clear();
      }
    }
    compositeActivityValues.flush();
    compositeActivityValues.delete(uidsToDelete.toLongArray());
View Full Code Here

Examples of it.unimi.dsi.fastutil.longs.LongArrayList.toLongArray()

        compositeActivityValues.delete(uidsToDelete.toLongArray());
        uidsToDelete.clear();
      }
    }
    compositeActivityValues.flush();
    compositeActivityValues.delete(uidsToDelete.toLongArray());
    compositeActivityValues.flush();
    int notDeletedIndex = compositeActivityValues.uidToArrayIndex.get(UID_BASE + 2);
    final CompositeActivityValues testActivityData = compositeActivityValues;   
    Wait.until(10000L, "", new Wait.Condition() {     
      public boolean evaluate() {
View Full Code Here

Examples of it.unimi.dsi.fastutil.longs.LongArrayList.toLongArray()

    } finally {
      if (reader != null) {
        reader.close();
      }
    }
    _idArray = idList.toLongArray();
  }

  @Override
  public byte[] handleQuery() throws Exception {
    long uid = _idArray[_rand.nextInt(_idArray.length)];
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.