Changeset 21279

Show
Ignore:
Timestamp:
07.12.2009 13:10:43 (10 years ago)
Author:
kjdon
Message:

class package name change, added hidden attribute to service, remove .jpg from id returned from search

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • gs3-extensions/pharos/trunk/src/java/imageis/PharosImageISServiceRack.java

    r21271 r21279  
    4848{ 
    4949 
    50    static Logger logger = Logger.getLogger(pharosimageis.PharosImageISServiceRack.class.getName()); 
     50   static Logger logger = Logger.getLogger(imageis.PharosImageISServiceRack.class.getName()); 
    5151 
    5252     
     
    7979 
    8080    // set up short_service_info_ - for now just has id and type. the name (lang dependent) will be added in if the list is requested. 
    81     Element tq_service = this.doc.createElement(GSXML.SERVICE_ELEM); 
    82     tq_service.setAttribute(GSXML.TYPE_ATT, GSXML.SERVICE_TYPE_QUERY); 
    83     tq_service.setAttribute(GSXML.NAME_ATT, PHAROS_QUERY_SERVICE); 
    84     this.short_service_info.appendChild(tq_service); 
     81    Element pq_service = this.doc.createElement(GSXML.SERVICE_ELEM); 
     82    pq_service.setAttribute(GSXML.TYPE_ATT, GSXML.SERVICE_TYPE_QUERY); 
     83    pq_service.setAttribute(GSXML.NAME_ATT, PHAROS_QUERY_SERVICE); 
     84    pq_service.setAttribute(GSXML.HIDDEN_ATT, "true"); 
     85    this.short_service_info.appendChild(pq_service); 
    8586 
    8687    // add some format info to service map if there is any - look in extra info 
     
    141142    pq_service.setAttribute(GSXML.TYPE_ATT, GSXML.SERVICE_TYPE_QUERY); 
    142143    pq_service.setAttribute(GSXML.NAME_ATT, PHAROS_QUERY_SERVICE); 
     144    pq_service.setAttribute(GSXML.HIDDEN_ATT, "true"); 
    143145    if (subset==null || subset.equals(GSXML.DISPLAY_TEXT_ELEM+GSXML.LIST_MODIFIER)) { 
    144146        pq_service.appendChild(GSXML.createDisplayTextElement(this.doc, GSXML.DISPLAY_TEXT_NAME, getServiceName(PHAROS_QUERY_SERVICE, lang) )); 
     
    216218    String search_results = null; 
    217219    try { 
     220      logger.error("querying on "+this.cluster_name+", "+query); 
    218221      search_results = pharos_engine.query(this.cluster_name, query); 
    219222    } catch (Exception e) { 
     
    246249    System.err.println("id = "+id+", rank = "+rank); 
    247250    if (id.startsWith(coll_prefix)) { 
    248        
    249       Element result_node = createDocNode(id.substring(prefix_len), rank); 
     251      id = id.substring(prefix_len); 
     252      id = id.replace(".jpg",""); 
     253      Element result_node = createDocNode(id, rank); 
    250254      document_list.appendChild(result_node); 
    251255    }