From 787cc34533f1cc631ef06133bfbb84614fca59c1 Mon Sep 17 00:00:00 2001 From: Johannes Theiner Date: Tue, 5 Mar 2019 14:07:16 +0100 Subject: [PATCH] first commit Signed-off-by: Johannes Theiner --- .gitignore | 2 + README.md | 1 + pom.xml | 243 ++++++++++++++++++++ src/main/java/de/hsel/itech/HelloWorld.java | 40 ++++ src/main/resources/icon.png | Bin 0 -> 1431 bytes src/test/java/de/hsel/itech/HelloTest.java | 18 ++ src/test/resources/test.txt | 1 + 7 files changed, 305 insertions(+) create mode 100644 .gitignore create mode 100644 README.md create mode 100644 pom.xml create mode 100644 src/main/java/de/hsel/itech/HelloWorld.java create mode 100644 src/main/resources/icon.png create mode 100644 src/test/java/de/hsel/itech/HelloTest.java create mode 100644 src/test/resources/test.txt 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 0000000000000000000000000000000000000000..bb1355d11d9c4b5671df0e3fc03156aba2c6b5f6 GIT binary patch literal 1431 zcma)+`!~}K0LH&FbK913OQa!k4>=5Pl-$YY9g18w!kZXMZio1O$uTM_L~gHGt_d}f zOD%~=OL83zSHJet`#I-%KIi!do(xxE$j3 z20T31Y6U-pAX8bP=G`dC`ZNZxQ-z)9B% zcUqaPo0a!9TC<(>zRV+)WEP9MH^(vfSk(JYqop0oNaeZ>M(12dU&qE`0$lY^2nQbw zi`$HdtOEJ)P|z8?4&f$Gm%)p2E|E~C5(kB!i|zq5SXG?5Z)jJMaA6Zz%K*Q#oI!R0 z5}<5I62w@mX-?&VmXm0XW@$|3FM4p94x^D;_yp_)Rrr~HT0Kw+U3SMh*J-S&3!@%B zHP<7vyr;20w)L1dW*HuWJb^s|odsvI*o^T}`gf}SdVnEnHNoX1VgvAnUUP@MSy&Ip-FdFr#D2Lq=hH$z9ZS`>%QOY+&-9PEQT1*5 zTU)qVK5fAZZS8Ivx0oNbV#Z1Xs*v*6TO0f*4^M`2$_F&pZzdjy`B=HXRmt1ARhNMK zMRy{p4eb;%nt2oRio%O!>-gs@&|ITP1~+2zgTjjTL%*U28o$;;x}*JjWP zIpjM;td3B{!#2#OX+jfA+GowCzYLi-X1JxwmpaiBuR5y?cn)+>!aCvb3YBzET+xpX;(vBMVIxG z>;Nr}LCHtJqVX@H=CFDizHhm(yjZfy``6{7LR8`1T03%AhOs45F|XgX^F9Zl9qv{l z1uV%Sp9rtpUL%v zl#0wV7|tv_;a~RC3hm4AgFWMh(^Hg>G3t#iVgf-jDj~Uy1|I6N99hF6yt_(X&Ai2N z{$VTrip3%lMfu~AcDsKtKeMbvle5FXJ-7ccGQR*7%mpP$ z!=y5T5Yvh`L+XXb3sRTeSA(X=bT$+JINh@+8pXt=5P35D{-kE{1V>jXzZzkpw)?Dr Mqb<(n(J4~Oe-z85nE(I) literal 0 HcmV?d00001 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