/** * Return a CompressedData object from a tagged object. * * @param ato the tagged object holding the object we want. * @param isExplicit true if the object is meant to be explicitly * tagged false otherwise. * @exception IllegalArgumentException if the object held by the * tagged object cannot be converted. */ public static CompressedData getInstance( ASN1TaggedObject ato, boolean isExplicit) { return getInstance(ASN1Sequence.getInstance(ato, isExplicit)); }
/** * Return a CompressedData object from the given object. * <p> * Accepted inputs: * <ul> * <li> null → null * <li> {@link CompressedData} object * <li> {@link org.bouncycastle.asn1.ASN1Sequence#getInstance(java.lang.Object) ASN1Sequence} input formats with CompressedData structure inside * </ul> * * @param obj the object we want converted. * @exception IllegalArgumentException if the object cannot be converted. */ public static CompressedData getInstance( Object obj) { if (obj instanceof CompressedData) { return (CompressedData)obj; } if (obj != null) { return new CompressedData(ASN1Sequence.getInstance(obj)); } return null; }
/** * Return a CompressedData object from the given object. * <p> * Accepted inputs: * <ul> * <li> null → null * <li> {@link CompressedData} object * <li> {@link org.bouncycastle.asn1.ASN1Sequence#getInstance(java.lang.Object) ASN1Sequence} input formats with CompressedData structure inside * </ul> * * @param obj the object we want converted. * @exception IllegalArgumentException if the object cannot be converted. */ public static CompressedData getInstance( Object obj) { if (obj instanceof CompressedData) { return (CompressedData)obj; } if (obj != null) { return new CompressedData(ASN1Sequence.getInstance(obj)); } return null; }
/** * Return a CompressedData object from a tagged object. * * @param ato the tagged object holding the object we want. * @param isExplicit true if the object is meant to be explicitly * tagged false otherwise. * @exception IllegalArgumentException if the object held by the * tagged object cannot be converted. */ public static CompressedData getInstance( ASN1TaggedObject ato, boolean isExplicit) { return getInstance(ASN1Sequence.getInstance(ato, isExplicit)); }