out.println("<P><FONT COLOR=" + TEXT_COLOR + "><I>Select 'Add/Update Yellow Pages...' to update <B>this</B> Cluster's JNDI entries."); out.println("Note that updates are only with respect to current Cluster."); out.println("To illustrate, why don't you navigate to each cluster and update the Yellow Pages"); out.println("with its attributes.  Query at each increment note the additions using 'Search Yellow Pages...'</P></FONT></I>");
out.println("<P><FONT COLOR=" + TEXT_COLOR + "><I>Select \"Add/Update Yellow Pages...\" to update <B>this</B> Cluster's JNDI entries."); out.println("Note that only the Roles of the current agent (this view) will be added."); out.println("You will need to \"Add/Update...\" individually for each agent you wish to add to the YP (use the agent links above to navigate to each agent in society)."); out.println("</P></FONT></I>");
    private void displayUserSearchCheckBoxes(PrintStream out,                                HttpInput query_parameters,                                QueryObject qObject, YPDemoSession session,                                PlanServiceContext psc, String cluster_id)    {        out.println("<HTML><BODY bgcolor=#FFFFCC>");        out.println("<form method=\"post\"");        out.println("action=\"?UPDATE\">");        out.println("<center><h1><Font color=GREEN>JNDI Yellow Pages Demonstration Viewer</font></h1></center>");        out.println("<center><h2><Font color=GREEN SIZE=-1>Your browser view is currently with respect to Cluster = "                                                + cluster_id + "</font></h2></center>");        //out.println("<center><h2><Font color=RED><I>DRAFT VERSION: 17.AUGUST.2001</I></font></h2></center>");        out.println("<P>");        out.println("<P><FONT COLOR=" + TEXT_COLOR + "><I>To change your cluster view, select links below</FONT></I></P>");        out.println(linksToOtherClusters(query_parameters, psc));        // BUTTON 1 ------------------        out.println("<P><FONT COLOR=" + TEXT_COLOR + "><I>Select 'Get queryable attributes...' ");        out.println("to update query attributes selection for search.  You need to do this each time you update YP (e.g. 'Add/Update Yellow Pages...')");        out.println("as well as each time you change view (to new Agent).</P></FONT></I>");        out.println("<div align=center>");        out.println("<input type=submit name="+BUTTON_GET_YP_ATTRIBUTES +" value=\"Get queryable attributes from Yellow Pages\">");        out.println("</div>");        out.println("<P>");        out.println("</P>");        // BUTTON 2 ------------------        out.println("<P>");        out.println("<P><FONT COLOR=" + TEXT_COLOR + "><I>Select 'Add/Update Yellow Pages...' to update <B>this</B> Cluster's JNDI entries.");        out.println("Note that updates are only with respect to current Cluster.");        out.println("To illustrate, why don't you navigate to each cluster and update the Yellow Pages");        out.println("with its attributes.  Query at each increment note the additions using 'Search Yellow Pages...'</P></FONT></I>");        out.println("<div align=center>");        out.println("<input type=submit name="+BUTTON_UPDATE_YP_ATTRIBUTES                                              +" value=\"Add/Update Yellow Pages with attributes for this cluster (  "                                              +cluster_id + ").\">");        out.println("</div>");        out.println("<P>");        out.println("</P>");        // BUTTON 3 ------------------        out.println("<P><FONT COLOR=" + TEXT_COLOR + "><I>Select 'Search Yellow Pages...' to search from all JNDI entries");        out.println("Select <FONT COLOR=BLUE>CONTEXT NAME</FONT> and <FONT COLOR=MAGENTA>ATTRIBUTE</FONT> pairs below.");        out.println("To update list, choose 'Get queryable attributes...' above.");        out.println("</I></FONT></P>");        out.println("<div align=center>");        out.println("<input type=submit name="+BUTTON_SUBMIT_YP_SEARCH+" value=\"Search Yellow Pages\">");        out.println("<P>");        out.println("</P>");        //        // START ROLE CHECK BOXES        //        /**        Object [] arr = qObject.getEntries().values().toArray();        for(int i=0; i< arr.length; i++) {            Object entry = arr[i];            if( entry == qObject.GET_ALL_NAMES ) {                 out.println("<input type=checkbox name=" + qObject.GET_ALL_NAMES + " value=X checked><I>Search for all attributes</I>,");            } else {                 out.println("<input type=checkbox name=" + entry.toString() + " value=X checked><I>" + entry.toString() + "</I>,");            }        }        **/        Set keys = qObject.getEntries().keySet();        Object [] keysArray = keys.toArray();        for(int i=0; i< keysArray.length; i++ ){             String name = (String)keysArray[i];             Vector v = (Vector)qObject.getEntries().get(name);             for(int j=0; j<v.size(); j++) {                 String attribute = (String)v.get(j);                  out.println("<input type=checkbox name={"                                            + name + "::" + attribute + "} value=X checked><I><FONT COLOR=BLUE>"                                            + name + "/</FONT><FONT COLOR=MAGENTA>"  + attribute + "</FONT></I>,");             }        }        //        // END SROLE CHECK BOXES        //        out.println("</div>");        out.println("<P>");        if( session.getTranscriptLength() > 0) {            out.println("<center><H2><FONT COLOR=GREEN><B>~~~~~~~~~~~~~~~~ Session Transcript (most recent first) ~~~~~~~~~~~~~~~~</B></FONT></H2></CENTER>");            out.println("<PRE>");            out.println(session.getTranscript());            out.println("</PRE>");        }        out.println("</form>");        out.println("</BODY></HTML>");   }