Changeset 25305


Ignore:
Timestamp:
2012-03-27T15:18:44+13:00 (12 years ago)
Author:
kjdon
Message:

tidying up handling of external links and hrefs that are relative greenstone links

Location:
main/trunk/greenstone3/src/java/org/greenstone/gsdl3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/action/DocumentAction.java

    r25128 r25305  
    4848    public static final String GOTO_PAGE_ARG = "gp";
    4949    public static final String ENRICH_DOC_ARG = "end";
     50    public static final String EXPAND_DOCUMENT_ARG = "ed";
     51    public static final String EXPAND_CONTENTS_ARG = "ec";
     52    public static final String REALISTIC_BOOK_ARG = "book";
    5053
    5154    /**
     
    9295        HashMap service_params = (HashMap) params.get("s0");
    9396
    94         String has_rl = null;
    95         String has_href = null;
    96         has_href = (String) params.get("href");//for an external link : get the href URL if it is existing in the params list
    97         has_rl = (String) params.get("rl");//for an external link : get the rl value if it is existing in the params list
    9897        String collection = (String) params.get(GSParams.COLLECTION);
    99         UserContext userContext = new UserContext(request);
    100         String document_name = (String) params.get(GSParams.DOCUMENT);
    101         if ((document_name == null || document_name.equals("")) && (has_href == null || has_href.equals("")))
     98        String document_id = (String) params.get(GSParams.DOCUMENT);
     99        if (document_id != null && document_id.equals("")) {
     100          document_id = null;
     101        }
     102        String href = (String) params.get(GSParams.HREF);//for an external link : get the href URL if it is existing in the params list
     103        if (href != null && href.equals("")) {
     104          href = null;
     105        }
     106        String rl = (String) params.get(GSParams.RELATIVE_LINK);//for an external link : get the rl value if it is existing in the params list
     107        if (document_id == null && href == null)
    102108        {
    103109            logger.error("no document specified!");
    104110            return result;
    105111        }
     112        if (rl != null && rl.equals("0")) {
     113          // this is a true external link, we should have been directed to a different page or action
     114          logger.error("rl value was 0, shouldn't get here");
     115          return result;
     116        }
    106117        String document_type = (String) params.get(GSParams.DOCUMENT_TYPE);
    107         if (document_type == null)
     118        if (document_type == null ||  document_type.equals(""))
    108119        {
    109120            document_type = "simple";
     
    117128        }
    118129
     130        String doc_id_modifier = "";
    119131        String sibling_num = (String) params.get(GOTO_PAGE_ARG);
    120132        if (sibling_num != null && !sibling_num.equals(""))
    121133        {
    122134            // we have to modify the doc name
    123             document_name = document_name + "." + sibling_num + ".ss";
     135            doc_id_modifier = "." + sibling_num + ".ss";
    124136        }
    125137
    126138        boolean expand_document = false;
    127         String ed_arg = (String) params.get(GSParams.EXPAND_DOCUMENT);
     139        String ed_arg = (String) params.get(EXPAND_DOCUMENT_ARG);
    128140        if (ed_arg != null && ed_arg.equals("1"))
    129141        {
     
    138150        else
    139151        {
    140             String ec_arg = (String) params.get(GSParams.EXPAND_CONTENTS);
     152            String ec_arg = (String) params.get(EXPAND_CONTENTS_ARG);
    141153            if (ec_arg != null && ec_arg.equals("1"))
    142154            {
     
    144156            }
    145157        }
     158       
     159        UserContext userContext = new UserContext(request);
    146160
    147161        //append site metadata
     
    165179        Element current_doc = this.doc.createElement(GSXML.DOC_NODE_ELEM);
    166180        basic_doc_list.appendChild(current_doc);
    167         if (document_name.length() != 0)
    168         {
    169             current_doc.setAttribute(GSXML.NODE_ID_ATT, document_name);
    170         }
    171         else if (has_href.length() != 0)
    172         {
    173             current_doc.setAttribute(GSXML.NODE_ID_ATT, has_href);
    174             current_doc.setAttribute("externalURL", has_rl);
     181        if (document_id != null)
     182        {
     183            current_doc.setAttribute(GSXML.NODE_ID_ATT, document_id+doc_id_modifier);
     184        }
     185        else
     186        {
     187            current_doc.setAttribute(GSXML.HREF_ID_ATT, href);
     188            // do we need this??
     189            current_doc.setAttribute(GSXML.ID_MOD_ATT, doc_id_modifier);
    175190        }
    176191
     
    198213            }
    199214
    200             // get teh info needed for paged naviagtion
     215            // get the info needed for paged naviagtion
    201216            ds_param = this.doc.createElement(GSXML.PARAM_ELEM);
    202217            ds_param_list.appendChild(ds_param);
     
    305320                // no structure nodes, so put in a dummy doc node
    306321                Element doc_node = this.doc.createElement(GSXML.DOC_NODE_ELEM);
    307                 if (document_name.length() != 0)
    308                 {
    309                     doc_node.setAttribute(GSXML.NODE_ID_ATT, document_name);
    310                 }
    311                 else if (has_href.length() != 0)
    312                 {
    313                     doc_node.setAttribute(GSXML.NODE_ID_ATT, has_href);
    314                     doc_node.setAttribute("externalURL", has_rl);
     322                if (document_id != null)
     323                {
     324                    doc_node.setAttribute(GSXML.NODE_ID_ATT, document_id);
     325                }
     326                else
     327                {
     328                    doc_node.setAttribute(GSXML.HREF_ID_ATT, href);
     329               
    315330                }
    316331                the_document.appendChild(doc_node);
     
    323338            // no structure request, so just put in a dummy doc node
    324339            Element doc_node = this.doc.createElement(GSXML.DOC_NODE_ELEM);
    325             if (document_name.length() != 0)
    326             {
    327                 doc_node.setAttribute(GSXML.NODE_ID_ATT, document_name);
    328             }
    329             else if (has_href.length() != 0)
    330             {
    331                 doc_node.setAttribute(GSXML.NODE_ID_ATT, has_href);
    332                 doc_node.setAttribute("externalURL", has_rl);
     340            if (document_id != null)
     341            {
     342                doc_node.setAttribute(GSXML.NODE_ID_ATT, document_id);
     343            }
     344            else
     345            {
     346                doc_node.setAttribute(GSXML.HREF_ID_ATT, href);
    333347            }
    334348            the_document.appendChild(doc_node);
     
    398412        Element doc_node = this.doc.createElement(GSXML.DOC_NODE_ELEM);
    399413        // the node we want is the root document node
    400         if (document_name.length() != 0)
    401         {
    402             doc_node.setAttribute(GSXML.NODE_ID_ATT, document_name + ".rt");
    403         }
    404         else if (has_href.length() != 0)
    405         {
    406             doc_node.setAttribute(GSXML.NODE_ID_ATT, has_href + ".rt");
    407             doc_node.setAttribute("externalURL", has_rl);
     414        if (document_id != null)
     415        {
     416            doc_node.setAttribute(GSXML.NODE_ID_ATT, document_id + ".rt");
     417        }
     418        else
     419        {
     420          doc_node.setAttribute(GSXML.HREF_ID_ATT, href);// + ".rt");
     421          // can we assume that href is always a top level doc??
     422          //doc_node.setAttribute(GSXML.ID_MOD_ATT, ".rt");
     423            //doc_node.setAttribute("externalURL", has_rl);
    408424        }
    409425        doc_list.appendChild(doc_node);
     
    486502            Element dc_response_doc = (Element) GSXML.getChildByTagName(dc_response_doc_list, GSXML.DOC_NODE_ELEM);
    487503            Element dc_response_doc_content = (Element) GSXML.getChildByTagName(dc_response_doc, GSXML.NODE_CONTENT_ELEM);
    488             Element dc_response_doc_external = (Element) GSXML.getChildByTagName(dc_response_doc, "external");
     504            //Element dc_response_doc_external = (Element) GSXML.getChildByTagName(dc_response_doc, "external");
    489505
    490506            if (dc_response_doc_content == null)
    491507            {
    492508                // no content to add
    493                 if (dc_response_doc_external != null)
    494                 {
    495                     String modified_doc_id = dc_response_doc.getAttribute(GSXML.NODE_ID_ATT);
    496 
    497                     the_document.setAttribute("selectedNode", modified_doc_id);
    498                     the_document.setAttribute("external", dc_response_doc_external.getAttribute("external_link"));
    499                 }
    500                 return result;
     509              if (dc_response_doc.getAttribute("external").equals("true")) {
     510               
     511                //if (dc_response_doc_external != null)
     512                //{
     513                    String href_id = dc_response_doc.getAttribute(GSXML.HREF_ID_ATT);
     514
     515                    the_document.setAttribute("selectedNode", href_id);
     516                    the_document.setAttribute("external", href_id);
     517              }
     518              return result;
    501519            }
    502520            if (highlight_query_terms)
     
    598616     * important for args that should not be saved
    599617     */
    600     public boolean getActionParameters(GSParams params)
     618    public boolean addActionParameters(GSParams params)
    601619    {
    602620        params.addParameter(GOTO_PAGE_ARG, false);
    603621        params.addParameter(ENRICH_DOC_ARG, false);
     622        params.addParameter(EXPAND_DOCUMENT_ARG, false);
     623        params.addParameter(EXPAND_CONTENTS_ARG, false);
     624        params.addParameter(REALISTIC_BOOK_ARG, false);
     625
    604626        return true;
    605627    }
  • main/trunk/greenstone3/src/java/org/greenstone/gsdl3/service/AbstractDocumentRetrieve.java

    r25259 r25305  
    4646/**
    4747 * Abstract class for Document Retrieval Services
    48  *
    49  * @author <a href="mailto:[email protected]">Katherine Don</a>
    5048 */
    5149
     
    7472
    7573    // means the id is not a greenstone id and needs translating
    76     protected static final String EXTID_PARAM = "ext";
     74  //    protected static final String EXTID_PARAM = "ext";
    7775
    7876    protected Element config_info = null; // the xml from the config file
     
    150148            macro_resolver.setSiteDetails(this.site_http_address, this.cluster_name, this.getLibraryName());
    151149            // set up the macro resolver
    152             Element replacement_elem = (Element) GSXML.getChildByTagName(extra_info, "replaceList");
     150            Element replacement_elem = (Element) GSXML.getChildByTagName(extra_info, GSXML.REPLACE_ELEM+GSXML.LIST_MODIFIER);
    153151            if (replacement_elem != null)
    154152            {
     
    156154            }
    157155            // look for any refs to global replace lists
    158             NodeList replace_refs_elems = extra_info.getElementsByTagName("replaceListRef");
     156            NodeList replace_refs_elems = extra_info.getElementsByTagName(GSXML.REPLACE_ELEM+GSXML.LIST_MODIFIER+GSXML.REF_MODIFIER);
    159157            for (int i = 0; i < replace_refs_elems.getLength(); i++)
    160158            {
     
    162160                if (!id.equals(""))
    163161                {
    164                     Element replace_list = GSXML.getNamedElement(this.router.config_info, "replaceList", "id", id);
     162                    Element replace_list = GSXML.getNamedElement(this.router.config_info, GSXML.REPLACE_ELEM+GSXML.LIST_MODIFIER, "id", id);
    165163                    if (replace_list != null)
    166164                    {
     
    206204        }
    207205
    208         boolean external_id = false;
    209206        // The metadata information required
    210207        ArrayList metadata_names_list = new ArrayList();
     
    225222                metadata_names_list.add(metadata);
    226223            }
    227             else if (param.getAttribute(GSXML.NAME_ATT).equals(EXTID_PARAM) && GSXML.getValue(param).equals("1"))
    228             {
    229                 external_id = true;
    230             }
     224           
    231225            param = (Element) param.getNextSibling();
    232226        }
     
    265259            Element request_node = (Element) request_nodes.item(i);
    266260            String node_id = request_node.getAttribute(GSXML.NODE_ID_ATT);
    267 
    268             boolean is_external_link = false;
    269             if (!node_id.startsWith("HASH") && !node_id.startsWith("D"))
    270             {
    271                 if (node_id.endsWith(".rt"))
    272                 {
    273                     node_id = getHrefOID(node_id.substring(0, node_id.length() - 3));
    274                     if (node_id != null)
    275                     {
    276                         node_id += ".rt";
    277                     }
    278                     else
    279                     {
    280                         is_external_link = true;
    281                     }
    282                 }
    283                 else
    284                 {
    285                     node_id = getHrefOID(node_id);
    286                     if (node_id == null)
    287                     {
    288                         is_external_link = true;
    289                     }
    290                 }
    291             }
    292             if (!is_external_link)
    293             {
    294                 if (external_id)
    295                 {
    296                     // can we have .pr etc extensions with external ids?
    297                     node_id = translateExternalId(node_id);
    298                 }
    299                 else if (idNeedsTranslating(node_id))
    300                 {
    301                     node_id = translateId(node_id);
    302                 }
    303             }
    304 
     261            boolean is_href_id = false;
     262            if (node_id.equals("")) {
     263              node_id = getGreenstoneIdFromHref(request_node);
     264              if(node_id == null) {
     265                // **** TODO, is this good enough???
     266                request_node.setAttribute("external_link", "true");
     267                continue;
     268              }
     269             
     270            }
     271             
     272            System.err.println("getting meta for node"+node_id);
     273
     274            // may have modifiers .rt, .1.ss etc
     275            if (idNeedsTranslating(node_id))
     276            {
     277                node_id = translateId(node_id);
     278            }
     279           
    305280            if (node_id == null)
    306281            {
    307282                continue;
    308283            }
    309             if (!is_external_link)
    310             {
    311                 try
    312                 {
    313                     Element metadata_list = getMetadataList(node_id, all_metadata, metadata_names_list);
    314                     if(metadata_list != null)
    315                     {
    316                         request_node.appendChild(metadata_list);
    317                     }
    318                 }
    319                 catch (GSException e)
    320                 {
    321                     GSXML.addError(this.doc, result, e.getMessage(), e.getType());
    322                     if (e.getType().equals(GSXML.ERROR_TYPE_SYSTEM))
    323                     {
    324                         // there is no point trying any others
    325                         return result;
    326                     }
    327                 }
    328             }
    329             else
    330             {
    331                 request_node.setAttribute("external_link", request_node.getAttribute(GSXML.NODE_ID_ATT));
    332             }
    333         }
     284            try
     285              {
     286                Element metadata_list = getMetadataList(node_id, all_metadata, metadata_names_list);
     287                if(metadata_list != null)
     288                  {
     289                request_node.appendChild(metadata_list);
     290                  }
     291              }
     292            catch (GSException e)
     293              {
     294                GSXML.addError(this.doc, result, e.getMessage(), e.getType());
     295                if (e.getType().equals(GSXML.ERROR_TYPE_SYSTEM))
     296                  {
     297                // there is no point trying any others
     298                return result;
     299                  }
     300              }
     301       
     302           
     303        } // for each doc node
     304
    334305        return result;
    335306    }
     
    377348            GSXML.addError(this.doc, result, "DocumentStructureRetrieve: no " + GSXML.DOC_NODE_ELEM + " found in the " + GSXML.DOC_NODE_ELEM + GSXML.LIST_MODIFIER, GSXML.ERROR_TYPE_SYNTAX);
    378349            return result;
    379         }
    380 
    381         Element extid_param = GSXML.getNamedElement(param_list, GSXML.PARAM_ELEM, GSXML.NAME_ATT, EXTID_PARAM);
    382         boolean external_id = false;
    383         if (extid_param != null && GSXML.getValue(extid_param).equals("1"))
    384         {
    385             external_id = true;
    386350        }
    387351
     
    446410
    447411            String doc_id = doc.getAttribute(GSXML.NODE_ID_ATT);
    448             String is_external = doc.getAttribute("externalURL");
    449 
    450             boolean is_external_link = false;
    451             if (is_external.equals("0"))
    452             {
    453                 is_external_link = true;
    454             }
    455             if (is_external.equals("1") && !doc_id.startsWith("HASH") && !is_external_link)
    456             {
    457                 if (doc_id.endsWith(".rt"))
    458                 {
    459                     doc_id = getHrefOID(doc_id.substring(0, doc_id.length() - 3));
    460                     if (doc_id != null)
    461                     {
    462                         doc_id += ".rt";
    463                     }
    464                     else
    465                     {
    466                         is_external_link = true;
    467                     }
    468                 }
    469                 else
    470                 {
    471                     doc_id = getHrefOID(doc_id);
    472                     if (doc_id == null)
    473                     {
    474                         is_external_link = true;
    475                     }
    476                 }
    477             }
    478             if (!is_external_link)
    479             {
    480                 if (external_id)
    481                 {
    482                     doc_id = translateExternalId(doc_id);
    483                     doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
    484                 }
    485                 else if (idNeedsTranslating(doc_id))
    486                 {
    487                     doc_id = translateId(doc_id);
    488                     doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
    489                 }
    490 
    491                 if (doc_id == null)
    492                 {
    493                     continue;
    494                 }
     412            boolean is_href_id = false;
     413            if (doc_id.equals("")) {
     414              doc_id = getGreenstoneIdFromHref(doc);
     415              if(doc_id == null) {
     416                // **** TODO, is this good enough???
     417                doc.setAttribute("external_link", "true");
     418                continue;
     419              }
     420              doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
     421            }
     422
     423            if (idNeedsTranslating(doc_id))
     424              {
     425                doc_id = translateId(doc_id);
     426                doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
     427              }
     428
     429            if (doc_id == null)
     430              {
     431                continue;
     432              }
    495433
    496434                if (want_info)
     
    591529                } // if want structure
    592530
    593             }
    594             else
    595             {
    596                 Element external_link_elem = this.doc.createElement("external");
    597                 external_link_elem.setAttribute("external_link", doc.getAttribute(GSXML.NODE_ID_ATT));
    598                 doc.appendChild(external_link_elem);
    599             }// if is_external_link
     531               
    600532        } // for each doc
    601533        return result;
     
    618550        // Get the parameters of the request
    619551        Element param_list = (Element) GSXML.getChildByTagName(request, GSXML.PARAM_ELEM + GSXML.LIST_MODIFIER);
    620         Element extid_param = GSXML.getNamedElement(param_list, GSXML.PARAM_ELEM, GSXML.NAME_ATT, EXTID_PARAM);
    621         boolean external_id = false;
    622         if (extid_param != null && GSXML.getValue(extid_param).equals("1"))
    623         {
    624             external_id = true;
    625         }
    626552        // Get the request content
    627553        Element query_doc_list = (Element) GSXML.getChildByTagName(request, GSXML.DOC_NODE_ELEM + GSXML.LIST_MODIFIER);
     
    633559
    634560        String lang = request.getAttribute(GSXML.LANG_ATT);
    635         Element doc_list = this.doc.createElement(GSXML.DOC_NODE_ELEM + GSXML.LIST_MODIFIER);
    636         result.appendChild(doc_list);
     561
     562        // copy the request doc node list to the response
     563        Element response_node_list = (Element) this.doc.importNode(query_doc_list, true);
     564        result.appendChild(response_node_list);
     565
     566        NodeList request_nodes = GSXML.getChildrenByTagName(response_node_list, GSXML.DOC_NODE_ELEM);
     567        if (request_nodes.getLength() == 0)
     568        {
     569            GSXML.addError(this.doc, result, "DocumentContentRetrieve: no " + GSXML.DOC_NODE_ELEM + " found in the " + GSXML.DOC_NODE_ELEM + GSXML.LIST_MODIFIER, GSXML.ERROR_TYPE_SYNTAX);
     570            return result;
     571        }
     572
     573        //Element doc_list = this.doc.createElement(GSXML.DOC_NODE_ELEM + GSXML.LIST_MODIFIER);
     574        //result.appendChild(doc_list);
    637575
    638576        // set up the retrieval??
    639577
    640578        // Get the documents
    641         String[] doc_ids = GSXML.getAttributeValuesFromList(query_doc_list, GSXML.NODE_ID_ATT);
    642         String[] is_externals = GSXML.getAttributeValuesFromList(query_doc_list, "externalURL");
    643 
    644         for (int i = 0; i < doc_ids.length; i++)
    645         {
    646             String doc_id = doc_ids[i];
    647             String is_external = is_externals[i];
    648 
    649             boolean is_external_link = false;
    650             if (is_external.equals("0"))
    651             {
    652                 is_external_link = true;
    653             }
    654             if (is_external.equals("1") && !doc_id.startsWith("HASH") && !is_external_link)
    655             {
    656                 //if (!doc_id.startsWith("HASH")){
    657                 if (doc_id.endsWith(".rt"))
    658                 {
    659                     String find_doc_id = getHrefOID(doc_id.substring(0, doc_id.length() - 3));
    660                     if (find_doc_id != null)
    661                     {
    662                         doc_id = doc_id + ".rt";
    663                     }
    664                     else
    665                     {
    666                         is_external_link = true;
    667                     }
    668 
    669                 }
    670                 else
    671                 {
    672                     String find_doc_id = getHrefOID(doc_id);
    673                     if (find_doc_id == null)
    674                     {
    675                         is_external_link = true;
    676                     }
    677                     else
    678                     {
    679                         doc_id = find_doc_id;
    680                     }
    681                 }
    682             }
    683 
    684             if (!is_external_link)
    685             {
    686                 // Create the document node
    687                 Element doc = this.doc.createElement(GSXML.DOC_NODE_ELEM);
    688                 doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
    689                 doc_list.appendChild(doc);
    690 
    691                 if (external_id)
    692                 {
    693                     doc_id = translateExternalId(doc_id);
    694                     doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
    695                 }
    696                 else if (idNeedsTranslating(doc_id))
    697                 {
    698                     doc_id = translateId(doc_id);
    699                     doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
    700                 }
    701                 if (doc_id == null)
    702                 {
    703                     continue;
    704                 }
    705                 try
    706                 {
    707                     Element node_content = getNodeContent(doc_id, lang);
    708                     doc.appendChild(node_content);
    709                 }
    710                 catch (GSException e)
    711                 {
    712                     GSXML.addError(this.doc, result, e.getMessage());
    713                     return result;
    714 
    715                 }
    716             }
    717             else
    718             {
    719                 Element doc = this.doc.createElement(GSXML.DOC_NODE_ELEM);
    720                 doc.setAttribute(GSXML.NODE_ID_ATT, doc_id);
    721                 //doc.setAttribute("external_link", doc_id);
    722                 Element external_link_elem = this.doc.createElement("external");
    723                 external_link_elem.setAttribute("external_link", doc_id);
    724                 doc.appendChild(external_link_elem);
    725 
    726                 doc_list.appendChild(doc);
    727             }
    728         }
     579        //String[] doc_ids = GSXML.getAttributeValuesFromList(query_doc_list, GSXML.NODE_ID_ATT);
     580        //String[] is_externals = GSXML.getAttributeValuesFromList(query_doc_list, "externalURL");
     581
     582        for (int i = 0; i < request_nodes.getLength(); i++)
     583        {
     584            Element request_node = (Element) request_nodes.item(i);
     585            String node_id = request_node.getAttribute(GSXML.NODE_ID_ATT);
     586            boolean is_href_id = false;
     587            if (node_id.equals("")) {
     588              node_id = getGreenstoneIdFromHref(request_node);
     589              if(node_id == null) {
     590                // **** TODO, is this good enough???
     591                request_node.setAttribute("external_link", "true");
     592                continue;
     593              }
     594             
     595            }
     596
     597            // may have modifiers .rt, .1.ss etc
     598            if (idNeedsTranslating(node_id))
     599            {
     600                node_id = translateId(node_id);
     601            }
     602           
     603            if (node_id == null)
     604            {
     605                continue;
     606            }
     607            try
     608              {
     609                Element node_content = getNodeContent(node_id, lang);
     610                request_node.appendChild(node_content);
     611              }
     612            catch (GSException e)
     613              {
     614                GSXML.addError(this.doc, result, e.getMessage());
     615                return result;
     616               
     617              }
     618        } // for each node
    729619        return result;
    730     }
     620    } // processDocumentContentRetrieve
    731621
    732622    /**
     
    869759    }
    870760
     761  protected String getGreenstoneIdFromHref(Element doc_node)
     762  {
     763    String node_id = doc_node.getAttribute(GSXML.HREF_ID_ATT);
     764    node_id = translateExternalId(node_id);
     765    if (node_id == null) {
     766      return node_id;
     767    }
     768    // check for id modifiers
     769    String id_mods = doc_node.getAttribute(GSXML.ID_MOD_ATT);
     770    if (!id_mods.equals("")) {
     771      node_id = node_id+id_mods;
     772    }
     773    return node_id;
     774  }
    871775    /**
    872776     * returns the document type of the doc that the specified node belongs to.
Note: See TracChangeset for help on using the changeset viewer.