@Override
 public void callback(DocumentClosure incomingClosure) {
   if (outputOneAtATime) incomingClosure.serialize(outputStream);
   else if (++currentResult >= documentCollection.size()) {
     System.out.println("\n\n");
     try {
       generateHtml();
     } catch (IllegalArgumentException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     } catch (IllegalAccessException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     } catch (IOException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     } catch (SIMPLTranslationException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     } catch (URISyntaxException e) {
       // TODO Auto-generated catch block
       e.printStackTrace();
     }
     semanticsSessionScope.getDownloadMonitors().stop(false);
   }
 }