TransportSecurityOptions { public static TransportSecurityOptions fromJsonFile(Path file) { try (InputStream in = Files.newInputStream(file)) { return new TransportSecurityOptionsJsonSerializer().deserialize(in); } catch (IOException e) { throw new UncheckedIOException(e); } } private  TransportSecurityOptions(Builder builder); Optional<Path> getPrivateKeyFile(); Optional<Path> getCertificatesFile(); Optional<Path> getCaCertificatesFile(); Optional<AuthorizedPeers> getAuthorizedPeers(); List<String> getAcceptedCiphers(); boolean isHostnameValidationDisabled(); static TransportSecurityOptions fromJsonFile(Path file); static TransportSecurityOptions fromJson(String json); String toJson(); void toJsonFile(Path file); @Override String toString(); @Override boolean equals(Object o); @Override int hashCode();  }
@Test public void can_read_options_from_json_file() { TransportSecurityOptions actualOptions = TransportSecurityOptions.fromJsonFile(TEST_CONFIG_FILE); assertEquals(OPTIONS, actualOptions); }