greenstone.org greenstone wiki greenstone trac planet greenstone

Changeset 16126

Show
Ignore:
Timestamp:
2008-06-24 16:46:29 (5 months ago)
Author:
mdewsnip
Message:

More code restructuring.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • gsdl/trunk/src/recpt/dynamicclassifieraction.cpp

    r16123 r16126  
    200200  // args["dcn"] may have been modified by output_hlist_classifier_nodes() above 
    201201  text_t classifier_node_OID = args["dcn"]; 
     202  logout << "Classifier node OID: " << classifier_node_OID << endl; 
     203 
     204  // Split the classifier node OID into its components, then remove any we've already dealt with 
     205  text_tlist classifier_node_OID_parts_remaining; 
     206  splitchar(classifier_node_OID.begin(), classifier_node_OID.end(), '|', classifier_node_OID_parts_remaining); 
     207  if (classifier_options["-group_by_first_character"] == "1") 
     208  { 
     209    classifier_node_OID_parts_remaining.pop_front(); 
     210  } 
     211  if (classifier_options["-use_hlist_at_top"] == "1") 
     212  { 
     213    classifier_node_OID_parts_remaining.pop_front(); 
     214  } 
    202215 
    203216  // Simple case at the top level: just output the child classifier nodes 
     
    217230    } 
    218231 
    219     // This is the classifier node OID without any hlist nodes 
    220     text_t classifier_node_OID_sans_hlists = classifier_node_OID; 
    221     if (classifier_node_OID == selected_hlist_node_OID) 
    222     { 
    223       classifier_node_OID_sans_hlists = ""; 
    224     } 
    225     else if (starts_with (classifier_node_OID, selected_hlist_node_OID + "|")) 
    226     { 
    227       classifier_node_OID_sans_hlists = substr (classifier_node_OID.begin() + (selected_hlist_node_OID + "|").size(), classifier_node_OID.end()); 
    228     } 
    229  
    230     // Determine the parent classifier node labels 
    231     text_tlist parent_classifier_node_labels; 
    232     splitchar(classifier_node_OID_sans_hlists.begin(), classifier_node_OID_sans_hlists.end(), '|', parent_classifier_node_labels); 
    233  
    234232    // Output the parent classifier nodes and the current classifier node 
    235     output_upper_classifier_nodes (selected_hlist_node_OID, parent_classifier_node_labels, classifier_node_indent, classifier_options, args, collectproto, browsers, disp, outconvert, textout, logout); 
     233    output_upper_classifier_nodes (current_classifier_node_OID, classifier_node_OID_parts_remaining, classifier_node_indent, classifier_options, args, collectproto, browsers, disp, outconvert, textout, logout); 
    236234 
    237235    // Output the child classifier nodes