Bouncy Castle Cryptography Library 1.85

org.bouncycastle.cms
Class CMSContentInfoParser

java.lang.Object
  extended byorg.bouncycastle.cms.CMSContentInfoParser
Direct Known Subclasses:
CMSAuthenticatedDataParser, CMSAuthEnvelopedDataParser, CMSCompressedDataParser, CMSEnvelopedDataParser, CMSSignedDataParser, CMSTimeStampedDataParser

public class CMSContentInfoParser
extends java.lang.Object


Field Summary
protected  org.bouncycastle.asn1.cms.ContentInfoParser _contentInfo
           
protected  java.io.InputStream _data
           
 
Constructor Summary
protected CMSContentInfoParser(java.io.InputStream data)
           
 
Method Summary
 void close()
          Close the underlying data stream.
 boolean isBEREncoded()
          Return true if the outer ContentInfo SEQUENCE of the stream used the indefinite-length (BER) method, false if it carried a definite length (DL/DER).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_contentInfo

protected org.bouncycastle.asn1.cms.ContentInfoParser _contentInfo

_data

protected java.io.InputStream _data
Constructor Detail

CMSContentInfoParser

protected CMSContentInfoParser(java.io.InputStream data)
                        throws CMSException
Method Detail

isBEREncoded

public boolean isBEREncoded()
Return true if the outer ContentInfo SEQUENCE of the stream used the indefinite-length (BER) method, false if it carried a definite length (DL/DER). Wire encodings that need to be reproduced or canonicalised exactly (e.g. ETSI archive-time-stamp imprints over the original coding) can use this to learn the original framing without a second pass over the data (see github #1983).

Returns:
true for an indefinite-length (BER) ContentInfo, false otherwise.

close

public void close()
           throws java.io.IOException
Close the underlying data stream.

Throws:
java.io.IOException - if the close fails.

Bouncy Castle Cryptography Library 1.85