src/java.base/share/classes/java/security/cert/TrustAnchor.java

Print this page
rev 10537 : 8055723[core]: Replace concat String to append in StringBuilder parameters
Contributed-by: Otavio Santana <otaviojava@java.net>

*** 318,333 **** */ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("[\n"); if (pubKey != null) { ! sb.append(" Trusted CA Public Key: " + pubKey.toString() + "\n"); ! sb.append(" Trusted CA Issuer Name: " ! + String.valueOf(caName) + "\n"); } else { ! sb.append(" Trusted CA cert: " + trustedCert.toString() + "\n"); } - if (nc != null) - sb.append(" Name Constraints: " + nc.toString() + "\n"); return sb.toString(); } } --- 318,337 ---- */ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("[\n"); if (pubKey != null) { ! sb.append(" Trusted CA Public Key: ").append(pubKey) ! .append('\n'); ! sb.append(" Trusted CA Issuer Name: ") ! .append(caName).append('\n'); } else { ! sb.append(" Trusted CA cert: ").append(trustedCert) ! .append('\n'); ! } ! if (nc != null) { ! sb.append(" Name Constraints: ").append(nc) ! .append('\n'); } return sb.toString(); } }