Definition at line 84 of file DoxygenConfig.java.
Public Member Functions | |
DoxygenConfig () | |
final void | setProperty (final String keyName, final String value) |
final void | setProperty (final String keyName, final int value) |
final void | setProperty (final String keyName, final boolean value) |
final TreeMap | getTaskAttributes () |
final List | getNestedAttributes () |
final DoxygenTask.Property | getAttribute (final String keyName) |
void | addNestedAttribute (DoxygenTask.Property attr) |
final void | writeDoxygenConfig (final String theConfigFilename) |
final TreeMap | readDoxygenConfig (String theConfigFilename) |
final void | cascadeDoxygenConfig (final TreeMap map) |
|
Definition at line 122 of file DoxygenConfig.java. References org.doxygen.tools.DoxygenConfig.setProperty().
00122 { 00123 setProperty("DETAILS_AT_TOP", true); 00124 setProperty("FILE_PATTERNS", "*.java"); 00125 setProperty("GENERATE_LATEX", false); 00126 setProperty("HAVE_DOT", false); 00127 setProperty("HIDE_UNDOC_MEMBERS", true); 00128 setProperty("INLINE_SOURCES", true); 00129 setProperty("INPUT", "src"); 00130 setProperty("GENERATE_TREEVIEW", true); 00131 setProperty("OPTIMIZE_OUTPUT_JAVA", true); 00132 setProperty("OUTPUT_DIRECTORY", "doc"); 00133 setProperty("QUIET", true); 00134 setProperty("RECURSIVE", true); 00135 setProperty("SOURCE_BROWSER", true); 00136 setProperty("TOC_EXPAND", true); 00137 } |
|
Add Nested Attribute to the already existing list. Definition at line 268 of file DoxygenConfig.java. Referenced by org.doxygen.tools.DoxygenTask.createProperty(), and org.doxygen.tools.DoxygenTask.setConfig().
00268 { 00269 nestedAttributes.add(attr); 00270 00271 } |
|
This method cascades all Ant task attribute and nest attribute values into the passed TreeMap instance. This TreeMap instance is supposed to have been populated from the generated or user-specified Doxygen configuraton file. <br/>
Definition at line 392 of file DoxygenConfig.java. Referenced by org.doxygen.tools.DoxygenConfig.writeDoxygenConfig().
00392 { 00393 if (taskAttributes.size() > 0) { 00394 Iterator iter = taskAttributes.values().iterator(); 00395 while (iter.hasNext()) { 00396 DoxygenTask.Property attribute = 00397 (DoxygenTask.Property) iter.next(); 00398 map.put(attribute.getName(), attribute.getValue()); 00399 } 00400 } 00401 if (nestedAttributes.size() > 0) { 00402 Iterator iter = nestedAttributes.iterator(); 00403 while (iter.hasNext()) { 00404 DoxygenTask.Property attribute = 00405 (DoxygenTask.Property) iter.next(); 00406 map.put(attribute.getName(), attribute.getValue()); 00407 } 00408 } 00409 } |
|
This method returns the attributes for jUnit test analysis.
Definition at line 252 of file DoxygenConfig.java. Referenced by org.doxygen.tools.DoxygenConfig.setProperty().
00252 { 00253 DoxygenTask.Property retval = null; 00254 if (taskAttributes.containsKey(keyName)) { 00255 retval = (DoxygenTask.Property) taskAttributes.get(keyName); 00256 } 00257 if (retval == null) { 00258 retval = new DoxygenTask.Property(); 00259 retval.setName(keyName); 00260 } 00261 return retval; 00262 } |
|
This method returns the list of nested attributes for jUnit test analysis. <br/>
Definition at line 235 of file DoxygenConfig.java.
00235 {
00236 return nestedAttributes;
00237 }
|
|
This method returns the task attributes for jUnit test analysis. <br/>
Definition at line 218 of file DoxygenConfig.java. Referenced by org.doxygen.tools.DoxygenTask.getTaskAttributes().
00218 {
00219 return taskAttributes;
00220 }
|
|
This method reads the Doxygen generated configuration file. <br/>
Definition at line 343 of file DoxygenConfig.java. Referenced by org.doxygen.tools.DoxygenConfig.writeDoxygenConfig().
00343 { 00344 TreeMap map = new TreeMap(); 00345 Properties p = new Properties(); 00346 try { 00347 p.load(new FileInputStream(theConfigFilename)); 00348 if (p.containsKey("Configuration")) { // bug ID=xxxxxx 00349 p.remove("Configuration"); 00350 p.remove("to"); 00351 p.remove("doxygen"); 00352 p.remove("Now"); 00353 p.remove(""); 00354 } 00355 if (p.containsKey("ROJECT_NUMBER")) { // bug ID=xxxxxx 00356 p.setProperty("PROJECT_NUMBER", p.getProperty("ROJECT_NUMBER")); 00357 p.remove("ROJECT_NUMBER"); 00358 } 00359 Enumeration e = p.keys(); 00360 while (e.hasMoreElements()) { 00361 String arg = (String) e.nextElement(); 00362 map.put(arg, p.getProperty(arg)); 00363 } 00364 } catch (IOException ioe) { 00365 throw new BuildException("Unable to read Doxygen config file: " 00366 + "[" + theConfigFilename + "]", ioe); 00367 } 00368 return map; 00369 } |
|
This method translates an Ant <doxygen> task element into a Doxygen configuration file property name/value pair. <br/>
Definition at line 195 of file DoxygenConfig.java. References org.doxygen.tools.DoxygenConfig.getAttribute().
00196 { 00197 DoxygenTask.Property attribute = getAttribute(keyName); 00198 taskAttributes.put(keyName, attribute); 00199 00200 String val = "YES"; 00201 if (!value) { val = "NO"; } 00202 attribute.setValue(val); 00203 } |
|
This method translates an Ant <doxygen> task element into a Doxygen configuration file property name/value pair.
Definition at line 174 of file DoxygenConfig.java. References org.doxygen.tools.DoxygenConfig.getAttribute().
00175 { 00176 DoxygenTask.Property attribute = getAttribute(keyName); 00177 taskAttributes.put(keyName, attribute); 00178 attribute.setValue("" + value); 00179 } |
|
This method translates an Ant <doxygen> task element into a Doxygen configuration file property name/value pair. <br/>
Definition at line 151 of file DoxygenConfig.java. References org.doxygen.tools.DoxygenConfig.getAttribute(). Referenced by org.doxygen.tools.DoxygenConfig.DoxygenConfig().
00152 { 00153 DoxygenTask.Property attribute = getAttribute(keyName); 00154 taskAttributes.put(keyName, attribute); 00155 00156 String val = value; 00157 if (val.indexOf(' ') > -1) { val = "\"" + val + "\""; } 00158 attribute.setValue(val); 00159 00160 } |
|
This method writes and synchronizes the properties. <br/>
Definition at line 282 of file DoxygenConfig.java. References org.doxygen.tools.DoxygenConfig.cascadeDoxygenConfig(), and org.doxygen.tools.DoxygenConfig.readDoxygenConfig(). Referenced by org.doxygen.tools.DoxygenTask.execute().
00282 { 00283 00284 PrintStream ps = null; 00285 TreeMap map = readDoxygenConfig(theConfigFilename); 00286 cascadeDoxygenConfig(map); 00287 try { 00288 ps = new PrintStream( 00289 new FileOutputStream(DoxygenTask.CONFIG_FILE)); 00290 Set keys = map.entrySet(); 00291 00292 Iterator i = keys.iterator(); 00293 while (i.hasNext()) { 00294 Map.Entry me = (Map.Entry) i.next(); 00295 String param = (String) me.getKey(); 00296 String value = (String) me.getValue(); 00297 String line = param + "\t="; 00298 if (value != null) { line += " " + value; } 00299 ps.println(line); 00300 } 00301 /* activityLog(false, "Updated Doxygen config file: " 00302 + "[" + DoxygenTask.CONFIG_FILE + "]"); 00303 */ 00304 } catch (IOException ioe) { 00305 throw new BuildException("Unable to update Doxygen config file: " 00306 + "[" + theConfigFilename + "]", ioe); 00307 } finally { 00308 if (ps != null) { 00309 ps.close(); 00310 ps = null; 00311 } 00312 } 00313 } |