public void writeObject(ASN1Encodable obj) throws IOException { if (obj != null) { obj.toASN1Primitive().encode(this); } else { throw new IOException("null object detected"); } }
public boolean equals(Object o) { if (this == o) { return true; } if (!(o instanceof ASN1Encodable)) { return false; } ASN1Encodable other = (ASN1Encodable) o; return this.toASN1Primitive().equals(other.toASN1Primitive()); }