亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? indexfiledeleter.java

?? lucene-2.4.0 是一個全文收索的工具包
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
          !fileName.equals(IndexFileNames.SEGMENTS_GEN)) {        // Unreferenced file, so remove it        if (infoStream != null) {          message("refresh [prefix=" + segmentName + "]: removing newly created unreferenced file \"" + fileName + "\"");        }        deleteFile(fileName);      }    }  }  public void refresh() throws IOException {    refresh(null);  }  public void close() throws IOException {    deletePendingFiles();  }  private void deletePendingFiles() throws IOException {    if (deletable != null) {      List oldDeletable = deletable;      deletable = null;      int size = oldDeletable.size();      for(int i=0;i<size;i++) {        if (infoStream != null)          message("delete pending file " + oldDeletable.get(i));        deleteFile((String) oldDeletable.get(i));      }    }  }  /**   * For definition of "check point" see IndexWriter comments:   * "Clarification: Check Points (and commits)".   *    * Writer calls this when it has made a "consistent   * change" to the index, meaning new files are written to   * the index and the in-memory SegmentInfos have been   * modified to point to those files.   *   * This may or may not be a commit (segments_N may or may   * not have been written).   *   * We simply incref the files referenced by the new   * SegmentInfos and decref the files we had previously   * seen (if any).   *   * If this is a commit, we also call the policy to give it   * a chance to remove other commits.  If any commits are   * removed, we decref their files as well.   */  public void checkpoint(SegmentInfos segmentInfos, boolean isCommit) throws IOException {    if (infoStream != null) {      message("now checkpoint \"" + segmentInfos.getCurrentSegmentFileName() + "\" [" + segmentInfos.size() + " segments " + "; isCommit = " + isCommit + "]");    }    // Try again now to delete any previously un-deletable    // files (because they were in use, on Windows):    deletePendingFiles();    // Incref the files:    incRef(segmentInfos, isCommit);    if (isCommit) {      // Append to our commits list:      commits.add(new CommitPoint(commitsToDelete, directory, segmentInfos));      // Tell policy so it can remove commits:      policy.onCommit(commits);      // Decref files for commits that were deleted by the policy:      deleteCommits();    } else {      final List docWriterFiles;      if (docWriter != null) {        docWriterFiles = docWriter.openFiles();        if (docWriterFiles != null)          // We must incRef these files before decRef'ing          // last files to make sure we don't accidentally          // delete them:          incRef(docWriterFiles);      } else        docWriterFiles = null;      // DecRef old files from the last checkpoint, if any:      int size = lastFiles.size();      if (size > 0) {        for(int i=0;i<size;i++)          decRef((List) lastFiles.get(i));        lastFiles.clear();      }      // Save files so we can decr on next checkpoint/commit:      size = segmentInfos.size();      for(int i=0;i<size;i++) {        SegmentInfo segmentInfo = segmentInfos.info(i);        if (segmentInfo.dir == directory) {          lastFiles.add(segmentInfo.files());        }      }      if (docWriterFiles != null)        lastFiles.add(docWriterFiles);    }  }  void incRef(SegmentInfos segmentInfos, boolean isCommit) throws IOException {    int size = segmentInfos.size();    for(int i=0;i<size;i++) {      SegmentInfo segmentInfo = segmentInfos.info(i);      if (segmentInfo.dir == directory) {        incRef(segmentInfo.files());      }    }    if (isCommit) {      // Since this is a commit point, also incref its      // segments_N file:      getRefCount(segmentInfos.getCurrentSegmentFileName()).IncRef();    }  }  void incRef(List files) throws IOException {    int size = files.size();    for(int i=0;i<size;i++) {      String fileName = (String) files.get(i);      RefCount rc = getRefCount(fileName);      if (infoStream != null && VERBOSE_REF_COUNTS) {        message("  IncRef \"" + fileName + "\": pre-incr count is " + rc.count);      }      rc.IncRef();    }  }  void decRef(List files) throws IOException {    int size = files.size();    for(int i=0;i<size;i++) {      decRef((String) files.get(i));    }  }  void decRef(String fileName) throws IOException {    RefCount rc = getRefCount(fileName);    if (infoStream != null && VERBOSE_REF_COUNTS) {      message("  DecRef \"" + fileName + "\": pre-decr count is " + rc.count);    }    if (0 == rc.DecRef()) {      // This file is no longer referenced by any past      // commit points nor by the in-memory SegmentInfos:      deleteFile(fileName);      refCounts.remove(fileName);    }  }  void decRef(SegmentInfos segmentInfos) throws IOException {    final int size = segmentInfos.size();    for(int i=0;i<size;i++) {      SegmentInfo segmentInfo = segmentInfos.info(i);      if (segmentInfo.dir == directory) {        decRef(segmentInfo.files());      }    }  }  private RefCount getRefCount(String fileName) {    RefCount rc;    if (!refCounts.containsKey(fileName)) {      rc = new RefCount();      refCounts.put(fileName, rc);    } else {      rc = (RefCount) refCounts.get(fileName);    }    return rc;  }  void deleteFiles(List files) throws IOException {    final int size = files.size();    for(int i=0;i<size;i++)      deleteFile((String) files.get(i));  }  /** Delets the specified files, but only if they are new   *  (have not yet been incref'd). */  void deleteNewFiles(Collection files) throws IOException {    final Iterator it = files.iterator();    while(it.hasNext()) {      final String fileName = (String) it.next();      if (!refCounts.containsKey(fileName))        deleteFile(fileName);    }  }  void deleteFile(String fileName)       throws IOException {    try {      if (infoStream != null) {        message("delete \"" + fileName + "\"");      }      directory.deleteFile(fileName);    } catch (IOException e) {			  // if delete fails      if (directory.fileExists(fileName)) {        // Some operating systems (e.g. Windows) don't        // permit a file to be deleted while it is opened        // for read (e.g. by another process or thread). So        // we assume that when a delete fails it is because        // the file is open in another process, and queue        // the file for subsequent deletion.        if (infoStream != null) {          message("IndexFileDeleter: unable to remove file \"" + fileName + "\": " + e.toString() + "; Will re-try later.");        }        if (deletable == null) {          deletable = new ArrayList();        }        deletable.add(fileName);                  // add to deletable      }    }  }  /**   * Tracks the reference count for a single index file:   */  final private static class RefCount {    int count;    public int IncRef() {      return ++count;    }    public int DecRef() {      assert count > 0;      return --count;    }  }  /**   * Holds details for each commit point.  This class is   * also passed to the deletion policy.  Note: this class   * has a natural ordering that is inconsistent with   * equals.   */  final private static class CommitPoint extends IndexCommit implements Comparable {    long gen;    List files;    String segmentsFileName;    boolean deleted;    Directory directory;    Collection commitsToDelete;    long version;    long generation;    final boolean isOptimized;    public CommitPoint(Collection commitsToDelete, Directory directory, SegmentInfos segmentInfos) throws IOException {      this.directory = directory;      this.commitsToDelete = commitsToDelete;      segmentsFileName = segmentInfos.getCurrentSegmentFileName();      version = segmentInfos.getVersion();      generation = segmentInfos.getGeneration();      int size = segmentInfos.size();      files = new ArrayList(size);      files.add(segmentsFileName);      gen = segmentInfos.getGeneration();      for(int i=0;i<size;i++) {        SegmentInfo segmentInfo = segmentInfos.info(i);        if (segmentInfo.dir == directory) {          files.addAll(segmentInfo.files());        }      }       isOptimized = segmentInfos.size() == 1 && !segmentInfos.info(0).hasDeletions();    }    public boolean isOptimized() {      return isOptimized;    }    public String getSegmentsFileName() {      return segmentsFileName;    }    public Collection getFileNames() throws IOException {      return Collections.unmodifiableCollection(files);    }    public Directory getDirectory() {      return directory;    }    public long getVersion() {      return version;    }    public long getGeneration() {      return generation;    }    /**     * Called only be the deletion policy, to remove this     * commit point from the index.     */    public void delete() {      if (!deleted) {        deleted = true;        commitsToDelete.add(this);      }    }    public boolean isDeleted() {      return deleted;    }    public int compareTo(Object obj) {      CommitPoint commit = (CommitPoint) obj;      if (gen < commit.gen) {        return -1;      } else if (gen > commit.gen) {        return 1;      } else {        return 0;      }    }  }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品一区二区在线免费观看| 久久电影网电视剧免费观看| 91精品国产麻豆| 国产成a人亚洲| 亚洲国产另类av| 亚洲天堂免费看| 欧美精品一二三四| 99免费精品视频| 免费人成网站在线观看欧美高清| 国产精品视频一二| 日韩欧美激情在线| 91毛片在线观看| 国产精品一区三区| 精品写真视频在线观看| 亚洲一区二区三区四区五区中文| 亚洲欧美另类在线| 亚洲综合色视频| 久久欧美一区二区| 91视频精品在这里| 亚洲成人tv网| 国产精品拍天天在线| www精品美女久久久tv| 精品对白一区国产伦| 亚洲视频一区二区在线| 日韩欧美一级在线播放| 日产国产高清一区二区三区| 久久日一线二线三线suv| 国产成人免费av在线| 日韩理论片中文av| 欧美色图在线观看| 美日韩一级片在线观看| 国产精品网站导航| 日韩精品免费专区| 一区二区免费在线| 一区二区三区高清不卡| 亚洲国产欧美一区二区三区丁香婷| 亚洲视频综合在线| 亚洲精品综合在线| 亚洲欧美一区二区三区孕妇| 中文字幕在线不卡一区| 国产精品久久久久久久裸模| 国产亚洲欧洲一区高清在线观看| 国产欧美一区二区精品性| 欧美韩国日本不卡| 国产欧美日韩视频一区二区| 亚洲综合在线观看视频| 国产精品动漫网站| 亚洲精品写真福利| 亚洲国产日日夜夜| 韩日av一区二区| 懂色av中文一区二区三区| 99精品国产一区二区三区不卡| 色婷婷精品久久二区二区蜜臀av | 久久久精品天堂| 亚洲日本中文字幕区| 国产精品国产三级国产aⅴ入口 | 亚洲午夜在线观看视频在线| 亚洲国产精品精华液网站| 国产美女久久久久| 欧美国产精品久久| a美女胸又www黄视频久久| 在线电影院国产精品| 不卡电影一区二区三区| 麻豆成人久久精品二区三区小说| 亚洲人成精品久久久久久 | 国产精品美女久久久久久久久 | 日本韩国一区二区三区视频| 欧美午夜寂寞影院| 久久久噜噜噜久久人人看| 亚洲男人的天堂在线aⅴ视频| 午夜不卡av在线| 国产精品1区2区3区| 一本大道av一区二区在线播放 | 久久se这里有精品| 国产精品77777| 欧美视频日韩视频| 国产精品无码永久免费888| 婷婷成人综合网| 欧美三级日韩在线| 久久久另类综合| 日韩精品亚洲一区二区三区免费| 国产成人亚洲精品狼色在线 | 91精品国产综合久久精品app | 在线不卡中文字幕播放| 欧美成人vps| 亚洲国产aⅴ天堂久久| 在线免费观看不卡av| 亚洲国产成人av| 国产成人午夜视频| 欧美伊人久久久久久午夜久久久久| 国产精品天美传媒| 欧美高清视频不卡网| av亚洲精华国产精华| 日本乱人伦一区| 国产91精品一区二区麻豆网站 | 3d成人h动漫网站入口| 色婷婷亚洲综合| 99精品视频在线免费观看| 国产91色综合久久免费分享| 蜜臀91精品一区二区三区| 欧美日韩成人综合| 一区二区成人在线| 91捆绑美女网站| 亚洲免费在线视频| 日本高清无吗v一区| 国产精品久久久久久久裸模| www.av精品| 亚洲欧美经典视频| 欧美三级三级三级爽爽爽| 一区二区三区四区国产精品| 成人免费不卡视频| 亚洲女厕所小便bbb| 欧美自拍偷拍午夜视频| 亚洲自拍另类综合| 欧美日韩一区二区三区在线看| 亚洲图片有声小说| 精品国产一区二区三区四区四| 午夜av区久久| 精品电影一区二区| 成人一区二区三区视频在线观看| 亚洲欧洲精品一区二区三区| 在线免费不卡电影| 免费观看在线综合| 国产欧美一区二区精品久导航| 91蝌蚪国产九色| 日本不卡视频在线| 国产精品久久久久久久久图文区| 91精品办公室少妇高潮对白| 韩国视频一区二区| 亚洲激情图片一区| 自拍偷拍欧美激情| 国产精品麻豆视频| 日本高清不卡aⅴ免费网站| 国产精品三级在线观看| 日韩欧美中文字幕一区| 精品国产一区二区三区久久久蜜月| 久久精品一区二区三区av| 国产一区二区美女诱惑| 成人性色生活片| 99久久精品国产麻豆演员表| 欧洲中文字幕精品| 欧美一区二区三区视频在线| 久久亚洲精华国产精华液| 国产精品国产a| 午夜精品一区在线观看| 国产一区啦啦啦在线观看| proumb性欧美在线观看| 色综合久久综合中文综合网| 国产精品原创巨作av| 亚洲成a人v欧美综合天堂 | 日韩国产欧美视频| 1024精品合集| 国产精品区一区二区三| 久久午夜羞羞影院免费观看| 欧美日韩在线免费视频| 懂色av一区二区三区免费观看| 亚洲高清视频在线| 国产精品久久一卡二卡| 精品国产乱子伦一区| 欧美军同video69gay| 色综合网站在线| caoporn国产精品| 成人一区二区三区视频在线观看| 午夜精品一区二区三区免费视频| 中文字幕亚洲精品在线观看 | 99精品欧美一区二区蜜桃免费| 免费欧美高清视频| 午夜精品久久久久久久99樱桃| 日韩一区在线免费观看| 国产精品久久久久影视| 欧美高清在线精品一区| 精品国产网站在线观看| 日韩免费一区二区三区在线播放| 欧美久久免费观看| 欧美日韩成人在线| 8v天堂国产在线一区二区| 欧美日韩aaaaa| 久久久无码精品亚洲日韩按摩| 一区二区三区 在线观看视频| 亚洲愉拍自拍另类高清精品| 亚洲一区二区高清| 亚洲精品欧美激情| 亚洲一区二区精品久久av| 亚洲一区二区偷拍精品| 亚洲午夜国产一区99re久久| 国产成人在线视频免费播放| 久久99精品国产麻豆婷婷洗澡| 久久69国产一区二区蜜臀| 国产麻豆成人精品| 99久久综合精品| 在线精品观看国产| 久久天堂av综合合色蜜桃网| 精品一区免费av| www国产亚洲精品久久麻豆| 亚洲精品国产成人久久av盗摄| 亚洲一区在线视频| 国产精品一区二区三区网站| 欧美卡1卡2卡| 亚洲精品日韩专区silk| 成人国产亚洲欧美成人综合网|