From: Svjatoslav Agejenko Date: Sun, 24 Dec 2017 13:20:17 +0000 (+0200) Subject: Reorganized project. X-Git-Tag: javainspect-1.7~29 X-Git-Url: http://www2.svjatoslav.eu/gitweb/?a=commitdiff_plain;h=4a2fa09cacf11397bf00407edc2947c23967afeb;p=javainspect.git Reorganized project. + Moved Demo project from test source directory to dedicated project directory. + Added SVG and PNG outputs as configurable options. + Migrated to java 8. --- diff --git a/example/pom.xml b/example/pom.xml deleted file mode 100644 index e3d0312..0000000 --- a/example/pom.xml +++ /dev/null @@ -1,24 +0,0 @@ - - 4.0.0 - com.myproject - myproject - 0.0 - jar - MyProject - MyProject - - - - - org.apache.maven.plugins - maven-compiler-plugin - 2.3.2 - - 1.8 - 1.8 - UTF-8 - - - - - diff --git a/example/src/main/java/com/myproject/Behavior.java b/example/src/main/java/com/myproject/Behavior.java deleted file mode 100644 index d35ce27..0000000 --- a/example/src/main/java/com/myproject/Behavior.java +++ /dev/null @@ -1,10 +0,0 @@ -package com.myproject; - -public interface Behavior { - - String translate(Object obj); - - default String serialize(Object obj) { - return obj.toString(); - } -} diff --git a/example/src/main/java/com/myproject/NumberTranslator.java b/example/src/main/java/com/myproject/NumberTranslator.java deleted file mode 100644 index b0cb6c4..0000000 --- a/example/src/main/java/com/myproject/NumberTranslator.java +++ /dev/null @@ -1,8 +0,0 @@ -package com.myproject; - -public class NumberTranslator implements Behavior { - - public String translate(Object obj) { - return serialize(obj); - } -} diff --git a/javainspect.iml b/javainspect.iml index ea566de..a81dd61 100644 --- a/javainspect.iml +++ b/javainspect.iml @@ -1,15 +1,16 @@ - - - - - - - + + + + + + + + - + \ No newline at end of file diff --git a/pom.xml b/pom.xml index fbdb534..592064d 100644 --- a/pom.xml +++ b/pom.xml @@ -25,8 +25,8 @@ maven-compiler-plugin 2.3.2 - 1.6 - 1.6 + 1.8 + 1.8 UTF-8 @@ -85,7 +85,7 @@ - eu.svjatoslav.inspector.java.methods.Main + eu.svjatoslav.inspector.java.Main @@ -107,7 +107,7 @@ eu.svjatoslav svjatoslavcommons - 1.5 + 1.6 diff --git a/src/main/java/eu/svjatoslav/inspector/java/Main.java b/src/main/java/eu/svjatoslav/inspector/java/Main.java new file mode 100644 index 0000000..f57f787 --- /dev/null +++ b/src/main/java/eu/svjatoslav/inspector/java/Main.java @@ -0,0 +1,29 @@ +package eu.svjatoslav.inspector.java; + +import eu.svjatoslav.inspector.java.structure.ClassGraph; + +import static java.io.File.separator; +import static java.lang.System.getProperty; + +public class Main { + public static void main(String[] args) { + if (args.length == 0) { + System.err.println("usage: javainspect [PROJECT_DIR] [PACKAGE_GLOB] [GRAPH_NAME]"); + System.exit(1); + } + + String projectDir = args[0]; + String packageGlob = args[1]; + String graphName = args[2]; + + ClassGraph cg = new ClassGraph(); + cg.setTargetDirectoryPath(getProperty("user.dir") + separator); + + cg.addProject(projectDir); + cg.whitelistClassPattern(packageGlob); + cg.setKeepDotFile(true); + cg.generateGraph(graphName); + + System.exit(0); + } +} diff --git a/src/main/java/eu/svjatoslav/inspector/java/RenderJavaInspect.java b/src/main/java/eu/svjatoslav/inspector/java/RenderJavaInspect.java new file mode 100755 index 0000000..c33c8a9 --- /dev/null +++ b/src/main/java/eu/svjatoslav/inspector/java/RenderJavaInspect.java @@ -0,0 +1,66 @@ +/* + * JavaInspect - Utility to visualize java software + * Copyright (C) 2013-2015, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of version 3 of the GNU Lesser General Public License + * or later as published by the Free Software Foundation. + */ + +package eu.svjatoslav.inspector.java; + +import eu.svjatoslav.inspector.java.structure.ClassGraph; +import eu.svjatoslav.inspector.java.structure.Utils; + +import java.io.FileNotFoundException; + +public class RenderJavaInspect { + + private static void fullProjectExample() { + // Create graph + final ClassGraph graph = new ClassGraph(); + + // Recursively scan current directory for Java source code and attempt + // to detect class names from there to be added to the graph. + graph.addProject("."); + + // do not show single classes with no relationships on the graph + graph.hideOrphanedClasses(); + + // Produce SVG image titled "JavaInspect full project.png" to the + // user Desktop directory. + graph.generateGraph("JavaInspect full project"); + } + + private static void handpickClassesExample() { + /* + * This example demonstrates generating of class graph from hand picked + * classes and visualizing GraphViz itself. + */ + + // Create graph + final ClassGraph graph = new ClassGraph(); + + // Add some random object to the graph. GraphViz will detect Class from + // the object. + graph.add(graph); + + // Also add some random class to the graph. + graph.add(Utils.class); + + // Keep intermediary GraphViz DOT file for reference. + graph.setKeepDotFile(true); + + // Produce SVG image titled "JavaInspect.svg" to the user Desktop + // directory + graph.generateGraph("JavaInspect"); + } + + public static void main(final String[] args) throws FileNotFoundException { + + handpickClassesExample(); + + fullProjectExample(); + + } +} diff --git a/src/main/java/eu/svjatoslav/inspector/java/methods/Main.java b/src/main/java/eu/svjatoslav/inspector/java/methods/Main.java deleted file mode 100644 index 7450c99..0000000 --- a/src/main/java/eu/svjatoslav/inspector/java/methods/Main.java +++ /dev/null @@ -1,30 +0,0 @@ -package eu.svjatoslav.inspector.java.methods; - -import eu.svjatoslav.inspector.java.structure.ClassGraph; - -import java.io.File; - -import static java.lang.System.getProperty; - -public class Main { - public static void main(String[] args) { - if (args.length == 0) { - System.err.println("usage: javainspect [PROJECT_DIR] [PACKAGE_GLOB] [GRAPH_NAME]"); - System.exit(1); - } - - String projectDir = args[0]; - String packageGlob = args[1]; - String graphName = args[2]; - - ClassGraph cg = new ClassGraph(); - cg.setTargetDirectory(getProperty("user.dir") + File.separator); - - cg.addProject(projectDir); - cg.whitelistClassPattern(packageGlob); - cg.setKeepDotFile(true); - cg.generateGraph(graphName); - - System.exit(0); - } -} diff --git a/src/main/java/eu/svjatoslav/inspector/java/methods/package-info.java b/src/main/java/eu/svjatoslav/inspector/java/methods/package-info.java index 3897205..b18889c 100755 --- a/src/main/java/eu/svjatoslav/inspector/java/methods/package-info.java +++ b/src/main/java/eu/svjatoslav/inspector/java/methods/package-info.java @@ -12,7 +12,8 @@ package eu.svjatoslav.inspector.java.methods; /** * This package contains quickly hacked together Java language parser. * Goal is to start visualizing method call references and other things - * which are not easily readable at runtime via reflection. + * which are not easily readable at runtime via reflection but are available + * when parsing java source code directly. *

