/// <summary>Creates a new long buffer by wrapping the given long array.</summary> /// <remarks> /// Creates a new long buffer by wrapping the given long array. /// <p> /// The new buffer's position will be /// <code>start</code> /// , limit will be /// <code>start + longCount</code> /// , capacity will be the length of the array. /// </remarks> /// <param name="array">the long array which the new buffer will be based on.</param> /// <param name="start"> /// the start index, must not be negative and not greater than /// <code>array.length</code> /// . /// </param> /// <param name="longCount"> /// the length, must not be negative and not greater than /// <code>array.length - start</code> /// . /// </param> /// <returns>the created long buffer.</returns> /// <exception> /// IndexOutOfBoundsException /// if either /// <code>start</code> /// or /// <code>longCount</code> /// is invalid. /// </exception> public static java.nio.LongBuffer wrap(long[] array_1, int start, int longCount) { java.util.Arrays.checkOffsetAndCount(array_1.Length, start, longCount); java.nio.LongBuffer buf = new java.nio.ReadWriteLongArrayBuffer(array_1); buf._position = start; buf._limit = start + longCount; return(buf); }
internal static java.nio.ReadWriteLongArrayBuffer copy(java.nio.LongArrayBuffer other , int markOfOther) { java.nio.ReadWriteLongArrayBuffer buf = new java.nio.ReadWriteLongArrayBuffer(other .capacity(), other.backingArray, other.offset); buf._limit = other._limit; buf._position = other.position(); buf._mark = markOfOther; return(buf); }
internal static java.nio.ReadWriteLongArrayBuffer copy(java.nio.LongArrayBuffer other , int markOfOther) { java.nio.ReadWriteLongArrayBuffer buf = new java.nio.ReadWriteLongArrayBuffer(other .capacity(), other.backingArray, other.offset); buf._limit = other._limit; buf._position = other.position(); buf._mark = markOfOther; return buf; }