SimpleAttributeTableGenerator.cs 750 B

12345678910111213141516171819202122232425262728293031
  1. #if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
  2. #pragma warning disable
  3. using System;
  4. using System.Collections.Generic;
  5. using Best.HTTP.SecureProtocol.Org.BouncyCastle.Asn1.Cms;
  6. namespace Best.HTTP.SecureProtocol.Org.BouncyCastle.Cms
  7. {
  8. /**
  9. * Basic generator that just returns a preconstructed attribute table
  10. */
  11. public class SimpleAttributeTableGenerator
  12. : CmsAttributeTableGenerator
  13. {
  14. private readonly AttributeTable attributes;
  15. public SimpleAttributeTableGenerator(
  16. AttributeTable attributes)
  17. {
  18. this.attributes = attributes;
  19. }
  20. public virtual AttributeTable GetAttributes(IDictionary<CmsAttributeTableParameter, object> parameters)
  21. {
  22. return attributes;
  23. }
  24. }
  25. }
  26. #pragma warning restore
  27. #endif