class TrustAnchorLocator {

    public static TrustAnchorLocator fromFile(File file) throws TrustAnchorExtractorException {
        try {
            String contents = Files.toString(file, Charsets.UTF_8);
            String trimmed = contents.trim();
            if (looksLikeUri(trimmed)) {
                return readStandardTrustAnchorLocator(file.getName(), trimmed);
            } else {
                return readExtendedTrustAnchorLocator(trimmed);
            }
        } catch (IllegalArgumentException | URISyntaxException | IOException e) {
            throw new TrustAnchorExtractorException("failed to load trust anchor locator " + file + ": " + e.getMessage(), e);
        }
    }

    public  TrustAnchorLocator(String caName, List<URI> location, String publicKeyInfo, List<URI> prefetchUris);

}