code: private void deleteFromVfs(CmsResource res) throws CmsException {
  
          String resourcename = m_cms.getSitePath(res);
  
          m_report.print(
              org.opencms.report.Messages.get().container(
                  org.opencms.report.Messages.RPT_SUCCESSION_1,
                  String.valueOf(m_count++)),
              I_CmsReport.FORMAT_NOTE);
          if (res.isFile()) {
              m_report.print(Messages.get().container(Messages.RPT_DEL_FILE_0), I_CmsReport.FORMAT_NOTE);
          } else {
              m_report.print(Messages.get().container(Messages.RPT_DEL_FOLDER_0), I_CmsReport.FORMAT_NOTE);
          }
          m_report.print(
              org.opencms.report.Messages.get().container(org.opencms.report.Messages.RPT_ARGUMENT_1, resourcename));
          m_report.print(org.opencms.report.Messages.get().container(org.opencms.report.Messages.RPT_DOTS_0));
  
          // lock the file in the VFS, so that it can be updated
          m_cms.lockResource(resourcename);
          m_cms.deleteResource(resourcename, CmsResource.DELETE_PRESERVE_SIBLINGS);
          // Remove it from the sync list
          m_syncList.remove(translate(resourcename));
  
          m_report.println(
              org.opencms.report.Messages.get().container(org.opencms.report.Messages.RPT_OK_0),
              I_CmsReport.FORMAT_OK);
      }
docs: Deletes a resource in the VFS and updates the synchronisation lists.<p>
  
  @param res The resource to be deleted
  
  @throws CmsException if something goes wrong