public LocalRepository(String name,File root) throws RepositoryException {
  super(name,null,null);
  this.root=root;
  mkdir();
  if (!root.isDirectory()) {
    throw new RepositoryException("Folder '" + root + "' is not a directory.");
  }
  if (!root.canWrite()) {
    throw new RepositoryException("Folder '" + root + "' is not writable.");
  }
  setRepository(this);
}

public LocalRepository ( String name , File root ) throws RepositoryException { super ( name , null , null ) ; this . root = root ; mkdir ( ) ; if ( ! root . isDirectory ( ) ) { throw new RepositoryException ( "Folder '" + root + "' is not a directory." ) ; } if ( ! root . canWrite ( ) ) { throw new RepositoryException ( "Folder '" + root + "' is not writable." ) ; } setRepository ( this ) ; }
creates a file - based repository in the given location .
