Lines Matching full:code
37 * Static utility methods pertaining to {@code long} primitives, that are not
48 * The number of bytes required to represent a primitive {@code long}
54 * Returns a hash code for {@code value}; equal to the result of invoking
55 * {@code ((Long) value).hashCode()}.
57 * @param value a primitive {@code long} value
58 * @return a hash code for the value
65 * Compares the two specified {@code long} values. The sign of the value
66 * returned is the same as that of {@code ((Long) a).compareTo(b)}.
68 * @param a the first {@code long} to compare
69 * @param b the second {@code long} to compare
70 * @return a negative value if {@code a} is less than {@code b}; a positive
71 * value if {@code a} is greater than {@code b}; or zero if they are equal
78 * Returns {@code true} if {@code target} is present as an element anywhere in
79 * {@code array}.
81 * @param array an array of {@code long} values, possibly empty
82 * @param target a primitive {@code long} value
83 * @return {@code true} if {@code array[i] == target} for some value of {@code
96 * Returns the index of the first appearance of the value {@code target} in
97 * {@code array}.
99 * @param array an array of {@code long} values, possibly empty
100 * @param target a primitive {@code long} value
101 * @return the least index {@code i} for which {@code array[i] == target}, or
102 * {@code -1} if no such index exists.
120 * Returns the start position of the first occurrence of the specified {@code
121 * target} within {@code array}, or {@code -1} if there is no such occurrence.
123 * <p>More formally, returns the lowest index {@code i} such that {@code
125 * the same elements as {@code target}.
127 * @param array the array to search for the sequence {@code target}
128 * @param target the array to search for as a sub-sequence of {@code array}
150 * Returns the index of the last appearance of the value {@code target} in
151 * {@code array}.
153 * @param array an array of {@code long} values, possibly empty
154 * @param target a primitive {@code long} value
155 * @return the greatest index {@code i} for which {@code array[i] == target},
156 * or {@code -1} if no such index exists.
174 * Returns the least value present in {@code array}.
176 * @param array a <i>nonempty</i> array of {@code long} values
177 * @return the value present in {@code array} that is less than or equal to
179 * @throws IllegalArgumentException if {@code array} is empty
193 * Returns the greatest value present in {@code array}.
195 * @param array a <i>nonempty</i> array of {@code long} values
196 * @return the value present in {@code array} that is greater than or equal to
198 * @throws IllegalArgumentException if {@code array} is empty
213 * For example, {@code concat(new long[] {a, b}, new long[] {}, new
214 * long[] {c}} returns the array {@code {a, b, c}}.
216 * @param arrays zero or more {@code long} arrays
235 * Returns a big-endian representation of {@code value} in an 8-element byte
236 * array; equivalent to {@code ByteBuffer.allocate(8).putLong(value).array()}.
237 * For example, the input value {@code 0x1213141516171819L} would yield the
238 * byte array {@code {0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19}}.
261 * Returns the {@code long} value whose big-endian representation is
262 * stored in the first 8 bytes of {@code bytes}; equivalent to {@code
264 * {@code {0x12, 0x13, 0x14, 0x15, 0x16, 0x17, 0x18, 0x19}} would yield the
265 * {@code long} value {@code 0x1213141516171819L}.
272 * @throws IllegalArgumentException if {@code bytes} has fewer than 8
290 * Returns an array containing the same values as {@code array}, but
291 * guaranteed to be of a specified minimum length. If {@code array} already
292 * has a length of at least {@code minLength}, it is returned directly.
293 * Otherwise, a new array of size {@code minLength + padding} is returned,
294 * containing the values of {@code array}, and zeroes in the remaining places.
300 * @throws IllegalArgumentException if {@code minLength} or {@code padding} is
302 * @return an array containing the values of {@code array}, with guaranteed
303 * minimum length {@code minLength}
322 * Returns a string containing the supplied {@code long} values separated
323 * by {@code separator}. For example, {@code join("-", 1L, 2L, 3L)} returns
324 * the string {@code "1-2-3"}.
328 * @param array an array of {@code long} values, possibly empty
346 * Returns a comparator that compares two {@code long} arrays
351 * {@code [] < [1L] < [1L, 2L] < [2L]}.
381 * Copies a collection of {@code Long} instances into a new array of
382 * primitive {@code long} values.
384 * <p>Elements are copied from the argument collection as if by {@code
388 * @param collection a collection of {@code Long} objects
389 * @return an array containing the same values as {@code collection}, in the
391 * @throws NullPointerException if {@code collection} or any of its elements
411 * but any attempt to set a value to {@code null} will result in a {@link
415 * {@code Long} objects written to or read from it. For example, whether
416 * {@code list.get(0) == list.get(0)} is true for the returned list is