<target depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest" name="do-dist"/> | <target depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest" name="do-dist"/> | ||||
<target depends="init" if="dist.ear.dir" name="library-inclusion-in-manifest"> | <target depends="init" if="dist.ear.dir" name="library-inclusion-in-manifest"> | ||||
<copyfiles files="${libs.javaee-web-api-7.0.classpath}" iftldtodir="${build.web.dir}/WEB-INF" todir="${dist.ear.dir}/lib"/> | <copyfiles files="${libs.javaee-web-api-7.0.classpath}" iftldtodir="${build.web.dir}/WEB-INF" todir="${dist.ear.dir}/lib"/> | ||||
<copyfiles files="${file.reference.jackson-annotations-2.9.0.jar}" iftldtodir="${build.web.dir}/WEB-INF" todir="${dist.ear.dir}/lib"/> | |||||
<copyfiles files="${file.reference.jackson-core-2.9.9.jar}" iftldtodir="${build.web.dir}/WEB-INF" todir="${dist.ear.dir}/lib"/> | |||||
<copyfiles files="${file.reference.jackson-databind-2.9.9.jar}" iftldtodir="${build.web.dir}/WEB-INF" todir="${dist.ear.dir}/lib"/> | |||||
<copyfiles files="${libs.MyLibrary.classpath}" iftldtodir="${build.web.dir}/WEB-INF" todir="${dist.ear.dir}/lib"/> | |||||
<mkdir dir="${build.web.dir}/META-INF"/> | <mkdir dir="${build.web.dir}/META-INF"/> | ||||
<manifest file="${build.web.dir}/META-INF/MANIFEST.MF" mode="update"/> | <manifest file="${build.web.dir}/META-INF/MANIFEST.MF" mode="update"/> | ||||
</target> | </target> | ||||
<target depends="init" name="library-inclusion-in-archive" unless="dist.ear.dir"> | <target depends="init" name="library-inclusion-in-archive" unless="dist.ear.dir"> | ||||
<copyfiles files="${libs.javaee-web-api-7.0.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> | <copyfiles files="${libs.javaee-web-api-7.0.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> | ||||
<copyfiles files="${file.reference.jackson-annotations-2.9.0.jar}" todir="${build.web.dir}/WEB-INF/lib"/> | |||||
<copyfiles files="${file.reference.jackson-core-2.9.9.jar}" todir="${build.web.dir}/WEB-INF/lib"/> | |||||
<copyfiles files="${file.reference.jackson-databind-2.9.9.jar}" todir="${build.web.dir}/WEB-INF/lib"/> | |||||
<copyfiles files="${libs.MyLibrary.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> | |||||
</target> | </target> | ||||
<target depends="init" if="dist.ear.dir" name="-clean-webinf-lib"> | <target depends="init" if="dist.ear.dir" name="-clean-webinf-lib"> | ||||
<delete dir="${build.web.dir}/WEB-INF/lib"/> | <delete dir="${build.web.dir}/WEB-INF/lib"/> |
build.xml.data.CRC32=20a1ec55 | |||||
build.xml.data.CRC32=da94db35 | |||||
build.xml.script.CRC32=2d64e8d1 | build.xml.script.CRC32=2d64e8d1 | ||||
build.xml.stylesheet.CRC32=651128d4@1.77.1.1 | build.xml.stylesheet.CRC32=651128d4@1.77.1.1 | ||||
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml. | # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml. | ||||
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you. | # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you. | ||||
nbproject/build-impl.xml.data.CRC32=20a1ec55 | |||||
nbproject/build-impl.xml.script.CRC32=b4f5594b | |||||
nbproject/build-impl.xml.data.CRC32=da94db35 | |||||
nbproject/build-impl.xml.script.CRC32=7578d253 | |||||
nbproject/build-impl.xml.stylesheet.CRC32=99ea4b56@1.77.1.1 | nbproject/build-impl.xml.stylesheet.CRC32=99ea4b56@1.77.1.1 |
endorsed.classpath=\ | endorsed.classpath=\ | ||||
${libs.javaee-endorsed-api-7.0.classpath} | ${libs.javaee-endorsed-api-7.0.classpath} | ||||
excludes= | excludes= | ||||
file.reference.jackson-annotations-2.9.0.jar=C:\\Users\\Edi\\Desktop\\jackson-annotations-2.9.0.jar | |||||
file.reference.jackson-core-2.9.9.jar=C:\\Users\\Edi\\Desktop\\jackson-core-2.9.9.jar | |||||
file.reference.jackson-databind-2.9.9.jar=C:\\Users\\Edi\\Desktop\\jackson-databind-2.9.9.jar | |||||
includes=** | includes=** | ||||
j2ee.compile.on.save=true | j2ee.compile.on.save=true | ||||
j2ee.copy.static.files.on.save=true | j2ee.copy.static.files.on.save=true | ||||
jar.compress=false | jar.compress=false | ||||
javac.classpath=\ | javac.classpath=\ | ||||
${libs.javaee-web-api-7.0.classpath}:\ | ${libs.javaee-web-api-7.0.classpath}:\ | ||||
${file.reference.jackson-annotations-2.9.0.jar}:\ | |||||
${file.reference.jackson-core-2.9.9.jar}:\ | |||||
${file.reference.jackson-databind-2.9.9.jar} | |||||
${libs.MyLibrary.classpath} | |||||
# Space-separated list of extra javac options | # Space-separated list of extra javac options | ||||
javac.compilerargs= | javac.compilerargs= | ||||
javac.debug=true | javac.debug=true |
<path-in-war>WEB-INF/lib</path-in-war> | <path-in-war>WEB-INF/lib</path-in-war> | ||||
</library> | </library> | ||||
<library dirs="200"> | <library dirs="200"> | ||||
<file>${file.reference.jackson-annotations-2.9.0.jar}</file> | |||||
<path-in-war>WEB-INF/lib</path-in-war> | |||||
</library> | |||||
<library dirs="200"> | |||||
<file>${file.reference.jackson-core-2.9.9.jar}</file> | |||||
<path-in-war>WEB-INF/lib</path-in-war> | |||||
</library> | |||||
<library dirs="200"> | |||||
<file>${file.reference.jackson-databind-2.9.9.jar}</file> | |||||
<file>${libs.MyLibrary.classpath}</file> | |||||
<path-in-war>WEB-INF/lib</path-in-war> | <path-in-war>WEB-INF/lib</path-in-war> | ||||
</library> | </library> | ||||
</web-module-libraries> | </web-module-libraries> |
import com.fasterxml.jackson.core.type.TypeReference; | import com.fasterxml.jackson.core.type.TypeReference; | ||||
import com.fasterxml.jackson.databind.JsonMappingException; | import com.fasterxml.jackson.databind.JsonMappingException; | ||||
import com.fasterxml.jackson.databind.ObjectMapper; | import com.fasterxml.jackson.databind.ObjectMapper; | ||||
import java.io.BufferedReader; | import java.io.BufferedReader; | ||||
import java.io.DataOutputStream; | import java.io.DataOutputStream; | ||||
import java.io.File; | import java.io.File; |
import java.io.FileNotFoundException; | import java.io.FileNotFoundException; | ||||
import java.io.IOException; | import java.io.IOException; | ||||
import java.io.PrintWriter; | import java.io.PrintWriter; | ||||
import java.io.UnsupportedEncodingException; | |||||
import static java.nio.charset.StandardCharsets.UTF_8; | import static java.nio.charset.StandardCharsets.UTF_8; | ||||
import java.util.ArrayList; | import java.util.ArrayList; | ||||
import java.util.Arrays; | import java.util.Arrays; |