@Test void testGetBundleForTrustDomain() { try { X509Bundle bundle = x509Source.getBundleForTrustDomain(TrustDomain.of("example.org")); assertNotNull(bundle); assertEquals(TrustDomain.of("example.org"), bundle.getTrustDomain()); } catch (BundleNotFoundException e) { fail(e); } }
@Override public X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain) throws BundleNotFoundException { if (isClosed()) { throw new IllegalStateException("X.509 bundle source is closed"); } return bundles.getBundleForTrustDomain(trustDomain); }
DefaultX509Source implements X509Source { @Override public X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain) throws BundleNotFoundException { if (isClosed()) { throw new IllegalStateException("X.509 bundle source is closed"); } return bundles.getBundleForTrustDomain(trustDomain); } }
DefaultX509Source implements X509Source { @Override public X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain) throws BundleNotFoundException { if (isClosed()) { throw new IllegalStateException("X.509 bundle source is closed"); } return bundles.getBundleForTrustDomain(trustDomain); } private  DefaultX509Source(final Function<List<X509Svid>, X509Svid> svidPicker, final WorkloadApiClient workloadApiClient); }
DefaultX509Source implements X509Source { @Override public X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain) throws BundleNotFoundException { if (isClosed()) { throw new IllegalStateException("X.509 bundle source is closed"); } return bundles.getBundleForTrustDomain(trustDomain); } private  DefaultX509Source(final Function<List<X509Svid>, X509Svid> svidPicker, final WorkloadApiClient workloadApiClient); static DefaultX509Source newSource(); static DefaultX509Source newSource(@NonNull final X509SourceOptions options); @Override X509Svid getX509Svid(); @Override X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain); @SneakyThrows @Override void close(); }
DefaultX509Source implements X509Source { @Override public X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain) throws BundleNotFoundException { if (isClosed()) { throw new IllegalStateException("X.509 bundle source is closed"); } return bundles.getBundleForTrustDomain(trustDomain); } private  DefaultX509Source(final Function<List<X509Svid>, X509Svid> svidPicker, final WorkloadApiClient workloadApiClient); static DefaultX509Source newSource(); static DefaultX509Source newSource(@NonNull final X509SourceOptions options); @Override X509Svid getX509Svid(); @Override X509Bundle getBundleForTrustDomain(@NonNull final TrustDomain trustDomain); @SneakyThrows @Override void close();  }