1 3 56 57 package org.jboss.util.xml.catalog.helpers; 58 59 71 public class Debug { 72 73 protected int debug = 0; 74 75 76 public Debug() { 77 } 79 80 81 public void setDebug(int newDebug) { 82 debug = newDebug; 83 } 84 85 86 public int getDebug() { 87 return debug; 88 } 89 90 101 public void message(int level, String message) { 102 if (debug >= level) { 103 System.out.println(message); 104 } 105 } 106 107 119 public void message(int level, String message, String spec) { 120 if (debug >= level) { 121 System.out.println(message + ": " + spec); 122 } 123 } 124 125 138 public void message(int level, String message, 139 String spec1, String spec2) { 140 if (debug >= level) { 141 System.out.println(message + ": " + spec1); 142 System.out.println("\t" + spec2); 143 } 144 } 145 } 146 | Popular Tags |