code: public static SQLDatabase openSQLDatabase(File dbFile, KeyProvider provider) throws IOException, SQLException {
          Misc.checkNotNull(dbFile, "dbFile");
          File dbDirectory = dbFile.getParentFile();
          if (!dbDirectory.mkdirs()){
              logger.info(String.format(Locale.ENGLISH, "Did not create directories for path: %s directories may already exist", dbFile));
          }
          Misc.checkArgument(dbDirectory.isDirectory(), "Input path is not a valid directory");
          Misc.checkArgument(dbDirectory.canWrite(), "Datastore directory is not writable");
          return internalOpenSQLDatabase(dbFile, provider);
      }
docs: <p>
  Open or create a database file, and return a connection to it, optionally backed by a
  SQLCipher enabled database.
  </p>
  <p>
  If the database file does not exist, it will be created, and any intermediate directories
  will be created as necessary.
  </p>
  @param dbFile full file path of the db file
  @param provider Key provider object storing the SQLCipher key
  Supply a NullKeyProvider to use a non-encrypted database.
  @return {@code SQLDatabase} for the given filename
  @throws IOException if the file cannot be opened, or the database files or its intermediate
  directories cannot be created.
  @throws SQLException if the database cannot be opened.