Org.BouncyCastle.Asn1.Cms.ContentInfo.ContentInfo C# (CSharp) Method

ContentInfo() private method

private ContentInfo ( Asn1Sequence seq ) : System
seq Org.BouncyCastle.Asn1.Asn1Sequence
return System
        private ContentInfo(
            Asn1Sequence seq)
        {
            if (seq.Count < 1 || seq.Count > 2)
                throw new ArgumentException("Bad sequence size: " + seq.Count, "seq");

            contentType = (DerObjectIdentifier) seq[0];

            if (seq.Count > 1)
            {
                Asn1TaggedObject tagged = (Asn1TaggedObject) seq[1];
                if (!tagged.IsExplicit() || tagged.TagNo != 0)
                    throw new ArgumentException("Bad tag for 'content'", "seq");

                content = tagged.GetObject();
            }
        }

Same methods

ContentInfo::ContentInfo ( DerObjectIdentifier contentType, Asn1Encodable content ) : System