Lines Matching refs:array
85 * Returns the least value present in {@code array}.
87 * @param array a <i>nonempty</i> array of {@code byte} values
88 * @return the value present in {@code array} that is less than or equal to
89 * every other value in the array
90 * @throws IllegalArgumentException if {@code array} is empty
92 public static byte min(byte... array) {
93 checkArgument(array.length > 0);
94 byte min = array[0];
95 for (int i = 1; i < array.length; i++) {
96 if (array[i] < min) {
97 min = array[i];
104 * Returns the greatest value present in {@code array}.
106 * @param array a <i>nonempty</i> array of {@code byte} values
107 * @return the value present in {@code array} that is greater than or equal to
108 * every other value in the array
109 * @throws IllegalArgumentException if {@code array} is empty
111 public static byte max(byte... array) {
112 checkArgument(array.length > 0);
113 byte max = array[0];
114 for (int i = 1; i < array.length; i++) {
115 if (array[i] > max) {
116 max = array[i];
129 * @param array an array of {@code byte} values, possibly empty
131 public static String join(String separator, byte... array) {
133 if (array.length == 0) {
138 StringBuilder builder = new StringBuilder(array.length * 5);
139 builder.append(array[0]);
140 for (int i = 1; i < array.length; i++) {
141 builder.append(separator).append(array[i]);
150 * prefix, or when one array is a prefix of the other, treats the shorter
151 * array as the lesser. For example, {@code [] < [0x01] < [0x01, 0x80] <