mirror of https://github.com/dspinellis/UMLGraph
Code formatting fixes
This commit is contained in:
parent
78ab2dc006
commit
2814117c20
|
|
@ -82,7 +82,7 @@ class ClassGraph {
|
|||
|
||||
protected Map<String, ClassInfo> classnames = new HashMap<String, ClassInfo>();
|
||||
protected Set<String> rootClasses;
|
||||
protected Map<String, ClassDoc> rootClassdocs = new HashMap<String, ClassDoc>();
|
||||
protected Map<String, ClassDoc> rootClassdocs = new HashMap<String, ClassDoc>();
|
||||
protected OptionProvider optionProvider;
|
||||
protected PrintWriter w;
|
||||
protected ClassDoc collectionClassDoc;
|
||||
|
|
@ -673,7 +673,8 @@ class ClassGraph {
|
|||
}
|
||||
}
|
||||
|
||||
/** Returns an array representing the imported classes of c.
|
||||
/**
|
||||
* Returns an array representing the imported classes of c.
|
||||
* Disables the deprecation warning, which is output, because the
|
||||
* imported classed are an implementation detail.
|
||||
*/
|
||||
|
|
@ -848,8 +849,10 @@ class ClassGraph {
|
|||
.append(".html").toString();
|
||||
}
|
||||
|
||||
/** Dot prologue
|
||||
* @throws IOException */
|
||||
/**
|
||||
* Dot prologue
|
||||
* @throws IOException
|
||||
*/
|
||||
public void prologue() throws IOException {
|
||||
Options opt = optionProvider.getGlobalOptions();
|
||||
OutputStream os;
|
||||
|
|
|
|||
|
|
@ -66,7 +66,5 @@ class ClassInfo {
|
|||
public static void reset() {
|
||||
classNumber = 0;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -192,5 +192,4 @@ public class ContextMatcher implements ClassMatcher {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -116,5 +116,4 @@ public class ContextView implements OptionProvider {
|
|||
if (!(matcher.matches(className) || opt.matchesIncludeExpression(className)))
|
||||
opt.setOption(HIDE_OPTIONS);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,5 +38,4 @@ public class InterfaceMatcher implements ClassMatcher {
|
|||
ClassDoc cd = root.classNamed(name);
|
||||
return cd == null ? false : matches(cd);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -130,7 +130,7 @@ public class Options implements Cloneable, OptionProvider {
|
|||
}
|
||||
|
||||
@Override
|
||||
public Object clone() {
|
||||
public Object clone() {
|
||||
Options clone = null;
|
||||
try {
|
||||
clone = (Options) super.clone();
|
||||
|
|
@ -680,5 +680,4 @@ public class Options implements Cloneable, OptionProvider {
|
|||
}
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -20,5 +20,4 @@ public class PackageMatcher implements ClassMatcher {
|
|||
return true;
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -77,5 +77,4 @@ public class PackageView implements OptionProvider {
|
|||
if (!included || this.opt.matchesHideExpression(className))
|
||||
opt.setOption(HIDE);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@
|
|||
*
|
||||
*
|
||||
*/
|
||||
|
||||
package org.umlgraph.doclet;
|
||||
|
||||
import java.util.regex.Pattern;
|
||||
|
|
@ -39,5 +40,4 @@ public class PatternMatcher implements ClassMatcher {
|
|||
public boolean matches(String name) {
|
||||
return pattern.matcher(name).matches();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -36,5 +36,4 @@ public enum RelationDirection {
|
|||
public RelationDirection inverse() {
|
||||
return this == IN ? OUT : this == OUT ? IN : this;
|
||||
}
|
||||
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,5 +46,4 @@ public class RelationPattern {
|
|||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,5 +32,4 @@ public class SubclassMatcher implements ClassMatcher {
|
|||
ClassDoc cd = root.classNamed(name);
|
||||
return cd == null ? false : matches(cd);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -138,12 +138,12 @@ public class UmlGraphDoc {
|
|||
dotExecutable = "dot";
|
||||
}
|
||||
File dotFile = new File(outputFolder, packageName.replace(".", "/") + "/" + name + ".dot");
|
||||
File svgFile = new File(outputFolder, packageName.replace(".", "/") + "/" + name + ".svg");
|
||||
File svgFile = new File(outputFolder, packageName.replace(".", "/") + "/" + name + ".svg");
|
||||
|
||||
try {
|
||||
Process p = Runtime.getRuntime().exec(new String [] {
|
||||
dotExecutable,
|
||||
"-Tsvg",
|
||||
"-Tsvg",
|
||||
"-o",
|
||||
svgFile.getAbsolutePath(),
|
||||
dotFile.getAbsolutePath()
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@
|
|||
*
|
||||
*
|
||||
*/
|
||||
|
||||
package org.umlgraph.doclet;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
|
@ -169,5 +170,4 @@ public class View implements OptionProvider {
|
|||
public String getDisplayName() {
|
||||
return "view " + viewDoc.name();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@
|
|||
*
|
||||
*
|
||||
*/
|
||||
|
||||
package org.umlgraph.doclet;
|
||||
|
||||
import com.sun.javadoc.ProgramElementDoc;
|
||||
|
|
|
|||
|
|
@ -145,5 +145,4 @@ public class BasicTest {
|
|||
differences.add(dotFile.getName() + " is different from the reference");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -304,5 +304,4 @@ public class DotDiff {
|
|||
return "Arc: " + from.label + " -> " + to.label + "; " + line;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -43,5 +43,4 @@ public class RunDoc {
|
|||
com.sun.tools.javadoc.Main.execute("UMLGraph test", pw, pw, pw,
|
||||
"org.umlgraph.doclet.UmlGraphDoc", options);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -55,6 +55,4 @@ public class RunOne {
|
|||
private static void runDoclet(String[] options) {
|
||||
com.sun.tools.javadoc.Main.execute("UMLGraph test", pw, pw, pw, "org.umlgraph.doclet.UmlGraph", options);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@
|
|||
*
|
||||
*
|
||||
*/
|
||||
|
||||
package org.umlgraph.test;
|
||||
|
||||
import java.io.File;
|
||||
|
|
@ -31,4 +32,4 @@ class SimpleFileFilter implements FilenameFilter {
|
|||
public boolean accept(File dir, String name) {
|
||||
return name.endsWith(extension);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,10 +34,10 @@ import java.util.List;
|
|||
public class TestUtils {
|
||||
|
||||
/**
|
||||
* Simple text file diffing: will tell you if two text files are line by
|
||||
* line equals, and will stop at the first difference found.
|
||||
* @throws IOException
|
||||
*/
|
||||
* Simple text file diffing: will tell you if two text files are line by
|
||||
* line equals, and will stop at the first difference found.
|
||||
* @throws IOException
|
||||
*/
|
||||
public static boolean textFilesEquals(PrintWriter pw, File refTextFile, File outTextFile)
|
||||
throws IOException {
|
||||
BufferedReader refReader = null, outReader = null;
|
||||
|
|
@ -123,8 +123,8 @@ public class TestUtils {
|
|||
}
|
||||
|
||||
/**
|
||||
* Deletes the content of the folder, eventually in a recursive way
|
||||
*/
|
||||
* Deletes the content of the folder, eventually in a recursive way
|
||||
*/
|
||||
public static void cleanFolder(File folder, boolean recurse) {
|
||||
for (File f : folder.listFiles()) {
|
||||
if (f.isDirectory()) {
|
||||
|
|
@ -138,7 +138,5 @@ public class TestUtils {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -16,6 +16,7 @@
|
|||
*
|
||||
*
|
||||
*/
|
||||
|
||||
package org.umlgraph.test;
|
||||
|
||||
import java.io.File;
|
||||
|
|
@ -78,14 +79,14 @@ public class UmlDocTest {
|
|||
}
|
||||
|
||||
/**
|
||||
* Ensures that reference and output have the same contents in terms of:
|
||||
* <ul>
|
||||
* <li> html files </li>
|
||||
* <li> dot files </li>
|
||||
* <li> folders </li>
|
||||
* </ul>
|
||||
* @throws IOException
|
||||
*/
|
||||
* Ensures that reference and output have the same contents in terms of:
|
||||
* <ul>
|
||||
* <li> html files </li>
|
||||
* <li> dot files </li>
|
||||
* <li> folders </li>
|
||||
* </ul>
|
||||
* @throws IOException
|
||||
*/
|
||||
private static void compareDocletOutputs(List<String> differences, File refFolder,
|
||||
File outFolder) throws IOException {
|
||||
if (!refFolder.exists() || !refFolder.isDirectory())
|
||||
|
|
@ -139,9 +140,9 @@ public class UmlDocTest {
|
|||
}
|
||||
|
||||
/**
|
||||
* Runs the UmlGraphDoc doclet
|
||||
* @param options
|
||||
*/
|
||||
* Runs the UmlGraphDoc doclet
|
||||
* @param options
|
||||
*/
|
||||
private static void runDoclet(String[] options) {
|
||||
pw.print("Run javadoc -doclet " + doclet);
|
||||
for (String o : options)
|
||||
|
|
@ -150,5 +151,4 @@ public class UmlDocTest {
|
|||
com.sun.tools.javadoc.Main.execute("UMLDoc test", pw, pw, pw,
|
||||
doclet, options);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue