From d62cdeb376fb5f0749ce637723a6cb305485aad8 Mon Sep 17 00:00:00 2001 From: Santo Cariotti Date: Wed, 19 Jan 2022 22:51:57 +0100 Subject: wsdl: add examples --- Year_3/TSDWL/WSDL/FootballClient/build.xml | 71 + Year_3/TSDWL/WSDL/FootballClient/catalog.xml | 4 + .../WSDL/FootballClient/nbproject/ant-deploy.xml | 76 + .../WSDL/FootballClient/nbproject/build-impl.xml | 1442 ++++++++++++++++ .../FootballClient/nbproject/genfiles.properties | 8 + .../TSDWL/WSDL/FootballClient/nbproject/jax-ws.xml | 38 + .../WSDL/FootballClient/nbproject/jaxws-build.xml | 46 + .../FootballClient/nbproject/project.properties | 84 + .../WSDL/FootballClient/nbproject/project.xml | 23 + .../TSDWL/WSDL/FootballClient/src/conf/MANIFEST.MF | 2 + .../ws.footballpool.dataaccess.eu/info.wso.wsdl | 1822 ++++++++++++++++++++ .../src/java/it/dmi/exams/tsdwl/StadiumInfo.java | 87 + .../src/java/it/dmi/exams/tsdwl/StadiumList.java | 103 ++ .../WSDL/FootballClient/web/META-INF/context.xml | 2 + .../FootballClient/web/WEB-INF/jax-ws-catalog.xml | 4 + Year_3/TSDWL/WSDL/FootballClient/web/index.html | 16 + Year_3/TSDWL/WSDL/FootballClient/web/list.jsp | 24 + Year_3/TSDWL/WSDL/FootballClient/web/search.html | 22 + 18 files changed, 3874 insertions(+) create mode 100644 Year_3/TSDWL/WSDL/FootballClient/build.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/catalog.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/ant-deploy.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/build-impl.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/genfiles.properties create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/jax-ws.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/jaxws-build.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/project.properties create mode 100644 Year_3/TSDWL/WSDL/FootballClient/nbproject/project.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/src/conf/MANIFEST.MF create mode 100644 Year_3/TSDWL/WSDL/FootballClient/src/conf/xml-resources/web-service-references/info/wsdl/ws.footballpool.dataaccess.eu/info.wso.wsdl create mode 100644 Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumInfo.java create mode 100644 Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumList.java create mode 100644 Year_3/TSDWL/WSDL/FootballClient/web/META-INF/context.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/web/WEB-INF/jax-ws-catalog.xml create mode 100644 Year_3/TSDWL/WSDL/FootballClient/web/index.html create mode 100644 Year_3/TSDWL/WSDL/FootballClient/web/list.jsp create mode 100644 Year_3/TSDWL/WSDL/FootballClient/web/search.html (limited to 'Year_3/TSDWL/WSDL/FootballClient') diff --git a/Year_3/TSDWL/WSDL/FootballClient/build.xml b/Year_3/TSDWL/WSDL/FootballClient/build.xml new file mode 100644 index 0000000..d5b88b4 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/build.xml @@ -0,0 +1,71 @@ + + + + + + + + + + + Builds, tests, and runs the project FootballClient. + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/catalog.xml b/Year_3/TSDWL/WSDL/FootballClient/catalog.xml new file mode 100644 index 0000000..3670a69 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/catalog.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/ant-deploy.xml b/Year_3/TSDWL/WSDL/FootballClient/nbproject/ant-deploy.xml new file mode 100644 index 0000000..55566c8 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/ant-deploy.xml @@ -0,0 +1,76 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/build-impl.xml b/Year_3/TSDWL/WSDL/FootballClient/nbproject/build-impl.xml new file mode 100644 index 0000000..f20ac3d --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/build-impl.xml @@ -0,0 +1,1442 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must set src.dir + Must set test.src.dir + Must set build.dir + Must set build.web.dir + Must set build.generated.dir + Must set dist.dir + Must set build.classes.dir + Must set dist.javadoc.dir + Must set build.test.classes.dir + Must set build.test.results.dir + Must set build.classes.excludes + Must set dist.war + + + + + + + + + +The Java EE server classpath is not correctly set up - server home directory is missing. +Either open the project in the IDE and assign the server or setup the server classpath manually. +For example like this: + ant -Dj2ee.server.home=<app_server_installation_directory> + + +The Java EE server classpath is not correctly set up. Your active server type is ${j2ee.server.type}. +Either open the project in the IDE and assign the server or setup the server classpath manually. +For example like this: + ant -Duser.properties.file=<path_to_property_file> (where you put the property "j2ee.platform.classpath" in a .properties file) +or ant -Dj2ee.platform.classpath=<server_classpath> (where no properties file is used) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must set javac.includes + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + No tests executed. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +The libs.CopyLibs.classpath property is not set up. +This property must point to +org-netbeans-modules-java-j2seproject-copylibstask.jar file which is part +of NetBeans IDE installation and is usually located at +<netbeans_installation>/java<version>/ant/extra folder. +Either open the project in the IDE and make sure CopyLibs library +exists or setup the property manually. For example like this: + ant -Dlibs.CopyLibs.classpath=a/path/to/org-netbeans-modules-java-j2seproject-copylibstask.jar + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must set JVM to use for profiling in profiler.info.jvm + Must set profiler agent JVM arguments in profiler.info.jvmargs.agent + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must select some files in the IDE or set javac.includes + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must select some files in the IDE or set javac.jsp.includes + + + + + + + + + + + + + + + + + + + + + + + + + + Must select a file in the IDE or set jsp.includes + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Browser not found, cannot launch the deployed application. Try to set the BROWSER environment variable. + + + Launching ${browse.url} + + + + + + Must select one file in the IDE or set run.class + + + + Must select one file in the IDE or set run.class + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must select one file in the IDE or set debug.class + + + + + + + + + + + + Must select one file in the IDE or set debug.class + + + + + Must set fix.includes + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + This target only works when run from inside the NetBeans IDE. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Must select some files in the IDE or set javac.includes + + + + + + + + + + + + + + + + + + + Some tests failed; see details above. + + + + + + + + + Must select some files in the IDE or set test.includes + + + + Some tests failed; see details above. + + + + Must select some files in the IDE or set test.class + Must select some method in the IDE or set test.method + + + + Some tests failed; see details above. + + + + + Must select one file in the IDE or set test.class + + + + Must select one file in the IDE or set test.class + Must select some method in the IDE or set test.method + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/genfiles.properties b/Year_3/TSDWL/WSDL/FootballClient/nbproject/genfiles.properties new file mode 100644 index 0000000..31d747b --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/genfiles.properties @@ -0,0 +1,8 @@ +build.xml.data.CRC32=aaea0a1d +build.xml.script.CRC32=c8a5d28b +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. +# 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=aaea0a1d +nbproject/build-impl.xml.script.CRC32=67c6fda6 +nbproject/build-impl.xml.stylesheet.CRC32=99ea4b56@1.77.1.1 diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/jax-ws.xml b/Year_3/TSDWL/WSDL/FootballClient/nbproject/jax-ws.xml new file mode 100644 index 0000000..8248530 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/jax-ws.xml @@ -0,0 +1,38 @@ + + + + + + https://ws.footballpool.dataaccess.eu/info.wso?WSDL + ws.footballpool.dataaccess.eu/info.wso.wsdl + eu.dataaccess.footballpool + catalog.xml + + + extension + true + + + verbose + true + + + fork + false + + + wsdlLocation + https://ws.footballpool.dataaccess.eu/info.wso?WSDL + + + xnocompile + true + + + xendorsed + true + + + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/jaxws-build.xml b/Year_3/TSDWL/WSDL/FootballClient/nbproject/jaxws-build.xml new file mode 100644 index 0000000..9bd9d81 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/jaxws-build.xml @@ -0,0 +1,46 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/project.properties b/Year_3/TSDWL/WSDL/FootballClient/nbproject/project.properties new file mode 100644 index 0000000..b8637ec --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/project.properties @@ -0,0 +1,84 @@ +annotation.processing.enabled=true +annotation.processing.enabled.in.editor=true +annotation.processing.processors.list= +annotation.processing.run.all.processors=true +annotation.processing.source.output=${build.generated.sources.dir}/ap-source-output +build.classes.dir=${build.web.dir}/WEB-INF/classes +build.classes.excludes=**/*.java,**/*.form +build.dir=build +build.generated.dir=${build.dir}/generated +build.generated.sources.dir=${build.dir}/generated-sources +build.test.classes.dir=${build.dir}/test/classes +build.test.results.dir=${build.dir}/test/results +build.web.dir=${build.dir}/web +build.web.excludes=${build.classes.excludes} +client.urlPart= +compile.jsps=false +conf.dir=${source.root}/conf +debug.classpath=${build.classes.dir}:${javac.classpath} +debug.test.classpath=\ + ${run.test.classpath} +display.browser=true +# Files to be excluded from distribution war +dist.archive.excludes= +dist.dir=dist +dist.ear.war=${dist.dir}/${war.ear.name} +dist.javadoc.dir=${dist.dir}/javadoc +dist.war=${dist.dir}/${war.name} +endorsed.classpath=\ + ${libs.javaee-endorsed-api-7.0.classpath} +excludes= +includes=** +j2ee.compile.on.save=true +j2ee.copy.static.files.on.save=true +j2ee.deploy.on.save=true +j2ee.platform=1.7-web +j2ee.platform.classpath=${j2ee.server.home}/lib/annotations-api.jar:${j2ee.server.home}/lib/catalina-ant.jar:${j2ee.server.home}/lib/catalina-ha.jar:${j2ee.server.home}/lib/catalina-storeconfig.jar:${j2ee.server.home}/lib/catalina-tribes.jar:${j2ee.server.home}/lib/catalina.jar:${j2ee.server.home}/lib/ecj-4.4.2.jar:${j2ee.server.home}/lib/el-api.jar:${j2ee.server.home}/lib/jasper-el.jar:${j2ee.server.home}/lib/jasper.jar:${j2ee.server.home}/lib/jsp-api.jar:${j2ee.server.home}/lib/servlet-api.jar:${j2ee.server.home}/lib/tomcat-api.jar:${j2ee.server.home}/lib/tomcat-coyote.jar:${j2ee.server.home}/lib/tomcat-dbcp.jar:${j2ee.server.home}/lib/tomcat-i18n-es.jar:${j2ee.server.home}/lib/tomcat-i18n-fr.jar:${j2ee.server.home}/lib/tomcat-i18n-ja.jar:${j2ee.server.home}/lib/tomcat-jdbc.jar:${j2ee.server.home}/lib/tomcat-jni.jar:${j2ee.server.home}/lib/tomcat-util-scan.jar:${j2ee.server.home}/lib/tomcat-util.jar:${j2ee.server.home}/lib/tomcat-websocket.jar:${j2ee.server.home}/lib/websocket-api.jar +j2ee.server.type=Tomcat +jar.compress=false +javac.classpath= +# Space-separated list of extra javac options +javac.compilerargs= +javac.debug=true +javac.deprecation=false +javac.processorpath=\ + ${javac.classpath} +javac.source=1.8 +javac.target=1.8 +javac.test.classpath=\ + ${javac.classpath}:\ + ${build.classes.dir} +javac.test.processorpath=\ + ${javac.test.classpath} +javadoc.additionalparam= +javadoc.author=false +javadoc.encoding=${source.encoding} +javadoc.noindex=false +javadoc.nonavbar=false +javadoc.notree=false +javadoc.preview=true +javadoc.private=false +javadoc.splitindex=true +javadoc.use=true +javadoc.version=false +javadoc.windowtitle= +lib.dir=${web.docbase.dir}/WEB-INF/lib +no.dependencies=false +persistence.xml.dir=${conf.dir} +platform.active=default_platform +resource.dir=setup +run.test.classpath=\ + ${javac.test.classpath}:\ + ${build.test.classes.dir} +# Space-separated list of JVM arguments used when running a class with a main method or a unit test +# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value): +runmain.jvmargs= +source.encoding=UTF-8 +source.root=src +src.dir=${source.root}/java +test.src.dir=test +war.content.additional= +war.ear.name=${war.name} +war.name=FootballClient.war +web.docbase.dir=web +webinf.dir=web/WEB-INF diff --git a/Year_3/TSDWL/WSDL/FootballClient/nbproject/project.xml b/Year_3/TSDWL/WSDL/FootballClient/nbproject/project.xml new file mode 100644 index 0000000..eb85024 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/nbproject/project.xml @@ -0,0 +1,23 @@ + + + org.netbeans.modules.web.project + + + + + + + + FootballClient + 1.6.5 + + + + + + + + + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/src/conf/MANIFEST.MF b/Year_3/TSDWL/WSDL/FootballClient/src/conf/MANIFEST.MF new file mode 100644 index 0000000..59499bc --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/src/conf/MANIFEST.MF @@ -0,0 +1,2 @@ +Manifest-Version: 1.0 + diff --git a/Year_3/TSDWL/WSDL/FootballClient/src/conf/xml-resources/web-service-references/info/wsdl/ws.footballpool.dataaccess.eu/info.wso.wsdl b/Year_3/TSDWL/WSDL/FootballClient/src/conf/xml-resources/web-service-references/info/wsdl/ws.footballpool.dataaccess.eu/info.wso.wsdl new file mode 100644 index 0000000..194bce6 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/src/conf/xml-resources/web-service-references/info/wsdl/ws.footballpool.dataaccess.eu/info.wso.wsdl @@ -0,0 +1,1822 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Returns an array with the information about the given yellow and red cards in all games. What date, minute, teams that were playing and player name + + + + + Returns an array with the id, name, country and flag reference of all players. Pass a 0 for all players and 1 for only the selected players. + + + + + Returns an array with the names of all players that have a yellow or a red card. The number of yellow and red cards is returned. + + + + + Returns an array with the names of all players that have the passed player role. If you pass a team name the result will be filtered on that team. For possible team names call the function TeamNames. For possible role codes call the function PlayerRoles + + + + + Returns an array with the information stored about all stadiums. The array contains the names, the city where the stadium can be found, the seat capacity, the google maps and wikipedia URLs + + + + + Returns an array with the names of all the coaches and the team name he/she is coaching + + + + + Returns the total number of red or yellow cards given for all games (iGameNumber < 1) or a specific game. For the game numbers call the function ResultsAllGames + + + + + Returns an array with all the city names where games are played + + + + + Get the top 25 countries starting with or containing the value of sName + + + + + Returns an array with a play levels and per level the start and end game date and ID + + + + + Returns an array of Game IDs grouped by City Name + + + + + Returns the results of a given game (pass the game ID). For the game numbers call the function ResultsAllGames + + + + + Returns the score for a team in a game. For the game numbers call the function ResultsAllGames. For the team ID call the function Teams + + + + + Returns the total number of goals scored + + + + + Returns the date of the first game in this group + + + + + Returns a list of groups (poule phase and later round of 16 etc) and the information such as name and date first and last game + + + + + Returns the date of the last game in this group. For the group code call the function GroupInfo + + + + + Returns an the standings in each group by passing the group ID. For the group ID call the function GroupInfo + + + + + Returns the date of the first game in this level. For a level Number call the Levels Function. + + + + + Returns the date of the last game in this level For a level number call the Levels function. For a level Number call the Levels Function. + + + + + Returns a array with level numbers. The numbers can be used in functions that require or offer an option to pass a level number such as LevelFirstGameDate + + + + + Returns a list with tournament dates + + + + + Returns an array with the next games of date that is greater than or equal to today. Only games of one day are returned. + + + + + Get the top 10 players where name, fullname, firstname or lastname contains the value of sName + + + + + Returns an array with the roles a player can have (defender etc) + + + + + Returns an array with the names of all players that have a yellow or a red card. The number of yellow and red cards is returned. + + + + + Returns an array with the names of all players that have scored a goal. + + + + + Returns game result of all games overall, in one group or at one level. When groupid < 1 All games are processed (optionally filtered by level). A Group ID or level can be retrieved via GroupInfo. + + + + + Returns a URL that can be used to show a small map of the stadium. For the name of the stadium call the funciton StadiumNames + + + + + Returns the information stored about a particular stadium. For that pass the exact name of the stadium. For the name of the stadium call the funciton StadiumNames + + + + + Returns an array of stadium names where the games are played + + + + + Returns a list of team IDs based on passed GroupCode (e.g A or H). For the group code call the function GroupInfo + + + + + Get the players of a team. This is the current squad. For the team name call the function TeamNames. Pass a 1 for selected players only or 0 for all registered players that belong to the team (now and in the past) + + + + + Returns an array with team names. The names can be used in functions that require or offer an option to pass a teamname + + + + + Get the top 10 teams starting with or containing the value of sTeamName. For the team name call the function TeamNames + + + + + Returns an array with the 5 best performing players. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + DataFlex Web Service for public information from the DataFlex Football Pool + + + + + + + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumInfo.java b/Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumInfo.java new file mode 100644 index 0000000..d3d3f4f --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumInfo.java @@ -0,0 +1,87 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package it.dmi.exams.tsdwl; + +import https.footballpool_dataaccess.TStadiumInfo; +import java.io.IOException; +import java.io.PrintWriter; +import javax.servlet.RequestDispatcher; +import javax.servlet.ServletException; +import javax.servlet.annotation.WebServlet; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +/** + * + * @author dcariotti + */ +@WebServlet(name = "StadiumInfo", urlPatterns = {"/StadiumInfo"}) +public class StadiumInfo extends HttpServlet { + /** + * Handles the HTTP GET method. + * + * @param request servlet request + * @param response servlet response + * @throws ServletException if a servlet-specific error occurs + * @throws IOException if an I/O error occurs + */ + @Override + protected void doGet(HttpServletRequest request, HttpServletResponse response) + throws ServletException, IOException { + RequestDispatcher view = request.getRequestDispatcher("search.html"); + + view.forward(request, response); + } + + /** + * Handles the HTTP POST method. + * + * @param request servlet request + * @param response servlet response + * @throws ServletException if a servlet-specific error occurs + * @throws IOException if an I/O error occurs + */ + @Override + protected void doPost(HttpServletRequest request, HttpServletResponse response) + throws ServletException, IOException { + TStadiumInfo stadium = this.stadiumInfo(request.getParameter("name")); + + response.setContentType("text/html;charset=UTF-8"); + try (PrintWriter out = response.getWriter()) { + out.println(""); + if (stadium.getSName().length() == 0) { + out.println("

