code: public boolean delete(String src, boolean recursive) throws IOException {
      checkOpen();
      clearFileStatusCache();
      
      try {
        return namenode.delete(src, recursive);
      } catch(RemoteException re) {
        throw re.unwrapRemoteException(AccessControlException.class);
      }
    }
docs: delete file or directory.
  delete contents of the directory if non empty and recursive
  set to true