Package org.bigbluebutton.webminer.web.model

Examples of org.bigbluebutton.webminer.web.model.MatchVO


          float score = hits[i].score;         
          Document doc = searcher.doc(hits[i].doc);         
          String path = doc.get("path");     
         
          if (path != null) {
            MatchVO matchVO = new MatchVO();
            matchVO.setFilePath(path);
            String fullContent = doc.get("title");
            String summary = getKeywordContext(queryStr, fullContent);
            matchVO.setContentSummary(summary);
           
            String fileName = doc.get("fileName");
            matchVO.setFileName(fileName);
            String indexSummary = doc.get("summary");
            matchVO.setIndexingSummary(indexSummary);
            matchVO.setScore(score);
            String title = indexSummary+": "+fileName+" (Match Score = "+score+")";
           
            //String content = doc.get("contents");               
           
            String allData=title+"%"+summary;
            if (doc.get("slideTime")!=null){
              allData += "%"+doc.get("slideTime");
              matchVO.setSlidePlayTime(doc.get("slideTime"));
            }
            //sortedMap.put(path, allData);
            sortedMap.put(path, matchVO);
           
            //model.put(path, newTitle+"%"+doc.get("summary")+"%"+doc.get("slideTime"));
            if (logger.isInfoEnabled()) {
              logger.info("----"+allData);
              logger.info((i + 1) + ". " + path);
            }

            if (title != null) {
              if (logger.isInfoEnabled()) {
                logger.info("   Title: " + doc.get("title"));
              }
            }
            if (bSmart){
              //Prepare for the grouping results           
              currentSession = getSessionNumberFromFileURL(path);
              //get existing current session organizer
              hitsOrganizer = hitsOrganizerMap.get(currentSession);
              if (hitsOrganizer==null){
                //create a new session organizer object
                hitsOrganizer = new SessionHitsOrganizer();
                hitsOrganizer.setSessionNum(currentSession);
                hitsOrganizerMap.put(currentSession, hitsOrganizer);
              }
              hitsOrganizer.setReleventRange((new Float(relRange)).floatValue());
              hitsOrganizer.addExactHits(path, score);
              matchVO.setSessionHitOrganier(hitsOrganizer);   
            }
           
          } else {
            System.out.println((i + 1) + ". "
                + "No path for this document");
View Full Code Here

TOP

Related Classes of org.bigbluebutton.webminer.web.model.MatchVO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.