/** * Constructs a new <code>SDSequence</code>. */ public SDSequence() { super(); Synthesized = false; ReadMe = false; _Debug = Debug.isSet("SDSequence"); }
/** * ************************************************************************ * Intitializes the servlet. Init (at this time) basically sets up * the object opendap.util.Debug from the debuggery flags in the * servlet InitParameters. The Debug object can be referenced (with * impunity) from anywhere in the VM. */ public void init() throws ServletException { super.init(); // debuggering String debugOn = getInitParameter("DebugOn"); if (debugOn != null) { StringTokenizer toker = new StringTokenizer(debugOn); while (toker.hasMoreTokens()) Debug.set(toker.nextToken(), true); } } /***************************************************************************/
Debug.set(tz.nextToken(), true); Debug.set(tz.nextToken(), false); Iterator iter = Debug.keySet().iterator(); while (iter.hasNext()) { String key = (String) iter.next(); pw.println(" " + key + " " + Debug.isSet(key)); Iterator iter = Debug.keySet().iterator(); while (iter.hasNext()) { String key = (String) iter.next(); boolean val = Debug.isSet(key); if (val) pw.println(" " + key + " " + Debug.isSet(key));
pw.println("-----done logShow"); } else if (cmd.equals("on")) Debug.set(tz.nextToken(), true); Debug.set(tz.nextToken(), false); Iterator iter = Debug.keySet().iterator(); while (iter.hasNext()) { String key = (String) iter.next(); pw.println(" " + key + " " + Debug.isSet(key)); Iterator iter = Debug.keySet().iterator(); while (iter.hasNext()) { String key = (String) iter.next(); boolean val = Debug.isSet(key); if (val) pw.println(" " + key + " " + Debug.isSet(key));
/** * Constructs a new <code>SDSequence</code>. */ public SDSequence() { super(); Synthesized = false; ReadMe = false; _Debug = Debug.isSet("SDSequence"); }
/** * Constructs a new <code>SDSequence</code> with name <code>n</code>. * * @param n the name of the variable. */ public SDSequence(String n) { super(n); Synthesized = false; ReadMe = false; _Debug = Debug.isSet("SDSequence"); }
/** * Constructs a new <code>SDSequence</code> with name <code>n</code>. * * @param n the name of the variable. */ public SDSequence(String n) { super(n); Synthesized = false; ReadMe = false; _Debug = Debug.isSet("SDSequence"); }
/** * Construct a new <code>CEEvaluator</code> with <code>dds</code> as the * DDS object with which to resolve all variable and function names. * * @param dds DDS object describing the dataset targeted by this * constraint. */ public CEEvaluator(ServerDDS dds) { _dds = dds; _cv = new Vector(); _Debug = Debug.isSet("CE"); if (_Debug) System.out.println("CE debugging enabled."); }
/** * Construct a new <code>CEEvaluator</code> with <code>dds</code> as the * DDS object with which to resolve all variable and function names. * * @param dds DDS object describing the dataset targeted by this * constraint. */ public CEEvaluator(ServerDDS dds) { _dds = dds; _cv = new Vector(); _Debug = Debug.isSet("CE"); if (_Debug) System.out.println("CE debugging enabled."); }
/** * Construct a new <code>CEEvaluator</code> with <code>dds</code> as the * DDS object with which to resolve all variable and function names, and * <code>clauseFactory</code> as a source of Clause objects . * * @param clauseFactory The factory which will be used by the parser to construct the clause * tree. This allows servers to pass in a factory which creates * custom clause objects. * @param dds DDS object describing the dataset targeted by this * constraint. */ public CEEvaluator(ServerDDS dds, ClauseFactory clauseFactory) { _dds = dds; _cv = new Vector(); _Debug = Debug.isSet("CE"); if (_Debug) System.out.println("CE debugging enabled."); this.clauseFactory = clauseFactory; _Debug = Debug.isSet("CEEvaluator"); }
/** * Construct a new <code>CEEvaluator</code> with <code>dds</code> as the * DDS object with which to resolve all variable and function names, and * <code>clauseFactory</code> as a source of Clause objects . * * @param clauseFactory The factory which will be used by the parser to construct the clause * tree. This allows servers to pass in a factory which creates * custom clause objects. * @param dds DDS object describing the dataset targeted by this * constraint. */ public CEEvaluator(ServerDDS dds, ClauseFactory clauseFactory) { _dds = dds; _cv = new Vector(); _Debug = Debug.isSet("CE"); if (_Debug) System.out.println("CE debugging enabled."); this.clauseFactory = clauseFactory; _Debug = Debug.isSet("CEEvaluator"); }
/** * Constructs a new <code>DDSXMLParser</code>. * The OPeNDAP namespace is defined during the construction * of an instance of this class. */ public DDSXMLParser(String nameSpace) { super(); opendapNameSpace = Namespace.getNamespace(nameSpace); lastDoc = null; _Debug = Debug.isSet("DDSXMLParser"); }
/** * Constructs a new <code>DDSXMLParser</code>. * The OPeNDAP namespace is defined during the construction * of an instance of this class. */ public DDSXMLParser(String nameSpace) { super(); opendapNameSpace = Namespace.getNamespace(nameSpace); lastDoc = null; _Debug = Debug.isSet("DDSXMLParser"); }
/** * Print the attribute table on the given <code>PrintWriter</code>. * * @param os the <code>PrintWriter</code> to use for output. * @param pad the number of spaces to indent each line. */ public void print(PrintWriter os, String pad) { if (Debug.isSet("AttributTable")) os.println("Entered AttributeTable.print()"); os.println(pad + getEncodedName() + " {"); for (Enumeration e = getNames(); e.hasMoreElements();) { String name = (String) e.nextElement(); Attribute a = getAttribute(name); if (a != null) a.print(os, pad + " "); } os.println(pad + "}"); if (Debug.isSet("AttributTable")) os.println("Leaving AttributeTable.print()"); os.flush(); }
/** * Print the attribute table on the given <code>PrintWriter</code>. * * @param os the <code>PrintWriter</code> to use for output. * @param pad the number of spaces to indent each line. */ public void print(PrintWriter os, String pad) { if (Debug.isSet("AttributTable")) os.println("Entered AttributeTable.print()"); os.println(pad + getName() + " {"); for (Enumeration e = getNames(); e.hasMoreElements();) { String name = (String) e.nextElement(); Attribute a = getAttribute(name); if (a != null) a.print(os, pad + " "); } os.println(pad + "}"); if (Debug.isSet("AttributTable")) os.println("Leaving AttributeTable.print()"); os.flush(); }
/** * ************************************************************************ * Default handler for the client's help request. * <p/> * <p> Returns an html page of help info for the server * * @param request The client's <code> HttpServletRequest</code> request * object. * @param response The server's <code> HttpServletResponse</code> response * object. */ public void doGetHELP(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { if (Debug.isSet("showResponse")) System.out.println("Sending Help Page."); response.setContentType("text/html"); response.setHeader("XDODS-Server", getServerVersion()); response.setHeader("Content-Description", "dods-help"); // Commented because of a bug in the OPeNDAP C++ stuff... //response.setHeader("Content-Encoding", "plain"); PrintWriter pw = new PrintWriter(new OutputStreamWriter(response.getOutputStream())); printHelpPage(pw); pw.flush(); response.setStatus(HttpServletResponse.SC_OK); }
public void print(PrintWriter os, String pad) { if (Debug.isSet("Alias")) { DAPNode.log.debug(" Attribute \"" + getClearName() + "\" is an Alias."); } os.println(pad + "Alias " + getEncodedName() + " " + getAliasedToAttributeField() + ";"); }
/** * ************************************************************************ * Default handler for the client's version request. * <p/> * <p>Returns a plain text document with server version and OPeNDAP core * version #'s * * @param request The client's <code> HttpServletRequest</code> request * object. * @param response The server's <code> HttpServletResponse</code> response * object. */ public void doGetVER(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { if (Debug.isSet("showResponse")) System.out.println("Sending Version Tag."); response.setContentType("text/plain"); response.setHeader("XDODS-Server", getServerVersion()); response.setHeader("Content-Description", "dods-version"); // Commented because of a bug in the OPeNDAP C++ stuff... //response.setHeader("Content-Encoding", "plain"); PrintWriter pw = new PrintWriter(new OutputStreamWriter(response.getOutputStream())); pw.println("Server Version: " + getServerVersion()); pw.flush(); response.setStatus(HttpServletResponse.SC_OK); }
public void print(PrintWriter os, String pad) { if (Debug.isSet("Alias")) System.out.println(" Attribute \"" + getClearName() + "\" is an Alias."); os.println(pad + "Alias " + getName() + " " + getAliasedToAttributeField() + ";"); }
/** * * @param pw * @param pad * @param constrained * @opendap.ddx.experimental */ public void printXML(PrintWriter pw, String pad, boolean constrained) { if (Debug.isSet("AttributTable")) pw.println("Entered AttributeTable.print()"); pw.println(pad + "<Attribute name=\"" + DDSXMLParser.normalizeToXML(getEncodedName()) + "\" type=\"Container\">"); Enumeration e = getNames(); while (e.hasMoreElements()) { String name = (String) e.nextElement(); Attribute a = getAttribute(name); if (a != null) a.printXML(pw, pad + "\t", constrained); } pw.println(pad + "</Attribute>"); if (Debug.isSet("AttributTable")) pw.println("Leaving AttributeTable.print()"); pw.flush(); }