X9ECParametersHolder.cs 586 B

12345678910111213141516171819202122232425262728
  1. #if !BESTHTTP_DISABLE_ALTERNATE_SSL && (!UNITY_WEBGL || UNITY_EDITOR)
  2. namespace Org.BouncyCastle.Asn1.X9
  3. {
  4. public abstract class X9ECParametersHolder
  5. {
  6. private X9ECParameters parameters;
  7. public X9ECParameters Parameters
  8. {
  9. get
  10. {
  11. lock (this)
  12. {
  13. if (parameters == null)
  14. {
  15. parameters = CreateParameters();
  16. }
  17. return parameters;
  18. }
  19. }
  20. }
  21. protected abstract X9ECParameters CreateParameters();
  22. }
  23. }
  24. #endif