PskEcDhClientKeyExchangeMessage extends ECDHClientKeyExchangeMessage { @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("PskEcDhClientKeyExchangeMessage:"); sb.append("\n PSKIdentity Length: "); if (identityLength != null && identityLength.getValue() != null) { sb.append(identityLength.getValue()); } else { sb.append("null"); } sb.append("\n PSKIdentity: "); if (identity != null) { sb.append(ArrayConverter.bytesToHexString(identity.getValue())); } else { sb.append("null"); } return sb.toString(); } PskEcDhClientKeyExchangeMessage(Config tlsConfig);  PskEcDhClientKeyExchangeMessage(); @Override String toString(); ModifiableByteArray getIdentity(); void setIdentity(ModifiableByteArray identity); void setIdentity(byte[] identity); ModifiableInteger getIdentityLength(); void setIdentityLength(ModifiableInteger identityLength); void setIdentityLength(Integer identityLength); @Override ProtocolMessageHandler getHandler(TlsContext context); @Override String toCompactString();  }
@Test public void testToString() { StringBuilder sb = new StringBuilder(); sb.append("PskEcDhClientKeyExchangeMessage:"); sb.append("\n PSKIdentity Length: ").append("null"); sb.append("\n PSKIdentity: ").append("null"); assertEquals(message.toString(), sb.toString()); }