From: <pka...@us...> - 2009-07-01 09:05:00
|
Revision: 284 http://cse-ip.svn.sourceforge.net/cse-ip/?rev=284&view=rev Author: pkasprzak Date: 2009-07-01 09:04:38 +0000 (Wed, 01 Jul 2009) Log Message: ----------- * WS-Interface to ConfigurationManager * Used by Login.bpel to determine login-data Modified Paths: -------------- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/build-impl.xml trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/genfiles.properties trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/project.xml trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/configuration.xml Added Paths: ----------- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jax-ws.xml trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jaxws-build.xml trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/conf/wsdl/ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/de/campussource/cse/webconfig/ConfigurationManagerWS.java Modified: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/build-impl.xml =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/build-impl.xml 2009-07-01 09:01:29 UTC (rev 283) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/build-impl.xml 2009-07-01 09:04:38 UTC (rev 284) @@ -16,6 +16,7 @@ --> <project xmlns:ejbjarproject1="http://www.netbeans.org/ns/j2ee-ejbjarproject/1" xmlns:ejbjarproject2="http://www.netbeans.org/ns/j2ee-ejbjarproject/2" xmlns:ejbjarproject3="http://www.netbeans.org/ns/j2ee-ejbjarproject/3" basedir=".." default="default" name="WebConfig-ejb-impl"> + <import file="jaxws-build.xml"/> <import file="ant-deploy.xml"/> <target depends="dist,javadoc" description="Build whole project." name="default"/> <!-- Modified: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/genfiles.properties =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/genfiles.properties 2009-07-01 09:01:29 UTC (rev 283) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/genfiles.properties 2009-07-01 09:04:38 UTC (rev 284) @@ -1,8 +1,9 @@ -build.xml.data.CRC32=d50701d3 +build.xml.data.CRC32=fcac7bb5 build.xml.script.CRC32=af89c22e build.xml.stylesheet.CRC32=e5f4c432 # 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=d50701d3 -nbproject/build-impl.xml.script.CRC32=35cc50a2 +nbproject/build-impl.xml.data.CRC32=fcac7bb5 +nbproject/build-impl.xml.script.CRC32=69e2ec3a nbproject/build-impl.xml.stylesheet.CRC32=36c39d59 +nbproject/jaxws-build.xml.stylesheet.CRC32=f49c6152 Added: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jax-ws.xml =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jax-ws.xml (rev 0) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jax-ws.xml 2009-07-01 09:04:38 UTC (rev 284) @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?> +<jax-ws xmlns="http://www.netbeans.org/ns/jax-ws/1"> + <services> + <service name="ConfigurationManagerWS"> + <implementation-class>de.campussource.cse.webconfig.ConfigurationManagerWS</implementation-class> + </service> + </services> + <clients/> +</jax-ws> Added: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jaxws-build.xml =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jaxws-build.xml (rev 0) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/jaxws-build.xml 2009-07-01 09:04:38 UTC (rev 284) @@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project xmlns:xalan="http://xml.apache.org/xslt" xmlns:ejbjarproject2="http://www.netbeans.org/ns/j2ee-ejbjarproject/2" xmlns:jaxws="http://www.netbeans.org/ns/jax-ws/1"> + <!-- + =================== + JAX-WS WSGEN SECTION + =================== + --> + <target name="wsgen-init" depends="init"> + <mkdir dir="${build.generated.dir}/wsgen/service"/> + <mkdir dir="${build.generated.dir}/wsgen/service/resources/"/> + <mkdir dir="${build.generated.dir}/wsgen/binaries"/> + <taskdef name="wsgen" classname="com.sun.tools.ws.ant.WsGen"> + <classpath path="${j2ee.platform.wsgen.classpath}"/> + </taskdef> + </target> + <target name="wsgen-compile" depends="wsgen-ConfigurationManagerWS"> + <ejbjarproject2:javac srcdir="${build.generated.dir}/wsgen/service" classpath="${j2ee.platform.wsgen.classpath}:${javac.classpath}" destdir="${classes.dir}"/> + </target> + <target name="wsgen-ConfigurationManagerWS" depends="wsgen-init, -do-compile"> + <wsgen destdir="${build.generated.dir}/wsgen/binaries" sourcedestdir="${build.generated.dir}/wsgen/service" resourcedestdir="${build.generated.dir}/wsgen/service/resources/" xendorsed="true" keep="false" genwsdl="true" sei="de.campussource.cse.webconfig.ConfigurationManagerWS"> + <classpath path="${java.home}/../lib/tools.jar:${classes.dir}:${j2ee.platform.wsgen.classpath}:${javac.classpath}"/> + </wsgen> + </target> + <!-- + =================== + JAX-WS WSIMPORT SECTION + =================== + --> +</project> Modified: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/project.xml =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/project.xml 2009-07-01 09:01:29 UTC (rev 283) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/nbproject/project.xml 2009-07-01 09:04:38 UTC (rev 284) @@ -2,6 +2,9 @@ <project xmlns="http://www.netbeans.org/ns/project/1"> <type>org.netbeans.modules.j2ee.ejbjarproject</type> <configuration> + <buildExtensions xmlns="http://www.netbeans.org/ns/ant-build-extender/1"> + <extension file="jaxws-build.xml" id="jaxws"/> + </buildExtensions> <data xmlns="http://www.netbeans.org/ns/j2ee-ejbjarproject/3"> <name>WebConfig-ejb</name> <minimum-ant-version>1.6.5</minimum-ant-version> Modified: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/configuration.xml =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/configuration.xml 2009-07-01 09:01:29 UTC (rev 283) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/configuration.xml 2009-07-01 09:04:38 UTC (rev 284) @@ -14,14 +14,14 @@ <setting name="ilias_login_password" description="Passwort f\xFCr Login" default="cs3-1p"/> <setting name="ilias_ws_url" description="URL der WS-Schnittstelle" default="http://localhost/ilias3/webservice/soap/server.php?debug=1"/> </category> - +<!-- <category name="Ilias2" description="Ilias-Adapter Einstellungen"> <setting name="ilias_login_client" description="Ident des Clients" default="test"/> <setting name="ilias_login_username" description="Username f\xFCr Login" default="root"/> <setting name="ilias_login_password" description="Passwort f\xFCr Login" default="cs3-1p"/> <setting name="ilias_ws_url" description="URL der WS-Schnittstelle" default="http://localhost/ilias3/webservice/soap/server.php?debug=1"/> </category> - +--> <!-- <category public="false" name="csecore" description="Grundlegende CSE Systemeinstellungen"> <setting name="CSE_Health_Komponente_Aktiv" description="Nutzung der Health Komponente (automatische Behebung von Inkonsistenzen)" default="true" type="1"/> Added: trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/de/campussource/cse/webconfig/ConfigurationManagerWS.java =================================================================== --- trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/de/campussource/cse/webconfig/ConfigurationManagerWS.java (rev 0) +++ trunk/sandbox/lsf-adapter-demo/WebConfig/WebConfig-ejb/src/java/de/campussource/cse/webconfig/ConfigurationManagerWS.java 2009-07-01 09:04:38 UTC (rev 284) @@ -0,0 +1,78 @@ +/* + * To change this template, choose Tools | Templates + * and open the template in the editor. + */ + +package de.campussource.cse.webconfig; + +import java.util.List; +import javax.ejb.EJB; +import javax.jws.Oneway; +import javax.jws.WebMethod; +import javax.jws.WebParam; +import javax.jws.WebService; +import javax.ejb.Stateless; + +/** + * + * @author pete + */ +@WebService(name="ConfigurationManager", targetNamespace="http://cse.campussource.de/ejb/ConfigurationManager") +@Stateless() +public class ConfigurationManagerWS { + @EJB + private ConfigurationManager ejbRef; + // Add business logic below. (Right-click in editor and choose + // "Web Service > Add Operation" + +/* + @WebMethod(operationName = "getSetting") + public Setting getSetting(@WebParam(name = "settingName") + String settingName, @WebParam(name = "categoryName") + String categoryName) throws SettingNotFoundException { + return ejbRef.getSetting(settingName, categoryName); + } +*/ + @WebMethod(operationName = "getSettingAsString") + public String getSettingAsString( @WebParam(name = "settingName") String settingName, + @WebParam(name = "categoryName") String categoryName) throws SettingNotFoundException { + return ejbRef.getSettingAsString(settingName, categoryName); + } + + @WebMethod(operationName = "getSettingAsInteger") + public int getSettingAsInteger( @WebParam(name = "settingName") String settingName, + @WebParam(name = "categoryName") String categoryName) throws SettingNotFoundException { + return ejbRef.getSettingAsInteger(settingName, categoryName); + } + + @WebMethod(operationName = "getSettingAsBoolean") + public boolean getSettingAsBoolean( @WebParam(name = "settingName") String settingName, + @WebParam(name = "categoryName") String categoryName) throws SettingNotFoundException { + return ejbRef.getSettingAsBoolean(settingName, categoryName); + } +/* + @WebMethod(operationName = "getSettings") + public List<Setting> getSettings() { + return ejbRef.getSettings(); + } + + @WebMethod(operationName = "getCategories") + public List<SettingCategory> getCategories() { + return ejbRef.getCategories(); + } + + @WebMethod(operationName = "deleteSetting") + @Oneway + public void deleteSetting(@WebParam(name = "setting") + Setting setting) { + ejbRef.deleteSetting(setting); + } + + @WebMethod(operationName = "updateSetting") + @Oneway + public void updateSetting(@WebParam(name = "setting") + Setting setting) { + ejbRef.updateSetting(setting); + } +*/ +} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |