List of utility methods to do List Combine
String | combine(final List> r, final char sep) Combine elements from a list using separator. StringBuilder buf = new StringBuilder(r.get(0).toString()); for (int i = 1; i < r.size(); i++) { buf.append(sep); buf.append(r.get(i)); return buf.toString(); |
byte[] | combine(final List Combines a list of byte arrays into one big byte array. int totalSize = 0; for (final byte[] dataPart : dataChunks) { totalSize += dataPart.length; final byte[] data = new byte[totalSize]; int index = 0; for (final byte[] dataPart : dataChunks) { System.arraycopy(dataPart, 0, data, index, dataPart.length); ... |
List | combine(final List combine final List<T> combinedList = new ArrayList<T>(); combinedList.addAll(list); combinedList.addAll(list2); return combinedList; |
List | combine(int sign, List combine List<Integer> bits = new ArrayList<>(); bits.add(sign); bits.addAll(exponentBits); bits.addAll(mantissaBits); return bits; |
String | combine(List r, char sep) combine StringBuilder buf = new StringBuilder(r.get(0).toString()); for (int i = 1; i < r.size(); i++) { buf.append(sep); buf.append(r.get(i)); return buf.toString(); |
List | combine(List
Combines a bunch of lists inside of a large list. List<T> majorList = new ArrayList<T>(); lists.forEach(majorList::addAll); return majorList; |
String | combine(List combine final StringBuffer Combined = new StringBuffer(""); if (commands != null) for (int commandIndex = startAt; commandIndex < endAt; commandIndex++) Combined.append(commands.get(commandIndex) + " "); return Combined.toString().trim(); |
String | combine(List combine StringBuilder buf = new StringBuilder(); if (strlist.isEmpty() == false) { for (int i = 0; i < strlist.size(); i++) { String elem = strlist.get(i); buf.append(elem); if (i != strlist.size() - 1) buf.append(delimiter); return buf.toString(); |
String | combine(List combine StringBuffer sb = new StringBuffer(); boolean isFirst = true; for (String token : tokens) { if (isFirst) isFirst = false; else sb.append(separator); sb.append(token); ... |
List | combine(List combine List<T> list = new ArrayList<T>(); for (T t : a) list.add(t); for (T t : b) list.add(t); return list; |