code: private void enqueueUnusedSegments() throws IOException
     {
        // walk through index segments
        String[] dirNames = directoryManager.getDirectoryNames();
        for (int i = 0; i < dirNames.length; i++)
        {
           if (dirNames[i].startsWith("_") && !indexNames.contains(dirNames[i]))
           {
              deletable.add(dirNames[i]);
           }
        }
     }
docs: Enqueues unused segments for deletion in {@link #deletable}. This method
  does not synchronize on {@link #deletable}! A caller must ensure that it
  is the only one acting on the {@link #deletable} map.
  
  @throws IOException
  if an error occurs while reading directories.