code: public void setDataHomeFile(File dir) {
          if (dir != null) {
              try {
                  // Switch to canonical for more detailed error messages.
                  dir = dir.getCanonicalFile();
              } catch (IOException e) {
              }
          }
          mDataHome = dir;
      }
docs: By default, data files are stored relative to the environment home. Call
  this method to override. For BDBRepositories that are log files only,
  this configuration is ignored.