* Work in progress... *

diff --git a/src/main/java/eu/svjatoslav/inspector/java/structure/ClassGraph.java b/src/main/java/eu/svjatoslav/inspector/java/structure/ClassGraph.java index c6b6cbf..a4d9015 100755 --- a/src/main/java/eu/svjatoslav/inspector/java/structure/ClassGraph.java +++ b/src/main/java/eu/svjatoslav/inspector/java/structure/ClassGraph.java @@ -23,6 +23,7 @@ import java.util.List; import java.util.Map; import static eu.svjatoslav.inspector.java.methods.JavaFile.UTF_8; +import static java.io.File.separator; public class ClassGraph { @@ -35,11 +36,13 @@ public class ClassGraph { private final List whitelistClassPatterns = new ArrayList(); - private String targetDirectory = CommonPathResolver.getDesktopDirectory() - .getAbsolutePath() + "/"; + private String targetDirectoryPath = CommonPathResolver.getDesktopDirectory() + .getAbsolutePath() + separator; private boolean keepDotFile; + TargetImageType targetImageType = TargetImageType.SVG; + public ClassGraph() { } @@ -84,6 +87,10 @@ public class ClassGraph { blacklistClassPatterns.add(pattern); } + public void setTargetImageType(TargetImageType targetImageType) { + this.targetImageType = targetImageType; + } + /** * @param resultFileName file name for the generated graph. File extension will be * added automatically. Existing file with the same name will be @@ -92,10 +99,8 @@ public class ClassGraph { public void generateGraph(final String resultFileName) { - final String dotFilePath = targetDirectory + resultFileName + ".dot"; - final String imageFilePath = targetDirectory + resultFileName + ".svg"; - - System.out.println("Dot file path:" + dotFilePath); + final String dotFilePath = targetDirectoryPath + resultFileName + ".dot"; + final String imageFilePath = targetDirectoryPath + resultFileName + "." + targetImageType.fileExtension; try { // write DOT file to disk @@ -106,16 +111,18 @@ public class ClassGraph { // execute GraphViz to visualize graph try { Runtime.getRuntime() - .exec(new String[]{"dot", "-Tsvg", dotFilePath, "-o", + .exec(new String[]{"dot", "-T" + targetImageType.fileExtension, dotFilePath, "-o", imageFilePath}).waitFor(); } catch (final InterruptedException ignored) { } if (!keepDotFile) // delete dot file - if (!new File(dotFilePath).delete()) throw new RuntimeException("Cannot delete file: " + dotFilePath); + if (!new File(dotFilePath).delete()) + throw new RuntimeException("Cannot delete file: " + dotFilePath); + } catch (final IOException e) { - System.err.println(e); + throw new RuntimeException("Unable to generate graph: " + e.getMessage(), e); } } @@ -196,11 +203,11 @@ public class ClassGraph { return this; } - public ClassGraph setTargetDirectory(String directoryPath) { - if (!directoryPath.endsWith("/")) - directoryPath += "/"; + public ClassGraph setTargetDirectoryPath(String directoryPath) { + if (!directoryPath.endsWith(separator)) + directoryPath += separator; - targetDirectory = directoryPath; + targetDirectoryPath = directoryPath; return this; } diff --git a/src/main/java/eu/svjatoslav/inspector/java/structure/TargetImageType.java b/src/main/java/eu/svjatoslav/inspector/java/structure/TargetImageType.java new file mode 100644 index 0000000..637724a --- /dev/null +++ b/src/main/java/eu/svjatoslav/inspector/java/structure/TargetImageType.java @@ -0,0 +1,12 @@ +package eu.svjatoslav.inspector.java.structure; + +public enum TargetImageType { + PNG("png"), + SVG("svg"); + + public final String fileExtension; + + TargetImageType(String fileExtension){ + this.fileExtension = fileExtension; + } +} diff --git a/src/main/java/eu/svjatoslav/inspector/java/structure/package-info.java b/src/main/java/eu/svjatoslav/inspector/java/structure/package-info.java new file mode 100755 index 0000000..eee827e --- /dev/null +++ b/src/main/java/eu/svjatoslav/inspector/java/structure/package-info.java @@ -0,0 +1,16 @@ +/* + * JavaInspect - Utility to visualize java software + * Copyright (C) 2013-2015, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of version 3 of the GNU Lesser General Public License + * or later as published by the Free Software Foundation. + */ + +package eu.svjatoslav.inspector.java.structure; + +/** + * This package contains mostly code that inspects java application by traversing + * class references using reflection at runtime. + */ + diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/RenderDemoClasses.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/RenderDemoClasses.java deleted file mode 100755 index 90aa480..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/RenderDemoClasses.java +++ /dev/null @@ -1,24 +0,0 @@ -/* - * JavaInspect - Utility to visualize java software - * Copyright (C) 2013-2015, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of version 3 of the GNU Lesser General Public License - * or later as published by the Free Software Foundation. - */ - -package eu.svjatoslav.inspector.java.structure.example; - -import eu.svjatoslav.inspector.java.structure.ClassGraph; -import eu.svjatoslav.inspector.java.structure.example.structure.SampleClass; -import eu.svjatoslav.inspector.java.structure.example.structure.SampleClass2; - -public class RenderDemoClasses { - - public static void main(final String[] args) { - - new ClassGraph().add(SampleClass.class, SampleClass2.class) - .generateGraph("example"); - } - -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/RenderJavaInspect.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/RenderJavaInspect.java deleted file mode 100755 index 1f38883..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/RenderJavaInspect.java +++ /dev/null @@ -1,69 +0,0 @@ -/* - * JavaInspect - Utility to visualize java software - * Copyright (C) 2013-2015, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of version 3 of the GNU Lesser General Public License - * or later as published by the Free Software Foundation. - */ - -package eu.svjatoslav.inspector.java.structure.example; - -import eu.svjatoslav.inspector.java.structure.ClassGraph; -import eu.svjatoslav.inspector.java.structure.Utils; - -import java.io.FileNotFoundException; - -public class RenderJavaInspect { - - private static void fullProjectExample() { - // Create graph - final ClassGraph graph = new ClassGraph(); - - // Recursively scan current directory for Java source code and attempt - // to detect class names from there to be added to the graph. - graph.addProject("."); - - // Blacklist example classes from being shown on the graph - graph.blacklistClassPattern("eu.svjatoslav.inspector.java.structure.example.*"); - - // do not show single classes with no relationships on the graph - graph.hideOrphanedClasses(); - - // Produce bitmap image titled "JavaInspect full project.png" to the - // user Desktop directory. - graph.generateGraph("JavaInspect full project"); - } - - private static void handpickClassesExample() { - /* - * This example demonstrates generating of class graph from hand picked - * classes and visualizing GraphViz itself. - */ - - // Create graph - final ClassGraph graph = new ClassGraph(); - - // Add some random object to the graph. GraphViz will detect Class from - // the object. - graph.add(graph); - - // Also add some random class to the graph. - graph.add(Utils.class); - - // Keep intermediary GraphViz DOT file for reference. - graph.setKeepDotFile(true); - - // Produce bitmap image titled "JavaInspect.png" to the user Desktop - // directory - graph.generateGraph("JavaInspect"); - } - - public static void main(final String[] args) throws FileNotFoundException { - - handpickClassesExample(); - - fullProjectExample(); - - } -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/ObjectReturnedByMethod.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/ObjectReturnedByMethod.java deleted file mode 100755 index 3e507bb..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/ObjectReturnedByMethod.java +++ /dev/null @@ -1,5 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public class ObjectReturnedByMethod { - -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/ObjectVisibleAsClassField.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/ObjectVisibleAsClassField.java deleted file mode 100755 index c69a881..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/ObjectVisibleAsClassField.java +++ /dev/null @@ -1,5 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public class ObjectVisibleAsClassField { - -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleClass.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleClass.java deleted file mode 100755 index 9336717..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleClass.java +++ /dev/null @@ -1,11 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public class SampleClass extends SampleSuperClass { - - ObjectVisibleAsClassField sampleClassField; - - public ObjectReturnedByMethod sampleMethod() { - return new ObjectReturnedByMethod(); - } - -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleClass2.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleClass2.java deleted file mode 100644 index 83b5205..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleClass2.java +++ /dev/null @@ -1,5 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public class SampleClass2 extends SampleSuperClass { - -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleEnum.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleEnum.java deleted file mode 100755 index 05a3f80..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleEnum.java +++ /dev/null @@ -1,7 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public enum SampleEnum { - - ONE, TWO, THREE, FOUR - -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleInterface.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleInterface.java deleted file mode 100755 index e9d6bc5..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleInterface.java +++ /dev/null @@ -1,5 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public interface SampleInterface { - SampleEnum getSomeValue(); -} diff --git a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleSuperClass.java b/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleSuperClass.java deleted file mode 100755 index 10de17e..0000000 --- a/src/test/java/eu/svjatoslav/inspector/java/structure/example/structure/SampleSuperClass.java +++ /dev/null @@ -1,10 +0,0 @@ -package eu.svjatoslav.inspector.java.structure.example.structure; - -public class SampleSuperClass implements SampleInterface { - - @Override - public SampleEnum getSomeValue() { - return SampleEnum.ONE; - } - -} diff --git a/usage examples/demo project/.gitignore b/usage examples/demo project/.gitignore new file mode 100644 index 0000000..2d513a0 --- /dev/null +++ b/usage examples/demo project/.gitignore @@ -0,0 +1,2 @@ +/.idea/ +/target/ diff --git a/usage examples/demo project/javainspect-demo.iml b/usage examples/demo project/javainspect-demo.iml new file mode 100644 index 0000000..42e85c2 --- /dev/null +++ b/usage examples/demo project/javainspect-demo.iml @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/usage examples/demo project/pom.xml b/usage examples/demo project/pom.xml new file mode 100644 index 0000000..faee7f6 --- /dev/null +++ b/usage examples/demo project/pom.xml @@ -0,0 +1,40 @@ + + 4.0.0 + eu.svjatoslav + javainspect-demo + 1.0-SNAPSHOT + jar + Java inspect demo + Demonstration project for Java inspect utility + + + + + org.apache.maven.plugins + maven-compiler-plugin + 2.3.2 + + 1.8 + 1.8 + UTF-8 + + + + + + + + eu.svjatoslav + javainspect + 1.7-SNAPSHOT + + + + + + svjatoslav.eu + Svjatoslav repository + http://www2.svjatoslav.eu/maven/ + + + diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/RenderUsingReflection.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/RenderUsingReflection.java new file mode 100755 index 0000000..df0ac1b --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/RenderUsingReflection.java @@ -0,0 +1,24 @@ +/* + * JavaInspect - Utility to visualize java software + * Copyright (C) 2013-2015, Svjatoslav Agejenko, svjatoslav@svjatoslav.eu + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of version 3 of the GNU Lesser General Public License + * or later as published by the Free Software Foundation. + */ + +package eu.svjatoslav.inspector.java.structure.example; + +import eu.svjatoslav.inspector.java.structure.ClassGraph; +import eu.svjatoslav.inspector.java.structure.example.torender.SampleClass; +import eu.svjatoslav.inspector.java.structure.example.torender.SampleClass2; + +public class RenderUsingReflection { + + public static void main(final String[] args) { + + new ClassGraph().add(SampleClass.class, SampleClass2.class) + .generateGraph("example"); + } + +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/ObjectReturnedByMethod.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/ObjectReturnedByMethod.java new file mode 100755 index 0000000..143ab77 --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/ObjectReturnedByMethod.java @@ -0,0 +1,5 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public class ObjectReturnedByMethod { + +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/ObjectVisibleAsClassField.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/ObjectVisibleAsClassField.java new file mode 100755 index 0000000..db5b5cc --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/ObjectVisibleAsClassField.java @@ -0,0 +1,5 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public class ObjectVisibleAsClassField { + +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleClass.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleClass.java new file mode 100755 index 0000000..9720c44 --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleClass.java @@ -0,0 +1,11 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public class SampleClass extends SampleSuperClass { + + ObjectVisibleAsClassField sampleClassField; + + public ObjectReturnedByMethod sampleMethod() { + return new ObjectReturnedByMethod(); + } + +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleClass2.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleClass2.java new file mode 100644 index 0000000..a2eba71 --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleClass2.java @@ -0,0 +1,5 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public class SampleClass2 extends SampleSuperClass { + +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleEnum.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleEnum.java new file mode 100755 index 0000000..ee8bf9e --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleEnum.java @@ -0,0 +1,7 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public enum SampleEnum { + + ONE, TWO, THREE, FOUR + +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleInterface.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleInterface.java new file mode 100755 index 0000000..648327f --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleInterface.java @@ -0,0 +1,5 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public interface SampleInterface { + SampleEnum getSomeValue(); +} diff --git a/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleSuperClass.java b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleSuperClass.java new file mode 100755 index 0000000..9230509 --- /dev/null +++ b/usage examples/demo project/src/main/java/eu/svjatoslav/inspector/java/structure/example/torender/SampleSuperClass.java @@ -0,0 +1,10 @@ +package eu.svjatoslav.inspector.java.structure.example.torender; + +public class SampleSuperClass implements SampleInterface { + + @Override + public SampleEnum getSomeValue() { + return SampleEnum.ONE; + } + +} diff --git a/usage examples/demo project/tools/open with IntelliJ IDEA b/usage examples/demo project/tools/open with IntelliJ IDEA new file mode 100755 index 0000000..1f82875 --- /dev/null +++ b/usage examples/demo project/tools/open with IntelliJ IDEA @@ -0,0 +1,6 @@ +#!/bin/bash + +cd "${0%/*}" + +cd .. +idea .