PopoDecKeyRespContent.cs 990 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
  2. #pragma warning disable
  3. namespace Best.HTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cmp
  4. {
  5. public class PopoDecKeyRespContent
  6. : Asn1Encodable
  7. {
  8. public static PopoDecKeyRespContent GetInstance(object obj)
  9. {
  10. if (obj is PopoDecKeyRespContent popoDecKeyRespContent)
  11. return popoDecKeyRespContent;
  12. if (obj != null)
  13. return new PopoDecKeyRespContent(Asn1Sequence.GetInstance(obj));
  14. return null;
  15. }
  16. private readonly Asn1Sequence m_content;
  17. private PopoDecKeyRespContent(Asn1Sequence seq)
  18. {
  19. m_content = seq;
  20. }
  21. public virtual DerInteger[] ToIntegerArray()
  22. {
  23. return m_content.MapElements(DerInteger.GetInstance);
  24. }
  25. /**
  26. * <pre>
  27. * PopoDecKeyRespContent ::= SEQUENCE OF INTEGER
  28. * </pre>
  29. * @return a basic ASN.1 object representation.
  30. */
  31. public override Asn1Object ToAsn1Object()
  32. {
  33. return m_content;
  34. }
  35. }
  36. }
  37. #pragma warning restore
  38. #endif