private void withCalculatedCertificateStrategy(ThrowableConsumer<? super UntrustedCertificateStrategyWithReason, ? extends CertificateException> block) throws CertificateException {
    UntrustedCertificateStrategy initialStrategy = myUntrustedCertificateStrategy.get();
    if (initialStrategy != null) {
      block.consume(new UntrustedCertificateStrategyWithReason(initialStrategy, null));
    }
    else {
      UntrustedCertificateStrategyWithReason strategy = ApplicationManager.getApplication().getService(InitialUntrustedCertificateStrategyProvider.class).getStrategy();
      block.consume(strategy);
    }
  }
private void withCalculatedCertificateStrategy(ThrowableConsumer<? super UntrustedCertificateStrategyWithReason, ? extends CertificateException> block)