Stadium not found!

"); + } else { + out.println("

Stadium info:

"); + out.println(stadium.getSName()); + out.println(stadium.getISeatsCapacity()); + out.println(stadium.getSCityName()); + out.println(stadium.getSGoogleMapsURL()); + out.println(stadium.getSWikipediaURL()); + } + out.println(""); + } + + } + + /** + * Returns a short description of the servlet. + * + * @return a String containing servlet description + */ + @Override + public String getServletInfo() { + return "Short description"; + }// + + private static TStadiumInfo stadiumInfo(java.lang.String sStadiumName) { + https.footballpool_dataaccess.Info service = new https.footballpool_dataaccess.Info(); + https.footballpool_dataaccess.InfoSoapType port = service.getInfoSoap(); + return port.stadiumInfo(sStadiumName); + } + +} diff --git a/Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumList.java b/Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumList.java new file mode 100644 index 0000000..9f3d037 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/src/java/it/dmi/exams/tsdwl/StadiumList.java @@ -0,0 +1,103 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package it.dmi.exams.tsdwl; + +import https.footballpool_dataaccess.ArrayOftStadiumInfo; +import https.footballpool_dataaccess.TStadiumInfo; +import java.io.IOException; +import java.io.PrintWriter; +import javax.servlet.RequestDispatcher; +import javax.servlet.ServletException; +import javax.servlet.annotation.WebServlet; +import javax.servlet.http.HttpServlet; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.util.ArrayList; +import java.util.List; +/** + * + * @author dcariotti + */ +@WebServlet(name = "StadiumList", urlPatterns = {"/StadiumList"}) +public class StadiumList extends HttpServlet { + + /** + * Processes requests for both HTTP GET and POST + * methods. + * + * @param request servlet request + * @param response servlet response + * @throws ServletException if a servlet-specific error occurs + * @throws IOException if an I/O error occurs + */ + protected void processRequest(HttpServletRequest request, HttpServletResponse response) + throws ServletException, IOException { + response.setContentType("text/html;charset=UTF-8"); + try (PrintWriter out = response.getWriter()) { + /* TODO output your page here. You may use following sample code. */ + out.println(""); + out.println(""); + out.println(""); + out.println("Servlet StadiumList"); + out.println(""); + out.println(""); + out.println("

