if (addresses.length == 1) { return addresses[0].toString(); } else { StringBuffer buf = new StringBuffer(addresses.length * 32); buf.append(addresses[0].toString()); for (int i = 1; i < addresses.length; i++) { buf.append(", "); buf.append(addresses[i].toString()); }
String p = getEncodedPersonal(); if (p == null) { return formatAddress(address); } else { StringBuffer buf = new StringBuffer(p.length() + 8 + address.length() + 3); buf.append(AddressParser.quoteString(p)); buf.append(" <").append(address).append(">");
    public static String toString(Address[] addresses) {        if (addresses == null || addresses.length == 0) {            return null;        }        if (addresses.length == 1) {            return addresses[0].toString();        } else {            StringBuffer buf = new StringBuffer(addresses.length * 32);            buf.append(addresses[0].toString());            for (int i = 1; i < addresses.length; i++) {                buf.append(", ");                buf.append(addresses[i].toString());            }            return buf.toString();        }    }