CryptoContainer { public static boolean isContainerFileName(String fileName) { return getFileExtension(fileName).toLowerCase(Locale.US).equals(EXTENSION); }  abstract File file(); abstract ImmutableList<File> dataFiles(); abstract ImmutableList<Certificate> recipients(); abstract boolean decrypted(); CryptoContainer decrypt(DecryptToken decryptToken, Certificate authCertificate,
                                   String pin1, File dataFilesDirectory); @WorkerThread static CryptoContainer open(File file); @WorkerThread static CryptoContainer encrypt(ImmutableList<File> dataFiles,
                                          ImmutableList<Certificate> recipients, File file); static boolean isContainerFileName(String fileName); static String createContainerFileName(String fileName);  }
@Test public void isContainerFileName_cdocExtension() { assertThat(CryptoContainer.isContainerFileName("some-file.cdoc")) .isTrue(); }
@Test public void isContainerFileName_cdocExtensionCaseSensitive() { assertThat(CryptoContainer.isContainerFileName("some-file.cDoC")) .isTrue(); }
@Test public void isContainerFileName_otherExtension() { assertThat(CryptoContainer.isContainerFileName("some-file.bdoc")) .isFalse(); }