This is an old revision of the document!
package demo.websvc;
/**
- This is an example of custom websvc dataset. Just compile it, package it in a jar file, copy it to /lib folder and
- restart server. It returns the following xml:
- <pre>
- <demo.websvc.MyWebSvc>
- <MyWebSvc>
- <!RequestURI>
- /MbtSvr/app=websvc&action=stat&components=Scxml,demo.websvc.MyWebSvc
- </RequestURI>
- <SysParams>
- {MODEL=!VendingMachineJava1, SVRMGR=http://laptop:8000, CURSVR=http://Laptop:8888, EMAIL=lin@to.com, EDITION=Enterprise}
- </SysParams>
- <WebSvcList>
- [Scxml]
- </WebSvcList>
- </MyWebSvc>
- </demo.websvc.MyWebSvc>
- </pre>
- @author yxl01
- /
public class MyWebSvc {
public static String getXML(String requestURI,
java.util.HashMap<String, String> sysParams,
java.util.HashMap<String, String> websvcList) {
return "<MyWebSvc><RequestURI><![CDATA[" + requestURI + "]]></RequestURI>"
+ "<SysParams>" + sysParams.toString() + "</SysParams>"
+ "<WebSvcList>" + websvcList.keySet().toString() +"</WebSvcList>"
+ "</MyWebSvc>";
}
}