Servlet StadiumList at " + request.getContextPath() + "

"); + out.println(""); + out.println(""); + } + } + + // + /** + * Handles the HTTP GET method. + * + * @param request servlet request + * @param response servlet response + * @throws ServletException if a servlet-specific error occurs + * @throws IOException if an I/O error occurs + */ + @Override + protected void doGet(HttpServletRequest request, HttpServletResponse response) + throws ServletException, IOException { + List stadiumList = this.allStadiumInfo().getTStadiumInfo(); + + request.setAttribute("stadiumList", stadiumList); + RequestDispatcher view = request.getRequestDispatcher("list.jsp"); + + view.forward(request, response); + } + + /** + * Handles the HTTP POST method. + * + * @param request servlet request + * @param response servlet response + * @throws ServletException if a servlet-specific error occurs + * @throws IOException if an I/O error occurs + */ + @Override + protected void doPost(HttpServletRequest request, HttpServletResponse response) + throws ServletException, IOException { + processRequest(request, response); + } + + /** + * Returns a short description of the servlet. + * + * @return a String containing servlet description + */ + @Override + public String getServletInfo() { + return "Short description"; + }// + + private static ArrayOftStadiumInfo allStadiumInfo() { + https.footballpool_dataaccess.Info service = new https.footballpool_dataaccess.Info(); + https.footballpool_dataaccess.InfoSoapType port = service.getInfoSoap(); + return port.allStadiumInfo(); + } + +} diff --git a/Year_3/TSDWL/WSDL/FootballClient/web/META-INF/context.xml b/Year_3/TSDWL/WSDL/FootballClient/web/META-INF/context.xml new file mode 100644 index 0000000..a3b375b --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/web/META-INF/context.xml @@ -0,0 +1,2 @@ + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/web/WEB-INF/jax-ws-catalog.xml b/Year_3/TSDWL/WSDL/FootballClient/web/WEB-INF/jax-ws-catalog.xml new file mode 100644 index 0000000..fa89486 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/web/WEB-INF/jax-ws-catalog.xml @@ -0,0 +1,4 @@ + + + + \ No newline at end of file diff --git a/Year_3/TSDWL/WSDL/FootballClient/web/index.html b/Year_3/TSDWL/WSDL/FootballClient/web/index.html new file mode 100644 index 0000000..c627c24 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/web/index.html @@ -0,0 +1,16 @@ + + + + + TODO supply a title + + + + +
TODO write content
+ + diff --git a/Year_3/TSDWL/WSDL/FootballClient/web/list.jsp b/Year_3/TSDWL/WSDL/FootballClient/web/list.jsp new file mode 100644 index 0000000..fba56fa --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/web/list.jsp @@ -0,0 +1,24 @@ +<%-- + Document : list + Created on : Jan 19, 2022, 8:53:23 PM + Author : dcariotti +--%> + +<%@page import="https.footballpool_dataaccess.ArrayOftStadiumInfo"%> +<%@page import="https.footballpool_dataaccess.TStadiumInfo"%> +<%@page import="java.util.List"%> +<%@page contentType="text/html" pageEncoding="UTF-8"%> + + + + + Stadium list + + +

Stadium list

+ <% List stadiums = (List) request.getAttribute("stadiumList"); %> + <% for (TStadiumInfo stadium : stadiums) { %> +

<%= stadium.getSName() %>

+ <% } %> + + diff --git a/Year_3/TSDWL/WSDL/FootballClient/web/search.html b/Year_3/TSDWL/WSDL/FootballClient/web/search.html new file mode 100644 index 0000000..4cac9f3 --- /dev/null +++ b/Year_3/TSDWL/WSDL/FootballClient/web/search.html @@ -0,0 +1,22 @@ + + + + + Search a stadium + + + + +
+
+ + +
+ +
+ + -- cgit v1.2.3-18-g5258