Development GUIDE
1. Create WSDL Stub Files using wsimport
1.1. Open Command Prompt (Run > cmd)
…
1.2. write “wsimport -d C:\FakeWSFiles -keep http://www.bestcoder.net:80/samples/FakeWS?wsdl”
“C:\FakeWSFiles -> Stub Files will be stored in this folder”
1.4. If everything is fine, you will see these messages on cmd.
parsing WSDL…
generating code…
compiling code…
2. Open Domino Designer, goto XPages Perspective, Open Your XPages Application and goto Package Explorer
2.1. Create src folder under WebContent\WEB-INF
2.2. Right click on src and click on Build Path > Use as Source Folder menu.
2.3. Goto C:\FakeWSFiles folder and open *.java file in notepad and copy package name.
2.4. Right click on WebContent\WEB-INF\src folder and New > Other > Java (Package)
2.5. Paste package name on next screen (Name field)
2.6. Click on Finish.
2.7. Goto C:\FakeWSFiles folder and copy all *.java files. (Select All *.Java Files and CTRL + C)
2.8. Select your Package under WebContent\WEB-INF\src and click CTRL + V
3. Now, all Java files is copied under your package.
4. Create another Class and write your own code inspired by this sample code.
Finally,
5. Add grant for related class at Domino JVM Security file
Open java.policy file from …\IBM\Lotus\Domino\jvm\lib\security
Append grant string after “// Notes java code gets all permissions”
grant {
permission java.lang.RuntimePermission “setContextClassLoader”;
permission java.lang.reflect.ReflectPermission “suppressAccessChecks”;
};
Or
grant {
permission java.security.AllPermission;
};
tell http q
load http
// *******************
USAGE in SSJS under Button (Server Options : Full Update) : com.domino.openntf.WSFake.Exec()
// *******************
1.2. write “wsimport -d C:\FakeWSFiles -keep http://www.bestcoder.net:80/samples/FakeWS?wsdl”
“C:\FakeWSFiles -> Stub Files will be stored in this folder”
1.4. If everything is fine, you will see these messages on cmd.
parsing WSDL…
generating code…
compiling code…
2. Open Domino Designer, goto XPages Perspective, Open Your XPages Application and goto Package Explorer
2.1. Create src folder under WebContent\WEB-INF
2.2. Right click on src and click on Build Path > Use as Source Folder menu.
2.3. Goto C:\FakeWSFiles folder and open *.java file in notepad and copy package name.
2.4. Right click on WebContent\WEB-INF\src folder and New > Other > Java (Package)
2.5. Paste package name on next screen (Name field)
2.6. Click on Finish.
2.7. Goto C:\FakeWSFiles folder and copy all *.java files. (Select All *.Java Files and CTRL + C)
2.8. Select your Package under WebContent\WEB-INF\src and click CTRL + V
3. Now, all Java files is copied under your package.
4. Create another Class and write your own code inspired by this sample code.
Finally,
5. Add grant for related class at Domino JVM Security file
Open java.policy file from …\IBM\Lotus\Domino\jvm\lib\security
Append grant string after “// Notes java code gets all permissions”
grant {
permission java.lang.RuntimePermission “setContextClassLoader”;
permission java.lang.reflect.ReflectPermission “suppressAccessChecks”;
};
Or
grant {
permission java.security.AllPermission;
};
tell http q
load http
// *******************
USAGE in SSJS under Button (Server Options : Full Update) : com.domino.openntf.WSFake.Exec()
// *******************