commit 787cc34533f1cc631ef06133bfbb84614fca59c1 Author: Johannes Theiner Date: Tue Mar 5 14:07:16 2019 +0100 first commit Signed-off-by: Johannes Theiner diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..04e3114 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +*.iml +/target \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..2e423cb --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +[Link](https://tomcat.joethei.space/itech/) \ No newline at end of file diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..a6ed7e3 --- /dev/null +++ b/pom.xml @@ -0,0 +1,243 @@ + + + 4.0.0 + + Internet-Technologien + https://tomcat.joethei.space/itech + + de.hsel + itech + 0.1.0-SNAPSHOT + war + + + 1.8 + checkstyle.xml + UTF-8 + + + + + Johannes Theiner + johannes.theiner@informatik-emden.de + + Server Admin + Developer + + + + + + + + + org.apache.tomcat.maven + tomcat7-maven-plugin + 2.2 + + https://tomcat.joethei.space/manager/text + TomcatServer + /itech + + + + org.apache.maven.plugins + maven-war-plugin + 3.1.0 + + + default-war + prepare-package + + false + + + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + ${java.version} + ${java.version} + + + + org.apache.maven.plugins + maven-javadoc-plugin + 3.0.1 + + + org.apache.maven.plugins + maven-surefire-plugin + 3.0.0-M1 + + + + org.apache.maven.plugins + maven-site-plugin + 3.7.1 + + + + + + + + org.apache.maven.plugins + maven-checkstyle-plugin + 3.0.0 + + + com.puppycrawl.tools + checkstyle + 8.17 + + + + ${project.build.sourceEncoding} + true + true + ${checkstyle_file} + + + + verify-style + process-classes + + check + + + + + + + org.apache.maven.plugins + maven-pmd-plugin + 3.11.0 + + ${java.version} + 100 + ${project.build.sourceEncoding} + true + + + + verify-optimization + process-classes + + check + cpd-check + + + + + + + com.github.spotbugs + spotbugs-maven-plugin + 3.1.9 + + Max + Low + false + + + com.h3xstream.findsecbugs + findsecbugs-plugin + 1.8.0 + + + com.mebigfatguy.fb-contrib + fb-contrib + 7.4.3.sb + + + + + + verify-errors + verify + + check + + + + + + + + + + + org.apache.maven.plugins + maven-checkstyle-plugin + + ${checkstyle_file} + + 3.0.0 + + + + checkstyle + + + + + + org.apache.maven.plugins + maven-jxr-plugin + 2.3 + + + com.github.spotbugs + spotbugs-maven-plugin + 3.1.9 + + + + + + + + javax.servlet + javax.servlet-api + 4.0.1 + provided + + + + + + org.projectlombok + lombok + 1.18.4 + compile + + + org.jetbrains + annotations + 13.0 + compile + + + + + org.junit.jupiter + junit-jupiter-api + 5.4.0 + test + + + org.junit.jupiter + junit-jupiter-engine + 5.4.0 + test + + + + + \ No newline at end of file diff --git a/src/main/java/de/hsel/itech/HelloWorld.java b/src/main/java/de/hsel/itech/HelloWorld.java new file mode 100644 index 0000000..73d6694 --- /dev/null +++ b/src/main/java/de/hsel/itech/HelloWorld.java @@ -0,0 +1,40 @@ +package de.hsel.itech; + +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.IOException; +import java.io.PrintWriter; + +/** + * @author Johannes Theiner + * @version 0.1 + * @since 0.1 + **/ +public class HelloWorld extends HttpServlet { + + private static final long serialVersionUID = 15679036735L; + + /** + * doGet. + * + * @param req Request + * @param resp Response + * @throws IOException failed + */ + @Override + protected void doGet(final HttpServletRequest req, final HttpServletResponse resp) + throws IOException { + + resp.setContentType("text/html"); + final PrintWriter out = resp.getWriter(); + out.println(""); + out.println(""); + out.println("Hallo Welt!"); + out.println(""); + out.println(""); + out.println("

Hallo Ostfriesland!

"); + out.println(""); + out.println(""); + } +} diff --git a/src/main/resources/icon.png b/src/main/resources/icon.png new file mode 100644 index 0000000..bb1355d Binary files /dev/null and b/src/main/resources/icon.png differ diff --git a/src/test/java/de/hsel/itech/HelloTest.java b/src/test/java/de/hsel/itech/HelloTest.java new file mode 100644 index 0000000..f9cc0f2 --- /dev/null +++ b/src/test/java/de/hsel/itech/HelloTest.java @@ -0,0 +1,18 @@ +package de.hsel.itech; + +import org.junit.jupiter.api.Test; + +import static org.junit.jupiter.api.Assertions.assertEquals; + +/** + * @author Johannes Theiner + * @version 0.1 + * @since 0.1 + **/ +public class HelloTest { + + @Test + void hello() { + assertEquals(2, 1+1); + } +} \ No newline at end of file diff --git a/src/test/resources/test.txt b/src/test/resources/test.txt new file mode 100644 index 0000000..a92550c --- /dev/null +++ b/src/test/resources/test.txt @@ -0,0 +1 @@ +Hallo Welt \ No newline at end of file