playing with svn, #2 git-svn-id: https://svn.apache.org/repos/asf/ode/tags/test-1@748312 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/_br-ode-1.X.svn/.gitignore b/_br-ode-1.X.svn/.gitignore new file mode 100644 index 0000000..3f68690 --- /dev/null +++ b/_br-ode-1.X.svn/.gitignore
@@ -0,0 +1,16 @@ +# for those of us using git internally +# before committing in the central svn repository. + +*.class +*.pyc +*.iml +*.ipr +*.iws +*.zip +*.jar +.classpath +.project +.metadata +bin +target +reports
diff --git a/_br-ode-1.X.svn/BUILDING b/_br-ode-1.X.svn/BUILDING new file mode 100644 index 0000000..170c805 --- /dev/null +++ b/_br-ode-1.X.svn/BUILDING
@@ -0,0 +1,75 @@ +================================ +Building Apache ODE from Sources +================================ + +If you downloaded the source distribution of ODE you can safely ignore the first paragraph. It's only useful if you want the bleeding edge of ODE. + +Getting the source code +----------------------- + +First you will have to make sure that you have [Subversion|http://svn.tigris.org]. If you don't know what Subversion is or don't have it installed, check [here|http://svnbook.red-bean.com]. Once installed run: + +svn checkout http://svn.apache.org/repos/asf/ode/trunk ode + +For more information or if you have any problem with Subversion (like being behind a proxy or a firewall) check our Source Code documentation (http://ode.apache.org/source-code.html). + +Building With Buildr +-------------------- + +Buildr requires a Ruby interpreter. If you're running Linux or Mac OS you most probably already have Ruby installed on your machine. For Winows user Ruby installation is very simple. You will need the following: + + * Ruby 1.8.x with RubyGems 0.9 or later. For Windows users using the Ruby One-Click Installer is the easiest (http://rubyforge.org/projects/rubyinstaller/). For Linux or Mac OS users, a Ruby interpreter is usually preinstalled. Just make sure to have the ruby-dev package (mkmf is needed for RJB). + + * Buildr. Install it by running 'gem install buildr -v 1.2.10'. A proper JAVA_HOME environment variable must be set. Make sure to choose either win32 or ruby platforms (don't choose java for Antwrap, that's JRuby). + +Building is then pretty simple. Open a command in the source root directory and run: + +rake package + +To try the test cases bundled with ODE: + +rake test + +It just works! For more information about buildr see http://buildr.rubyforge.org/. + +Running in Tomcat (WAR deployment) +---------------------------------- + +You should find the full distribution in the distro-axis2/target directory. Unzip it somewhere on your disk, everything needed is inside. + +Get the WAR file in the distribution root directory (should be named apache-ode-war-x.x.zip), rename it to *ode.war* and copy this file to Tomcat's webapp directory. You should get a blank page under http://localhost:8080/ode. The Ode WAR includes its own embedded database (Derby - http://db.apache.org/derby) so you don't have to worry about configuring any external database for now. + +Testing a Tomcat Deployment +--------------------------- + +Copy the content of examples directory in the distribution (the 3 sub-directories) to _tomcat/webapps/ode/WEB-INF/processes_, this will automatically deploy the 3 example processes. Use the sendsoap command located in the distribution _bin_ directory to send test messages. The messages to run each of the 3 examples are provided in their respective directory (testRequest.soap). For each example type: + +bin/sendsoap http://localhost:8080/ode/processes/helloWorld examples/HelloWorld2/testRequest.soap + +or + +bin/sendsoap.sh http://localhost:8080/ode/processes/helloWorld examples/HelloWorld2/testRequest.soap + +The URLs should be updated according to the address defined in the WSDL file for the process service. + +If you want to use an IDE to explore the PXE sources or debug PXE executables, Eclipse .project and .classpath files are present in all the modules; simply choose File|Import from the Eclipse menu, and select the root ODE directory. You may also use Maven to generate project files for other IDEs. See the Maven documentation for details. + +Running in ServiceMix (JBI deployment) +-------------------------------------- + +You should find the full distribution in the distro-jbi/target directory. Unzip it somewhere on your disk, everything needed is inside. + +Get the zip containing ODE's service engine in the distribution root directory (should be named apache-ode-jbi-x.x.zip) and copy it in the install directory of ServiceMix 3.1. Most process deployments will also require HTTP binding so you should also copy the servicemix-shared and servicemix-http zip files from its components directory to its install directory. Start ServiceMix by going into its root directory and type: + +bin/servicemix + +The server should start properly. + +Testing a ServiceMix Deployment +------------------------------- + +JBI examples come with ant scripts to build the service assemblies and test them. It's just a 3 step process: + +1. Go to the example directory and run ant (no need to specify a task, the default one will work). +2. Copy the zip service assembly created in the build subdirectory to the deploy directory of ServiceMix. +3. Run 'ant test' from the example directory.
diff --git a/_br-ode-1.X.svn/KEYS b/_br-ode-1.X.svn/KEYS new file mode 100644 index 0000000..4131593 --- /dev/null +++ b/_br-ode-1.X.svn/KEYS
@@ -0,0 +1,119 @@ +This file contains the PGP keys of various developers. + +Users: pgp < KEYS + gpg --import KEYS +Developers: + pgp -kxa <your name> and append it to this file. + (pgpk -ll <your name> && pgpk -xa <your name>) >> this file. + (gpg --list-sigs <your name> + && gpg --armor --export <your name>) >> this file. + + +pub 1024D/4A9EA70E 2007-08-27 +uid Matthieu Riou (CODE SIGNING KEY) <mriou@apache.org> +sig 3 4A9EA70E 2007-08-27 Matthieu Riou (CODE SIGNING KEY) <mriou@apache.org> +sub 2048g/2BB53026 2007-08-27 +sig 4A9EA70E 2007-08-27 Matthieu Riou (CODE SIGNING KEY) <mriou@apache.org> + +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1.4.6 (GNU/Linux) + +mQGiBEbTJ5sRBADMkb8JsY99WJrjC4UhurXgVXpZgvYZos5g1emZsNh8CE13rPOF +LQEwBUsotxbbyLdvqp5o1wzWsZWMMe/4IL6Wx0CWDAXLkank/oogRvgrlckJBJ7/ +I/yS/i8ace2rO4sondzbbG+Tg/c0+AxE9HjOSOVgvB4UqeSox2OLdhgpnwCgotmg +gtdolYzr79wYXh1IeKlBRKED/RqJZQaPTtCtQO/ac+3zQ/7y7zdjoYVcDIeifzlG +1yL77Qw/LYT8y5OkO/6vvyLQwnRFTeBqlHYTmCUa+2HMh+BJTWRpDEQbAOHMgMEo +HuQwX6H5LzuJr2KmxTvQvf50FdhOXUT86pJIyGpsK/ask3SUdu81imoAEEMb9bZs +TStPA/4kHwn5WSNtTWyQz0jkdNQU2l1PVf5fh6kLIqDoAzzrtPh9NUARGkZLS4rr +6fqHJnmVu4mVzChY5QwWKTZfBjkLXn4YiOiNxjWEou34yLGXgTEiE1UQ7cqmvvQn +gRpAwYuchX54PAye5dUecjKwsbIMDRSScaEMtIutiNa+vWo2+bQzTWF0dGhpZXUg +UmlvdSAoQ09ERSBTSUdOSU5HIEtFWSkgPG1yaW91QGFwYWNoZS5vcmc+iGAEExEC +ACAFAkbTJ5sCGwMGCwkIBwMCBBUCCAMEFgIDAQIeAQIXgAAKCRD6yNe+Sp6nDmLe +AJkBhrRz3vC2++d06A19aLcF/UVZWgCfTQ2Wlg9f6qCxSkSdAeCglBgHCMO5Ag0E +RtMnvRAIAL8lBayW+D2GJ9uydAIXBXaeT5DY55GV0FcoCy0AkwaVhFYfikL1iT0Z +vcBtL0hEufywQC9W2rvqFWft2YS0NfChbeDQtkwo7kUB+AX+sreG5FzRCWEjZ3oN +THmITusuEZwXXLJAf0Rm+JmOQEZeZywYut4VSwkp7pPVlJQ8AIgxCl8HDtQriHVs +Fls3Xa/FyXfaeXQVKp9w3WLr5ONMLhUmJxPnG+mvdUJgR6yebKdYZVFpXfwOeMhM +ZdAYT/Hg7HmfwJpoJONrtlejR1VmNYY1rzb9jVplTqCCm1BDJDsJWUfPkiI7T/bx +o8l4Rq7hNESfvjGOTO7OwBYkIR0GossAAwUIALvlj5JTYFWoj+u/pa5qovgx702G +Rrw4dgMiqKdVYWJZahjmUjs9uqCI1nVROKeSHs3j+3kxH8YGHBlkJo/6yicrZpIm +mO74Abxi0+yjN9T7GpuZ9rYnYNvBSUA5hqEuMGFOeSU8ZznPsG7fBTWhuknxxOrU +mGjHGOQZXwcq0GSzZwVGkBZ1gIb0a4wwsk86uMubi5bD3I0MSVWh2ZUBZfAr5MPg +dQ1PI9tib1G6J0JhKY+95yOwujdqrmpBxdRtxN3IMIzpe2nBwlkP9CDNKhJn+sKB +MRClYk6vHp6Q+W4ikln/P62H0CrOfh3jzAYfNcW/lxlp6ZbsRVrwhr+nM3mISQQY +EQIACQUCRtMnvQIbDAAKCRD6yNe+Sp6nDppoAJ0ZNcruq5Jc0aZ1yvNLQORewQa7 +WQCgn7JcUG0i3/7Kk4101XIhgfNgXww= +=dGgn +-----END PGP PUBLIC KEY BLOCK----- + + +pub 1024D/2EED13CE 2007-05-09 +uid Alex Boisvert (CODE SIGNING KEY) <alex.boisvert@gmail.com> +sig 3 2EED13CE 2007-05-09 Alex Boisvert (CODE SIGNING KEY) <alex.boisvert@gmail.com> +sub 1024g/54BC5E9F 2007-05-09 +sig 2EED13CE 2007-05-09 Alex Boisvert (CODE SIGNING KEY) <alex.boisvert@gmail.com> + + +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1.4.6 (GNU/Linux) + +mQGiBEZCQ80RBACdngN/JZod5XLn8Was2AbSutxP/H5WssX/StS+0BLNRn+FMhtn +xXKkJwqKtqbKoHzEKKziQHybD5AfXSBj21l2iZXPfcwfsJJVpDmwBr7p6SPXdNEY +eDoSW8ZVsA81m/Oc/kxbglVSiH39O3olrQ7bwaKyBMR2QkjxynJYGImtFwCg8FKy +tPJRTUaXHGYtoGw7Jh5fNSsEAI9qQYA8IK2AwyjJE5D/rcv0nahzFRZqT+HZwmfP +FVqsgIBUt7KKuDpWw2dzf6utmKHq9JZZb7BvDlfYv7PbPIioX+35SNu7cQUNy7al +5aCgf7+evukiQBiEHZio8AzaLquCq/A29igf4fINZ4AJKTL0iRhJAKk3gey/CrOj +p61WA/oDpGIXU4adXg4x/dbUT2pbgh+KZu8oNjaMH6ZwAQtHYJ3wabH1masz+yb3 +spAUZ3IHJmFrpZeJYCUlLXZqu+/0R7hnoNH9zaE2g1JGwtiKjLEmubCp3nme0/Ca +lt8aG9XpgcWe09rA7Sbd7p9Pkdgor/p0yaF6eJl5wETdCTTjpLQ6QWxleCBCb2lz +dmVydCAoQ09ERSBTSUdOSU5HIEtFWSkgPGFsZXguYm9pc3ZlcnRAZ21haWwuY29t +PohgBBMRAgAgBQJGQkPNAhsjBgsJCAcDAgQVAggDBBYCAwECHgECF4AACgkQ9sJV +Ei7tE873UgCeKKtOd1wW8B1b7vlT8J8y5a35kNMAoJ9WjLxFmKbKOkxYrt54esl6 +mGXouQENBEZCQ84QBADI6QppW8BMMaQ4us7axSinOOgTGGkOjuv48d8JnNkgUj34 +N84PME18JlTD9jlkVf+PHjYMaA3fkiKfjlojq0D9V4l7zVDd7e8O5LRL1eOKzivl +A84a3d2574V1I3ioljCyXLA+41OxYE4DtNXH+mvcumhYGBu2Bg0I5ZuXDvhv5wAE +CwQAnSLLv0M9LptAiOXl012jgP/4yuZDnBKczvAzMzR847Sy4Shuk03H2rN12+AM +rX+unJpcGOGxlzJ8Mb40aauBc270wVSCrza9z7/i/4DLPsTUuc+ZgBLWuv+lNitD +UeieigodJqbr8EFNj6MlhJyUeGxbFmkngR80nZX06sAIILyISQQYEQIACQUCRkJD +zgIbDAAKCRD2wlUSLu0TzhPzAJ93zO3DP6/fcA1yfbFSSbgLGI7+/wCdFMH1Ptl8 +sGH4v6GYUVHyfKnWKbg= +=X6Yk +-----END PGP PUBLIC KEY BLOCK----- + + +pub 1024D/14A8A2BA 2007-06-12 +uid Assaf Arkin <assaf@apache.org> +sig 3 14A8A2BA 2007-06-12 Assaf Arkin <assaf@apache.org> +sub 2048g/8CA2779E 2007-06-12 +sig 14A8A2BA 2007-06-12 Assaf Arkin <assaf@apache.org> + +-----BEGIN PGP PUBLIC KEY BLOCK----- +Version: GnuPG v1.4.7 (GNU/Linux) + +mQGiBEZvELsRBADBaOF4FVOIkkzA6XlK4lX8TbV5J3crP4M+1I5BWuKsA5oZYCkX +ARjYfSC62K2fsTSwGTU6M684M+DOKljhjFhs24bL7Yr/1iAEh1RC+aQJ0HJw8ME4 +yxU/WSez6KzQJ8fV7M6MOg9fwI3pf27USf91cdbjLMdi4mvAIbkA/ECi7wCgveA6 +nXpXF8fsKkr+Ijl5FBWYlA0EAIQRzcX12CkFOtJsGHkzZpcInKZkimBKUxrL0lK0 +/EahOPpWjzHdV64OVspgnFECmipwQBLzNAH16XEb9ikwum0PCKj4BnIgkmFjZfFA +lHLQTqN+JeSCDHI1vxwPfKh2MOrCbCU3EBQgcWhO/WakK/AXyu9bertGum1oNAc/ +LkFkA/sE1/7A2ZMyQVYxwigcYjI5FpfA3PI/Irxup38bQ4atuQrLx/vLbNrDPStw +yECB6oo3/acjGDkoEH9dergxyID4aZaGb3vJmtuzNrxJzxIkHepodTN0hXi2kLft +K0B6Vo6Ufv9eaeHnEf/1460JbDAq7w2g5JTnFkRnnWKet+ghQLQeQXNzYWYgQXJr +aW4gPGFzc2FmQGFwYWNoZS5vcmc+iGAEExECACAFAkZvELsCGwMGCwkIBwMCBBUC +CAMEFgIDAQIeAQIXgAAKCRDXkC1vFKiiuoEUAJ9rm/RkZdJSP9bGmcE3cteTa/IG +JwCeOxg1QVZ0qv6kjOM2RxfaHJeD3EC5Ag0ERm8QuxAIAIeYs8PNbNLFnaXV7Y/N +UJ07s1D/0+USJwUVJ/SX4AVyx8CYVMXo+lu9le+JeJfVI2dRlbIes2H8o4WevOP8 +k831oUfqgLF8FKjYE/2Gt6vDWRT9kcN/mxTo0NeVhAIEVSI1Nkppj1B+05IXEJvb +ZaS4GXW/tXXthVTtgHvjEA0maWMMFvUz1HlfEoepzsKTxxiGQJeRIz4hyRE1nuV+ +bUIXItUYBBaj1Y5prQkzI2WjA75hw+4ZeHYM7wgzWP/1MZwylUicvYsEtJeKXZRw +IZrKZelffcIZB3OZMUQuJyFMcRz5AVgHLuFTfG7yMLTMxWTNa2b09p8l0TnJuhbI +0g8AAwUH/iAEbtT42jvt+EsJIz37K1yV5RMKA6ApAsbRkNOAwXQgdEqky/c26KBa +Ug4nAdAUm+5Hkx/R3F2wKsxSWiWneNM93tInQH0xdfHPCICfmyUPzTS0igEktqQw +AWYpegKNXzKg+SmKJZsME50bgEZCB2zPIp/AHmG4SbI9THYvPjHbQKf0yzIO0dIw +xPxKI0dFSASg3oebANtLAUIPIV/QLNWhPwxT/Qe3aBNc5rfl7vSkVv7loBHE/1lj +++MUlrkmzegJAg9u9GSEfoxFjVbK176IdlJoflZnv1pFkGRbBvOaaCVCllLVJMZS +HlzsreJCFPVgnK3/PMUn2XauF9Y9MjCISQQYEQIACQUCRm8QuwIbDAAKCRDXkC1v +FKiiuuCjAJ9UhVa0wHAzYXPJatNdgbkHJuQOqgCbB+lDb7ZGGjC9wToAI/ha1Pz+ +T6Y= +=uoUw +-----END PGP PUBLIC KEY BLOCK-----
diff --git a/_br-ode-1.X.svn/LICENSE b/_br-ode-1.X.svn/LICENSE new file mode 100644 index 0000000..b5b2504 --- /dev/null +++ b/_br-ode-1.X.svn/LICENSE
@@ -0,0 +1,182 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + +======================================================================= + +Third-party licenses are reproduced in the lib directory of the binary +distributions. +
diff --git a/_br-ode-1.X.svn/NOTICE b/_br-ode-1.X.svn/NOTICE new file mode 100644 index 0000000..4097e57 --- /dev/null +++ b/_br-ode-1.X.svn/NOTICE
@@ -0,0 +1,186 @@ + ========================================================================= + == NOTICE file for use with the Apache License, Version 2.0, == + == in this case for the Apache ODE distribution. == + ========================================================================= + + Apache Ode + This product includes software developed at + The Apache Software Foundation (http://www.apache.org/). + +COPYRIGHT NOTICES + +Copyright 1999-2006 Intalio + +This product includes software developed by Intalio +http://www.intalio.com + +Copyright 2006 Sybase + +This product includes software developed by Sybase. +http://www.sybase.com + +========================================================================= +== Derby Notice == +========================================================================= + +Portions of Derby were orginally developed by +International Business Machines Corporation and are +licensed to the Apache Software Foundation under the +"Software Grant and Corporate Contribution License Agreement", +informally known as the "Derby CLA". + +The portion of the functionTests under 'nist' was originally +developed by the National Institute of Standards and Technology (NIST), +an agency of the United States Department of Commerce, and adapted by +International Business Machines Corporation in accordance with the NIST +Software Acknowledgment and Redistribution document at +http://www.itl.nist.gov/div897/ctg/sql_form.htm + + +========================================================================= +== OpenJPA Notice == +========================================================================= + +* OpenJPA includes software developed by the SERP project + Copyright (c) 2002-2006, A. Abram White. All rights reserved. + +* OpenJPA is bundled with the binaries from the JPA specification, by + Sun Microsystems and licensed under the CDDL 1.0. The source code is + available at: https://glassfish.dev.java.net/source/browse/glassfish/ + +========================================================================= +== Saxon Notice == +========================================================================= + +The Program includes all or portions of the following software: "The +Saxon XSLT and XQuery Processor from Saxonica Limited" distributed under +an MPL v1.0 license. Please refer to the homepage URL at +http://www.saxonica.com/. + +========================================================================= +== Sun Notice == +========================================================================= + +This product includes software (Java Activation Framework) which was +developed by Sun Microsystems under a CDDL license. +(http://www.sun.com/) + +========================================================================= +== Woodstox Notice == +========================================================================= + +This product includes software developed by the Woodstox Project +(http://woodstox.codehaus.org/). + +========================================================================= +== WSDL4J Notice == +========================================================================= + +The Program includes all or portions of the following software which is +subject to the Common Public License ("CPL Code"). This software +consists of voluntary contributions made by many individuals on behalf of +the WSDL4J project. + +You may download the source version of the WSDL4J component at +http://sourceforge.net/projects/wsdl4j + +========================================================================= +== Xalan Notice == +========================================================================= + +Apache Xalan (Xalan serializer) +Copyright 1999-2006 The Apache Software Foundation + +This product includes software developed at +The Apache Software Foundation (http://www.apache.org/). + +Portions of this software was originally based on the following: + - software copyright (c) 1999-2002, Lotus Development Corporation., + http://www.lotus.com. + - software copyright (c) 2001-2002, Sun Microsystems., + http://www.sun.com. + - software copyright (c) 2003, IBM Corporation., + http://www.ibm.com. + +========================================================================= +== Xerces Notice == +========================================================================= + +Portions of this software were originally based on the following: + - software copyright (c) 1999, IBM Corporation., http://www.ibm.com. + - software copyright (c) 1999, Sun Microsystems., http://www.sun.com. + - voluntary contributions made by Paul Eng on behalf of the + Apache Software Foundation that were originally developed at + iClick, Inc., software copyright (c) 1999. + + +========================================================================= +== XmlBeans Notice == +========================================================================= + +Portions of this software were originally based on the following: + - software copyright (c) 2000-2003, BEA Systems, <http://www.bea.com/>. + +Aside from contributions to the Apache XMLBeans project, this +software also includes: + + - one or more source files from the Apache Xerces-J and Apache Axis + products, Copyright (c) 1999-2003 Apache Software Foundation + + - W3C XML Schema documents Copyright 2001-2003 (c) World Wide Web + Consortium (Massachusetts Institute of Technology, European Research + Consortium for Informatics and Mathematics, Keio University) + + - resolver.jar from Apache Xml Commons project, + Copyright (c) 2001-2003 Apache Software Foundation + + - Piccolo XML Parser for Java from http://piccolo.sourceforge.net/, + Copyright 2002 Yuval Oren under the terms of the Apache Software + License 2.0 + +========================================================================= +== OASIS Notice == +========================================================================= + +OASIS takes no position regarding the validity or scope of any +intellectual property or other rights that might be claimed to pertain +to the implementation or use of the technology described in this +document or the extent to which any license under such rights might or +might not be available; neither does it represent that it has made any +effort to identify any such rights. Information on OASIS's procedures +with respect to rights in OASIS specifications can be found at the +OASIS website. Copies of claims of rights made available for +publication and any assurances of licenses to be made available, or the +result of an attempt made to obtain a general license or permission for +the use of such proprietary rights by implementors or users of this +specification, can be obtained from the OASIS Executive Director. + +OASIS invites any interested party to bring to its attention any +copyrights, patents or patent applications, or other proprietary rights +which may cover technology that may be required to implement this +specification. Please address the information to the OASIS Executive +Director. + +Copyright (C) OASIS Open (2004-2005). All Rights Reserved. + +This document and translations of it may be copied and furnished to +others, and derivative works that comment on or otherwise explain it or +assist in its implementation may be prepared, copied, published and +distributed, in whole or in part, without restriction of any kind, +provided that the above copyright notice and this paragraph are included +on all such copies and derivative works. However, this document itself +may not be modified in any way, such as by removing the copyright notice +or references to OASIS, except as needed for the purpose of developing +OASIS specifications, in which case the procedures for copyrights +defined in the OASIS Intellectual Property Rights document must be +followed, or as required to translate it into languages other than +English. + +The limited permissions granted above are perpetual and will not be +revoked by OASIS or its successors or assigns. + +This document and the information contained herein is provided on an +"AS IS" basis and OASIS DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, +INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE +INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED +WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
diff --git a/_br-ode-1.X.svn/README b/_br-ode-1.X.svn/README new file mode 100644 index 0000000..69746cd --- /dev/null +++ b/_br-ode-1.X.svn/README
@@ -0,0 +1,36 @@ +============== + Apache ODE +============== + +Apache ODE is a WS-BPEL compliant web services orchestration engine. +It organizes web services calls following a process description +written in BPEL. Another way to describe it would be a web service +capable workflow engine. + +For more information check the following resources: + + * Our web site: http://ode.apache.org/ + * The WS-BPEL 2.0 technical committee webinars linked here: + http://ode.apache.org/introduction.html + +Apache ODE is an open source project, as such we welcome all your +help and contributions. To participate and get involved, our mailing +lists are the best resources to start from: + + http://ode.apache.org/mailing-lists.html + +Finally here is a non exhaustive but representative features list: + + * Compliant with both BPEL4WS 1.1 and WS-BPEL 2.0. + * Deploys both as a WAR in any web container (using an Axis2-based + communication layer) or as a JBI service assembly. + * Small footprint server suitable for experimentation or + single-server production use. + * Compiled approach to BPEL that provides detailed analysis and + validation at the command line or at deployment. + * Processes hot deployment and management web service interface (war + deployment only). + * High level API to the engine that allows you to integrate the core + with virtually any communication layer or even embed it. + +
diff --git a/_br-ode-1.X.svn/RELEASE_NOTES b/_br-ode-1.X.svn/RELEASE_NOTES new file mode 100644 index 0000000..01b5748 --- /dev/null +++ b/_br-ode-1.X.svn/RELEASE_NOTES
@@ -0,0 +1,20 @@ +======================== +Apache ODE Release Notes +======================== + +Apache ODE 1.3 includes both a few new features and many bug fixes. +It's also the most stable version of ODE released so far. + +Apache ODE 1.1.1 requires Java 1.5.x. The WAR distribution can run in +most J2EE servlet container. The JBI distribution should be able to +run in any JBI container but has only been tested with ServiceMix +3.1 so far. See the BUILDING file if you want to build your own +distribution from the source release. + +Changes: +------- + +See our Jira for more information: + +https://issues.apache.org/jira/browse/ODE/fixforversion/12312750 +
diff --git a/_br-ode-1.X.svn/Rakefile b/_br-ode-1.X.svn/Rakefile new file mode 100644 index 0000000..2f4ba29 --- /dev/null +++ b/_br-ode-1.X.svn/Rakefile
@@ -0,0 +1,640 @@ +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +gem "buildr", "~>1.2.4" +require "buildr" +require "buildr/xmlbeans.rb" +require "buildr/openjpa" +require "buildr/javacc" +require "buildr/jetty" +require "buildr/hibernate" + +# Keep this structure to allow the build system to update version numbers. +VERSION_NUMBER = "1.3-SNAPSHOT" +NEXT_VERSION = "1.4" + +ANNONGEN = "annogen:annogen:jar:0.1.0" +ANT = "ant:ant:jar:1.6.5" +AXIOM = [ group("axiom-api", "axiom-impl", "axiom-dom", + :under=>"org.apache.ws.commons.axiom", :version=>"1.2.5") ] +AXIS2_ALL = group("axis2-adb", "axis2-codegen", "axis2-kernel", + "axis2-java2wsdl", "axis2-jibx", "axis2-saaj", "axis2-xmlbeans", + :under=>"org.apache.axis2", :version=>"1.3") +AXIS2_TEST = group("httpcore", "httpcore-nio", "httpcore-niossl", + :under=>"org.apache.httpcomponents", :version=>"4.0-alpha5") +AXIS2_MODULES = struct( + :mods => ["org.apache.rampart:rampart:mar:1.3", + "org.apache.rampart:rahas:mar:1.3", + "org.apache.axis2:addressing:mar:1.3"], + :libs => [group("rampart-core", "rampart-policy", "rampart-trust", + :under=>"org.apache.rampart", + :version=>"1.3"), + "org.apache.ws.security:wss4j:jar:1.5.3", + "org.apache.santuario:xmlsec:jar:1.4.0", + "opensaml:opensaml:jar:1.1", + "bouncycastle:bcprov-jdk15:jar:132"] +) +AXIS2_WAR = "org.apache.axis2:axis2-webapp:war:1.3" +BACKPORT = "backport-util-concurrent:backport-util-concurrent:jar:3.0" +COMMONS = struct( + :codec =>"commons-codec:commons-codec:jar:1.3", + :collections =>"commons-collections:commons-collections:jar:3.1", + :dbcp =>"commons-dbcp:commons-dbcp:jar:1.2.1", + :fileupload =>"commons-fileupload:commons-fileupload:jar:1.1.1", + :httpclient =>"commons-httpclient:commons-httpclient:jar:3.0", + :lang =>"commons-lang:commons-lang:jar:2.3", + :logging =>"commons-logging:commons-logging:jar:1.1", + :io =>"commons-io:commons-io:jar:1.4", + :pool =>"commons-pool:commons-pool:jar:1.2", + :primitives =>"commons-primitives:commons-primitives:jar:1.0" +) +DERBY = "org.apache.derby:derby:jar:10.4.1.3" +DERBY_TOOLS = "org.apache.derby:derbytools:jar:10.4.1.3" +DOM4J = "dom4j:dom4j:jar:1.6.1" +GERONIMO = struct( + :kernel =>"org.apache.geronimo.modules:geronimo-kernel:jar:2.0.1", + :transaction =>"org.apache.geronimo.components:geronimo-transaction:jar:2.0.1", + :connector =>"org.apache.geronimo.components:geronimo-connector:jar:2.0.1" +) +HIBERNATE = [ "org.hibernate:hibernate:jar:3.2.5.ga", "asm:asm:jar:1.5.3", + "antlr:antlr:jar:2.7.6", "cglib:cglib:jar:2.1_3", "net.sf.ehcache:ehcache:jar:1.2.3" ] +HSQLDB = "hsqldb:hsqldb:jar:1.8.0.7" +JAVAX = struct( + :activation =>"javax.activation:activation:jar:1.1", + #:activation =>"geronimo-spec:geronimo-spec-activation:jar:1.0.2-rc4", + :connector =>"org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec:jar:1.0", + :ejb =>"org.apache.geronimo.specs:geronimo-ejb_2.1_spec:jar:1.1", + :javamail =>"geronimo-spec:geronimo-spec-javamail:jar:1.3.1-rc5", + :jms =>"geronimo-spec:geronimo-spec-jms:jar:1.1-rc4", + :persistence =>"javax.persistence:persistence-api:jar:1.0", + :servlet =>"org.apache.geronimo.specs:geronimo-servlet_2.4_spec:jar:1.0", + :stream =>"stax:stax-api:jar:1.0.1", + :transaction =>"org.apache.geronimo.specs:geronimo-jta_1.1_spec:jar:1.1", + :resource =>"org.apache.geronimo.specs:geronimo-j2ee-connector_1.5_spec:jar:1.0" +) +JAXEN = "jaxen:jaxen:jar:1.1.1" +JBI = "org.apache.servicemix:servicemix-jbi:jar:3.1.1-incubating" +JENCKS = "org.jencks:jencks:jar:all:1.3" +JIBX = "jibx:jibx-run:jar:1.1-beta3" +LOG4J = "log4j:log4j:jar:1.2.13" +OPENJPA = ["org.apache.openjpa:openjpa:jar:1.3.0-SNAPSHOT", + "net.sourceforge.serp:serp:jar:1.13.1"] + +SAXON = group("saxon", "saxon-xpath", "saxon-dom", "saxon-xqj", :under=>"net.sf.saxon", :version=>"9.x") +SERVICEMIX = group("servicemix-core", "servicemix-shared", "servicemix-services", + :under=>"org.apache.servicemix", :version=>"3.1-incubating") +SPRING = group("spring-beans", "spring-context", "spring-core", "spring-jmx", + :under=>"org.springframework", :version=>"2.0.1") +TRANQL = [ "tranql:tranql-connector:jar:1.1", "axion:axion:jar:1.0-M3-dev", COMMONS.primitives ] +WOODSTOX = "woodstox:wstx-asl:jar:3.2.1" +WSDL4J = "wsdl4j:wsdl4j:jar:1.6.1" +XALAN = "org.apache.ode:xalan:jar:2.7.0-2" +XERCES = "xerces:xercesImpl:jar:2.9.0" +XSTREAM = "xstream:xstream:jar:1.2" +WS_COMMONS = struct( + :axiom =>AXIOM, + :neethi =>"org.apache.neethi:neethi:jar:2.0.2", + :xml_schema =>"org.apache.ws.commons.schema:XmlSchema:jar:1.3.2" +) +XBEAN = group("xbean-classloader", "xbean-kernel", "xbean-server", "xbean-spring", + :under=>"org.apache.xbean", :version=>"2.8") +XMLBEANS = "org.apache.xmlbeans:xmlbeans:jar:2.3.0" + +repositories.remote << "http://pxe.intalio.org/public/maven2" +repositories.remote << "http://people.apache.org/repo/m2-incubating-repository" +repositories.remote << "http://repo1.maven.org/maven2" +repositories.remote << "http://people.apache.org/repo/m2-snapshot-repository" +repositories.remote << "http://download.java.net/maven/2" +repositories.remote << "http://ws.zones.apache.org/repository2" +repositories.release_to[:url] ||= "sftp://guest@localhost/home/guest" + +# Changing releases tag names +class Release + class << self + def tag_with_apache_ode(version) + tag_without_apache_ode("APACHE_ODE_#{version.upcase}") + end + alias_method_chain :tag, :apache_ode + end +end + + +desc "Apache ODE" +#define "ode", :group=>"org.apache.ode", :version=>VERSION_NUMBER do +define "ode" do + project.version = VERSION_NUMBER + project.group = "org.apache.ode" + + compile.options.source = "1.5" + compile.options.target = "1.5" + manifest["Implementation-Vendor"] = "Apache Software Foundation" + meta_inf << file("NOTICE") + + desc "ODE Axis Integration Layer" + define "axis2" do + compile.with projects("bpel-api", "bpel-connector", "bpel-dao", "bpel-epr", "bpel-runtime", + "scheduler-simple", "bpel-schemas", "bpel-store", "utils"), + AXIOM, AXIS2_ALL, COMMONS.lang, COMMONS.logging, COMMONS.collections, COMMONS.httpclient, COMMONS.lang, + DERBY, GERONIMO.kernel, GERONIMO.transaction, JAVAX.activation, JAVAX.servlet, JAVAX.stream, + JAVAX.transaction, JENCKS, WSDL4J, WS_COMMONS, XMLBEANS, AXIS2_MODULES.libs + + test.exclude 'org.apache.ode.axis2.management.*' + test.with project("tools"), AXIOM, JAVAX.javamail, COMMONS.codec, COMMONS.httpclient, XERCES, WOODSTOX + + package :jar + end + + desc "ODE Axis2 Based Web Application" + define "axis2-war" do + libs = projects("axis2", "bpel-api", "bpel-compiler", "bpel-connector", "bpel-dao", + "bpel-epr", "bpel-obj", "bpel-ql", "bpel-runtime", "scheduler-simple", + "bpel-schemas", "bpel-store", "dao-hibernate", "jacob", "jca-ra", "jca-server", + "utils", "dao-jpa"), + AXIS2_ALL, ANNONGEN, BACKPORT, COMMONS.codec, COMMONS.collections, COMMONS.fileupload, COMMONS.io, COMMONS.httpclient, + COMMONS.lang, COMMONS.logging, COMMONS.pool, DERBY, DERBY_TOOLS, JAXEN, JAVAX.activation, JAVAX.ejb, JAVAX.javamail, + JAVAX.connector, JAVAX.jms, JAVAX.persistence, JAVAX.transaction, JAVAX.stream, JIBX, + GERONIMO.connector, GERONIMO.kernel, GERONIMO.transaction, LOG4J, OPENJPA, SAXON, TRANQL, + WOODSTOX, WSDL4J, WS_COMMONS, XALAN, XERCES, XMLBEANS, + AXIS2_MODULES.libs + + package(:war).with(:libs=>libs).path("WEB-INF").tap do |web_inf| + web_inf.merge project("dao-jpa-ojpa-derby").package(:zip) + web_inf.merge project("dao-hibernate-db").package(:zip) + web_inf.include project("axis2").path_to("src/main/wsdl/*") + web_inf.include project("bpel-schemas").path_to("src/main/xsd/pmapi.xsd") + end + package(:war).path("WEB-INF/modules").include(artifacts(AXIS2_MODULES.mods)) + package(:war).tap do |root| + root.merge(artifact(AXIS2_WAR)).exclude("WEB-INF/*").exclude("META-INF/*") + end + + task("start"=>[package(:war), jetty.use]) do |task| + class << task ; attr_accessor :url, :path ; end + task.url = "http://localhost:8080/ode" + task.path = jetty.deploy(task.url, task.prerequisites.first) + jetty.teardown task("stop") + end + + task("stop") do |task| + if url = task("start").url rescue nil + jetty.undeploy url + end + end + + test.using :testng, :properties=>{ "log4j.debug" => true, "log4j.configuration"=>"test-log4j.properties" } + test.with projects("tools"), libs, AXIS2_TEST, AXIOM, JAVAX.servlet, Buildr::Jetty::REQUIRES, HIBERNATE, DOM4J + test.setup task(:prepare_webapp) do |task| + webapp_dir = "target/test-classes/webapp" + cp_r _("src/main/webapp"), _("target/test-classes") + cp Dir[_("src/main/webapp/WEB-INF/classes/*")], _("target/test-classes") + cp Dir[project("axis2").path_to("src/main/wsdl/*")], _("#{webapp_dir}/WEB-INF") + cp project("bpel-schemas").path_to("src/main/xsd/pmapi.xsd"), _("#{webapp_dir}/WEB-INF") + rm_rf Dir[_(webapp_dir) + "/**/.svn"] + mkdir _("#{webapp_dir}/WEB-INF/processes") unless File.exist?(_("#{webapp_dir}/WEB-INF/processes")) + mkdir _("#{webapp_dir}/WEB-INF/modules") unless File.exist?(_("#{webapp_dir}/WEB-INF/modules")) + # move around some property files for test purpose + mv Dir[_("target/test-classes/TestEndpointProperties/*_global_conf*.endpoint")], _("#{webapp_dir}/WEB-INF/conf") + artifacts(AXIS2_MODULES.mods).map {|a| a.invoke } + cp AXIS2_MODULES.mods.map {|a| repositories.locate(a)} , _("#{webapp_dir}/WEB-INF/modules") + end + test.setup unzip(_("target/test-classes/webapp/WEB-INF")=>project("dao-jpa-ojpa-derby").package(:zip)) + test.setup unzip(_("target/test-classes/webapp/WEB-INF")=>project("dao-hibernate-db").package(:zip)) + + NativeDB.prepare_configs test, _(".") + + test.setup prepare_secured_services_tests(_("target/test-classes/TestRampartBasic/secured-services"), "sample*.axis2") + test.setup prepare_secured_services_tests(_("target/test-classes/TestRampartPolicy/secured-services"), "sample*-policy.xml") + + test.setup prepare_secured_processes_tests(_("target/test-classes/TestRampartBasic/secured-processes")) + test.setup prepare_secured_processes_tests(_("target/test-classes/TestRampartPolicy/secured-processes")) + end + + desc "ODE APIs" + define "bpel-api" do + compile.with projects("utils", "bpel-obj", "bpel-schemas"), WSDL4J, COMMONS.logging + package :jar + end + + desc "ODE JCA connector" + define "bpel-api-jca" do + compile.with project("bpel-api"), JAVAX.connector + package :jar + end + + desc "ODE BPEL Compiler" + define "bpel-compiler" do + compile.with projects("bpel-api", "bpel-obj", "bpel-schemas", "utils"), + COMMONS.logging, JAVAX.stream, JAXEN, SAXON, WSDL4J, XALAN, XERCES, COMMONS.collections + test.resources { filter(project("bpel-scripts").path_to("src/main/resources")).into(test.resources.target).run } + package :jar + end + + desc "ODE JCA Connector Implementation" + define "bpel-connector" do + compile.with projects("bpel-api", "bpel-api-jca", "bpel-runtime", "jca-ra", "jca-server") + package :jar + end + + desc "ODE DAO Interfaces" + define "bpel-dao" do + compile.with project("bpel-api") + package :jar + end + + desc "ODE Interface Layers Common" + define "bpel-epr" do + compile.with projects("utils", "bpel-dao", "bpel-api"), + AXIOM, COMMONS.lang, COMMONS.logging, DERBY, JAVAX.connector, JAVAX.stream, JAVAX.transaction, GERONIMO.transaction, GERONIMO.connector, TRANQL, XMLBEANS + package :jar + end + + desc "ODE BPEL Object Model" + define "bpel-obj" do + compile.with project("utils"), SAXON, WSDL4J, COMMONS.collections + package :jar + end + + desc "ODE BPEL Query Language" + define "bpel-ql" do + pkg_name = "org.apache.ode.ql.jcc" + jjtree = jjtree(_("src/main/jjtree"), :in_package=>pkg_name) + compile.from javacc(jjtree, :in_package=>pkg_name), jjtree + compile.with projects("bpel-api", "bpel-compiler", "bpel-obj", "jacob", "utils") + + package :jar + end + + desc "ODE Runtime Engine" + define "bpel-runtime" do + compile.from apt + compile.with projects("bpel-api", "bpel-compiler", "bpel-dao", "bpel-obj", "bpel-schemas", + "bpel-store", "jacob", "jacob-ap", "utils"), + COMMONS.logging, COMMONS.collections, COMMONS.httpclient, JAXEN, JAVAX.persistence, JAVAX.stream, SAXON, WSDL4J, XMLBEANS + + test.with projects("scheduler-simple", "dao-jpa", "dao-hibernate", "bpel-epr"), + BACKPORT, COMMONS.pool, COMMONS.lang, DERBY, JAVAX.connector, JAVAX.transaction, + GERONIMO.transaction, GERONIMO.kernel, GERONIMO.connector, TRANQL, HSQLDB, JAVAX.ejb, + LOG4J, XERCES, Buildr::OpenJPA::REQUIRES, XALAN + + package :jar + end + + desc "ODE Simple Scheduler" + define "scheduler-simple" do + compile.with projects("bpel-api", "utils"), COMMONS.collections, COMMONS.logging, JAVAX.transaction + test.compile.with HSQLDB, GERONIMO.kernel, GERONIMO.transaction + test.with HSQLDB, JAVAX.transaction, JAVAX.resource, JAVAX.connector, LOG4J, + GERONIMO.kernel, GERONIMO.transaction, BACKPORT, JAVAX.ejb + package :jar + end + + desc "ODE Schemas" + define "bpel-schemas" do + compile_xml_beans _("src/main/xsd/*.xsdconfig"), _("src/main/xsd") + package :jar + end + + desc "ODE BPEL Test Script Files" + define "bpel-scripts" do + package :jar + end + + desc "ODE Process Store" + define "bpel-store" do + compile.with projects("bpel-api", "bpel-compiler", "bpel-dao", "bpel-obj", "bpel-schemas", "bpel-epr", + "dao-hibernate", "utils"), + COMMONS.logging, JAVAX.persistence, JAVAX.stream, HIBERNATE, HSQLDB, XMLBEANS, XERCES, WSDL4J + compile { open_jpa_enhance } + resources hibernate_doclet(:package=>"org.apache.ode.store.hib", :excludedtags=>"@version,@author,@todo") + + test.with COMMONS.collections, COMMONS.lang, JAVAX.connector, JAVAX.transaction, DOM4J, LOG4J, + XERCES, XALAN, JAXEN, SAXON, OPENJPA + package :jar + end + + desc "ODE BPEL Tests" + define "bpel-test" do + compile.with projects("bpel-api", "bpel-compiler", "bpel-dao", "bpel-runtime", + "bpel-store", "utils", "bpel-epr", "dao-jpa"), + DERBY, Java::JUnit::JUNIT_REQUIRES, JAVAX.persistence, OPENJPA, WSDL4J, COMMONS.httpclient, + COMMONS.codec + + test.with projects("bpel-obj", "jacob", "bpel-schemas", + "bpel-scripts", "scheduler-simple"), + COMMONS.collections, COMMONS.lang, COMMONS.logging, DERBY, JAVAX.connector, + JAVAX.stream, JAVAX.transaction, JAXEN, HSQLDB, LOG4J, SAXON, XERCES, XMLBEANS, XALAN + + package :jar + end + + desc "ODE Hibernate DAO Implementation" + define "dao-hibernate" do + compile.with projects("bpel-api", "bpel-dao", "bpel-ql", "utils"), + COMMONS.lang, COMMONS.logging, JAVAX.transaction, HIBERNATE, DOM4J + resources hibernate_doclet(:package=>"org.apache.ode.daohib.bpel.hobj", :excludedtags=>"@version,@author,@todo") + + test.with project("bpel-epr"), BACKPORT, COMMONS.collections, COMMONS.lang, HSQLDB, + GERONIMO.transaction, GERONIMO.kernel, GERONIMO.connector, JAVAX.connector, JAVAX.ejb, SPRING + + package :jar + end + + desc "ODE Hibernate Compatible Databases" + define "dao-hibernate-db" do + predefined_for = lambda { |name| _("src/main/sql/simplesched-#{name}.sql") } + properties_for = lambda { |name| _("src/main/sql/ode.#{name}.properties") } + + dao_hibernate = project("dao-hibernate").compile.target + bpel_store = project("bpel-store").compile.target + + Buildr::Hibernate::REQUIRES[:xdoclet] = Buildr.group("xdoclet", "xdoclet-xdoclet-module", "xdoclet-hibernate-module", + :under=>"xdoclet", :version=>"1.2.3") + ["xdoclet:xjavadoc:jar:1.1-j5"] + export = lambda do |properties, source, target| + file(target=>[properties, source]) do |task| + mkpath File.dirname(target), :verbose=>false + # Protection against a buildr bug until the fix is released, avoids build failure + class << task ; attr_accessor :ant ; end + task.enhance { |task| task.ant = Buildr::Hibernate.schemaexport } + + hibernate_schemaexport target do |task, ant| + ant.schemaexport(:properties=>properties.to_s, :quiet=>"yes", :text=>"yes", :delimiter=>";", + :drop=>"no", :create=>"yes", :output=>target) do + ant.fileset(:dir=>source.to_s) { + ant.include :name=>"**/*.hbm.xml" + ant.exclude :name=>"**/HMessageExchangeProperty.hbm.xml"} + end + end + end + end + + runtime_sql = export[ properties_for[:derby], dao_hibernate, _("target/runtime.sql") ] + store_sql = export[ properties_for[:derby], bpel_store, _("target/store.sql") ] + derby_sql = concat(_("target/derby.sql")=>[ predefined_for[:derby], runtime_sql, store_sql ]) + derby_db = Derby.create(_("target/derby/hibdb")=>derby_sql) + build derby_db + + %w{ mysql firebird hsql postgres sqlserver oracle }.each do |db| + partial = export[ properties_for[db], dao_hibernate, _("target/partial.#{db}.sql") ] + build concat(_("target/#{db}.sql")=>[ predefined_for[db], partial ]) + end + + NativeDB.create_dbs self, _("."), :hib + + package(:zip).include(derby_db) + end + + desc "ODE OpenJPA DAO Implementation" + define "dao-jpa" do + compile.with projects("bpel-api", "bpel-dao", "utils"), + COMMONS.collections, COMMONS.logging, JAVAX.connector, JAVAX.persistence, JAVAX.transaction, + OPENJPA, XERCES + compile { open_jpa_enhance } + package :jar + end + + desc "ODE OpenJPA Derby Database" + define "dao-jpa-ojpa-derby" do + %w{ derby mysql oracle }.each do |db| + db_xml = _("src/main/descriptors/persistence.#{db}.xml") + scheduler_sql = _("src/main/scripts/simplesched-#{db}.sql") + partial_sql = file("target/partial.#{db}.sql"=>db_xml) do |task| + mkpath _("target"), :verbose=>false + Buildr::OpenJPA.mapping_tool :properties=>db_xml, :action=>"build", :sql=>task.name, + :classpath=>projects("bpel-store", "dao-jpa", "bpel-api", "bpel-dao", "utils" ) + end + sql = concat(_("target/#{db}.sql")=>[_("src/main/scripts/license-header.sql"), partial_sql, scheduler_sql]) + build sql + end + derby_db = Derby.create(_("target/derby/jpadb")=>_("target/derby.sql")) + + test.with projects("bpel-api", "bpel-dao", "bpel-obj", "bpel-epr", "dao-jpa", "utils"), + BACKPORT, COMMONS.collections, COMMONS.lang, COMMONS.logging, GERONIMO.transaction, + GERONIMO.kernel, GERONIMO.connector, HSQLDB, JAVAX.connector, JAVAX.ejb, JAVAX.persistence, + JAVAX.transaction, LOG4J, OPENJPA, XERCES, WSDL4J + + build derby_db + + NativeDB.create_dbs self, _("."), :jpa + + package(:zip).include(derby_db) + end + + desc "ODE JAva Concurrent OBjects" + define "jacob" do + compile.with projects("utils", "jacob-ap"), COMMONS.logging + compile.from apt + + package :jar + end + + desc "ODE Jacob APR Code Generation" + define "jacob-ap" do + compile.with Java.tools_jar + package :jar + end + + desc "ODE JBI Integration Layer" + define "jbi" do + compile.with projects("bpel-api", "bpel-connector", "bpel-dao", "bpel-epr", "bpel-obj", + "bpel-runtime", "scheduler-simple", "bpel-schemas", "bpel-store", "utils"), + AXIOM, COMMONS.logging, COMMONS.pool, JAVAX.transaction, JBI, LOG4J, WSDL4J, XERCES + + package(:jar) + package(:jbi).tap do |jbi| + libs = artifacts(package(:jar), + projects("bpel-api", "bpel-api-jca", "bpel-compiler", "bpel-connector", "bpel-dao", + "bpel-epr", "jca-ra", "jca-server", "bpel-obj", "bpel-ql", "bpel-runtime", + "scheduler-simple", "bpel-schemas", "bpel-store", "dao-hibernate", "dao-jpa", + "jacob", "jacob-ap", "utils"), + ANT, AXIOM, BACKPORT, COMMONS.codec, COMMONS.collections, COMMONS.dbcp, COMMONS.lang, COMMONS.pool, + COMMONS.primitives, DERBY, GERONIMO.connector, GERONIMO.transaction, JAXEN, JAVAX.connector, + JAVAX.ejb, JAVAX.jms, JAVAX.persistence, JAVAX.stream, JAVAX.transaction, LOG4J, OPENJPA, + SAXON, TRANQL, XALAN, XERCES, XMLBEANS, XSTREAM, WSDL4J) + + jbi.component :type=>:service_engine, :name=>"OdeBpelEngine", :description=>self.comment + jbi.component :class_name=>"org.apache.ode.jbi.OdeComponent", :libs=>libs + jbi.bootstrap :class_name=>"org.apache.ode.jbi.OdeBootstrap", :libs=>libs + jbi.merge project("dao-hibernate-db").package(:zip) + jbi.merge project("dao-jpa-ojpa-derby").package(:zip) + jbi.include path_to("src/main/jbi/ode-jbi.properties") + end + + test.with projects("dao-jpa", "bpel-compiler", "bpel-api-jca", "jca-ra", + "jca-server", "jacob"), + BACKPORT, COMMONS.lang, COMMONS.collections, DERBY, GERONIMO.connector, GERONIMO.kernel, + GERONIMO.transaction, JAVAX.connector, JAVAX.ejb, JAVAX.persistence, JAVAX.stream, + JAVAX.transaction, JAXEN, JBI, OPENJPA, SAXON, SERVICEMIX, SPRING, TRANQL, + XALAN, XBEAN, XMLBEANS, XSTREAM + test.using :properties=>{ "jbi.install"=>_("target/smixInstallDir"), "jbi.examples"=>_("../distro/src/examples-jbi/") } + test.setup unzip(_("target/smixInstallDir/install/ODE")=>project("dao-jpa-ojpa-derby").package(:zip)) + end + + desc "ODE JCA Resource Archive" + define "jca-ra" do + compile.with project("utils"), JAVAX.connector + package :jar + end + + desc "ODE JCA Server" + define "jca-server" do + compile.with projects("jca-ra", "utils"), COMMONS.logging + package :jar + end + + desc "ODE Tools" + define "tools" do + compile.with projects("bpel-compiler", "utils"), ANT, COMMONS.httpclient, COMMONS.logging + package :jar + end + + desc "ODE Utils" + define "utils" do + compile.with AXIOM, AXIS2_ALL, COMMONS.collections, COMMONS.logging, COMMONS.pool, COMMONS.httpclient, COMMONS.codec, LOG4J, XERCES, JAVAX.stream, WSDL4J + test.exclude "*TestResources" + package :jar + end + +end + +define "apache-ode" do + [:version, :group, :manifest, :meta_inf].each { |prop| send "#{prop}=", project("ode").send(prop) } + + def distro(project, postfix) + id = project.parent.id + postfix + project.package(:zip, :id=>id).path("#{id}-#{version}").tap do |zip| + zip.include meta_inf + ["RELEASE_NOTES", "README"].map { |f| path_to(f) } + zip.path("examples").include project.path_to("src/examples"+postfix), :as=>"." + + # Libraries + zip.path("lib").include artifacts(COMMONS.logging, COMMONS.codec, COMMONS.httpclient, + COMMONS.pool, COMMONS.collections, JAXEN, SAXON, LOG4J, WSDL4J, XALAN, XERCES) + project("ode").projects("utils", "tools", "bpel-compiler", "bpel-api", "bpel-obj", "bpel-schemas"). + map(&:packages).flatten.each do |pkg| + zip.include(pkg.to_s, :as=>"#{pkg.id}.#{pkg.type}", :path=>"lib") + end + + # Including third party licenses + Dir["#{project.path_to("license")}/*LICENSE"].each { |l| zip.include(l, :path=>"lib") } + zip.include(project.path_to("target/LICENSE")) + + # Include supported database schemas + Dir["#{project("ode:dao-jpa-ojpa-derby").path_to("target")}/*.sql"].each do |f| + zip.include(f, :path=>"sql") unless f =~ /partial/ + end + + # Tools scripts (like bpelc and sendsoap) + bins = file(project.path_to("target/bin")=>FileList[project.path_to("src/bin/*")]) do |task| + mkpath task.name + cp task.prerequisites, task.name + chmod 0755, FileList[task.name + "/*"], :verbose=>false + end + zip.include(bins) + + yield zip + # For some reason this always fails on a clean build, commenting until I have time to inquire + # project.check zip, "should contain mysql.sql" do + # it.should contain("sql/mysql.sql") + # end + end + end + + desc "ODE Axis2 Based Distribution" + define "distro" do + parent.distro(self, "-war") { |zip| zip.include project("ode:axis2-war").package(:war), :as=>"ode.war" } + parent.distro(self, "-jbi") { |zip| zip.include project("ode:jbi").package(:zip) } + + # Preparing third party licenses + build do + Dir.mkdir(project.path_to("target")) unless File.exist?(project.path_to("target")) + cp parent.path_to("LICENSE"), project.path_to("target/LICENSE") + File.open(project.path_to("target/LICENSE"), "a+") do |l| + l << Dir["#{project.path_to("license")}/*LICENSE"].map { |f| "lib/"+f[/[^\/]*$/] }.join("\n") + end + end + + project("ode:axis2-war").task("start").enhance do |task| + target = "#{task.path}/webapp/WEB-INF/processes" + puts "Deploying processes to #{target}" if verbose + verbose(false) do + mkpath target + cp_r FileList[_("src/examples/*")].to_a, target + rm Dir.glob("#{target}/*.deployed") + end + end + end + + package(:zip, :id=>"#{id}-sources").path("#{id}-sources-#{version}").tap do |zip| + if File.exist?(".svn") + `svn status -v`.reject { |l| l[0] == ?? || l[0] == ?D }. + map { |l| l.split.last }.reject { |f| File.directory?(f) }. + each { |f| zip.include f, :as=>f } + else + zip.include Dir.pwd, :as=>"." + end + end + + package(:zip, :id=>"#{id}-docs").include(javadoc(project("ode").projects).target) unless ENV["JAVADOC"] =~ /^(no|off|false|skip)$/i +end + +# Helper methods +################### +def prepare_secured_processes_tests(test_dir) + task(test_dir.to_sym) do + mkdir "#{test_dir}/modules" unless File.directory? "#{test_dir}/modules" + artifacts(AXIS2_MODULES.mods).map {|a| a.invoke } + cp AXIS2_MODULES.mods.map {|a| repositories.locate(a)} , _("#{test_dir}/modules") + + Dir.chdir(test_dir) do + Dir['sample*-service.xml'].each do |service_file| + sample_name = service_file.split('-').first + proc_dir = "process-#{sample_name}" + cp_r "process-template/.", proc_dir + cp service_file, "#{proc_dir}/HelloService.axis2" + end + end + end +end +def prepare_secured_services_tests(test_dir, file_pattern) + task(test_dir.to_sym) do + # copy the required modules + mkdir "#{test_dir}/modules" unless File.directory? "#{test_dir}/modules" + artifacts(AXIS2_MODULES.mods).map {|a| a.invoke } + cp AXIS2_MODULES.mods.map {|a| repositories.locate(a)} , _("#{test_dir}/modules") + # generate one process per test + Dir.chdir(test_dir) do + Dir[file_pattern].each do |config_file| + sample_name = File.basename(config_file, "."+config_file.split('.').last) + # create process directory + proc_dir = "process-#{sample_name}" + mkdir proc_dir unless File.directory? proc_dir + # copy files + cp config_file, proc_dir + # copy files from template and replace variable names + Dir["process-template/*"].each do |file| + lines = IO.readlines(file) + # copy file and replace template values + File.open("#{proc_dir}/#{File.basename(file)}", 'w') { |f| + lines.each { |l| + l.gsub!("{sample.namespace}", "http://#{sample_name.gsub('-','.')}.samples.rampart.apache.org") + l.gsub!("{sample.service.name}", sample_name) + f<<l + } + } + end + end + end + end +end
diff --git a/_br-ode-1.X.svn/axis2-war/lib/maven-artifact-ant-2.0.4-dep.jar b/_br-ode-1.X.svn/axis2-war/lib/maven-artifact-ant-2.0.4-dep.jar new file mode 100644 index 0000000..4c18c9a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/lib/maven-artifact-ant-2.0.4-dep.jar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/classes/commons-logging.properties b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/classes/commons-logging.properties new file mode 100644 index 0000000..a786d00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/classes/commons-logging.properties
@@ -0,0 +1,30 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. +# + +# This is the logging properties that goes to the war, there are two logging conf kept at the +# svn, one for developement (one at src/test-resources) and other for producation + +# Uncomment the next line to disable all logging. +#org.apache.commons.logging.Log=org.apache.commons.logging.impl.NoOpLog + +# Uncomment the next line to enable the simple log based logging +#org.apache.commons.logging.Log=org.apache.commons.logging.impl.SimpleLog + +# Uncomment the next line to enable log4j based logging +org.apache.commons.logging.Log=org.apache.commons.logging.impl.Log4JLogger
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties new file mode 100644 index 0000000..4e657dd --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/classes/log4j.properties
@@ -0,0 +1,34 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Set root logger level to WARN and its only appender to CONSOLE +log4j.rootLogger=WARN, CONSOLE + +# log4j properties to work with commandline tools. +log4j.category.org.mortbay=ERROR +log4j.category.org.hibernate.type=WARN +log4j.category.org.objectweb=ERROR +log4j.category.org.apache.ode.axis2=DEBUG +log4j.category.org.apache.ode.axis2.hooks.SessionInHandler=INFO +log4j.category.org.apache.ode.bpel.engine=DEBUG +log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=DEBUG +log4j.category.org.apache.ode.bpel.epr=INFO + +# Console appender +log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender +log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout +log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.hib-derby/axis2.xml b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.hib-derby/axis2.xml new file mode 100644 index 0000000..34b5518 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.hib-derby/axis2.xml
@@ -0,0 +1,310 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<axisconfig name="AxisJava2.0"> + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + <parameter name="enableSwA" locked="false">false</parameter> + + <!--Uncomment if you want to enable file caching for attachments --> + <!--parameter name="cacheAttachments" locked="false">true</parameter> + <parameter name="attachmentDIR" locked="false"></parameter> + <parameter name="sizeThreshold" locked="false">4000</parameter--> + + <!--This will give out the timout of the configuration contexts, in seconds--> + <parameter name="ConfigContextTimeoutInterval" locked="false">30</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the expcetion--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">true</parameter> + + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="ServicesDirectory" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="ModulesDirectory" locked="false">modules</parameter>--> + + + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distingiush those endpoints--> + <!--In case of a servlet, if you change this you have to manually change the settings of your servlet container to map this --> + <!--context path to proper Axis2 servlets--> + <parameter name="servicePath" locked="false">processes</parameter> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + + <!--Set the flag to true if you want to enable transport level session mangment--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">true</parameter> + + <!-- If you have a frontend host which exposes this webservice using a different public URL --> + <!-- use this parameter to override autodetected url --> + <!--<parameter name="httpFrontendHostUrl" locked="false">https://someotherhost/context</parameter>--> + + + <!-- The way of adding listener to the system--> + <!-- <listener class="org.apache.axis2.ObserverIMPL">--> + <!-- <parameter name="RSS_URL" locked="false">http://127.0.0.1/rss</parameter>--> + <!-- </listener>--> + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Deafult Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can ovride this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">8080</parameter> + <!-- Here is the complete list of supported parameters (see example settings further below): + port: the port to listen on (default 6060) + hostname: if non-null, url prefix used in reply-to endpoint references (default null) + originServer: value of http Server header in outgoing messages (default "Simple-Server/1.1") + requestTimeout: value in millis of time that requests can wait for data (default 20000) + requestTcpNoDelay: true to maximize performance and minimize latency (default true) + false to minimize bandwidth consumption by combining segments + requestCoreThreadPoolSize: number of threads available for request processing (unless queue fills up) (default 25) + requestMaxThreadPoolSize: number of threads available for request processing if queue fills us (default 150) + note that default queue never fills up: see HttpFactory + threadKeepAliveTime: time to keep threads in excess of core size alive while inactive (default 180) + note that no such threads can exist with default unbounded request queue + threadKeepAliveTimeUnit: TimeUnit of value in threadKeepAliveTime (default SECONDS) (default SECONDS) + --> + <!-- <parameter name="hostname" locked="false">http://www.myApp.com/ws</parameter> --> + <!-- <parameter name="originServer" locked="false">My-Server/1.1</parameter> --> + <!-- <parameter name="requestTimeout" locked="false">10000</parameter> --> + <!-- <parameter name="requestTcpNoDelay" locked="false">false</parameter> --> + <!-- <parameter name="requestCoreThreadPoolSize" locked="false">50</parameter> --> + <!-- <parameter name="RequestMaxThreadPoolSize" locked="false">100</parameter> --> + <!-- <parameter name="threadKeepAliveTime" locked="false">240000</parameter> --> + <!-- <parameter name="threadKeepAliveTimeUnit" locked="false">MILLISECONDS</parameter> --> + </transportReceiver> + + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener"> + <parameter name="myTopicConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">TopicConnectionFactory</parameter> + </parameter> + + <parameter name="myQueueConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + + <parameter name="default" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + </transportReceiver>--> + + <!--Uncomment if you want to have SMTP transport support--> + <!--<transportReceiver name="mail" class="org.apache.axis2.transport.mail.SimpleMailListener">--> + <!--<parameter name="transport.mail.pop3.host" locked="false">127.0.0.1</parameter>--> + <!--<parameter name="transport.mail.pop3.user" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.password" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.port" locked="false">110</parameter>--> + <!--<parameter name="transport.mail.replyToAddress" locked="false">axis2@127.0.0.1</parameter>--> + <!--</transportReceiver>--> + + <!--Uncomment if you want to have TCP transport support--> + <!--transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6060</parameter-->> + <!--If you want to give your own host address for EPR generation--> + <!--uncommet following paramter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + <!-- /transportReceiver --> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + --> + + <!-- Uncomment this one with the appropriate papameters to enable the SMTP transport Receiver + <transportSender name="mailto" class="org.apache.axis2.transport.mail.MailTransportSender"> + <parameter name="transport.mail.smtp.host" locked="false">127.0.0.1</parameter> + <parameter name="transport.mail.smtp.user" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.password" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.port" locked="false">25</parameter> + </transportSender> + --> + + <!-- ================================================= --> + <!-- Global Modules --> + <!-- ================================================= --> + <!-- Uncomment this to enable Addressing --> + <!-- module ref="addressing"/--> + + <!--Configuring module , providing parameters for modules whether they refer or not--> + <!--<moduleConfig name="addressing">--> + <!--<parameter name="addressingPara" locked="false">N/A</parameter>--> + <!--</moduleConfig>--> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/> + <handler name="RequestURIOperationDispatcher" + class="org.apache.axis2.dispatchers.RequestURIOperationDispatcher"/> + <handler name="HTTPLocationBasedDispatcher" + class="org.apache.axis2.dispatchers.HTTPLocationBasedDispatcher"/> + + <handler name="ODEAxisDispatcher" + class="org.apache.ode.axis2.hooks.ODEAxisDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="ProcessHeader"> + <handler name="SessionInHandler" + class="org.apache.ode.axis2.hooks.SessionInHandler"> + <order phase="PostDispatch"/> + </handler> + </phase> + <phase name="OperationInPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="ProcessHeader"> + <handler name="SessionOutHandler" + class="org.apache.ode.axis2.hooks.SessionOutHandler"> + <order phase="PreDispatch"/> + </handler> + </phase> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.dispatchers.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties new file mode 100644 index 0000000..cdd49a6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.hib-derby/ode-axis2.properties
@@ -0,0 +1,3 @@ +ode-axis2.dao.factory=org.apache.ode.axis2.instancecleanup.HibDaoConnectionFactoryImpl +ode-axis2.db.emb.name=hibdb +ode-axis2.db.mode=EMBEDDED \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.jpa-derby/axis2.xml b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.jpa-derby/axis2.xml new file mode 100644 index 0000000..34b5518 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.jpa-derby/axis2.xml
@@ -0,0 +1,310 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<axisconfig name="AxisJava2.0"> + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + <parameter name="enableSwA" locked="false">false</parameter> + + <!--Uncomment if you want to enable file caching for attachments --> + <!--parameter name="cacheAttachments" locked="false">true</parameter> + <parameter name="attachmentDIR" locked="false"></parameter> + <parameter name="sizeThreshold" locked="false">4000</parameter--> + + <!--This will give out the timout of the configuration contexts, in seconds--> + <parameter name="ConfigContextTimeoutInterval" locked="false">30</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the expcetion--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">true</parameter> + + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="ServicesDirectory" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="ModulesDirectory" locked="false">modules</parameter>--> + + + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distingiush those endpoints--> + <!--In case of a servlet, if you change this you have to manually change the settings of your servlet container to map this --> + <!--context path to proper Axis2 servlets--> + <parameter name="servicePath" locked="false">processes</parameter> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + + <!--Set the flag to true if you want to enable transport level session mangment--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">true</parameter> + + <!-- If you have a frontend host which exposes this webservice using a different public URL --> + <!-- use this parameter to override autodetected url --> + <!--<parameter name="httpFrontendHostUrl" locked="false">https://someotherhost/context</parameter>--> + + + <!-- The way of adding listener to the system--> + <!-- <listener class="org.apache.axis2.ObserverIMPL">--> + <!-- <parameter name="RSS_URL" locked="false">http://127.0.0.1/rss</parameter>--> + <!-- </listener>--> + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Deafult Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can ovride this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">8080</parameter> + <!-- Here is the complete list of supported parameters (see example settings further below): + port: the port to listen on (default 6060) + hostname: if non-null, url prefix used in reply-to endpoint references (default null) + originServer: value of http Server header in outgoing messages (default "Simple-Server/1.1") + requestTimeout: value in millis of time that requests can wait for data (default 20000) + requestTcpNoDelay: true to maximize performance and minimize latency (default true) + false to minimize bandwidth consumption by combining segments + requestCoreThreadPoolSize: number of threads available for request processing (unless queue fills up) (default 25) + requestMaxThreadPoolSize: number of threads available for request processing if queue fills us (default 150) + note that default queue never fills up: see HttpFactory + threadKeepAliveTime: time to keep threads in excess of core size alive while inactive (default 180) + note that no such threads can exist with default unbounded request queue + threadKeepAliveTimeUnit: TimeUnit of value in threadKeepAliveTime (default SECONDS) (default SECONDS) + --> + <!-- <parameter name="hostname" locked="false">http://www.myApp.com/ws</parameter> --> + <!-- <parameter name="originServer" locked="false">My-Server/1.1</parameter> --> + <!-- <parameter name="requestTimeout" locked="false">10000</parameter> --> + <!-- <parameter name="requestTcpNoDelay" locked="false">false</parameter> --> + <!-- <parameter name="requestCoreThreadPoolSize" locked="false">50</parameter> --> + <!-- <parameter name="RequestMaxThreadPoolSize" locked="false">100</parameter> --> + <!-- <parameter name="threadKeepAliveTime" locked="false">240000</parameter> --> + <!-- <parameter name="threadKeepAliveTimeUnit" locked="false">MILLISECONDS</parameter> --> + </transportReceiver> + + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener"> + <parameter name="myTopicConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">TopicConnectionFactory</parameter> + </parameter> + + <parameter name="myQueueConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + + <parameter name="default" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + </transportReceiver>--> + + <!--Uncomment if you want to have SMTP transport support--> + <!--<transportReceiver name="mail" class="org.apache.axis2.transport.mail.SimpleMailListener">--> + <!--<parameter name="transport.mail.pop3.host" locked="false">127.0.0.1</parameter>--> + <!--<parameter name="transport.mail.pop3.user" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.password" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.port" locked="false">110</parameter>--> + <!--<parameter name="transport.mail.replyToAddress" locked="false">axis2@127.0.0.1</parameter>--> + <!--</transportReceiver>--> + + <!--Uncomment if you want to have TCP transport support--> + <!--transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6060</parameter-->> + <!--If you want to give your own host address for EPR generation--> + <!--uncommet following paramter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + <!-- /transportReceiver --> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + --> + + <!-- Uncomment this one with the appropriate papameters to enable the SMTP transport Receiver + <transportSender name="mailto" class="org.apache.axis2.transport.mail.MailTransportSender"> + <parameter name="transport.mail.smtp.host" locked="false">127.0.0.1</parameter> + <parameter name="transport.mail.smtp.user" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.password" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.port" locked="false">25</parameter> + </transportSender> + --> + + <!-- ================================================= --> + <!-- Global Modules --> + <!-- ================================================= --> + <!-- Uncomment this to enable Addressing --> + <!-- module ref="addressing"/--> + + <!--Configuring module , providing parameters for modules whether they refer or not--> + <!--<moduleConfig name="addressing">--> + <!--<parameter name="addressingPara" locked="false">N/A</parameter>--> + <!--</moduleConfig>--> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/> + <handler name="RequestURIOperationDispatcher" + class="org.apache.axis2.dispatchers.RequestURIOperationDispatcher"/> + <handler name="HTTPLocationBasedDispatcher" + class="org.apache.axis2.dispatchers.HTTPLocationBasedDispatcher"/> + + <handler name="ODEAxisDispatcher" + class="org.apache.ode.axis2.hooks.ODEAxisDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="ProcessHeader"> + <handler name="SessionInHandler" + class="org.apache.ode.axis2.hooks.SessionInHandler"> + <order phase="PostDispatch"/> + </handler> + </phase> + <phase name="OperationInPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="ProcessHeader"> + <handler name="SessionOutHandler" + class="org.apache.ode.axis2.hooks.SessionOutHandler"> + <order phase="PreDispatch"/> + </handler> + </phase> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.dispatchers.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.jpa-derby/ode-axis2.properties b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.jpa-derby/ode-axis2.properties new file mode 100644 index 0000000..750708d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.jpa-derby/ode-axis2.properties
@@ -0,0 +1 @@ +ode-axis2.dao.factory=org.apache.ode.axis2.instancecleanup.JpaDaoConnectionFactoryImpl \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.template/axis2.xml b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.template/axis2.xml new file mode 100644 index 0000000..34b5518 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.template/axis2.xml
@@ -0,0 +1,310 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<axisconfig name="AxisJava2.0"> + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + <parameter name="enableSwA" locked="false">false</parameter> + + <!--Uncomment if you want to enable file caching for attachments --> + <!--parameter name="cacheAttachments" locked="false">true</parameter> + <parameter name="attachmentDIR" locked="false"></parameter> + <parameter name="sizeThreshold" locked="false">4000</parameter--> + + <!--This will give out the timout of the configuration contexts, in seconds--> + <parameter name="ConfigContextTimeoutInterval" locked="false">30</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the expcetion--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">true</parameter> + + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="ServicesDirectory" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="ModulesDirectory" locked="false">modules</parameter>--> + + + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distingiush those endpoints--> + <!--In case of a servlet, if you change this you have to manually change the settings of your servlet container to map this --> + <!--context path to proper Axis2 servlets--> + <parameter name="servicePath" locked="false">processes</parameter> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + + <!--Set the flag to true if you want to enable transport level session mangment--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">true</parameter> + + <!-- If you have a frontend host which exposes this webservice using a different public URL --> + <!-- use this parameter to override autodetected url --> + <!--<parameter name="httpFrontendHostUrl" locked="false">https://someotherhost/context</parameter>--> + + + <!-- The way of adding listener to the system--> + <!-- <listener class="org.apache.axis2.ObserverIMPL">--> + <!-- <parameter name="RSS_URL" locked="false">http://127.0.0.1/rss</parameter>--> + <!-- </listener>--> + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Deafult Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can ovride this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">8080</parameter> + <!-- Here is the complete list of supported parameters (see example settings further below): + port: the port to listen on (default 6060) + hostname: if non-null, url prefix used in reply-to endpoint references (default null) + originServer: value of http Server header in outgoing messages (default "Simple-Server/1.1") + requestTimeout: value in millis of time that requests can wait for data (default 20000) + requestTcpNoDelay: true to maximize performance and minimize latency (default true) + false to minimize bandwidth consumption by combining segments + requestCoreThreadPoolSize: number of threads available for request processing (unless queue fills up) (default 25) + requestMaxThreadPoolSize: number of threads available for request processing if queue fills us (default 150) + note that default queue never fills up: see HttpFactory + threadKeepAliveTime: time to keep threads in excess of core size alive while inactive (default 180) + note that no such threads can exist with default unbounded request queue + threadKeepAliveTimeUnit: TimeUnit of value in threadKeepAliveTime (default SECONDS) (default SECONDS) + --> + <!-- <parameter name="hostname" locked="false">http://www.myApp.com/ws</parameter> --> + <!-- <parameter name="originServer" locked="false">My-Server/1.1</parameter> --> + <!-- <parameter name="requestTimeout" locked="false">10000</parameter> --> + <!-- <parameter name="requestTcpNoDelay" locked="false">false</parameter> --> + <!-- <parameter name="requestCoreThreadPoolSize" locked="false">50</parameter> --> + <!-- <parameter name="RequestMaxThreadPoolSize" locked="false">100</parameter> --> + <!-- <parameter name="threadKeepAliveTime" locked="false">240000</parameter> --> + <!-- <parameter name="threadKeepAliveTimeUnit" locked="false">MILLISECONDS</parameter> --> + </transportReceiver> + + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener"> + <parameter name="myTopicConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">TopicConnectionFactory</parameter> + </parameter> + + <parameter name="myQueueConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + + <parameter name="default" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + </transportReceiver>--> + + <!--Uncomment if you want to have SMTP transport support--> + <!--<transportReceiver name="mail" class="org.apache.axis2.transport.mail.SimpleMailListener">--> + <!--<parameter name="transport.mail.pop3.host" locked="false">127.0.0.1</parameter>--> + <!--<parameter name="transport.mail.pop3.user" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.password" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.port" locked="false">110</parameter>--> + <!--<parameter name="transport.mail.replyToAddress" locked="false">axis2@127.0.0.1</parameter>--> + <!--</transportReceiver>--> + + <!--Uncomment if you want to have TCP transport support--> + <!--transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6060</parameter-->> + <!--If you want to give your own host address for EPR generation--> + <!--uncommet following paramter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + <!-- /transportReceiver --> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + --> + + <!-- Uncomment this one with the appropriate papameters to enable the SMTP transport Receiver + <transportSender name="mailto" class="org.apache.axis2.transport.mail.MailTransportSender"> + <parameter name="transport.mail.smtp.host" locked="false">127.0.0.1</parameter> + <parameter name="transport.mail.smtp.user" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.password" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.port" locked="false">25</parameter> + </transportSender> + --> + + <!-- ================================================= --> + <!-- Global Modules --> + <!-- ================================================= --> + <!-- Uncomment this to enable Addressing --> + <!-- module ref="addressing"/--> + + <!--Configuring module , providing parameters for modules whether they refer or not--> + <!--<moduleConfig name="addressing">--> + <!--<parameter name="addressingPara" locked="false">N/A</parameter>--> + <!--</moduleConfig>--> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/> + <handler name="RequestURIOperationDispatcher" + class="org.apache.axis2.dispatchers.RequestURIOperationDispatcher"/> + <handler name="HTTPLocationBasedDispatcher" + class="org.apache.axis2.dispatchers.HTTPLocationBasedDispatcher"/> + + <handler name="ODEAxisDispatcher" + class="org.apache.ode.axis2.hooks.ODEAxisDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="ProcessHeader"> + <handler name="SessionInHandler" + class="org.apache.ode.axis2.hooks.SessionInHandler"> + <order phase="PostDispatch"/> + </handler> + </phase> + <phase name="OperationInPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="ProcessHeader"> + <handler name="SessionOutHandler" + class="org.apache.ode.axis2.hooks.SessionOutHandler"> + <order phase="PreDispatch"/> + </handler> + </phase> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.dispatchers.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.template/ode-axis2.properties b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.template/ode-axis2.properties new file mode 100644 index 0000000..8eda983 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf.template/ode-axis2.properties
@@ -0,0 +1,6 @@ +ode-axis2.dao.factory=@connfactory@ +ode-axis2.db.mode=INTERNAL +ode-axis2.db.int.jdbcurl=@url@ +ode-axis2.db.int.driver=@driver@ +ode-axis2.db.int.username=@userid@ +ode-axis2.db.int.password=@password@ \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf/axis2.xml b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf/axis2.xml new file mode 100644 index 0000000..d93fe1b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/conf/axis2.xml
@@ -0,0 +1,311 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<axisconfig name="AxisJava2.0"> + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + <parameter name="enableSwA" locked="false">false</parameter> + + <!--Uncomment if you want to enable file caching for attachments --> + <!--parameter name="cacheAttachments" locked="false">true</parameter> + <parameter name="attachmentDIR" locked="false"></parameter> + <parameter name="sizeThreshold" locked="false">4000</parameter--> + + <!--This will give out the timout of the configuration contexts, in seconds--> + <parameter name="ConfigContextTimeoutInterval" locked="false">30</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the expcetion--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">true</parameter> + + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="ServicesDirectory" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="ModulesDirectory" locked="false">modules</parameter>--> + + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distingiush those endpoints--> + <!--In case of a servlet, if you change this you have to manually change the settings of your servlet container to map this --> + <!--context path to proper Axis2 servlets--> + <parameter name="servicePath" locked="false">processes</parameter> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + + <!--Set the flag to true if you want to enable transport level session mangment--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">true</parameter> + + <!-- If you have a frontend host which exposes this webservice using a different public URL --> + <!-- use this parameter to override autodetected url --> + <!--<parameter name="httpFrontendHostUrl" locked="false">https://someotherhost/context</parameter>--> + + + <!-- The way of adding listener to the system--> + <!-- <listener class="org.apache.axis2.ObserverIMPL">--> + <!-- <parameter name="RSS_URL" locked="false">http://127.0.0.1/rss</parameter>--> + <!-- </listener>--> + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Deafult Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can ovride this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">8080</parameter> + <!-- Here is the complete list of supported parameters (see example settings further below): + port: the port to listen on (default 6060) + hostname: if non-null, url prefix used in reply-to endpoint references (default null) + originServer: value of http Server header in outgoing messages (default "Simple-Server/1.1") + requestTimeout: value in millis of time that requests can wait for data (default 20000) + requestTcpNoDelay: true to maximize performance and minimize latency (default true) + false to minimize bandwidth consumption by combining segments + requestCoreThreadPoolSize: number of threads available for request processing (unless queue fills up) (default 25) + requestMaxThreadPoolSize: number of threads available for request processing if queue fills us (default 150) + note that default queue never fills up: see HttpFactory + threadKeepAliveTime: time to keep threads in excess of core size alive while inactive (default 180) + note that no such threads can exist with default unbounded request queue + threadKeepAliveTimeUnit: TimeUnit of value in threadKeepAliveTime (default SECONDS) (default SECONDS) + --> + <!-- <parameter name="hostname" locked="false">http://www.myApp.com/ws</parameter> --> + <!-- <parameter name="originServer" locked="false">My-Server/1.1</parameter> --> + <!-- <parameter name="requestTimeout" locked="false">10000</parameter> --> + <!-- <parameter name="requestTcpNoDelay" locked="false">false</parameter> --> + <!-- <parameter name="requestCoreThreadPoolSize" locked="false">50</parameter> --> + <!-- <parameter name="RequestMaxThreadPoolSize" locked="false">100</parameter> --> + <!-- <parameter name="threadKeepAliveTime" locked="false">240000</parameter> --> + <!-- <parameter name="threadKeepAliveTimeUnit" locked="false">MILLISECONDS</parameter> --> + </transportReceiver> + + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportReceiver name="jms" class="org.apache.axis2.transport.jms.JMSListener"> + <parameter name="myTopicConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">TopicConnectionFactory</parameter> + </parameter> + + <parameter name="myQueueConnectionFactory" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + + <parameter name="default" locked="false"> + <parameter name="java.naming.factory.initial" locked="false">org.apache.activemq.jndi.ActiveMQInitialContextFactory</parameter> + <parameter name="java.naming.provider.url" locked="false">tcp://localhost:61616</parameter> + <parameter name="transport.jms.ConnectionFactoryJNDIName" locked="false">QueueConnectionFactory</parameter> + </parameter> + </transportReceiver>--> + + <!--Uncomment if you want to have SMTP transport support--> + <!--<transportReceiver name="mail" class="org.apache.axis2.transport.mail.SimpleMailListener">--> + <!--<parameter name="transport.mail.pop3.host" locked="false">127.0.0.1</parameter>--> + <!--<parameter name="transport.mail.pop3.user" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.password" locked="false">axis2</parameter>--> + <!--<parameter name="transport.mail.pop3.port" locked="false">110</parameter>--> + <!--<parameter name="transport.mail.replyToAddress" locked="false">axis2@127.0.0.1</parameter>--> + <!--</transportReceiver>--> + + <!--Uncomment if you want to have TCP transport support--> + <!--transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6060</parameter-->> + <!--If you want to give your own host address for EPR generation--> + <!--uncommet following paramter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + <!-- /transportReceiver --> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <!--Uncomment this and configure as appropriate for JMS transport support, after setting up your JMS environment (e.g. ActiveMQ) + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + --> + + <!-- Uncomment this one with the appropriate papameters to enable the SMTP transport Receiver + <transportSender name="mailto" class="org.apache.axis2.transport.mail.MailTransportSender"> + <parameter name="transport.mail.smtp.host" locked="false">127.0.0.1</parameter> + <parameter name="transport.mail.smtp.user" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.password" locked="false">axis2</parameter> + <parameter name="transport.mail.smtp.port" locked="false">25</parameter> + </transportSender> + --> + + <!-- ================================================= --> + <!-- Global Modules --> + <!-- ================================================= --> + <!-- Uncomment this to enable Addressing --> + <!-- module ref="addressing"/--> + + <!--Configuring module , providing parameters for modules whether they refer or not--> + <!--<moduleConfig name="addressing">--> + <!--<parameter name="addressingPara" locked="false">N/A</parameter>--> + <!--</moduleConfig>--> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"/> + <handler name="ODEAxisServiceDispatcher" + class="org.apache.ode.axis2.hooks.ODEAxisServiceDispatcher"/> + </phase> + <phase name="Security"/> + <phase name="Addressing"> + <handler name="ODEAxisOperationDispatcher" + class="org.apache.ode.axis2.hooks.ODEAxisOperationDispatcher"/> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.dispatchers.AddressingBasedDispatcher"> + <order phase="Addressing"/> + </handler> + </phase> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"/> + <handler name="RequestURIOperationDispatcher" + class="org.apache.axis2.dispatchers.RequestURIOperationDispatcher"/> + <handler name="HTTPLocationBasedDispatcher" + class="org.apache.axis2.dispatchers.HTTPLocationBasedDispatcher"/> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="ProcessHeader"> + <handler name="SessionInHandler" + class="org.apache.ode.axis2.hooks.SessionInHandler"> + <order phase="PostDispatch"/> + </handler> + </phase> + <phase name="OperationInPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="ProcessHeader"> + <handler name="SessionOutHandler" + class="org.apache.ode.axis2.hooks.SessionOutHandler"> + <order phase="PreDispatch"/> + </handler> + </phase> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="Addressing"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.dispatchers.AddressingBasedDispatcher"> + <order phase="Addressing"/> + </handler> + </phase> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.dispatchers.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.dispatchers.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + <phase name="soapmonitorPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="soapmonitorPhase"/> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/services/version.aar b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/services/version.aar new file mode 100644 index 0000000..7f66f30 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/services/version.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/web.xml b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/web.xml new file mode 100644 index 0000000..5141f1c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/WEB-INF/web.xml
@@ -0,0 +1,102 @@ +<?xml version="1.0" encoding="ISO-8859-1"?> + +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd"> + +<web-app> + <display-name>Apache-Axis2</display-name> + <servlet> + <servlet-name>AxisServlet</servlet-name> + <display-name>Apache-Axis Servlet</display-name> + <servlet-class> + org.apache.ode.axis2.hooks.ODEAxisServlet</servlet-class> + <!--<init-param>--> + <!--<param-name>axis2.xml.path</param-name>--> + <!--<param-value>/WEB-INF/conf/axis2.xml</param-value>--> + <!--<param-name>axis2.xml.url</param-name>--> + <!--<param-value>http://localhot/myrepo/axis2.xml</param-value>--> + <!--<param-name>axis2.repository.path</param-name>--> + <!--<param-value>/WEB-INF</param-value>--> + <!--<param-name>axis2.repository.url</param-name>--> + <!--<param-value>http://localhot/myrepo</param-value>--> + <!--</init-param>--> + <load-on-startup>1</load-on-startup> + </servlet> + <servlet> + <servlet-name>AxisAdminServlet</servlet-name> + <display-name>Apache-Axis AxisAdmin Servlet (REST)</display-name> + <servlet-class>org.apache.axis2.transport.http.AxisAdminServlet</servlet-class> + </servlet> + + <servlet-mapping> + <servlet-name>AxisServlet</servlet-name> + <url-pattern>/servlet/AxisServlet</url-pattern> + </servlet-mapping> + + <servlet-mapping> + <servlet-name>AxisServlet</servlet-name> + <url-pattern>*.jws</url-pattern> + </servlet-mapping> + + <servlet-mapping> + <servlet-name>AxisServlet</servlet-name> + <url-pattern>/services/*</url-pattern> + </servlet-mapping> + + <servlet-mapping> + <servlet-name>AxisServlet</servlet-name> + <url-pattern>/processes/*</url-pattern> + </servlet-mapping> + + <servlet-mapping> + <servlet-name>AxisServlet</servlet-name> + <url-pattern>/deployment/*</url-pattern> + </servlet-mapping> + + <servlet-mapping> + <servlet-name>AxisAdminServlet</servlet-name> + <url-pattern>/axis2-admin/*</url-pattern> + </servlet-mapping> + + <welcome-file-list> + <welcome-file>/index.html</welcome-file> + </welcome-file-list> + + <error-page> + <error-code>404</error-code> + <location>/axis2-web/Error/error404.jsp</location> + </error-page> + + <error-page> + <error-code>500</error-code> + <location>/axis2-web/Error/error500.jsp</location> + </error-page> + + <!-- UNCOMMENT TO USE APPSERVER DATASOURCE + <resource-ref> + <res-ref-name>jdbc/ode-ds</res-ref-name> + <res-type>javax.sql.DataSource</res-type> + <res-auth>Container</res-auth> + <res-sharing-scope>Shareable</res-sharing-scope> + </resource-ref> + UNCOMMENT TO USE APPSERVER DATASOURCE --> + +</web-app>
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/SyntaxHighlighter.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/SyntaxHighlighter.css new file mode 100644 index 0000000..85a8261 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/SyntaxHighlighter.css
@@ -0,0 +1,185 @@ +.dp-highlighter +{ + font-family: "Consolas", "Courier New", Courier, mono, serif; + font-size: 12px; + background-color: #E7E5DC; + width: 99%; + overflow: auto; + margin: 18px 0 18px 0 !important; + padding-top: 1px; /* adds a little border on top when controls are hidden */ +} + +/* clear styles */ +.dp-highlighter ol, +.dp-highlighter ol li, +.dp-highlighter ol li span +{ + margin: 0; + padding: 0; + border: none; +} + +.dp-highlighter a, +.dp-highlighter a:hover +{ + background: none; + border: none; + padding: 0; + margin: 0; +} + +.dp-highlighter .bar +{ + padding-left: 45px; +} + +.dp-highlighter.collapsed .bar, +.dp-highlighter.nogutter .bar +{ + padding-left: 0px; +} + +.dp-highlighter ol +{ + list-style: decimal; /* for ie */ + background-color: #fff; + margin: 0px 0px 1px 45px !important; /* 1px bottom margin seems to fix occasional Firefox scrolling */ + padding: 0px; + color: #5C5C5C; +} + +.dp-highlighter.nogutter ol, +.dp-highlighter.nogutter ol li +{ + list-style: none !important; + margin-left: 0px !important; +} + +.dp-highlighter ol li, +.dp-highlighter .columns div +{ + list-style: decimal-leading-zero; /* better look for others, override cascade from OL */ + list-style-position: outside !important; + border-left: 3px solid #6CE26C; + background-color: #F8F8F8; + color: #5C5C5C; + padding: 0 3px 0 10px !important; + margin: 0 !important; + line-height: 14px; +} + +.dp-highlighter.nogutter ol li, +.dp-highlighter.nogutter .columns div +{ + border: 0; +} + +.dp-highlighter .columns +{ + background-color: #F8F8F8; + color: gray; + overflow: hidden; + width: 100%; +} + +.dp-highlighter .columns div +{ + padding-bottom: 5px; +} + +.dp-highlighter ol li.alt +{ + background-color: #FFF; + color: inherit; +} + +.dp-highlighter ol li span +{ + color: black; + background-color: inherit; +} + +/* Adjust some properties when collapsed */ + +.dp-highlighter.collapsed ol +{ + margin: 0px; +} + +.dp-highlighter.collapsed ol li +{ + display: none; +} + +/* Additional modifications when in print-view */ + +.dp-highlighter.printing +{ + border: none; +} + +.dp-highlighter.printing .tools +{ + display: none !important; +} + +.dp-highlighter.printing li +{ + display: list-item !important; +} + +/* Styles for the tools */ + +.dp-highlighter .tools +{ + padding: 3px 8px 3px 10px; + font: 9px Verdana, Geneva, Arial, Helvetica, sans-serif; + color: silver; + background-color: #f8f8f8; + padding-bottom: 10px; + border-left: 3px solid #6CE26C; +} + +.dp-highlighter.nogutter .tools +{ + border-left: 0; +} + +.dp-highlighter.collapsed .tools +{ + border-bottom: 0; +} + +.dp-highlighter .tools a +{ + font-size: 9px; + color: #a0a0a0; + background-color: inherit; + text-decoration: none; + margin-right: 10px; +} + +.dp-highlighter .tools a:hover +{ + color: red; + background-color: inherit; + text-decoration: underline; +} + +/* About dialog styles */ + +.dp-about { background-color: #fff; color: #333; margin: 0px; padding: 0px; } +.dp-about table { width: 100%; height: 100%; font-size: 11px; font-family: Tahoma, Verdana, Arial, sans-serif !important; } +.dp-about td { padding: 10px; vertical-align: top; } +.dp-about .copy { border-bottom: 1px solid #ACA899; height: 95%; } +.dp-about .title { color: red; background-color: inherit; font-weight: bold; } +.dp-about .para { margin: 0 0 4px 0; } +.dp-about .footer { background-color: #ECEADB; color: #333; border-top: 1px solid #fff; text-align: right; } +.dp-about .close { font-size: 11px; font-family: Tahoma, Verdana, Arial, sans-serif !important; background-color: #ECEADB; color: #333; width: 60px; height: 22px; } + +/* Language specific styles */ + +.dp-highlighter .comment, .dp-highlighter .comments { color: #008200; background-color: inherit; } +.dp-highlighter .string { color: blue; background-color: inherit; } +.dp-highlighter .keyword { color: #069; font-weight: bold; background-color: inherit; } +.dp-highlighter .preprocessor { color: gray; background-color: inherit; }
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/global.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/global.css new file mode 100644 index 0000000..113bdb3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/global.css
@@ -0,0 +1,395 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/*------------------------------------------------------------------ +[Global Stylesheet] + +Version: 1.0 +Last change: 05/06/2008 +Assigned to: Apache Software Foundation +Primary use: ODE Management Console +-------------------------------------------------------------------*/ + +/** +* ---------------------------------------------------------------- +* html, body +* ---------------------------------------------------------------- +*/ + +html { + background: #27343c; + color: #666; + font: 76% Arial, Helvetica, sans-serif; + text-align: center; +} + +html, body { + margin: 0; + padding: 0; +} + +body { + text-align: left; + width: 930px; + margin: 0 auto; + line-height: 1em; +} + +#header { + clear: both; +} + +#login { + color: #334550; + font-family: Arial, Helvetica, sans-serif; + font-size: 11px; + float: right; + height: 74px; + line-height: 88px; +} + +#login a:link, #login a:visited { + color: #57B3E1; +} + +.greeting { + color: #fff; +} + +#siteNav { + background: #0c1216 url( ../images/navBack.png ) top left no-repeat; + height: 32px; +} + +/*------------------------------------- + SiteNav +---------------------------------------*/ + +#siteNav ul { + margin-left: 15px; + padding-top: 4px; + z-index: 1; +} + +#siteNav li { + float: left; + position: relative; + top: 0; + left: 0; +} + +#siteNav li a { + padding: 8px 12px 8px 12px; +} + +#siteNav li.current a { + margin-bottom: 0px; +} + +#siteNav li ul { + display: none; + position: absolute; + top: 0; + left: 0; + margin: 0; + padding: 0; +} + +#siteNav ul:after { + content: "."; + display: block; + height: 0; + clear: both; + visibility: hidden; +} + +#siteNav li ul li ul { + position: relative; +} + +#siteNav li ul li { + width: 175px; +} + +#siteNav li > ul { + top: auto; + left: auto; +} + +#siteNav li:hover ul { + display: block; +} + +#siteNav li.current ul { + padding-bottom: 1px; +} + +#siteNav li { + font-size: 12px; + text-align: center; +} + +#siteNav li li { + text-align: left; +} + +#siteNav li li li { + text-indent: 10px; +} + +#siteNav a { + text-decoration: none; + display: block; +} + +#siteNav li { +} + +#siteNav li a:link, #siteNav li a:visited { + background: transparent url( ../images/site_nav_borders.gif ) bottom right no-repeat; + color: #c2d4dd; +} + +#siteNav li a:hover { + background: #baced7 url( ../images/site_nav_hover_bg.gif ) bottom left repeat-x; + color: #24495e; +} + +#siteNav li.current a:link, #siteNav li.current a:visited { + background: #f0f5f8 url( ../images/tab-selected-mid.png ) bottom left repeat-x; + color: #37454e; /*border-bottom: 1px solid #d7e5ed;*/ +} + +#siteNav li ul, #siteNav li.current ul { + border-left: 1px solid #bcd1df; + border-bottom: 1px solid #bcd1df; + border-right: 1px solid #bcd1df; +} + +#siteNav li.over { + color: yellow; + border: 1px solid red; +} + +#wrapper { + background: transparent url( ../images/wrapper_back.png ) repeat-y scroll left top; + border-top: 1px solid #FFFFFF; +} + +#wrapper #insideW { + background: transparent url( ../images/inner_back.png ) repeat-x scroll left top; + margin: 0px; + padding: 0px; + +} + +#insideW #insideL { + background: transparent url( ../images/bottom_m.png ) no-repeat scroll left bottom; +} + +#wrapper #pageNav { + background: transparent url( ../images/pagenav_back.png ) repeat-y scroll left top; + float: right; + width: 234px; + min-height: 110px; +} + +#wrapper #content { + padding-bottom: 32px; + padding-top: 25px; + padding-left: 25px; + padding-right: 25px; /*width: 620px;*/ + min-height: 80px; +} +#wrapper #content_index { + padding-bottom: 32px; + padding-top: 5px; + padding-left:10.5px; + padding-right:10.5px; /*width: 620px;*/ + min-height: 80px; +} + +#content_index #main_img{ + background:transparent url(../images/img_main.png) no-repeat scroll left top; + min-height:60px; + padding-top:230px; + padding-left:20px; +} +#content_index #main_img #nav{ + +} + +/* Table style */ +caption { + padding: 0 0 5px 0; + font: italic 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + text-align: left; + border-bottom: 1px dotted #000000; + margin-bottom: 10px; +} + +th { + font: bold 11px "Trebuchet MS", Verdana, Arial, Helvetica, + sans-serif; + color: #6D929B; + letter-spacing: 2px; + text-align: left; + padding: 6px 6px 6px 12px; +} + +th.nobg { + border-top: 0; + border-left: 0; + border-right: 1px solid #C1DAD7; + background: none; +} + +th.spec { + border-left: 1px solid #C1DAD7; + border-top: 0; + background: #fff url( ../images/bullet1.gif ) no-repeat; + font: bold 10px "Trebuchet MS", Verdana, Arial, Helvetica, + sans-serif; +} + +th.specalt { + border-left: 1px solid #C1DAD7; + border-top: 0; + background: #f5fafa url( ../images/bullet2.gif ) no-repeat; + font: bold 10px "Trebuchet MS", Verdana, Arial, Helvetica, + sans-serif; + color: #B4AA9D; +} + +td { + background: #fff; + padding: 6px 6px 6px 12px; + color: #6D929B; +} + +td.alt { + font: italic 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + text-align: left; + color: #B4AA9D; +} + +tr.alt { + background: #F5FAFA; + color: #B4AA9D; +} + +.process { + margin-top: 10px; + padding: 0px; + border: 1px solid; +} + +.process h3 { + color:#000000; + font: bold 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + padding-left: 5px; + padding-bottom:5px; + padding-top:5px; + background: #ffc; + padding-right:5px; + border-bottom:1px solid #B4AA9D; +} + +.process h3 img{ + font: bold 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + vertical-align:middle; + margin-right:4px; + background: #B4AA9D; +} + +.clearboth{ + clear:both; +} + +.processcontrols{ + float:right; +} + +.instance { + margin-top: 10px; + padding: 0px; + border: 1px solid; +} + +.instance h3 { + color:#000000; + font: bold 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + padding-left: 5px; + padding-bottom:5px; + padding-top:5px; + background: #ffc; + padding-right:5px; + border-bottom:1px solid #B4AA9D; +} + +.instance h3 img{ + font: bold 14px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + vertical-align:middle; + margin-right:4px; + background: #B4AA9D; +} + +h2 { + padding: 0 0 5px 0; + font: italic 17px "Trebuchet MS", Verdana, Arial, Helvetica, sans-serif; + font-weight:bold; + text-align: left; + border-bottom: 1px dotted #000000; + margin-bottom: 10px; +} + +/* BUTTONS */ + +.clear { /* generic container (i.e. div) for floating buttons */ + overflow: hidden; + width: 100%; +} + +a.button { + background: transparent url('../images/bg_button_a.gif') no-repeat scroll top right; + color: #444; + display: block; + float: left; + font: normal 12px arial, sans-serif; + height: 24px; + margin-right: 6px; + padding-right: 18px; /* sliding doors padding */ + text-decoration: none; +} + +a.button span { + background: transparent url('../images/bg_button_span.gif') no-repeat; + display: block; + line-height: 14px; + padding: 5px 0 5px 18px; +} + +a.button:active { + background-position: bottom right; + color: #000; + outline: none; /* hide dotted outline in Firefox */ +} + +a.button:active span { + background-position: bottom left; + padding: 6px 0 4px 18px; /* push text down 1px */ +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/reset.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/reset.css new file mode 100644 index 0000000..e81153c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/reset.css
@@ -0,0 +1,44 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/*------------------------------------------------------------------ +[Reset Stylesheet] + +Version: 1.0 +Last change: 05/06/2008 +Assigned to: Apache Software Foundation +Primary use: ODE Management Console +-------------------------------------------------------------------*/ + +p, div, h1, h2, h3, h4, ul, li, form, input, select, option { + margin: 0; + padding: 0; +} + +img { + margin: 0; + padding: 0; + border: 0; +} + +ul { + list-style: none; +} + +a { + outline: 0; +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/style.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/style.css new file mode 100644 index 0000000..4983e7c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/css/style.css
@@ -0,0 +1,31 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +/*------------------------------------------------------------------ +[Master Stylesheet] + +Version: 1.0 +Last change: 05/06/2008 +Assigned to: Apache Software Foundation +Primary use: ODE Management Console +-------------------------------------------------------------------*/ +@import "reset.css"; +@import "global.css"; +/*@import "colors.css"; +@import "typography.css"; +@import "flash.css";*/ +/* @import "debugging.css"; */ \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/deployment.html b/_br-ode-1.X.svn/axis2-war/src/main/webapp/deployment.html new file mode 100644 index 0000000..5899e39 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/deployment.html
@@ -0,0 +1,203 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>Apache ODE | Deployment</title> + <link rel="stylesheet" href="css/style.css" type="text/css" media="screen, projection"/> + <link rel="stylesheet" href="js/yui/css/container.css" media="screen, projection"/> + <link rel="stylesheet" href="js/yui/css/button.css" media="screen, projection"/> + <link rel="stylesheet" href="js/bubbling/assets/accordion.css" media="screen, projection"/> + <link rel="stylesheet" type="text/css" href="js/yui/tab/skins/sam/tabview.css"/> + <link rel="stylesheet" type=="text/css" href="js/codepress/codepress.css"/> + <script type="text/javascript" src="js/WSRequest.js"> + </script> + <script type="text/javascript" src="js/codepress/codepress.js"> + </script> + <script type="text/javascript" src="js/ProcessManagementAPI.js"> + </script> + <script type="text/javascript" src="js/InstanceManagementAPI.js"> + </script> + <script type="text/javascript" src="js/DeploymentService.js"> + </script> + <script type="text/javascript" src="js/yui/utilities.js"> + </script> + <script type="text/javascript" src="js/yui/container.js"></script> + <script type="text/javascript" src="js/yui/button.js"> + </script> + <script type="text/javascript" src="js/yui/animation.js"> + </script> + <script type="text/javascript" src="js/bubbling/bubbling.js"> + </script> + <script type="text/javascript" src="js/bubbling/accordion.js"> + </script> + <script type="text/javascript" src="js/ODE.js"> + </script> + <script type="text/javascript" src="js/yui/tabview.js"> + </script> + <script type="text/javascript"> + + function init(){ + org.apache.ode.DeploymentHandling.populateDeployedPacks(); + setInterval('org.apache.ode.DeploymentHandling.populateDeployedPacks()', 15000); + var myTabs = new YAHOO.widget.TabView("tabt"); + } + + YAHOO.util.Event.onDOMReady(init); + </script> + <style type="text/css"> + button { + background: transparent url(../button/assets/add.gif) no-repeat scroll 10% 50%; + padding-left: 2em; + } + + .link { + margin-left: 5px; + color: blue; + } + + .myAccordion .yui-cms-accordion .yui-cms-item { + margin-bottom: 10px; + } + + .bd { + background: #FFFFFF none repeat scroll 0 0; + } + + ul.deployed { + padding: 10px 0px; + list-style-image: url(images/process.png); + margin-left: 30px; + } + + ul.deployed li { + font-family: serif; + font-size: 1.2em; + font-weight: bold; + padding: 5px 10px 5px 0px; + line-height: 20px; + } + + .depn, .createn{ + margin-top:30px; + } + </style> + </head> + <body> + <div id="header"> + <div id="login"> + <a href="http://apache.org">Apache</a> + |<a href="http://ode.apache.org">ODE</a> + |<a href="http://ode.apache.org/user-guide.html">User Guide</a> + |<a href="http://ode.apache.org/developer-guide.html">Developer Guide</a> + </div> + <h1><img src="images/logo.png" alt="Apache ODE"/></h1> + </div> + <div id="siteNav"> + <ul> + <li> + <a href="index.html">Home</a> + </li> + <li> + <a href="processes.html">Processes</a> + </li> + <li> + <a href="instances.html">Instances</a> + </li> + <li class="current"> + <a href="#">Deployment</a> + </li> + </ul> + </div> + <div id="wrapper"> + <dir id="insideW"> + <div id="insideL"> + <div id="content" class="yui-skin-sam"> + + <h2>Deployed Packages</h2> + <div id="deployed" class="yui-skin-sam"> + + </div> + + <h2 class="depn">Deploy New Process</h2> + <script type="text/javascript"> + // Removes leading whitespaces + function LTrim( value ) { + var re = /\s*((\S+\s*)*)/; + return value.replace(re, "$1"); + } + + // Removes ending whitespaces + function RTrim( value ) { + var re = /((\s*\S+)*)\s*/; + return value.replace(re, "$1"); + } + + // Removes leading and ending whitespaces + function trim( value ) { + return LTrim(RTrim(value)); + } + + function clearOpstat(){ + var opStatDiv = document.getElementById('opstat'); + opStatDiv.value = ""; + } + + function handleSuccess(o){ + document.getElementById('opstat').innerHTML = '<h2 style="color:red;border-bottom:0px;">'+ trim(o.responseText).replace(/\n/g, "") + '</h2>'; + org.apache.ode.DeploymentHandling.populateDeployedPacks(); + } + function handleFailure(o){ + document.getElementById('opstat').innerHTML = trim(o.responseText).replace(/\n/g, ""); + } + + var callback = { + success:handleSuccess, + failure:handleFailure, + upload:handleSuccess + } + + function submitFormAsync(fomrID){ + clearOpstat(); + var form = document.getElementById(fomrID); + if(document.getElementById('uploadfile').value == ""){ + alert('Please select a package to deploy!'); + }else{ + YAHOO.util.Connect.setForm(form, true, true); + YAHOO.util.Connect.asyncRequest("POST", form.getAttribute("action"), callback, null); + } + } + </script> + <form id="formdep" name="form" method="post" enctype="multipart/form-data" action="fileupload.jsp" > + <table> + <tr> + <th align="left"> + Name + </th> + <td> + <input type="text" id="fileName" name="fileName" /> + </td> + </tr> + <tr> + <th align="left"> + Upload File + </th> + <td> + <input type="file" id="uploadfile" name="uploadfile" /> + </td> + </tr> + </table> + <br> + <input type="button" id="doUpload" name="doUpload" value="OK" onclick="submitFormAsync('formdep');" /> + + </form> + <div id="opstat" onload="clearOpstat();"> + </div> + <div> + <script type="text/javascript"> + CodePress.run(); + </script> + </div> + </div> + </dir> + </div> + </body> + </html>
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/favicon.ico b/_br-ode-1.X.svn/axis2-war/src/main/webapp/favicon.ico new file mode 100644 index 0000000..cac0909 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/favicon.ico Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/fileupload.jsp b/_br-ode-1.X.svn/axis2-war/src/main/webapp/fileupload.jsp new file mode 100644 index 0000000..f80b151 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/fileupload.jsp
@@ -0,0 +1,135 @@ +<%@ page import="java.util.List" %> +<%@ page import="java.util.Iterator" %> +<%@ page import="java.io.File" %> +<%@ page import="java.lang.String" %> +<%@ page import="java.io.InputStream" %> +<%@ page import="org.apache.commons.codec.binary.Base64" %> +<%@ page import="org.apache.commons.fileupload.servlet.ServletFileUpload"%> +<%@ page import="org.apache.commons.fileupload.disk.DiskFileItemFactory"%> +<%@ page import="org.apache.commons.fileupload.*"%> +<%@ page import="org.apache.axis2.client.Options" %> +<%@ page import="org.apache.axis2.client.ServiceClient" %> +<%@ page import="org.apache.axis2.addressing.EndpointReference" %> +<%@ page import="org.apache.axiom.om.OMElement" %> +<%@ page import="org.apache.axiom.om.OMFactory" %> +<%@ page import="org.apache.axiom.om.OMAbstractFactory" %> +<%@ page import="org.apache.axiom.om.OMText" %> +<%@ page import="javax.xml.stream.XMLStreamReader"%> +<%@ page import="javax.xml.stream.XMLInputFactory"%> +<%@ page import="org.apache.axiom.om.impl.builder.StAXOMBuilder"%> +<%@ page import="java.io.StringReader"%> +<%@ page import="org.apache.commons.httpclient.protocol.ProtocolSocketFactory"%> +<%@ page import="org.apache.commons.httpclient.protocol.Protocol"%> +<%@ page import="org.apache.axiom.soap.SOAP11Constants"%> +<%@ page import="org.apache.axiom.soap.SOAP12Constants"%> +<%@ page import="org.apache.axis2.Constants"%> +<%@ page import="org.apache.axis2.description.WSDL2Constants"%> +<%@ page import="org.apache.axis2.util.JavaUtils"%> +<%@ page import="org.apache.axis2.addressing.AddressingConstants"%> +<%@ page import="org.apache.axis2.transport.http.HttpTransportProperties"%> +<%@ page import="org.apache.axis2.transport.http.HTTPConstants"%> +<%@ page import="org.apache.axis2.AxisFault"%> +<%@ page import="org.apache.axis2.context.OperationContext"%> +<%@ page import="org.apache.axis2.context.MessageContext"%> +<%@ page import="org.apache.axiom.soap.SOAPEnvelope"%> +<%@ page import="org.apache.axiom.om.OMNamespace"%> +<%@ page contentType="text/plain" language="java" %> + +<% +boolean isMultipart = ServletFileUpload.isMultipartContent(request); +if (!isMultipart) { +} else { + FileItemFactory factory = new DiskFileItemFactory(); + ServletFileUpload upload = new ServletFileUpload(factory); + List items = null; + String packageName = null; + try { + items = upload.parseRequest(request); + } catch (FileUploadException e) { + e.printStackTrace(); + } + Iterator itr = items.iterator(); + while (itr.hasNext()) { + FileItem item = (FileItem) itr.next(); + if (item.isFormField()) { + if(item.getFieldName().equals("fileName")){ + packageName = item.getString(); + } + } else { + try { + String itemName = item.getName(); + String extension = itemName.toLowerCase(); + if(extension.endsWith(".zip")){ + long size = item.getSize(); + InputStream is = item.getInputStream(); + byte[] bytes = new byte[(int)size]; + int offset = 0; + int numRead = 0; + while (offset < bytes.length + && (numRead=is.read(bytes, offset, bytes.length-offset)) >= 0) { + offset += numRead; + } + if (offset < bytes.length) { + out.println("Overflow Error Occurred!"); + }else{ + if(!Base64.isArrayByteBase64(bytes)){ + byte[] encodedBytes = Base64.encodeBase64(bytes); + String encodedString = new String(encodedBytes); + Options opts = new Options(); + opts.setAction("http://www.apache.org/ode/deployapi/DeploymentPortType/deployRequest"); + opts.setSoapVersionURI(SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI); + opts.setProperty(Constants.Configuration.HTTP_METHOD, + Constants.Configuration.HTTP_METHOD_POST); + opts.setTo(new EndpointReference("http://localhost:8080/ode/processes/DeploymentService")); + + OMElement payload = null; + OMFactory omFactory = OMAbstractFactory.getOMFactory(); + OMNamespace ns = omFactory.createOMNamespace("http://www.apache.org/ode/pmapi","p"); + payload = omFactory.createOMElement("deploy", ns); + OMElement name = omFactory.createOMElement("name", ns); + OMElement packageCont = omFactory.createOMElement("package", ns); + OMElement zipEle = omFactory.createOMElement("zip", ns); + if(packageName != null && encodedString != null){ + OMText nameText = omFactory.createOMText(name, packageName); + OMText packageText = omFactory.createOMText(zipEle, encodedString); + packageCont.addChild(zipEle); + payload.addChild(name); + payload.addChild(packageCont); + + //creating service client + ServiceClient sc = new ServiceClient(); + sc.setOptions(opts); + + try { + //invoke service + OMElement responseMsg = sc.sendReceive(payload); + String body = responseMsg.toString(); + if(body.indexOf("name") > 0){ + out.println("Package deployed successfully!"); + }else{ + out.println("Package deployement failed!"); + } + } catch (AxisFault axisFault) { + out.println("Axis2 Fault Occurred while Sending the request!"); + } + }else{ + out.println("No package Name specified!"); + break; + } + }else{ + out.println("TODO: Implement Base64 encoded string support!"); + } + } + + }else{ + out.write("Wrong input format. Inout file must be zip archive!"); + } + } catch (Exception e) { + out.println(e); + out.println("Exception occuured while processing the file upload request!"); + } + } + } +} +%> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/31-Document_48x48.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/31-Document_48x48.png new file mode 100644 index 0000000..acd63b6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/31-Document_48x48.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/activate.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/activate.png new file mode 100644 index 0000000..02a7570 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/activate.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/addGadgetIcon.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/addGadgetIcon.gif new file mode 100644 index 0000000..4ba3521 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/addGadgetIcon.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/arrowsDown.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/arrowsDown.gif new file mode 100644 index 0000000..81e78e1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/arrowsDown.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/arrowsUp.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/arrowsUp.gif new file mode 100644 index 0000000..f01eee8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/arrowsUp.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_button_a.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_button_a.gif new file mode 100644 index 0000000..c8e740d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_button_a.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_button_span.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_button_span.gif new file mode 100644 index 0000000..7da2e19 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_button_span.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_header.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_header.jpg new file mode 100644 index 0000000..10dbd74 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bg_header.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bottom.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bottom.png new file mode 100644 index 0000000..cd84c28 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bottom.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bottom_m.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bottom_m.png new file mode 100644 index 0000000..4e3be20 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bottom_m.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bullet1.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bullet1.gif new file mode 100644 index 0000000..ae352c2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bullet1.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bullet2.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bullet2.gif new file mode 100644 index 0000000..04b293d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/bullet2.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/buttonBack.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/buttonBack.gif new file mode 100644 index 0000000..9320070 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/buttonBack.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/closeIcon.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/closeIcon.gif new file mode 100644 index 0000000..d58d4db --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/closeIcon.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/dguide.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/dguide.png new file mode 100644 index 0000000..5bce350 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/dguide.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/gadgetTitleBg.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/gadgetTitleBg.jpg new file mode 100644 index 0000000..47444e5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/gadgetTitleBg.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/guide.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/guide.png new file mode 100644 index 0000000..fb8a133 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/guide.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/home.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/home.png new file mode 100644 index 0000000..13f4430 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/home.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/img_main.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/img_main.png new file mode 100644 index 0000000..d663429 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/img_main.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/info.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/info.png new file mode 100644 index 0000000..699b0c2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/info.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/inner_back.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/inner_back.png new file mode 100644 index 0000000..f86f252 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/inner_back.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/logo.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/logo.png new file mode 100644 index 0000000..4ef369c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/logo.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/navBack.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/navBack.png new file mode 100644 index 0000000..20a8cfa --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/navBack.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/pagenav_back.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/pagenav_back.png new file mode 100644 index 0000000..09b7d17 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/pagenav_back.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/process.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/process.png new file mode 100644 index 0000000..188e53a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/process.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/retire.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/retire.png new file mode 100644 index 0000000..3aa84a6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/retire.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/settingsIcon.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/settingsIcon.gif new file mode 100644 index 0000000..00f1ebf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/settingsIcon.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/site_nav_borders.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/site_nav_borders.gif new file mode 100644 index 0000000..ca74247 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/site_nav_borders.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/site_nav_hover_bg.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/site_nav_hover_bg.gif new file mode 100644 index 0000000..11764d2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/site_nav_hover_bg.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/tab-selected-mid.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/tab-selected-mid.png new file mode 100644 index 0000000..8c2180a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/tab-selected-mid.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_end.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_end.jpg new file mode 100644 index 0000000..73d2cbc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_end.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_end.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_end.png new file mode 100644 index 0000000..215dc72 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_end.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_start.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_start.jpg new file mode 100644 index 0000000..cffa1f6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_start.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_start.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_start.png new file mode 100644 index 0000000..91e106f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_bottom_start.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_close.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_close.jpg new file mode 100644 index 0000000..748ffde --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_close.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_max.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_max.jpg new file mode 100644 index 0000000..6657212 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_max.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_min.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_min.jpg new file mode 100644 index 0000000..43b2f03 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_min.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_resize.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_resize.gif new file mode 100644 index 0000000..7c09c2c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_resize.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_end.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_end.jpg new file mode 100644 index 0000000..ba6edb0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_end.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_end.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_end.png new file mode 100644 index 0000000..f776f07 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_end.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_start.jpg b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_start.jpg new file mode 100644 index 0000000..495b5dd --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_start.jpg Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_start.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_start.png new file mode 100644 index 0000000..77a5ad8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/window_top_start.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/wrapper_back.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/wrapper_back.png new file mode 100644 index 0000000..3aa85ba --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/wrapper_back.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/wrapper_column_top.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/wrapper_column_top.gif new file mode 100644 index 0000000..3143e76 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/images/wrapper_column_top.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/index.html b/_br-ode-1.X.svn/axis2-war/src/main/webapp/index.html new file mode 100644 index 0000000..fb7dd77 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/index.html
@@ -0,0 +1,222 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>Apache ODE | Home</title> + <link rel="stylesheet" href="css/style.css" type="text/css" media="screen, projection"/> + + <script type="text/javascript" src="js/WSRequest.js"> + </script> + <script type="text/javascript" src="js/ProcessManagementAPI.js"> + </script> + <script type="text/javascript" src="js/yui/utilities.js"> + </script> + <script type="text/javascript" src="js/yui/button.js"></script> + <script type="text/javascript" src="js/yui/container.js"></script> + <script type="text/javascript" src="js/bubbling/bubbling.js"> + </script> + <script type="text/javascript" src="js/bubbling/accordion.js"> + </script> + <script type="text/javascript" src="js/yui/tabview.js"> + </script> + <script type="text/javascript" src="js/yui/animation.js"> + </script> + <script type="text/javascript" src="js/yui/json-min.js"> + </script> + <script type="text/javascript" src="js/yui/datasource-beta-min.js"> + </script> + <script type="text/javascript" src="js/yui/charts-experimental-min.js"> + </script> + + <script type="text/javascript" src="js/ODE.js"> + </script> + <script type="text/javascript"> + YAHOO.widget.Chart.SWFURL = "js/yui/charts.swf"; + function populateStats(){ + var stat = org.apache.ode.ProcessHandling.stats(); + var html = '<table><tr><td class="bl">Total Number of Processes in the System: </td><td>'+ + stat.numOfProcesses+ '</td><td class="bl">Total Number of Instances in the System:</td><td>'+ + stat.totalInst+ '</td></tr></table>'; + + var statEle = document.getElementById('summary_tb'); + statEle.innerHTML = html; + var chart_data = + [ + {instances: "Active", count:stat.activeInst}, + {instances: "Completed", count:stat.completedInst}, + {instances: "Terminated", count:stat.terminatedInst}, + {instances: "Error", count:stat.errorInst}, + {instances: "Failed", count:stat.failedInst}, + {instances: "Suspended", count:stat.suspendedInst} + ] + var ds = new YAHOO.util.DataSource(chart_data); + ds.responseType = YAHOO.util.DataSource.TYPE_JSARRAY; + ds.responseSchema = {fields:["instances", "count"]}; + var chartPie = new YAHOO.widget.PieChart("summary_chart", ds, + { + dataField: "count", + categoryField: "instances", + style: + { + padding: 10, + legend: + { + display: "right", + padding: 10, + spacing: 5, + font: + { + family: "Arial", + size: 13 + } + } + } + }); + } + + function init(){ + populateStats(); + setInterval("populateStats()", 10000); + } + + YAHOO.util.Event.onDOMReady(init); + + </script> + <style type="text/css"> + #nav ul { + margin-left: 0; + padding-left: 0; + display: inline; + font-size: 16px; + font-family: Georgia; + color: #ffffff; + font-weight: bold; + font-style: normal; + } + + #nav ul li { + margin-left: 0; + /*padding: 3px 15px;*/ + list-style: none; + display: inline; + } + + #nav ul li a { + background: transparent none no-repeat scroll left center; + /*line-height:80px;*/ + padding-top: 14.5px; + padding-bottom: 14.5px; + padding-left: 50px; + padding-right: 5px; + } + + #nav ul li a:hover { + color: #000; + } + + #nav ul li a.home { + background-image: url(images/home.png); + } + + #nav ul li a.uguide { + background-image: url(images/guide.png); + } + + #nav ul li a.dguide { + background-image: url(images/dguide.png); + } + #summary_chart{ + width:370px; + height:250px; + float:left; + } + .sub_h{ + font-family:Georgia; + border-top:#0099FF solid 1px; + border-bottom:#0099FF solid 1px; + line-height:25px; + font-style:normal; + font-weight:normal; + color: #006699; + } + #summary_tb{ + text-align:left; + font-family:Georgia; + font-style:normal; + font-weight:normal; + font-size:1.5em; + } + .bl{ + color:#000; + } + </style> + <script type="text/javascript"> + </script> + </head> + <body> + <div id="header"> + <div id="login"> + <a href="http://apache.org">Apache</a> + |<a href="http://ode.apache.org">ODE</a> + |<a href="http://ode.apache.org/user-guide.html">User Guide</a> + |<a href="http://ode.apache.org/developer-guide.html">Developer Guide</a> + </div> + <h1><img src="images/logo.png" alt="Apache ODE"/></h1> + </div> + <div id="siteNav"> + <ul> + <li class="current"> + <a href="#">Home</a> + </li> + <li> + <a href="processes.html">Processes</a> + </li> + <li> + <a href="instances.html">Instances</a> + </li> + <li> + <a href="deployment.html">Deployment</a> + </li> + </ul> + </div> + <div id="wrapper"> + <dir id="insideW"> + <div id="insideL"> + <div id="content_index"> + <div id="main_img"> + <div id="nav"> + <ul> + <li> + <a class="home" href="http://ode.apache.org/">Apache ODE</a> + </li> + <li> + <a class="uguide" href="http://ode.apache.org/user-guide.html">User Guide</a> + </li> + <li> + <a class="dguide" href="http://ode.apache.org/developer-guide.html">Developer Guide</a> + </li> + </ul> + </div> + </div> + <div id="stats"> + <div id="chart"> + <h2 class="sub_h">Summary of Instances</h2> + <table> + <tr> + <td id="summary_tb"> + </td> + </tr> + <tr> + <td id="summary_chart"> + </td> + </tr> + </table> + </div> + </div> + <div id="events"> + </div> + </div> + </div> + </dir> + </div> + </body> +</html>
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/instances.html b/_br-ode-1.X.svn/axis2-war/src/main/webapp/instances.html new file mode 100644 index 0000000..9b5bbc4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/instances.html
@@ -0,0 +1,93 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>Apache ODE | Instances</title> + <link rel="stylesheet" href="css/style.css" type="text/css" media="screen, projection"/> + <link rel="stylesheet" href="js/yui/css/container.css" media="screen, projection"/> + <link rel="stylesheet" href="js/yui/css/button.css" media="screen, projection"/> + <link rel="stylesheet" href="js/bubbling/assets/accordion.css" media="screen, projection"/> + <script type="text/javascript" src="js/WSRequest.js"> + </script> + <script type="text/javascript" src="js/ProcessManagementAPI.js"> + </script> + <script type="text/javascript" src="js/InstanceManagementAPI.js"> + </script> + <script type="text/javascript" src="js/yui/utilities.js"> + </script> + <script type="text/javascript" src="js/yui/container.js"></script> + <script type="text/javascript" src="js/yui/button.js"></script> + <script type="text/javascript" src="js/yui/button.js"> + </script> + <script type="text/javascript" src="js/yui/animation.js"> + </script> + <script type="text/javascript" src="js/bubbling/bubbling.js"> + </script> + <script type="text/javascript" src="js/bubbling/accordion.js"> + </script> + <script type="text/javascript" src="js/ODE.js"> + </script> + <script type="text/javascript"> + function init(){ + org.apache.ode.InstanceHandling.populateContent(); + setInterval('org.apache.ode.InstanceHandling.populateContent()', 15000); + } + + YAHOO.util.Event.onDOMReady(init); + </script> + <style type="text/css"> + button { + background: transparent url(../button/assets/add.gif) no-repeat scroll 10% 50%; + padding-left: 2em; + } + + .link { + margin-left: 5px; + color: blue; + } + + .myAccordion .yui-cms-accordion .yui-cms-item { + margin-bottom: 10px; + } + + .bd { + background: #FFFFFF none repeat scroll 0 0; + } + </style> + </head> + <body> + <div id="header"> + <div id="login"> + <a id="loginLink" href="#">Login</a> + |<a href="http://apache.org">Apache</a> + |<a href="http://ode.apache.org">ODE</a> + |<a href="http://ode.apache.org/user-guide.html">User Guide</a> + |<a href="http://ode.apache.org/developer-guide.html">Developer Guide</a> + </div> + <h1><img src="images/logo.png" alt="Apache ODE"/></h1> + </div> + <div id="siteNav"> + <ul> + <li> + <a href="index.html">Home</a> + </li> + <li> + <a href="processes.html">Processes</a> + </li> + <li class="current"> + <a href="#">Instances</a> + </li> + <li> + <a href="deployment.html">Deployment</a> + </li> + </ul> + </div> + <div id="wrapper"> + <dir id="insideW"> + <div id="insideL"> + <div id="content" class="yui-skin-sam"> + </div> + </div> + </dir> + </div> + </body> +</html>
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/DeploymentService.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/DeploymentService.js new file mode 100644 index 0000000..37fa66a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/DeploymentService.js
@@ -0,0 +1,585 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +var baseURL; +if (location.host.indexOf('/') == -1 && location.protocol.indexOf('/') == -1) { + baseURL = location.protocol + "//" + location.host + "/"; +}else if(location.host.indexOf('/') != -1 && location.protocol.indexOf('/') == -1){ + baseURL = location.protocol + "//" + location.host; +} +var address = baseURL + "ode/processes/DeploymentService"; + +var DeploymentService = new WebService("DeploymentPort"); + +DeploymentService.undeploy = + function undeploy(/* QName */ _packageName) + { + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.undeploy.callback != null && typeof(this.undeploy.callback) == 'function'); + request = + '<p:undeploy xmlns:p="http://www.apache.org/ode/pmapi">' + + (_packageName == null ? '' : '<packageName>' + this._encodeXML(_packageName) + '</packageName>') + + '</p:undeploy>' ; + + if (isAsync) { + try { + this._call( + "undeploy", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + var extractedValue = WSRequest.util._stringValue(response.documentElement); + resultValue = /* Boolean */ extractedValue == "true" || extractedValue == "1"; + } + callbacks[0](resultValue); + } + }, + new Array(this.undeploy.callback, this.undeploy.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.undeploy.onError(error); + } + } else { + try { + response = this._call("undeploy", request); + var extractedValue = WSRequest.util._stringValue(response.documentElement); + resultValue = /* Boolean */ extractedValue == "true" || extractedValue == "1"; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. + } +DeploymentService.undeploy.callback = null; + +DeploymentService.listDeployedPackages = + function listDeployedPackages() + { + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listDeployedPackages.callback != null && typeof(this.listDeployedPackages.callback) == 'function'); + request = + '<p:listDeployedPackages xmlns:p="http://www.apache.org/ode/pmapi">' + + '</p:listDeployedPackages>' ; + + if (isAsync) { + try { + this._call( + "listDeployedPackages", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* packageNames */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listDeployedPackages.callback, this.listDeployedPackages.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listDeployedPackages.onError(error); + } + } else { + try { + response = this._call("listDeployedPackages", request); + resultValue = /* packageNames */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. + } +DeploymentService.listDeployedPackages.callback = null; + +DeploymentService.getProcessPackage = + function getProcessPackage(/* QName */ _processName) + { + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getProcessPackage.callback != null && typeof(this.getProcessPackage.callback) == 'function'); + request = + '<p:getProcessPackage xmlns:p="http://www.apache.org/ode/pmapi">' + + (_processName == null ? '' : '<processName>' + this._encodeXML(_processName) + '</processName>') + + '</p:getProcessPackage>' ; + + if (isAsync) { + try { + this._call( + "getProcessPackage", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + var extractedValue = WSRequest.util._stringValue(response.documentElement); + resultValue = /* string */ extractedValue; + } + callbacks[0](resultValue); + } + }, + new Array(this.getProcessPackage.callback, this.getProcessPackage.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getProcessPackage.onError(error); + } + } else { + try { + response = this._call("getProcessPackage", request); + var extractedValue = WSRequest.util._stringValue(response.documentElement); + resultValue = /* string */ extractedValue; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. + } +DeploymentService.getProcessPackage.callback = null; + +DeploymentService.listProcesses = + function listProcesses(/* string */ _packageName) + { + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listProcesses.callback != null && typeof(this.listProcesses.callback) == 'function'); + request = + '<p:listProcesses xmlns:p="http://www.apache.org/ode/pmapi">' + + (_packageName == null ? '' : '<packageName>' + this._encodeXML(_packageName) + '</packageName>') + + '</p:listProcesses>' ; + + if (isAsync) { + try { + this._call( + "listProcesses", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* processIds */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listProcesses.callback, this.listProcesses.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listProcesses.onError(error); + } + } else { + try { + response = this._call("listProcesses", request); + resultValue = /* processIds */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. + } +DeploymentService.listProcesses.callback = null; + +// WebService object. +function WebService(endpointName) +{ + this.readyState = 0; + this.onreadystatechange = null; + + //public accessors for manually intervening in setting the address (e.g. supporting tcpmon) + this.getAddress = function (endpointName) + { + return this._endpointDetails[endpointName].address; + } + + this.setAddress = function (endpointName, address) + { + this._endpointDetails[endpointName].address = address; + } + + // private helper functions + this._getWSRequest = function() + { + var wsrequest; + try { + wsrequest = new WSRequest(); + } catch(e) { + try { + wsrequest = new ActiveXObject("WSRequest"); + } catch(e) { + try { + wsrequest = new SOAPHttpRequest(); + netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); + } catch (e) { + throw new WebServiceError("WSRequest object not defined.", "WebService._getWSRequest() cannot instantiate WSRequest object."); + } + } + } + return wsrequest; + } + + this._endpointDetails = + { + "DeploymentPort": { + "type" : "SOAP11", + "address" : address, + "action" : { + "undeploy" : "http://www.apache.org/ode/deployapi/DeploymentPortType/undeployRequest", + "listDeployedPackages" : "http://www.apache.org/ode/deployapi/DeploymentPortType/listDeployedPackagesRequest", + "getProcessPackage" : "http://www.apache.org/ode/deployapi/DeploymentPortType/getProcessPackageRequest", + "listProcesses" : "http://www.apache.org/ode/deployapi/DeploymentPortType/listProcessesRequest", + "deploy" : "http://www.apache.org/ode/deployapi/DeploymentPortType/deployRequest" + } + } + }; + this.endpoint = endpointName; + + this._encodeXML = function (value) { + var re; + var str = value.toString(); + re = /&/g; + str = str.replace(re, "&"); + re = /</g; + str = str.replace(re, "<"); + return(str); + }; + + this._call = function (opName, reqContent, callback, userdata) + { + var details = this._endpointDetails[this.endpoint]; + if (details.type == 'SOAP12') this._options.useSOAP = 1.2; + else if (details.type == 'SOAP11') this._options.useSOAP = 1.1; + else if (details.type == 'HTTP') this._options.useSOAP = false; + + if (details.action != null) { + this._options.useWSA = true; + this._options.action = details.action[opName]; + } else if (details.soapaction != null) { + this._options.useWSA = false; + this._options.action = details.soapaction[opName]; + } else { + this._options.useWSA = false; + this._options.action = undefined; + } + + if (details["httpmethod"] != null) { + this._options.HTTPMethod = details.httpmethod[opName]; + } else { + this._options.HTTPMethod = null; + } + + if (details["httpinputSerialization"] != null) { + this._options.HTTPInputSerialization = details.httpinputSerialization[opName]; + } else { + this._options.HTTPInputSerialization= null; + } + + if (details["httplocation"] != null) { + this._options.HTTPLocation = details.httplocation[opName]; + } else { + this._options.HTTPLocation = null; + } + + if (details["httpignoreUncited"] != null) { + this._options.HTTPLocationIgnoreUncited = details.httpignoreUncited[opName]; + } else { + this._options.HTTPLocationIgnoreUncited = null; + } + + if (details["httpqueryParameterSeparator"] != null) { + this._options.HTTPQueryParameterSeparator = details.httpqueryParameterSeparator[opName]; + } else { + this._options.HTTPQueryParameterSeparator = null; + } + + var isAsync = (typeof(callback) == 'function'); + + var thisRequest = this._getWSRequest(); + if (isAsync) { + thisRequest._userdata = userdata; + thisRequest.onreadystatechange = + function() { + if (thisRequest.readyState == 4) { + callback(thisRequest, userdata); + } + } + } + thisRequest.open(this._options, details.address, isAsync); + thisRequest.send(reqContent); + if (isAsync) { + return ""; + } else { + try { + var resultContent = thisRequest.responseText; + if (resultContent == "") { + throw new WebServiceError("No response", "WebService._call() did not recieve a response to a synchronous request."); + } + var resultXML = thisRequest.responseXML; + } catch (e) { + throw new WebServiceError(e); + } + return resultXML; + } + } +} +WebService.visible = false; + +// library function for dynamically converting an element with js:type annotation to a Javascript type. +convertJSType.visible = false; +function convertJSType(element, isWrapped) { + if (element == null) return ""; + var extractedValue = WSRequest.util._stringValue(element); + var resultValue, i; + var type = element.getAttribute("js:type"); + if (type == null) { + type = "xml"; + } else { + type = type.toString(); + } + switch (type) { + case "string": + return extractedValue; + break; + case "number": + return parseFloat(extractedValue); + break; + case "boolean": + return extractedValue == "true" || extractedValue == "1"; + break; + case "date": + return xs_dateTime_to_date(extractedValue); + break; + case "array": + resultValue = new Array(); + for (i=0; i<element.childNodes.length; i++) { + resultValue = resultValue.concat(convertJSType(element.childNodes[i])); + } + return(resultValue); + break; + case "object": + resultValue = new Object(); + for (i=0; i<element.childNodes.length; i++) { + resultValue[element.childNodes[i].tagName] = convertJSType(element.childNodes[i]); + } + return(resultValue); + break; + case "xmllist": + return element.childNodes; + break; + case "xml": + default: + if (isWrapped == true) + return element.firstChild; + else return element; + break; + } +} + +// library function for parsing xs:date, xs:time, and xs:dateTime types into Date objects. +function xs_dateTime_to_date(dateTime) +{ + var buffer = dateTime; + var p = 0; // pointer to current parse location in buffer. + + var era, year, month, day, hour, minute, second, millisecond; + + // parse date, if there is one. + if (buffer.substr(p,1) == '-') + { + era = -1; + p++; + } else { + era = 1; + } + + if (buffer.charAt(p+2) != ':') + { + year = era * buffer.substr(p,4); + p += 5; + month = buffer.substr(p,2); + p += 3; + day = buffer.substr(p,2); + p += 3; + } else { + year = 1970; + month = 1; + day = 1; + } + + // parse time, if there is one + if (buffer.charAt(p) != '+' && buffer.charAt(p) != '-') + { + hour = buffer.substr(p,2); + p += 3; + minute = buffer.substr(p,2); + p += 3; + second = buffer.substr(p,2); + p += 2; + if (buffer.charAt(p) == '.') + { + millisecond = parseFloat(buffer.substr(p))*1000; + // Note that JS fractional seconds are significant to 3 places - xs:time is significant to more - + // though implementations are only required to carry 3 places. + p++; + while (buffer.charCodeAt(p) >= 48 && buffer.charCodeAt(p) <= 57) p++; + } else { + millisecond = 0; + } + } else { + hour = 0; + minute = 0; + second = 0; + millisecond = 0; + } + + var tzhour = 0; + var tzminute = 0; + // parse time zone + if (buffer.charAt(p) != 'Z' && buffer.charAt(p) != '') { + var sign = (buffer.charAt(p) == '-' ? -1 : +1); + p++; + tzhour = sign * buffer.substr(p,2); + p += 3; + tzminute = sign * buffer.substr(p,2); + } + + var thisDate = new Date(); + thisDate.setUTCFullYear(year); + thisDate.setUTCMonth(month-1); + thisDate.setUTCDate(day); + thisDate.setUTCHours(hour); + thisDate.setUTCMinutes(minute); + thisDate.setUTCSeconds(second); + thisDate.setUTCMilliseconds(millisecond); + thisDate.setUTCHours(thisDate.getUTCHours() - tzhour); + thisDate.setUTCMinutes(thisDate.getUTCMinutes() - tzminute); + return thisDate; +} +xs_dateTime_to_date.visible = false; + +function scheme(url) { + var s = url.substring(0, url.indexOf(':')); + return s; +} +scheme.visible = false; + +function domain(url) { + var d = url.substring(url.indexOf('://') + 3, url.indexOf('/',url.indexOf('://')+3)); + return d; +} +domain.visible = false; + +function domainNoPort(url) { + var d = domain(url); + if (d.indexOf(":") >= 0) + d = d.substring(0, d.indexOf(':')); + return d; +} +domainNoPort.visible = false; + +try { + var secureEndpoint = ""; + var pageUrl = document.URL; + var pageScheme = scheme(pageUrl); + // only attempt fixup if we're from an http/https domain ('file:' works fine on IE without fixup) + if (pageScheme == "http" || pageScheme == "https") { + var pageDomain = domain(pageUrl); + var pageDomainNoPort = domainNoPort(pageUrl); + var endpoints = DeploymentService._endpointDetails; + // loop through each available endpoint + for (var i in endpoints) { + var address = endpoints[i].address; + // if we're in a secure domain, set the endpoint to the first secure endpoint we come across + if (secureEndpoint == "" && pageScheme == "https" && scheme(address) == "https") { + secureEndpoint = i; + DeploymentService.endpoint=secureEndpoint; + } + // if we're in a known localhost domain, rewrite the endpoint domain so that we won't get + // a bogus xss violation + if (pageDomainNoPort.indexOf('localhost') == 0 || pageDomainNoPort.indexOf('127.0.0.1') == 0 ) { + endpoints[i].address = address.replace(domainNoPort(address), pageDomainNoPort); + } + } + } +} catch (e) { } +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/InstanceManagementAPI.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/InstanceManagementAPI.js new file mode 100644 index 0000000..f285748 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/InstanceManagementAPI.js
@@ -0,0 +1,1298 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +var baseURL; +if (location.host.indexOf('/') == -1 && location.protocol.indexOf('/') == -1) { + baseURL = location.protocol + "//" + location.host + "/"; +}else if(location.host.indexOf('/') != -1 && location.protocol.indexOf('/') == -1){ + baseURL = location.protocol + "//" + location.host; +} +var address = baseURL + "ode/processes/InstanceManagement"; + +var InstanceManagementService = new WebService("InstanceManagementPort"); + +InstanceManagementService.listInstances = +function listInstances(/* string */ _filter, /* int */ _limit, /* string */ _order) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listInstances.callback != null && typeof(this.listInstances.callback) == 'function'); + request = + '<p:listInstances xmlns:p="http://www.apache.org/ode/pmapi">' + + (_filter == null ? '' : '<filter>' + this._encodeXML(_filter) + '</filter>') + + (_limit == null ? '' : '<limit>' + this._encodeXML(_limit) + '</limit>') + + (_order == null ? '' : '<order>' + this._encodeXML(_order) + '</order>') + + '</p:listInstances>'; + + if (isAsync) { + try { + this._call( + "listInstances", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listInstances.callback, this.listInstances.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listInstances.onError(error); + } + } else { + try { + response = this._call("listInstances", request); + resultValue = /* tInstanceInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.listInstances.callback = null; + +InstanceManagementService.resume = +function resume(/* long */ _iid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.resume.callback != null && typeof(this.resume.callback) == 'function'); + request = + '<p:resume xmlns:p="http://www.apache.org/ode/pmapi">' + + (_iid == null ? '' : '<iid>' + this._encodeXML(_iid) + '</iid>') + + '</p:resume>'; + + if (isAsync) { + try { + this._call( + "resume", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.resume.callback, this.resume.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.resume.onError(error); + } + } else { + try { + response = this._call("resume", request); + resultValue = /* tInstanceInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.resume.callback = null; + +InstanceManagementService.terminate = +function terminate(/* long */ _iid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.terminate.callback != null && typeof(this.terminate.callback) == 'function'); + request = + '<p:terminate xmlns:p="http://www.apache.org/ode/pmapi">' + + (_iid == null ? '' : '<iid>' + this._encodeXML(_iid) + '</iid>') + + '</p:terminate>'; + + if (isAsync) { + try { + this._call( + "terminate", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.terminate.callback, this.terminate.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.terminate.onError(error); + } + } else { + try { + response = this._call("terminate", request); + resultValue = /* tInstanceInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.terminate.callback = null; + +InstanceManagementService.listAllInstances = +function listAllInstances() +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listAllInstances.callback != null && typeof(this.listAllInstances.callback) == 'function'); + request = + '<p:listAllInstances xmlns:p="http://www.apache.org/ode/pmapi">' + + '</p:listAllInstances>'; + + if (isAsync) { + try { + this._call( + "listAllInstances", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listAllInstances.callback, this.listAllInstances.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listAllInstances.onError(error); + } + } else { + try { + response = this._call("listAllInstances", request); + resultValue = /* tInstanceInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.listAllInstances.callback = null; + +InstanceManagementService.suspend = +function suspend(/* long */ _iid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.suspend.callback != null && typeof(this.suspend.callback) == 'function'); + request = + '<p:suspend xmlns:p="http://www.apache.org/ode/pmapi">' + + (_iid == null ? '' : '<iid>' + this._encodeXML(_iid) + '</iid>') + + '</p:suspend>'; + + if (isAsync) { + try { + this._call( + "suspend", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.suspend.callback, this.suspend.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.suspend.onError(error); + } + } else { + try { + response = this._call("suspend", request); + resultValue = /* tInstanceInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.suspend.callback = null; + +InstanceManagementService.listAllInstancesWithLimit = +function listAllInstancesWithLimit(/* int */ _payload) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listAllInstancesWithLimit.callback != null && typeof(this.listAllInstancesWithLimit.callback) == 'function'); + request = + '<p:listAllInstancesWithLimit xmlns:p="http://www.apache.org/ode/pmapi">' + + (_payload == null ? '' : '<payload>' + this._encodeXML(_payload) + '</payload>') + + '</p:listAllInstancesWithLimit>'; + + if (isAsync) { + try { + this._call( + "listAllInstancesWithLimit", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listAllInstancesWithLimit.callback, this.listAllInstancesWithLimit.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listAllInstancesWithLimit.onError(error); + } + } else { + try { + response = this._call("listAllInstancesWithLimit", request); + resultValue = /* tInstanceInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.listAllInstancesWithLimit.callback = null; + +InstanceManagementService.getScopeInfo = +function getScopeInfo(/* long */ _siid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getScopeInfo.callback != null && typeof(this.getScopeInfo.callback) == 'function'); + request = + '<p:getScopeInfo xmlns:p="http://www.apache.org/ode/pmapi">' + + (_siid == null ? '' : '<siid>' + this._encodeXML(_siid) + '</siid>') + + '</p:getScopeInfo>'; + + if (isAsync) { + try { + this._call( + "getScopeInfo", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tScopeInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getScopeInfo.callback, this.getScopeInfo.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getScopeInfo.onError(error); + } + } else { + try { + response = this._call("getScopeInfo", request); + resultValue = /* tScopeInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.getScopeInfo.callback = null; + +InstanceManagementService.recoverActivity = +function recoverActivity(/* string */ _action, /* long */ _aid, /* long */ _iid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.recoverActivity.callback != null && typeof(this.recoverActivity.callback) == 'function'); + request = + '<p:recoverActivity xmlns:p="http://www.apache.org/ode/pmapi">' + + (_action == null ? '' : '<action>' + this._encodeXML(_action) + '</action>') + + (_aid == null ? '' : '<aid>' + this._encodeXML(_aid) + '</aid>') + + (_iid == null ? '' : '<iid>' + this._encodeXML(_iid) + '</iid>') + + '</p:recoverActivity>'; + + if (isAsync) { + try { + this._call( + "recoverActivity", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.recoverActivity.callback, this.recoverActivity.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.recoverActivity.onError(error); + } + } else { + try { + response = this._call("recoverActivity", request); + resultValue = /* tInstanceInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.recoverActivity.callback = null; + +InstanceManagementService.queryInstances = +function queryInstances(/* string */ _payload) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.queryInstances.callback != null && typeof(this.queryInstances.callback) == 'function'); + request = + '<p:queryInstances xmlns:p="http://www.apache.org/ode/pmapi">' + + (_payload == null ? '' : '<payload>' + this._encodeXML(_payload) + '</payload>') + + '</p:queryInstances>'; + + if (isAsync) { + try { + this._call( + "queryInstances", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.queryInstances.callback, this.queryInstances.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.queryInstances.onError(error); + } + } else { + try { + response = this._call("queryInstances", request); + resultValue = /* tInstanceInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.queryInstances.callback = null; + +InstanceManagementService.getInstanceInfo = +function getInstanceInfo(/* long */ _iid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getInstanceInfo.callback != null && typeof(this.getInstanceInfo.callback) == 'function'); + request = + '<p:getInstanceInfo xmlns:p="http://www.apache.org/ode/pmapi">' + + (_iid == null ? '' : '<iid>' + this._encodeXML(_iid) + '</iid>') + + '</p:getInstanceInfo>'; + + if (isAsync) { + try { + this._call( + "getInstanceInfo", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getInstanceInfo.callback, this.getInstanceInfo.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getInstanceInfo.onError(error); + } + } else { + try { + response = this._call("getInstanceInfo", request); + resultValue = /* tInstanceInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.getInstanceInfo.callback = null; + +InstanceManagementService.listEvents = +function listEvents(/* string */ _eventFilter, /* int */ _maxCount, /* string */ _instanceFilter) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listEvents.callback != null && typeof(this.listEvents.callback) == 'function'); + request = + '<p:listEvents xmlns:p="http://www.apache.org/ode/pmapi">' + + (_eventFilter == null ? '' : '<eventFilter>' + this._encodeXML(_eventFilter) + '</eventFilter>') + + (_maxCount == null ? '' : '<maxCount>' + this._encodeXML(_maxCount) + '</maxCount>') + + (_instanceFilter == null ? '' : '<instanceFilter>' + this._encodeXML(_instanceFilter) + '</instanceFilter>') + + '</p:listEvents>'; + + if (isAsync) { + try { + this._call( + "listEvents", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tEventInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listEvents.callback, this.listEvents.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listEvents.onError(error); + } + } else { + try { + response = this._call("listEvents", request); + resultValue = /* tEventInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.listEvents.callback = null; + +InstanceManagementService.deleteInstance = +function deleteInstance(/* string */ _filter) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.deleteInstance.callback != null && typeof(this.deleteInstance.callback) == 'function'); + request = + '<p:delete xmlns:p="http://www.apache.org/ode/pmapi">' + + (_filter == null ? '' : '<filter>' + this._encodeXML(_filter) + '</filter>') + + '</p:delete>'; + + if (isAsync) { + try { + this._call( + "delete", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* iidsType */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.deleteInstance.callback, this.deleteInstance.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.deleteInstance.onError(error); + } + } else { + try { + response = this._call("delete", request); + resultValue = /* iidsType */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.deleteInstance.callback = null; + +InstanceManagementService.getEventTimeline = +function getEventTimeline(/* string */ _eventFilter, /* string */ _instanceFilter) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getEventTimeline.callback != null && typeof(this.getEventTimeline.callback) == 'function'); + request = + '<p:getEventTimeline xmlns:p="http://www.apache.org/ode/pmapi">' + + (_eventFilter == null ? '' : '<eventFilter>' + this._encodeXML(_eventFilter) + '</eventFilter>') + + (_instanceFilter == null ? '' : '<instanceFilter>' + this._encodeXML(_instanceFilter) + '</instanceFilter>') + + '</p:getEventTimeline>'; + + if (isAsync) { + try { + this._call( + "getEventTimeline", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* listType */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getEventTimeline.callback, this.getEventTimeline.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getEventTimeline.onError(error); + } + } else { + try { + response = this._call("getEventTimeline", request); + resultValue = /* listType */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.getEventTimeline.callback = null; + +InstanceManagementService.fault = +function fault(/* long */ _iid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.fault.callback != null && typeof(this.fault.callback) == 'function'); + request = + '<p:fault xmlns:p="http://www.apache.org/ode/pmapi">' + + (_iid == null ? '' : '<iid>' + this._encodeXML(_iid) + '</iid>') + + '</p:fault>'; + + if (isAsync) { + try { + this._call( + "fault", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tInstanceInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.fault.callback, this.fault.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.fault.onError(error); + } + } else { + try { + response = this._call("fault", request); + resultValue = /* tInstanceInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.fault.callback = null; + +InstanceManagementService.getScopeInfoWithActivity = +function getScopeInfoWithActivity(/* long */ _sid, /* boolean */ _activityInfo) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getScopeInfoWithActivity.callback != null && typeof(this.getScopeInfoWithActivity.callback) == 'function'); + request = + '<p:getScopeInfoWithActivity xmlns:p="http://www.apache.org/ode/pmapi">' + + (_sid == null ? '' : '<sid>' + this._encodeXML(_sid) + '</sid>') + + (_activityInfo == null ? '' : '<activityInfo>' + this._encodeXML(_activityInfo) + '</activityInfo>') + + '</p:getScopeInfoWithActivity>'; + + if (isAsync) { + try { + this._call( + "getScopeInfoWithActivity", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tScopeInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getScopeInfoWithActivity.callback, this.getScopeInfoWithActivity.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getScopeInfoWithActivity.onError(error); + } + } else { + try { + response = this._call("getScopeInfoWithActivity", request); + resultValue = /* tScopeInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.getScopeInfoWithActivity.callback = null; + +InstanceManagementService.getVariableInfo = +function getVariableInfo(/* string */ _sid, /* string */ _varName) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getVariableInfo.callback != null && typeof(this.getVariableInfo.callback) == 'function'); + request = + '<p:getVariableInfo xmlns:p="http://www.apache.org/ode/pmapi">' + + (_sid == null ? '' : '<sid>' + this._encodeXML(_sid) + '</sid>') + + (_varName == null ? '' : '<varName>' + this._encodeXML(_varName) + '</varName>') + + '</p:getVariableInfo>'; + + if (isAsync) { + try { + this._call( + "getVariableInfo", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tVariableInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getVariableInfo.callback, this.getVariableInfo.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getVariableInfo.onError(error); + } + } else { + try { + response = this._call("getVariableInfo", request); + resultValue = /* tVariableInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +InstanceManagementService.getVariableInfo.callback = null; + + + +// WebService object. +function WebService(endpointName) +{ + this.readyState = 0; + this.onreadystatechange = null; + + //public accessors for manually intervening in setting the address (e.g. supporting tcpmon) + this.getAddress = function (endpointName) + { + return this._endpointDetails[endpointName].address; + } + + this.setAddress = function (endpointName, address) + { + this._endpointDetails[endpointName].address = address; + } + + // private helper functions + this._getWSRequest = function() + { + var wsrequest; + try { + wsrequest = new WSRequest(); + } catch(e) { + try { + wsrequest = new ActiveXObject("WSRequest"); + } catch(e) { + try { + wsrequest = new SOAPHttpRequest(); + netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); + } catch (e) { + throw new WebServiceError("WSRequest object not defined.", "WebService._getWSRequest() cannot instantiate WSRequest object."); + } + } + } + return wsrequest; + } + + this._endpointDetails = + { + "InstanceManagementPort": { + "type" : "SOAP11", + "address" : address, + "action" : { + "listInstances" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/listInstancesRequest", + "resume" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/resumeRequest", + "terminate" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/terminateRequest", + "listAllInstances" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/listAllInstancesRequest", + "suspend" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/suspendRequest", + "listAllInstancesWithLimit" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/listAllInstancesWithLimitRequest", + "getScopeInfo" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/getScopeInfoRequest", + "recoverActivity" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/recoverActivityRequest", + "queryInstances" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/queryInstancesRequest", + "getInstanceInfo" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/getInstanceInfoRequest", + "listEvents" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/listEventsRequest", + "delete" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/deleteRequest", + "getEventTimeline" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/getEventTimelineRequest", + "fault" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/faultRequest", + "getScopeInfoWithActivity" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/getScopeInfoWithActivityRequest", + "getVariableInfo" : "http://www.apache.org/ode/pmapi/InstanceManagementPortType/getVariableInfoRequest" + } + } + }; + this.endpoint = endpointName; + + this._encodeXML = function (value) { + var re; + var str = value.toString(); + re = /&/g; + str = str.replace(re, "&"); + re = /</g; + str = str.replace(re, "<"); + return(str); + }; + + this._call = function (opName, reqContent, callback, userdata) + { + var details = this._endpointDetails[this.endpoint]; + if (details.type == 'SOAP12') this._options.useSOAP = 1.2; + else if (details.type == 'SOAP11') this._options.useSOAP = 1.1; + else if (details.type == 'HTTP') this._options.useSOAP = false; + + if (details.action != null) { + this._options.useWSA = true; + this._options.action = details.action[opName]; + } else if (details.soapaction != null) { + this._options.useWSA = false; + this._options.action = details.soapaction[opName]; + } else { + this._options.useWSA = false; + this._options.action = undefined; + } + + if (details["httpmethod"] != null) { + this._options.HTTPMethod = details.httpmethod[opName]; + } else { + this._options.HTTPMethod = null; + } + + if (details["httpinputSerialization"] != null) { + this._options.HTTPInputSerialization = details.httpinputSerialization[opName]; + } else { + this._options.HTTPInputSerialization = null; + } + + if (details["httplocation"] != null) { + this._options.HTTPLocation = details.httplocation[opName]; + } else { + this._options.HTTPLocation = null; + } + + if (details["httpignoreUncited"] != null) { + this._options.HTTPLocationIgnoreUncited = details.httpignoreUncited[opName]; + } else { + this._options.HTTPLocationIgnoreUncited = null; + } + + if (details["httpqueryParameterSeparator"] != null) { + this._options.HTTPQueryParameterSeparator = details.httpqueryParameterSeparator[opName]; + } else { + this._options.HTTPQueryParameterSeparator = null; + } + + var isAsync = (typeof(callback) == 'function'); + + var thisRequest = this._getWSRequest(); + if (isAsync) { + thisRequest._userdata = userdata; + thisRequest.onreadystatechange = + function() { + if (thisRequest.readyState == 4) { + callback(thisRequest, userdata); + } + } + } + thisRequest.open(this._options, details.address, isAsync); + thisRequest.send(reqContent); + if (isAsync) { + return ""; + } else { + try { + var resultContent = thisRequest.responseText; + if (resultContent == "") { + throw new WebServiceError("No response", "WebService._call() did not recieve a response to a synchronous request."); + } + var resultXML = thisRequest.responseXML; + } catch (e) { + throw new WebServiceError(e); + } + return resultXML; + } + } +} +WebService.visible = false; + +// library function for dynamically converting an element with js:type annotation to a Javascript type. +convertJSType.visible = false; +function convertJSType(element, isWrapped) { + if (element == null) return ""; + var extractedValue = WSRequest.util._stringValue(element); + var resultValue, i; + var type = element.getAttribute("js:type"); + if (type == null) { + type = "xml"; + } else { + type = type.toString(); + } + switch (type) { + case "string": + return extractedValue; + break; + case "number": + return parseFloat(extractedValue); + break; + case "boolean": + return extractedValue == "true" || extractedValue == "1"; + break; + case "date": + return xs_dateTime_to_date(extractedValue); + break; + case "array": + resultValue = new Array(); + for (i = 0; i < element.childNodes.length; i++) { + resultValue = resultValue.concat(convertJSType(element.childNodes[i])); + } + return(resultValue); + break; + case "object": + resultValue = new Object(); + for (i = 0; i < element.childNodes.length; i++) { + resultValue[element.childNodes[i].tagName] = convertJSType(element.childNodes[i]); + } + return(resultValue); + break; + case "xmllist": + return element.childNodes; + break; + case "xml": + default: + if (isWrapped == true) + return element.firstChild; + else return element; + break; + } +} + +// library function for parsing xs:date, xs:time, and xs:dateTime types into Date objects. +function xs_dateTime_to_date(dateTime) +{ + var buffer = dateTime; + var p = 0; // pointer to current parse location in buffer. + + var era, year, month, day, hour, minute, second, millisecond; + + // parse date, if there is one. + if (buffer.substr(p, 1) == '-') + { + era = -1; + p++; + } else { + era = 1; + } + + if (buffer.charAt(p + 2) != ':') + { + year = era * buffer.substr(p, 4); + p += 5; + month = buffer.substr(p, 2); + p += 3; + day = buffer.substr(p, 2); + p += 3; + } else { + year = 1970; + month = 1; + day = 1; + } + + // parse time, if there is one + if (buffer.charAt(p) != '+' && buffer.charAt(p) != '-') + { + hour = buffer.substr(p, 2); + p += 3; + minute = buffer.substr(p, 2); + p += 3; + second = buffer.substr(p, 2); + p += 2; + if (buffer.charAt(p) == '.') + { + millisecond = parseFloat(buffer.substr(p)) * 1000; + // Note that JS fractional seconds are significant to 3 places - xs:time is significant to more - + // though implementations are only required to carry 3 places. + p++; + while (buffer.charCodeAt(p) >= 48 && buffer.charCodeAt(p) <= 57) p++; + } else { + millisecond = 0; + } + } else { + hour = 0; + minute = 0; + second = 0; + millisecond = 0; + } + + var tzhour = 0; + var tzminute = 0; + // parse time zone + if (buffer.charAt(p) != 'Z' && buffer.charAt(p) != '') { + var sign = (buffer.charAt(p) == '-' ? -1 : +1); + p++; + tzhour = sign * buffer.substr(p, 2); + p += 3; + tzminute = sign * buffer.substr(p, 2); + } + + var thisDate = new Date(); + thisDate.setUTCFullYear(year); + thisDate.setUTCMonth(month - 1); + thisDate.setUTCDate(day); + thisDate.setUTCHours(hour); + thisDate.setUTCMinutes(minute); + thisDate.setUTCSeconds(second); + thisDate.setUTCMilliseconds(millisecond); + thisDate.setUTCHours(thisDate.getUTCHours() - tzhour); + thisDate.setUTCMinutes(thisDate.getUTCMinutes() - tzminute); + return thisDate; +} +xs_dateTime_to_date.visible = false; + +function scheme(url) { + var s = url.substring(0, url.indexOf(':')); + return s; +} +scheme.visible = false; + +function domain(url) { + var d = url.substring(url.indexOf('://') + 3, url.indexOf('/', url.indexOf('://') + 3)); + return d; +} +domain.visible = false; + +function domainNoPort(url) { + var d = domain(url); + if (d.indexOf(":") >= 0) + d = d.substring(0, d.indexOf(':')); + return d; +} +domainNoPort.visible = false; + +try { + var secureEndpoint = ""; + var pageUrl = document.URL; + var pageScheme = scheme(pageUrl); + // only attempt fixup if we're from an http/https domain ('file:' works fine on IE without fixup) + if (pageScheme == "http" || pageScheme == "https") { + var pageDomain = domain(pageUrl); + var pageDomainNoPort = domainNoPort(pageUrl); + var endpoints = InstanceManagementService._endpointDetails; + // loop through each available endpoint + for (var i in endpoints) { + var address = endpoints[i].address; + // if we're in a secure domain, set the endpoint to the first secure endpoint we come across + if (secureEndpoint == "" && pageScheme == "https" && scheme(address) == "https") { + secureEndpoint = i; + InstanceManagementService.endpoint = secureEndpoint; + } + // if we're in a known localhost domain, rewrite the endpoint domain so that we won't get + // a bogus xss violation + if (pageDomainNoPort.indexOf('localhost') == 0 || pageDomainNoPort.indexOf('127.0.0.1') == 0) { + endpoints[i].address = address.replace(domainNoPort(address), pageDomainNoPort); + } + } + } +} catch (e) { +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/ODE.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/ODE.js new file mode 100644 index 0000000..f09158e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/ODE.js
@@ -0,0 +1,1387 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +var org; +if (!org) { + org = {}; +} +else if (typeof org != "object") { + throw new Error("org already exists and is not an object"); +} + +if (!org.apache) { + org.apache = {}; +} +else if (typeof org.apache != "object") { + throw new Error("org.apache already exists and is not an object"); +} + +if (!org.apache.ode) { + org.apache.ode = {}; +} +else if (typeof org.apache.ode != "object") { + throw new Error("org.apache.ode already exists"); +} + +if(org.apache.ode.XHRObject){ + throw new Error("org.apache.ode.XHRObject already exists"); +} + +org.apache.ode.XHRObject = {}; + +(function (){ + var msxml_progid = [ + 'Microsoft.XMLHTTP', + 'MSXML2.XMLHTTP.3.0', + 'MSXML2.XMLHTTP' + ] + function createXhrObject(){ + var xhr; + try + { + // Instantiates XMLHttpRequest in non-IE browsers and assigns to http. + xhr = new XMLHttpRequest(); + } + catch(e) + { + for(var i=0; i<msxml_progid.length; ++i){ + try + { + // Instantiates XMLHttpRequest for IE and assign to http + xhr = new ActiveXObject(msxml_progid[i]); + break; + } + catch(e){} + } + } + finally + { + return xhr; + } + } + + function xhrSyncGetRequest(url, text){ + var request = createXhrObject(); + request.open('GET', url, false); + request.send(null); + + if (request.status == 200) { // Make sure there were no errors // Make sure the response is an XML document + if(text == true){ + return request.responseText; + } + if (request.getResponseHeader("Content-Type").match(/text\/xml/) != null || request.getResponseHeader("Content-Type").match(/application\/xml/) != null) { + return request.responseXML; + }else{ + return request.responseText; + } + + }else { + aler("Error occurred during the GET request"); + return null; + } + } + var ns = org.apache.ode.XHRObject; + ns.xhrSyncGetRequest = xhrSyncGetRequest; + +})(); + +if (org.apache.ode.DOMHelper) { + throw new Error("org.apache.ode.DOMHelper already exists"); +} + +// Utility methods for handling DOM in cross browser way. +org.apache.ode.DOMHelper = {}; + +(function(){ + + function getElementsByTagName(tagName, ns, prefix, scope){ + var elementListForReturn = scope.getElementsByTagName(prefix+":"+tagName); + if(elementListForReturn.length == 0){ + elementListForReturn = scope.getElementsByTagName(tagName); + if(elementListForReturn.length == 0){ + elementListForReturn = scope.getElementsByTagName("ns:"+tagName); + if(elementListForReturn.length == 0 && document.getElementsByTagNameNS){ + elementListForReturn = scope.getElementsByTagNameNS(ns, tagName); + } + } + } + + return elementListForReturn; + } + + // Find all Text nodes at or beneath the node n. + // Concatenate their content and return it as a string. + function getText(n){ + var strings = []; + getStrings(n, strings); + return strings.join(""); + + function getStrings(n, strings){ + if (n.nodeType == 3 /* Node.TEXT_NODE */) + strings.push(n.data); + else if (n.nodeType == 1 /* Node.ELEMENT_NODE */) { + for (var m = n.firstChild; m != null; m = m.nextSibling) { + getStrings(m, strings); + } + } + } + } + + var ns = org.apache.ode.DOMHelper; + ns.getElementsByTagName = getElementsByTagName; + ns.getText = getText; +})(); + +if(org.apache.ode.Widgets){ + throw new Error("org.apache.ode.Widgets already exists"); +} + +org.apache.ode.Widgets = {}; + +(function(){ + function operationConfirmation(msg, handleYes, handleNo){ + + var handleYesWrapper= function(){ + this.hide(); + handleYes(); + + } + + var handleNoWrapper = function(){ + this.hide(); + handleNo(); + + } + + var simpleDiag = new YAHOO.widget.SimpleDialog('confimationdialogue',{ + width:'350px', + fixedcenter:true, + visible:true, + draggable:true, + close:false, + text:msg, + icon:YAHOO.widget.SimpleDialog.ICON_WARN, + constraintoviewport:true, + buttons:[{ + text:'Yes', + handler:handleYesWrapper, + isDefault:true + },{ + text:'No', + handler:handleNoWrapper + }] + }); + + simpleDiag.setHeader('Apache ODE'); + simpleDiag.render('content'); + simpleDiag.show(); + + } + + function alert(msg, iconT){ + if(iconT == 'undefined') + iconT = YAHOO.widget.SimpleDialog.ICON_INFO; + + var handleOK = function(){ + this.hide(); + } + + var simpleAlert = new YAHOO.widget.SimpleDialog('alertbox',{ + width:'350px', + fixedcenter:true, + visible:true, + draggable:true, + close:false, + text:msg, + icon:iconT, + constraintoviewport:true, + buttons:[{text:'OK', + handler:handleOK, + isDefault:true}] + }); + + simpleAlert.setHeader('Apache ODE'); + simpleAlert.render('content'); + simpleAlert.show(); + } + + var ns = org.apache.ode.Widgets; + ns.operationConfirm = operationConfirmation; + ns.alert = alert; +})(); + + + +// Definition of Process Information processing class start from here. +// This class will be used to get the details of processes from ODE +// process management service and visualize them in Web interface. +// Process retiring, activation is also handle from this class. +if (org.apache.ode.ProcessHandling) { + throw new Error("org.apache.ode.ProcessHandling already exists"); +} + +org.apache.ode.ProcessHandling = {}; + +(function(){ + var processInfoNS = "http://www.apache.org/ode/pmapi/types/2006/08/02/"; + var processInfoNSPrefix = "ns"; + var processInfoTagName = "process-info"; + + function loadProcessInfo(){ + // Use ProcessManagementService to get the details about currently available + // processes in the engine. This method returns a XML document like following: + // <?xml version='1.0' encoding='UTF-8'?> + //<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"> + // <soapenv:Body> + // <axis2ns8:listAllProcessesResponse xmlns:axis2ns8="http://www.apache.org/ode/pmapi"> + // <process-info-list> + // <ns:process-info xmlns:ns="http://www.apache.org/ode/pmapi/types/2006/08/02/"> + // <ns:pid>{http://ode/bpel/unit-test}HelloWorld2-3</ns:pid> + // <ns:status>ACTIVE</ns:status> + // <ns:version>3 + // </ns:version> + // <ns:definition-info> + // <ns:process-name xmlns:unit="http://ode/bpel/unit-test">unit:HelloWorld2 + // </ns:process-name> + // </ns:definition-info> + // <ns:deployment-info> + // <ns:package>HelloWorld2</ns:package> + // <ns:document>HelloWorld2.bpel + // </ns:document> + // <ns:deploy-date>2008-06-15T17:52:04.523+05:30</ns:deploy-date> + // </ns:deployment-info> + // <ns:instance-summary> + // <ns:instances state="ACTIVE" count="0"/> + // <ns:instances state="COMPLETED" count="0"/> + // <ns:instances state="ERROR" count="0"/> + // <ns:instances state="FAILED" count="0"/> + // <ns:instances state="SUSPENDED" count="0"/> + // <ns:instances state="TERMINATED" count="0"/> + // </ns:instance-summary> + // <ns:properties /> + // <ns:endpoints/> + // <ns:documents> + // <ns:document> + // <ns:name>HelloWorld2.bpel</ns:name> + // <ns:type>http://schemas.xmlsoap.org/ws/2004/03/business-process/ + // </ns:type> + // <ns:source>file:/home/milinda/programs/apache-tomcat-5.5.26/webapps/ode/WEB-INF/processes/HelloWorld2/HelloWorld2.bpel + // </ns:source> + // </ns:document> + // <ns:document> + // <ns:name>HelloWorld2.wsdl</ns:name> + // <ns:type>http://schemas.xmlsoap.org/wsdl/</ns:type> + // <ns:source> + // file:/home/milinda/programs/apache-tomcat-5.5.26/webapps/ode/WEB-INF/processes/HelloWorld2/HelloWorld2.wsdl + // </ns:source> + // </ns:document> + // <ns:document> + // <ns:name>HelloWorld2.cbp</ns:name> + // <ns:type>http://www.fivesight.com/schemas/2005/12/19/CompiledBPEL + // </ns:type> + // <ns:source>file:/home/milinda/programs/apache-tomcat-5.5.26/webapps/ode/WEB-INF/processes/HelloWorld2/HelloWorld2.cbp + // </ns:source> + // </ns:document> + // </ns:documents> + // </ns:process-info> + // </process-info-list> + // </axis2ns8:listAllProcessesResponse> + // </soapenv:Body> + //</soapenv:Envelope> + + try { + var listAllProcessesRes = ProcessManagementService.listAllProcesses(); + return listAllProcessesRes; + } + catch (e) { + if (typeof e == "string") { + alert("Exception Occurred " + e.toString()); + } + else { + alert("Exception Occurred!" + e); + } + return null; + } + } + + function InstanceSummary(activeIns, completedIns, errorIns, failedIns, suspendedIns, terminatedIns){ + this.activeInstances = activeIns; + this.completedInstances = completedIns; + this.errorInstances = errorIns; + this.failedInstances = failedIns; + this.suspendedInstances = suspendedIns; + this.terminatedInstances = terminatedIns; + } + + function Process( + pid, version, status, depDate, nameWithVer, processName, urlOfName, prefixOfName, instanceSummary){ + this.pid = pid; + this.version = version; + this.status = status; + this.depDate = depDate; + this.nameWithVer = nameWithVer; + this.processName = processName; + this.urlOfName = urlOfName; + this.prefixOfName = prefixOfName; + this.instanceSummary = instanceSummary; + } + + function processProcessInfoList(listAllProcessesRes){ + var returnInfoArray = []; + var processInfoList = org.apache.ode.DOMHelper.getElementsByTagName( + processInfoTagName, + processInfoNS, + processInfoNSPrefix, + listAllProcessesRes); + if(processInfoList.length == 0){ + return 0; + }else{ + + for(var i = 0; i < processInfoList.length; i++){ + var activeInstances = 0; + var completedInstances = 0; + var errorInstances = 0; + var failedInstances = 0; + var suspendedInstances = 0; + var terminatedInstances = 0; + + var scopeEle = processInfoList[i]; + + var pidEle = org.apache.ode.DOMHelper.getElementsByTagName("pid", processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var pid = org.apache.ode.DOMHelper.getText(pidEle); + + var versionEle = org.apache.ode.DOMHelper.getElementsByTagName('version', processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var version = org.apache.ode.DOMHelper.getText(versionEle); + + var statusEle = org.apache.ode.DOMHelper.getElementsByTagName('status', processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var status = org.apache.ode.DOMHelper.getText(statusEle); + + var depInfoEle = org.apache.ode.DOMHelper.getElementsByTagName("deployment-info", processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var depDateEle = org.apache.ode.DOMHelper.getElementsByTagName("deploy-date", processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var depDate = org.apache.ode.DOMHelper.getText(depDateEle); + + var defInfoEle = org.apache.ode.DOMHelper.getElementsByTagName("definition-info", processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var processNameEle = org.apache.ode.DOMHelper.getElementsByTagName("process-name", processInfoNS, processInfoNSPrefix, scopeEle)[0]; + var processName = org.apache.ode.DOMHelper.getText(processNameEle); + + var len = pid.length; + var endPos = pid.indexOf('}'); + var startPos = pid.indexOf('{'); + var nameWithVersion = pid.substr(++endPos, len); + var indexOfColon = processName.indexOf(':'); + var prefixOfName = processName.substring(0, indexOfColon); + var urlOfName = pid.substr(++startPos, (endPos - 2)); + + var instanceSummaryEle = org.apache.ode.DOMHelper.getElementsByTagName("instance-summary", processInfoNS, processInfoNSPrefix, scopeEle)[0]; + + for(var m = instanceSummaryEle.firstChild; m != null; m = m.nextSibling){ + var state = m.getAttribute("state"); + var count = m.getAttribute("count"); + if (state == 'ACTIVE') { + activeInstances = parseInt(count); + }else if (state == 'COMPLETED') { + completedInstances = parseInt(count); + }else if (state == 'ERROR') { + errorInstances = parseInt(count); + }else if (state == 'FAILED') { + failedInstances = parseInt(count); + }else if (state == 'SUSPENDED') { + suspendedInstances = parseInt(count); + }else if (state == 'TERMINATED') { + terminatedInstances = parseInt(count); + } + } + + var instanceSummary = new InstanceSummary( + activeInstances, + completedInstances, + errorInstances, + failedInstances, + suspendedInstances, + terminatedInstances); + + var processInfo = new Process(pid, + version, + status, + depDate, + nameWithVersion, + processName, + urlOfName, + prefixOfName, + instanceSummary); + + returnInfoArray[i] = processInfo; + } + } + + return returnInfoArray; + } + + function createProcessWidget(process, i){ + var retireBtnID = 'retire' + i; + var retierBtnVar = 'retireBtn' + i; + var activateBtnID = 'activate'+i; + var activateVar = 'activateBtn' + i; + var viewProDetID = 'viewProcessDet'+i; + var viewProDetVar = 'viewProcessDetVar'+i; + var active = "true"; + var retire = "false"; + if(process.status.toUpperCase() == 'ACTIVE'){ + active = "true"; + retire = "false"; + }else{ + active = "false"; + retire = "true"; + } + str = '<div class="yui-cms-item yui-panel selected"><div class="hd">'+ + process.pid + + '</div><div class="bd"><div class="fixed">'+ + '<table><tr><td class="alt"> Process Summary</td></tr><tr><th>' + + 'Deploy Date:</th><td>' + + process.depDate + + '</td><th>Status:</th><td>' + + process.status + + '</td><th>Version:</th><td>' + + process.version + + '</td></tr>' + + '<table><tr><td class="alt"> Instance Summary</td></tr><tr><th>Active:</th><td>' + + process.instanceSummary.activeInstances + + '</td><th>Terminated:</th><td>' + + process.instanceSummary.terminatedInstances + + '</td><th>Completed:</th><td>' + + process.instanceSummary.completedInstances + + '</td><th>Error:</th><td>' + + process.instanceSummary.errorInstances + + '</td><th>Failed:</th><td>' + + process.instanceSummary.failedInstances + + '</td><th>Suspended:</th><td>' + + process.instanceSummary.suspendedInstances + + '</td> </tr></table></table>' + + '</div></div><div class="ft">'+ + '<span id="'+ retireBtnID + + '" class="yui-button yui-push-button"><span class="first-child"><input type="button" name="'+ retireBtnID +'name" value="Retire"></span></span>'+ + '<span id="'+ activateBtnID + + '" class="yui-button yui-push-button"><span class="first-child"><input type="button" name="'+ activateVar +'name" value="Activate"></span></span>'+ + '<span id="'+ viewProDetID + + '" class="yui-button yui-push-button"><span class="first-child"><input type="button" name="'+ viewProDetVar +'name" value="Details"></span></span>'+ + '<script type="text/javascript">'+ + 'function '+retierBtnVar+'retireProcess(){org.apache.ode.ProcessHandling.retireProcess("'+ process.nameWithVer +'","'+ process.urlOfName +'","'+process.prefixOfName+'");}'+ + 'function '+activateVar+'activateProcess(){org.apache.ode.ProcessHandling.activateProcess("'+ process.nameWithVer +'","'+ process.urlOfName +'","'+process.prefixOfName+'");}'+ + 'function '+viewProDetVar+'viewProcessDetails(){org.apache.ode.ProcessHandling.viewProcessDetails("'+ process.nameWithVer +'","'+ process.urlOfName +'","'+process.prefixOfName+'");}'+ + + 'var ' + retierBtnVar + '=new YAHOO.widget.Button("'+ retireBtnID +'");'+ + retierBtnVar + '.addListener("click", '+retierBtnVar+'retireProcess); '+ + retierBtnVar+'.set("disabled",'+retire+');'+ + 'var ' + activateVar + '=new YAHOO.widget.Button("'+ activateBtnID + '");' + + activateVar+'.addListener("click", '+activateVar+'activateProcess); ' + + activateVar+'.set("disabled",'+active+');'+ + 'var ' + viewProDetVar + '=new YAHOO.widget.Button("'+ viewProDetID + '");' + + viewProDetVar+'.addListener("click", '+viewProDetVar+'viewProcessDetails); ' + + '</script>'+ + '</div> <div class="actions"><a href="#" class="accordionToggleItem"> </a>'+ + '</div><div class="actions"><a href="#" class="accordionToggleItem"> </a>'+ + '</div></div>' + + return str; + } + + function populateContentArea(){ + + var contentHTML = '<h2>Currently Deployed Processes</h2>'; + var processesInfo = loadProcessInfo(); + + var processArray = processProcessInfoList(processesInfo); + if (processArray != 0 ) { + for (var i = 0; i < processArray.length; i++) { + contentHTML += createProcessWidget(processArray[i], i); + } + }else{ + contentHTML += '<p>Currently no processes are available.</p>' + } + var content = document.getElementById('content'); + var newDiv = document.createElement('div'); + YAHOO.util.Dom.addClass(newDiv, 'myAccordion'); + var innerDiv = document.createElement('div'); + YAHOO.util.Dom.addClass(innerDiv, 'yui-cms-accordion multiple fade fixIE'); + innerDiv.innerHTML = contentHTML; + newDiv.appendChild(innerDiv); + if(content.firstChild){ + content.replaceChild(newDiv, content.firstChild); + }else{ + content.appendChild(newDiv); + } + + } + + function getStatistics(){ + function Statistics(numOfProces, active, terminated, error, failed, suspended, completed){ + this.numOfProcesses = numOfProces; + this.activeInst = active; + this.terminatedInst = terminated; + this.errorInst = error; + this.failedInst = failed; + this.suspendedInst = suspended; + this.completedInst = completed; + this.totalInst = active + terminated + error + failed + suspended + completed; + } + var stat; + var processes = processProcessInfoList(loadProcessInfo()); + var numOfProcesses = processes.length; + var _ter = 0; + var _act = 0; + var _error = 0; + var _fail = 0; + var _susp = 0; + var _com = 0; + if(numOfProcesses != 0){ + for(var i = 0; i < processes.length; i++){ + _act += processes[i].instanceSummary.activeInstances; + _ter += processes[i].instanceSummary.terminatedInstances; + _error += processes[i].instanceSummary.errorInstances; + _fail += processes[i].instanceSummary.failedInstances; + _susp += processes[i].instanceSummary.suspendedInstances; + _com += processes[i].instanceSummary.completedInstances; + } + stat = new Statistics(numOfProcesses, _act, _ter, _error, _fail, _susp, _com); + }else{ + stat = new Statistics(0,0,0,0,0,0,0); + } + return stat; + } + + function _populateContentArea(){ + setTimeout("populateContentArea()", 5000); + } + + function retireProcess(processName, url, prefix){ + try { + + function handleYes(){ + var response; + try{ + response = ProcessManagementService.setRetired(true, processName, url, prefix); + }catch(e){ + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString(), YAHOO.widget.SimpleDialog.ICON_ALARM); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!", YAHOO.widget.SimpleDialog.ICON_ALARM); + } + } + var prefixWithName = prefix + ':' + processName; + var defInfoEle = org.apache.ode.DOMHelper.getElementsByTagName('definition-info', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', response)[0]; + + if (defInfoEle) { + var processNameEle = org.apache.ode.DOMHelper.getElementsByTagName('process-name', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', defInfoEle)[0]; + if (processNameEle) { + var proNameFromRes = org.apache.ode.DOMHelper.getText(processNameEle); + if (prefixWithName == proNameFromRes) { + org.apache.ode.ProcessHandling.populateContent(); + } + else { + org.apache.ode.Widgets.alert('Error occurred during retiring the process!', YAHOO.widget.SimpleDialog.ICON_ALARM); + } + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during retiring the process!', YAHOO.widget.SimpleDialog.ICON_ALARM); + } + return true; + + } + + function handleNo(){ + org.apache.ode.Widgets..alert('Retiring cancelled!', YAHOO.widget.SimpleDialog.ICON_INFO); + } + var msg = 'Do you want to retire the process '+ processName + '?'; + org.apache.ode.Widgets.operationConfirm(msg, handleYes, handleNo); + } + catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + + } + return false; + } + + function activateProcess(processName, url, prefix){ + try { + function handleYes(){ + var response; + try{ + response = ProcessManagementService.activate(processName, url, prefix); + }catch(e){ + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + var prefixWithName = prefix + ':' + processName; + var defInfoEle = org.apache.ode.DOMHelper.getElementsByTagName('definition-info', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', response)[0]; + if (defInfoEle) { + var processNameEle = org.apache.ode.DOMHelper.getElementsByTagName('process-name', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', defInfoEle)[0]; + + if(processNameEle){ + var proNameFromRes = org.apache.ode.DOMHelper.getText(processNameEle); + if (prefixWithName == proNameFromRes) { + org.apache.ode.ProcessHandling.populateContent(); + }else{ + org.apache.ode.Widgets.alert('Error occurred while activating process!'); + } + } + }else{ + org.apache.ode.Widgets.alert('Error occurred while activating process!'); + } + } + + function handleNo(){ + org.apache.ode.Widgets.alert('Process Activation Cancelled!'); + } + + var msg = 'Do you want to activate the process '+ processName+'?'; + org.apache.ode.Widgets.operationConfirm(msg, handleYes, handleNo); + + }catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + return false; + } + + function viewProcessDetails(processName, url, prefix){ + var proPID = 'prodet'+processName; + var processDefURL = ''; + var processN = processName.substring(0, (processName.indexOf('-'))); + + var urlRequestURL = 'http://localhost:8080/ode/deployment/getProcessDefinition/' + processN ; + try{ + var response = ProcessManagementService.getProcessInfo(processName, url, prefix); + var processInfoEle = org.apache.ode.DOMHelper.getElementsByTagName( + processInfoTagName, + processInfoNS, + processInfoNSPrefix, + response)[0]; + + + + var handleSuccess = function(o){ + if(o.responseXML){ + var proDefURLEle = o.responseXML.getElementsByTagName('url')[0]; + var proDefURL = org.apache.ode.DOMHelper.getText(proDefURLEle); + + var handleSuccessIn = function(o){ + var myPanel = new YAHOO.widget.Panel(proPID, { + width:"600px", + fixedcenter: true, + underlay:"shadow", + close:true, + visible:true, + draggable: true, + zindex:4, + modal:true} ); + + myPanel.setHeader("Process Details: " + processName); + + var processInfoStr = ProcessManagementService.text.replace(/>/g, '>\n'); + processInfoStr = processInfoStr.replace(/<\//g, '\n</'); + processInfoStr = processInfoStr.replace(/>\n>\n<\//g, '>\n</'); + + var processDefStr = o.responseText; + processDefStr = processDefStr.replace(/<\//g, '\n</'); + processDefStr = processDefStr.replace(/>\n>\n<\//g, '>\n</'); + + var detailsTabs = new YAHOO.widget.TabView(); + + var proInfoTab = new YAHOO.widget.Tab( { + label: 'Process Info', + content:'<textarea id="proinfo" class="codepress html" style="width: 568px; height: 570px;"></textarea>' + + }); + detailsTabs.addTab(proInfoTab); + + var proDefTab = new YAHOO.widget.Tab({ + label: 'Process Definition', + content:'<textarea id="prodef" class="codepress html" style="width: 568px; height: 570px;"></textarea>', + active: true + }); + + detailsTabs.addTab(proDefTab); + + + var tabDiv = document.createElement('div'); + detailsTabs.appendTo(tabDiv); + + + myPanel.setBody(tabDiv); + myPanel.cfg.setProperty("underlay","matte"); + myPanel.render("content"); + var proInfoEle = document.getElementById('proinfo'); + proInfoEle.appendChild(document.createTextNode(processInfoStr)); + var proDefEle = document.getElementById('prodef'); + proDefEle.appendChild(document.createTextNode(processDefStr)); + } + + var handleFailureIn = function(o){ + org.apache.ode.Widgets.alert("Request Failed: Getting Process Definition."); + } + + var callbackIn = { + success: handleSuccessIn, + failure: handleFailureIn, + } + + var requestIn = YAHOO.util.Connect.asyncRequest('GET', proDefURL, callbackIn); + } + } + + var handleFailure = function(o){ + org.apache.ode.Widgets.alert("Request failed: Geting process definition URL"); + } + + var callback = { + success: handleSuccess, + failure: handleFailure, + } + + var request = YAHOO.util.Connect.asyncRequest('GET', urlRequestURL, callback); + + }catch(e){ + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured in viewProcessDetails :\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred in viewProcessDetails !"); + } + } + return false; + } + + var ns = org.apache.ode.ProcessHandling; + ns.loadProcessInfo = loadProcessInfo; + ns.processInfo = processProcessInfoList; + ns.activateProcess = activateProcess; + ns.retireProcess = retireProcess; + ns.populateContent = populateContentArea; + ns.viewProcessDetails = viewProcessDetails; + ns.stats = getStatistics; + +})(); + +if (org.apache.ode.InstanceHandling) { + throw new Error("org.apache.ode.InstanceHandling already exists"); +} + +org.apache.ode.InstanceHandling = {}; + +(function(){ + var instanceInfoNS = "http://www.apache.org/ode/pmapi/types/2006/08/02/"; + var instanceInfoNSPrefix = "ns"; + var instanceInfoTagName = "instance-info"; + + function loadInstanceInfo(){ + try { + var responseDoc = InstanceManagementService.listAllInstances(); + return responseDoc; + } + catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured in loadInstanceInfo():\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred in loadInstanceInfo()!"); + } + } + } + + function InstanceInfo(iid, pid, rootScope, siid, statusR, nameR, modelID, statusI, dateStarted, dateLastActive){ + this.iid = iid; + this.pid = pid; + this.rootScope = rootScope; + this.siid = siid; + this.statusR = statusR; + this.nameR = nameR; + this.modelID = modelID; + this.statuI = statusI; + this.dateStarted = dateStarted; + this.dateLastActive = dateLastActive; + } + + function processInstanceInfo(instanceInfoDoc){ + var returnInstanceArray = []; + var instanceInfoList = org.apache.ode.DOMHelper.getElementsByTagName( + instanceInfoTagName, + instanceInfoNS, + instanceInfoNSPrefix, + instanceInfoDoc); + if (instanceInfoList.length == 0){ + return 0; + }else{ + for(var i = 0; i < instanceInfoList.length; i++){ + var scopeEle = instanceInfoList[i]; + var iidEle = org.apache.ode.DOMHelper.getElementsByTagName('iid', instanceInfoNS, instanceInfoNSPrefix, scopeEle)[0]; + var iid = org.apache.ode.DOMHelper.getText(iidEle); + + var pidEle = org.apache.ode.DOMHelper.getElementsByTagName('pid', instanceInfoNS, instanceInfoNSPrefix, scopeEle)[0]; + var pid = org.apache.ode.DOMHelper.getText(pidEle); + + var rootScopeEle = org.apache.ode.DOMHelper.getElementsByTagName('root-scope', instanceInfoNS, instanceInfoNSPrefix, scopeEle)[0]; + var siid = rootScopeEle.getAttribute('siid'); + var statusR = rootScopeEle.getAttribute('status'); + var nameR = rootScopeEle.getAttribute('name'); + var modelID = rootScopeEle.getAttribute('modelId'); + + var statusIEle = org.apache.ode.DOMHelper.getElementsByTagName('status', instanceInfoNS, instanceInfoNSPrefix, scopeEle)[0]; + var statusI = org.apache.ode.DOMHelper.getText(statusIEle); + + var dateSEle = org.apache.ode.DOMHelper.getElementsByTagName('dt-started', instanceInfoNS, instanceInfoNSPrefix, scopeEle)[0]; + var dateStarted = org.apache.ode.DOMHelper.getText(dateSEle); + + var lastAEle = org.apache.ode.DOMHelper.getElementsByTagName('dt-last-active', instanceInfoNS, instanceInfoNSPrefix, scopeEle)[0]; + var lastActive = org.apache.ode.DOMHelper.getText(lastAEle); + + var instance = new InstanceInfo(iid, pid, rootScopeEle, siid, statusR, nameR, modelID, statusI, dateStarted, lastActive); + + returnInstanceArray[i] = instance; + } + } + + return returnInstanceArray; + } + + function createInstanceWidget(instance, i){ + var terminateBtnID = 'terminateIns'+i; + var terminateBtnVar = 'terminateVar'+i; + var suspendBtnID = 'suspendBtn' + i; + var suspenBtnVar = 'suspendBtnVar' + i; + var resumeBtnID = 'resumeBtn' + i; + var resumeBtnVar = 'resumeBtnVar' + i; + var _term = "false"; + var _susp = "false"; + var _resu = "true"; + if(instance.statuI.toUpperCase() == 'ACTIVE'){ + _term = "false"; + _susp = "false"; + _resu = "true"; + }else if(instance.statuI.toUpperCase() == 'COMPLETED' || instance.statuI.toUpperCase() == 'ERROR' + || instance.statuI.toUpperCase() == 'FAILED'){ + _term = "false"; + _susp = "true"; + _resu = "true"; + }else if(instance.statuI.toUpperCase() == 'SUSPENDED'){ + _term = "false"; + _susp = "true"; + _resu = "false"; + }else if(instance.statuI.toUpperCase() == 'TERMINATED'){ + _term = "true"; + _susp = "true"; + _resu = "true"; + } + + str = '<div class="yui-cms-item yui-panel selected"><div class="hd">Instance ID: '+ + instance.iid + + '</div><div class="bd"><div class="fixed">'+ + '<table><tr><td class="alt">Instance Summary</td></tr><tr><th>' + + 'Process:</th><td>' + instance.pid + '</td><th>Status:</th><td>' + + instance.statuI + '</td></tr><tr><th>Date Started:</th><td>' + + instance.dateStarted + '</td><th>Date Last Active</th><td>' + + instance.dateLastActive + '</td></tr></table>' + + '</div></div><div class="ft">'+ + '<span id="'+ terminateBtnID + + '" class="yui-button yui-push-button"><span class="first-child"><input type="button" name="'+ terminateBtnID +'name" value="Terminate"></span></span>'+ + '<span id="'+ suspendBtnID + + '" class="yui-button yui-push-button"><span class="first-child"><input type="button" name="'+ suspendBtnID +'name" value="Suspend"></span></span>'+ + '<span id="'+ resumeBtnID + + '" class="yui-button yui-push-button"><span class="first-child"><input type="button" name="'+ resumeBtnID +'name" value="Resume"></span></span>'+ + '<script type="text/javascript">'+ + 'function '+terminateBtnVar+'terminateIns(){org.apache.ode.InstanceHandling.terminateInstance("'+instance.iid +'");}'+ + 'function '+suspenBtnVar+'suspendIns(){org.apache.ode.InstanceHandling.suspendInstance("'+instance.iid +'");}'+ + 'function '+resumeBtnVar+'resumeIns(){org.apache.ode.InstanceHandling.resumeInstance("'+instance.iid +'");}'+ + + 'var ' + terminateBtnVar + '=new YAHOO.widget.Button("'+ terminateBtnID + '");'+ + terminateBtnVar + '.addListener("click", '+terminateBtnVar+'terminateIns); '+ + terminateBtnVar+ '.set("disabled",' + _term + ');'+ + 'var ' + suspenBtnVar + '=new YAHOO.widget.Button("'+ suspendBtnID + '");' + + suspenBtnVar+'.addListener("click", '+suspenBtnVar+'suspendIns); ' + + suspenBtnVar+ '.set("disabled",' + _susp + ');' + + 'var ' + resumeBtnVar + '=new YAHOO.widget.Button("'+ resumeBtnID + '");' + + resumeBtnVar+'.addListener("click", '+resumeBtnVar+'resumeIns); ' + + resumeBtnVar+ '.set("disabled",' + _resu + ');' + + '</script>'+ + '</div> <div class="actions"><a href="#" class="accordionToggleItem"> </a>'+ + '</div></div>' + + return str; + } + + function populateContentArea(){ + + var contentHTML = '<h2>Currently Available Instances</h2>'; + var instanceInfo = loadInstanceInfo(); + + var instanceArray = processInstanceInfo(instanceInfo); + if (instanceArray != 0 ) { + for (var i = 0; i < instanceArray.length; i++) { + contentHTML += createInstanceWidget(instanceArray[i], i); + } + }else{ + contentHTML += '<p>Currently no instances are available.</p>' + } + var content = document.getElementById('content'); + var newDiv = document.createElement('div'); + YAHOO.util.Dom.addClass(newDiv, 'myAccordion'); + var innerDiv = document.createElement('div'); + YAHOO.util.Dom.addClass(innerDiv, 'yui-cms-accordion multiple fade fixIE'); + innerDiv.innerHTML = contentHTML; + newDiv.appendChild(innerDiv); + if(content.firstChild){ + content.replaceChild(newDiv, content.firstChild); + }else{ + content.appendChild(newDiv); + } + + } + + function terminateInstance(instanceID){ + try { + + function handleYes(){ + var response; + try{ + response = InstanceManagementService.terminate(instanceID); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + var insEle = org.apache.ode.DOMHelper.getElementsByTagName('instance-info', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', response)[0]; + if(insEle){ + var iidEle = org.apache.ode.DOMHelper.getElementsByTagName('iid', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', insEle)[0]; + if(iidEle){ + var iidFromRes = org.apache.ode.DOMHelper.getText(iidEle); + if (iidFromRes == instanceID) { + org.apache.ode.InstanceHandling.populateContent(); + }else{ + org.apache.ode.Widgets.alert('Error occurred during termination of instance!'); + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during termination of instance!'); + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during instance termination!'); + } + + } + function handleNo(){ + org.apache.ode.Widgets.alert('Instance terminating cancelled!'); + } + + var msg = 'Do you want to terminate instance '+ instanceID + '?'; + org.apache.ode.Widgets.operationConfirm(msg, handleYes, handleNo); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + return false; + } + + function suspendInstance(instanceID){ + try { + function handleYes(){ + var response; + try{ + response = InstanceManagementService.suspend(instanceID); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + var insEle = org.apache.ode.DOMHelper.getElementsByTagName('instance-info', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', response)[0]; + if(insEle){ + var iidEle = org.apache.ode.DOMHelper.getElementsByTagName('iid', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', insEle)[0]; + if(iidEle){ + var iidFromRes = org.apache.ode.DOMHelper.getText(iidEle); + if (iidFromRes == instanceID) { + org.apache.ode.InstanceHandling.populateContent(); + }else{ + org.apache.ode.Widgets.alert('Error occurred during suspending of instance!'); + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during suspending of instance!'); + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during instance suspending!'); + } + } + + function handleNo(){ + org.apache.ode.Widgets.alert('Instance suspending cancelled!'); + } + var msg = 'Do you want to suspend instance ' + instanceID + '?'; + org.apache.ode.Widgets.operationConfirm(msg, handleYes, handleNo); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + + } + + function resumeInstance(instanceID){ + try { + function handleYes(){ + var response; + try{ + response = InstanceManagementService.resume(instanceID); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + + var insEle = org.apache.ode.DOMHelper.getElementsByTagName('instance-info', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', response)[0]; + if(insEle){ + var iidEle = org.apache.ode.DOMHelper.getElementsByTagName('iid', 'http://www.apache.org/ode/pmapi/types/2006/08/02/', 'ns', insEle)[0]; + if(iidEle){ + var iidFromRes = org.apache.ode.DOMHelper.getText(iidEle); + if (iidFromRes == instanceID) { + org.apache.ode.InstanceHandling.populateContent(); + }else{ + org.apache.ode.Widgets.alert('Error occurred during resuming of instance!'); + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during resuming of instance!'); + } + }else{ + org.apache.ode.Widgets.alert('Error occurred during instance resuming!'); + } + + } + + function handleNo(){ + org.apache.ode.Widgets.alert('Instance resuming cancelled!'); + } + + var msg = 'Do you want to resume instance'+ instanceID + '?'; + org.apache.ode.Widgets.operationConfirm(msg, handleYes, handleNo); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + return false; + } + + var ns = org.apache.ode.InstanceHandling; + ns.terminateInstance = terminateInstance; + ns.suspendInstance = suspendInstance; + ns.resumeInstance = resumeInstance; + ns.populateContent = populateContentArea; +})(); + +if(org.apache.ode.DeploymentHandling){ + throw new Error("org.apache.ode.DeploymentHandling already exists"); +} + +org.apache.ode.DeploymentHandling = {}; + +(function(){ + var bundleDataUrl = 'http://localhost:8080/ode/deployment/bundles/'; + var packageDocsUrl = 'http://localhost:8080/ode/deployment/getBundleDocs/'; + + function loadDeployedPackages(){ + try{ + var response = DeploymentService.listDeployedPackages(); + return response; + }catch(e){ + if(typeof e == 'string'){ + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + }else{ + org.apache.ode.Widgets.alert("Exception occurred in loadDeployedBundles."); + } + } + } + + function getDeployedPackages(){ + var packageNames = []; + var response = loadDeployedPackages(); + var names = response.getElementsByTagName('name'); + if (names.length != 0) { + for (var i = 0; i < names.length; i++) { + packageNames[i] = org.apache.ode.DOMHelper.getText(names[i]); + } + return packageNames; + }else{ + return 0; + } + + } + + function getProcesses(packageName){ + try{ + var processes = []; + var response = DeploymentService.listProcesses(packageName); + var ids = response.getElementsByTagName('id'); + if(ids.length != 0){ + for(var i =0; i < ids.length; i++){ + processes[i] = org.apache.ode.DOMHelper.getText(ids[i]); + } + return processes; + }else{ + return 0; + } + + }catch(e){ + if(typeof e == 'string'){ + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + }else{ + org.apache.ode.Widgets.alert("Exception occurred in getProcesses."); + } + } + } + function getPackageContents(packageName){ + var contents = []; + var i = 0; + var url = packageDocsUrl + packageName; + try{ + var response = org.apache.ode.XHRObject.xhrSyncGetRequest(url, false); + }catch(e){ + org.apache.ode.Widgets.alert("Exception occurred during getting paackage contents."); + return null; + } + if(response != null && typeof response != 'string'){ + var processEle = response.getElementsByTagName('process')[0]; + for(var m = processEle.firstChild; m != null; m = m.nextSibling){ + if(m.localName != 'pid'){ + contents[i] = org.apache.ode.DOMHelper.getText(m); + i++; + } + + } + return contents; + }else{ + return null; + } + } + + function populateDeployedPackages(){ + var contentHtml = ''; + var deployedPacks = getDeployedPackages(); + for(var i = 0; i < deployedPacks.length; i++){ + var packageundepId = deployedPacks[i].replace(/-/, "_")+"undeployid"; + var packageundepVar = deployedPacks[i].replace(/-/,"_")+"undeployvar"; + var packageDetailsId = deployedPacks[i].replace(/-/,"_")+"detid"; + var packageDetailsVar = deployedPacks[i].replace(/-/,"_")+"detvar"; + contentHtml += '<div class="yui-cms-item yui-panel selected"><div class="hd">'+ + deployedPacks[i] + + '</div><div class="bd"><div class="fixed">'+ + '<table><tr class="alt"><td>Processes:</td></tr><tr><td>' + var processes = getProcesses(deployedPacks[i]); + if(processes != 0){ + for(var j = 0; j < processes.length; j++){ + contentHtml += processes[j]+', '; + } + }else{ + contentHtml += 'Error occurred during getting processes or no processes.'; + } + contentHtml += '</td></tr><tr class="alt"><td>Contents:</td></tr><tr><td>'; + var content = getPackageContents(deployedPacks[i]); + if(content != null){ + for(var k =0; k < content.length; k++){ + var strC = content[k]; + var index = strC.indexOf('/'); + contentHtml += strC.substr(index+1) + ", "; + } + }else{ + contentHtml += 'Error occurred during getting package Content or no content.' + } + contentHtml += '</td></tr></table></div></div><div class="ft">'+ + '<span id="'+ packageundepId + '" class="yui-button yui-push-button">'+ + '<span class="first-child"><input type="button" name="'+ packageundepVar + + 'name" value="Undeploy"></span></span>'+ + '<span id="'+ packageDetailsId + + '" class="yui-button yui-push-button"><span class="first-child">'+ + '<input type="button" name="'+ packageDetailsVar +'name" value="Details"></span></span>'+ + '<script type="text/javascript">'+ + 'function '+ packageundepVar + + 'undeployPackage(){org.apache.ode.DeploymentHandling.undeployPackage("'+ + deployedPacks[i] +'");}' + + 'function '+ packageDetailsVar + + 'viewDetails(){org.apache.ode.DeploymentHandling.viewPackDetails("'+ + deployedPacks[i] +'"'+ ');}' + + 'var ' + packageundepVar + '=new YAHOO.widget.Button("'+ packageundepId + '");'+ + packageundepVar + '.addListener("click", ' + packageundepVar + 'undeployPackage); '+ + 'var ' + packageDetailsVar + '=new YAHOO.widget.Button("'+ packageDetailsId + '");' + + packageDetailsVar +'.addListener("click", ' + packageDetailsVar + 'viewDetails); ' + + '</script>'+ + '</div> <div class="actions"><a href="#" class="accordionToggleItem"> </a>'+ + '</div></div>' + //alert(contentHtml); + + } + var deployed = document.getElementById('deployed'); + var newDiv = document.createElement('div'); + YAHOO.util.Dom.addClass(newDiv, 'myAccordion'); + var innerDiv = document.createElement('div'); + YAHOO.util.Dom.addClass(innerDiv, 'yui-cms-accordion multiple fade fixIE'); + innerDiv.innerHTML = contentHtml; + newDiv.appendChild(innerDiv); + if(deployed.firstChild){ + deployed.replaceChild(newDiv, deployed.firstChild); + }else{ + deployed.appendChild(newDiv); + } + + + } + + function viewPackDetails(packageName){ + var winID = 'deployedPack'+packageName; + var bundleDocs = []; + + bundleDocs = getPackageContents(packageName); + + var packPanel = new YAHOO.widget.Panel(winID, { + width:"600px", + fixedcenter:true, + underlay:"shadow", + close:true, + visible:true, + draggable:true, + zindex:4, + modal:true}); + + packPanel.setHeader("Package Details: " + packageName); + + var packDetTabs = new YAHOO.widget.TabView(); + + for(var j = 0; j < bundleDocs.length; j++){ + var activeS = false; + var strC = bundleDocs[j]; + if (j == 0){ + activeS = true; + } + var index = strC.indexOf('/'); + var docName = strC.substr(index+1); + var indexDot = docName.indexOf('.'); + var idTxt = docName.substr(0, (indexDot-1)) + j; + var textAreaStr = '<textarea id="'+ idTxt + '"` class="codepress html" style="width: 568px; height:570px;"></textarea>'; + packDetTabs.addTab(new YAHOO.widget.Tab({ + label:docName, + content:textAreaStr, + active:activeS})); + } + + var tabsDiv = document.createElement('div'); + packDetTabs.appendTo(tabsDiv); + + packPanel.setBody(tabsDiv); + packPanel.cfg.setProperty("underlay","matte"); + packPanel.render("content"); + + for(var k = 0; k < bundleDocs.length; k++){ + var strC = bundleDocs[k]; + var index = strC.indexOf('/'); + var docName = strC.substr(index+1); + var indexDot = docName.indexOf('.'); + var idTxt = docName.substr(0, (indexDot-1)) + k; + var bundleUrl = bundleDataUrl + strC; + var responseText = org.apache.ode.XHRObject.xhrSyncGetRequest(bundleUrl, true); + //var resStr = responseText.replace(/<\//g, '\n</'); + //resStr = resStr.replace(/>\n>\n<\//g, '>\n</'); + + if(typeof responseText == 'string'){ + var textAreaEle = document.getElementById(idTxt); + textAreaEle.appendChild(document.createTextNode(responseText)); + }else{ + org.apache.ode.Widgets.alert('Response Type not recognized for document: '+ docName); + } + } + } + + function undeployPackage(packageName){ + try{ + function handleYes(){ + var response; + try{ + response = DeploymentService.undeploy(packageName); + } catch (e) { + if (typeof(e) == "string") { + org.apache.ode.Widgets.alert("Exception occured:\n" + e.toString()); + } + else { + org.apache.ode.Widgets.alert("Exception occurred!"); + } + } + if(response == true){ + org.apache.ode.Widgets.alert('Package '+ packageName + 'undeployed successfully.'); + org.apache.ode.DeploymentHandling.populateDeployedPacks(); + }else{ + org.apache.ode.Widgets.alert('Error occurred during undeployment or undeplyment unsuccessful.'); + } + } + + function handleNo(){ + org.apache.ode.Widgets.alert('Package undeployment cancelled!'); + } + + var msg = 'Dou you want to undeploy package ' + packageName + '?'; + + org.apache.ode.Widgets.operationConfirm(msg,handleYes, handleNo); + + }catch(e){ + if(typeof e == 'string'){ + org.apache.ode.Widgets.alert("Exception occurred while undeploying the package: " + e.toString()); + }else{ + org.apache.ode.Widgets.alert("Exception occurred while undeploying the package."); + } + } + } + + var ns = org.apache.ode.DeploymentHandling; + ns.getDeployedPackages = getDeployedPackages; + ns.undeployPackage = undeployPackage; + ns.viewPackDetails = viewPackDetails; + ns.populateDeployedPacks = populateDeployedPackages; +})(); +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/ProcessManagementAPI.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/ProcessManagementAPI.js new file mode 100644 index 0000000..e0a9d78 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/ProcessManagementAPI.js
@@ -0,0 +1,946 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +var baseURL; +if (location.host.indexOf('/') == -1 && location.protocol.indexOf('/') == -1) { + baseURL = location.protocol + "//" + location.host + "/"; +}else if(location.host.indexOf('/') != -1 && location.protocol.indexOf('/') == -1){ + baseURL = location.protocol + "//" + location.host; +} +var address = baseURL + "ode/processes/ProcessManagement"; + +var ProcessManagementService = new WebServiceClient("ProcessManagementPort"); + +ProcessManagementService.getExtensibilityElements = function getExtensibilityElements(/* aidsType */ _aids, /* QName */ _pid) { + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getExtensibilityElements.callback != null && typeof(this.getExtensibilityElements.callback) == 'function'); + request = + '<p:getExtensibilityElements xmlns:p="http://www.apache.org/ode/pmapi">' + + (_aids == null ? '' : '<aids>' + _aids + '</aids>') + + (_pid == null ? '' : '<pid>' + this._encodeXML(_pid) + '</pid>') + + '</p:getExtensibilityElements>'; + + if (isAsync) { + try { + this._call( + "getExtensibilityElements", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getExtensibilityElements.callback, this.getExtensibilityElements.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getExtensibilityElements.onError(error); + } + } else { + try { + response = this._call("getExtensibilityElements", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.getExtensibilityElements.callback = null; + +ProcessManagementService.activate = +function activate(/* String */ _name, /* String */ _nmspURL, /* String */ _prefix) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.activate.callback != null && typeof(this.activate.callback) == 'function'); + request = + '<p:activate xmlns:p="http://www.apache.org/ode/pmapi">' + + ((_name != null && _nmspURL != null && _prefix != null) ? '<pid xmlns:' + this._encodeXML(_prefix) + '="' + this._encodeXML(_nmspURL) + '">' + + this._encodeXML(_prefix) + ':' + this._encodeXML(_name) + '</pid>' : '') + + '</p:activate>'; + + if (isAsync) { + try { + this._call( + "activate", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.activate.callback, this.activate.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.activate.onError(error); + } + } else { + try { + response = this._call("activate", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.activate.callback = null; + +ProcessManagementService.setProcessProperty = +function setProcessProperty(/* QName */ _propertyName, /* string */ _propertyValue, /* QName */ _pid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.setProcessProperty.callback != null && typeof(this.setProcessProperty.callback) == 'function'); + request = + '<p:setProcessProperty xmlns:p="http://www.apache.org/ode/pmapi">' + + (_propertyName == null ? '' : '<propertyName>' + this._encodeXML(_propertyName) + '</propertyName>') + + (_propertyValue == null ? '' : '<propertyValue>' + this._encodeXML(_propertyValue) + '</propertyValue>') + + (_pid == null ? '' : '<pid>' + this._encodeXML(_pid) + '</pid>') + + '</p:setProcessProperty>'; + + if (isAsync) { + try { + this._call( + "setProcessProperty", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.setProcessProperty.callback, this.setProcessProperty.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.setProcessProperty.onError(error); + } + } else { + try { + response = this._call("setProcessProperty", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.setProcessProperty.callback = null; + +ProcessManagementService.getProcessInfoCustom = +function getProcessInfoCustom(/* string */ _customizer, /* QName */ _pid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getProcessInfoCustom.callback != null && typeof(this.getProcessInfoCustom.callback) == 'function'); + request = + '<p:getProcessInfoCustom xmlns:p="http://www.apache.org/ode/pmapi">' + + (_customizer == null ? '' : '<customizer>' + this._encodeXML(_customizer) + '</customizer>') + + (_pid == null ? '' : '<pid>' + this._encodeXML(_pid) + '</pid>') + + '</p:getProcessInfoCustom>'; + + if (isAsync) { + try { + this._call( + "getProcessInfoCustom", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getProcessInfoCustom.callback, this.getProcessInfoCustom.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getProcessInfoCustom.onError(error); + } + } else { + try { + response = this._call("getProcessInfoCustom", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.getProcessInfoCustom.callback = null; + +ProcessManagementService.listProcessesCustom = +function listProcessesCustom(/* string */ _filter, /* string */ _customizer, /* string */ _orderKeys) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listProcessesCustom.callback != null && typeof(this.listProcessesCustom.callback) == 'function'); + request = + '<p:listProcessesCustom xmlns:p="http://www.apache.org/ode/pmapi">' + + (_filter == null ? '' : '<filter>' + this._encodeXML(_filter) + '</filter>') + + (_customizer == null ? '' : '<customizer>' + this._encodeXML(_customizer) + '</customizer>') + + (_orderKeys == null ? '' : '<orderKeys>' + this._encodeXML(_orderKeys) + '</orderKeys>') + + '</p:listProcessesCustom>'; + + if (isAsync) { + try { + this._call( + "listProcessesCustom", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listProcessesCustom.callback, this.listProcessesCustom.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listProcessesCustom.onError(error); + } + } else { + try { + response = this._call("listProcessesCustom", request); + resultValue = /* tProcessInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.listProcessesCustom.callback = null; + +ProcessManagementService.getProcessInfo = +function getProcessInfo(/* String */ _name, /* String */ _nmspURL, /* String */ _prefix) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.getProcessInfo.callback != null && typeof(this.getProcessInfo.callback) == 'function'); + request = + '<p:getProcessInfo xmlns:p="http://www.apache.org/ode/pmapi">' + + ((_name != null && _nmspURL != null && _prefix != null) ? '<pid xmlns:' + this._encodeXML(_prefix) + '="' + this._encodeXML(_nmspURL) + '">' + + this._encodeXML(_prefix) + ':' + this._encodeXML(_name) + '</pid>' : '') + + '</p:getProcessInfo>'; + + if (isAsync) { + try { + this._call( + "getProcessInfo", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.getProcessInfo.callback, this.getProcessInfo.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.getProcessInfo.onError(error); + } + } else { + try { + response = this._call("getProcessInfo", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.getProcessInfo.callback = null; + +ProcessManagementService.listProcesses = +function listProcesses(/* string */ _filter, /* string */ _orderKeys) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listProcesses.callback != null && typeof(this.listProcesses.callback) == 'function'); + request = + '<p:listProcesses xmlns:p="http://www.apache.org/ode/pmapi">' + + (_filter == null ? '' : '<filter>' + this._encodeXML(_filter) + '</filter>') + + (_orderKeys == null ? '' : '<orderKeys>' + this._encodeXML(_orderKeys) + '</orderKeys>') + + '</p:listProcesses>'; + + if (isAsync) { + try { + this._call( + "listProcesses", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listProcesses.callback, this.listProcesses.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listProcesses.onError(error); + } + } else { + try { + response = this._call("listProcesses", request); + resultValue = /* tProcessInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.listProcesses.callback = null; + +ProcessManagementService.setRetired = +function setRetired(/* boolean */ _retired, /* String */ _name, /* String */ _nmspURL, /* String */ _prefix) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.setRetired.callback != null && typeof(this.setRetired.callback) == 'function'); + request = + '<p:setRetired xmlns:p="http://www.apache.org/ode/pmapi">' + + (_retired == null ? '' : '<retired>' + this._encodeXML(_retired) + '</retired>') + + ((_name != null && _nmspURL != null && _prefix != null) ? '<pid xmlns:' + this._encodeXML(_prefix) + '="' + this._encodeXML(_nmspURL) + '">' + + this._encodeXML(_prefix) + ':' + this._encodeXML(_name) + '</pid>' : '') + + '</p:setRetired>'; + + if (isAsync) { + try { + this._call( + "setRetired", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.setRetired.callback, this.setRetired.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.setRetired.onError(error); + } + } else { + try { + response = this._call("setRetired", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.setRetired.callback = null; + +ProcessManagementService.setProcessPropertyNode = +function setProcessPropertyNode(/* QName */ _propertyName, /* anyType */ _propertyValue, /* QName */ _pid) +{ + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.setProcessPropertyNode.callback != null && typeof(this.setProcessPropertyNode.callback) == 'function'); + request = + '<p:setProcessPropertyNode xmlns:p="http://www.apache.org/ode/pmapi">' + + (_propertyName == null ? '' : '<propertyName>' + this._encodeXML(_propertyName) + '</propertyName>') + + (_propertyValue == null ? '' : '<propertyValue>' + _propertyValue + '</propertyValue>') + + (_pid == null ? '' : '<pid>' + this._encodeXML(_pid) + '</pid>') + + '</p:setProcessPropertyNode>'; + + if (isAsync) { + try { + this._call( + "setProcessPropertyNode", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfo */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.setProcessPropertyNode.callback, this.setProcessPropertyNode.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.setProcessPropertyNode.onError(error); + } + } else { + try { + response = this._call("setProcessPropertyNode", request); + resultValue = /* tProcessInfo */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.setProcessPropertyNode.callback = null; + +ProcessManagementService.listAllProcesses = function listAllProcesses() { + var isAsync, request, response, resultValue; + + this._options = new Array(); + isAsync = (this.listAllProcesses.callback != null && typeof(this.listAllProcesses.callback) == 'function'); + request = + '<p:listAllProcesses xmlns:p="http://www.apache.org/ode/pmapi">' + + '</p:listAllProcesses>'; + + if (isAsync) { + try { + this._call( + "listAllProcesses", + request, + function(thisRequest, callbacks) { + if (thisRequest.error != null) { + callbacks[1](thisRequest.error); + } else { + response = thisRequest.responseXML; + if (response == null) { + resultValue = null; + } else { + resultValue = /* tProcessInfoList */ response.documentElement; + } + callbacks[0](resultValue); + } + }, + new Array(this.listAllProcesses.callback, this.listAllProcesses.onError) + ); + } catch (e) { + var error; + if (WebServiceError.prototype.isPrototypeOf(e)) { + error = e; + } else if (typeof(e) == "string") { + error = new WebServiceError(e, "Internal Error"); + } else { + error = new WebServiceError(e.description, e.number, e.number); + } + this.listAllProcesses.onError(error); + } + } else { + try { + response = this._call("listAllProcesses", request); + resultValue = /* tProcessInfoList */ response.documentElement; + return resultValue; + } catch (e) { + if (typeof(e) == "string") throw(e); + if (e.message) throw(e.message); + throw (e.reason + e.detail); + } + } + return null; // Suppress warnings when there is no return. +} +ProcessManagementService.listAllProcesses.callback = null; + + + +// WebService object. +function WebServiceClient(endpointName) +{ + this.readyState = 0; + this.onreadystatechange = null; + + //public accessors for manually intervening in setting the address (e.g. supporting tcpmon) + this.getAddress = function (endpointName) + { + return this._endpointDetails[endpointName].address; + } + + this.setAddress = function (endpointName, address) + { + this._endpointDetails[endpointName].address = address; + } + + // private helper functions + this._getWSRequest = function() + { + var wsrequest; + try { + wsrequest = new WSRequest(); + } catch(e) { + try { + wsrequest = new ActiveXObject("WSRequest"); + } catch(e) { + try { + wsrequest = new SOAPHttpRequest(); + netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect"); + } catch (e) { + throw new WebServiceError("WSRequest object not defined.", "WebServiceClient._getWSRequest() cannot instantiate WSRequest object."); + } + } + } + return wsrequest; + } + + this._endpointDetails = + { + "ProcessManagementPort": { + "type" : "SOAP11", + "address" : address, + "action" : { + "getExtensibilityElements" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/getExtensibilityElementsRequest", + "activate" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/activateRequest", + "setProcessProperty" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/setProcessPropertyRequest", + "getProcessInfoCustom" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/getProcessInfoCustomRequest", + "listProcessesCustom" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/listProcessesCustomRequest", + "getProcessInfo" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/getProcessInfoRequest", + "listProcesses" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/listProcessesRequest", + "setRetired" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/setRetiredRequest", + "setProcessPropertyNode" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/setProcessPropertyNodeRequest", + "listAllProcesses" : "http://www.apache.org/ode/pmapi/ProcessManagementPortType/listAllProcessesRequest" + } + } + }; + this.endpoint = endpointName; + + this._encodeXML = function (value) { + var re; + var str = value.toString(); + re = /&/g; + str = str.replace(re, "&"); + re = /</g; + str = str.replace(re, "<"); + return(str); + }; + + this._call = function (opName, reqContent, callback, userdata) + { + var details = this._endpointDetails[this.endpoint]; + if (details.type == 'SOAP12') this._options.useSOAP = 1.2; + else if (details.type == 'SOAP11') this._options.useSOAP = 1.1; + else if (details.type == 'HTTP') this._options.useSOAP = false; + + if (details.action != null) { + this._options.useWSA = true; + this._options.action = details.action[opName]; + } else if (details.soapaction != null) { + this._options.useWSA = false; + this._options.action = details.soapaction[opName]; + } else { + this._options.useWSA = false; + this._options.action = undefined; + } + + if (details["httpmethod"] != null) { + this._options.HTTPMethod = details.httpmethod[opName]; + } else { + this._options.HTTPMethod = null; + } + + if (details["httpinputSerialization"] != null) { + this._options.HTTPInputSerialization = details.httpinputSerialization[opName]; + } else { + this._options.HTTPInputSerialization = null; + } + + if (details["httplocation"] != null) { + this._options.HTTPLocation = details.httplocation[opName]; + } else { + this._options.HTTPLocation = null; + } + + if (details["httpignoreUncited"] != null) { + this._options.HTTPLocationIgnoreUncited = details.httpignoreUncited[opName]; + } else { + this._options.HTTPLocationIgnoreUncited = null; + } + + if (details["httpqueryParameterSeparator"] != null) { + this._options.HTTPQueryParameterSeparator = details.httpqueryParameterSeparator[opName]; + } else { + this._options.HTTPQueryParameterSeparator = null; + } + + var isAsync = (typeof(callback) == 'function'); + + var thisRequest = this._getWSRequest(); + if (isAsync) { + thisRequest._userdata = userdata; + thisRequest.onreadystatechange = + function() { + if (thisRequest.readyState == 4) { + callback(thisRequest, userdata); + } + } + } + thisRequest.open(this._options, details.address, isAsync); + thisRequest.send(reqContent); + if (isAsync) { + return ""; + } else { + try { + var resultContent = thisRequest.responseText; + ProcessManagementService.text = resultContent; + if (resultContent == "") { + throw new WebServiceError("No response", "WebServiceClient._call() did not recieve a response to a synchronous request."); + } + var resultXML = thisRequest.responseXML; + } catch (e) { + throw new WebServiceError(e); + } + return resultXML; + } + } +} +WebServiceClient.visible = false; + +// library function for dynamically converting an element with js:type annotation to a Javascript type. +convertJSType.visible = false; +function convertJSType(element, isWrapped) { + if (element == null) return ""; + var extractedValue = WSRequest.util._stringValue(element); + var resultValue, i; + var type = element.getAttribute("js:type"); + if (type == null) { + type = "xml"; + } else { + type = type.toString(); + } + switch (type) { + case "string": + return extractedValue; + break; + case "number": + return parseFloat(extractedValue); + break; + case "boolean": + return extractedValue == "true" || extractedValue == "1"; + break; + case "date": + return xs_dateTime_to_date(extractedValue); + break; + case "array": + resultValue = new Array(); + for (i = 0; i < element.childNodes.length; i++) { + resultValue = resultValue.concat(convertJSType(element.childNodes[i])); + } + return(resultValue); + break; + case "object": + resultValue = new Object(); + for (i = 0; i < element.childNodes.length; i++) { + resultValue[element.childNodes[i].tagName] = convertJSType(element.childNodes[i]); + } + return(resultValue); + break; + case "xmllist": + return element.childNodes; + break; + case "xml": + default: + if (isWrapped == true) + return element.firstChild; + else return element; + break; + } +} + +// library function for parsing xs:date, xs:time, and xs:dateTime types into Date objects. +function xs_dateTime_to_date(dateTime) +{ + var buffer = dateTime; + var p = 0; // pointer to current parse location in buffer. + + var era, year, month, day, hour, minute, second, millisecond; + + // parse date, if there is one. + if (buffer.substr(p, 1) == '-') + { + era = -1; + p++; + } else { + era = 1; + } + + if (buffer.charAt(p + 2) != ':') + { + year = era * buffer.substr(p, 4); + p += 5; + month = buffer.substr(p, 2); + p += 3; + day = buffer.substr(p, 2); + p += 3; + } else { + year = 1970; + month = 1; + day = 1; + } + + // parse time, if there is one + if (buffer.charAt(p) != '+' && buffer.charAt(p) != '-') + { + hour = buffer.substr(p, 2); + p += 3; + minute = buffer.substr(p, 2); + p += 3; + second = buffer.substr(p, 2); + p += 2; + if (buffer.charAt(p) == '.') + { + millisecond = parseFloat(buffer.substr(p)) * 1000; + // Note that JS fractional seconds are significant to 3 places - xs:time is significant to more - + // though implementations are only required to carry 3 places. + p++; + while (buffer.charCodeAt(p) >= 48 && buffer.charCodeAt(p) <= 57) p++; + } else { + millisecond = 0; + } + } else { + hour = 0; + minute = 0; + second = 0; + millisecond = 0; + } + + var tzhour = 0; + var tzminute = 0; + // parse time zone + if (buffer.charAt(p) != 'Z' && buffer.charAt(p) != '') { + var sign = (buffer.charAt(p) == '-' ? -1 : +1); + p++; + tzhour = sign * buffer.substr(p, 2); + p += 3; + tzminute = sign * buffer.substr(p, 2); + } + + var thisDate = new Date(); + thisDate.setUTCFullYear(year); + thisDate.setUTCMonth(month - 1); + thisDate.setUTCDate(day); + thisDate.setUTCHours(hour); + thisDate.setUTCMinutes(minute); + thisDate.setUTCSeconds(second); + thisDate.setUTCMilliseconds(millisecond); + thisDate.setUTCHours(thisDate.getUTCHours() - tzhour); + thisDate.setUTCMinutes(thisDate.getUTCMinutes() - tzminute); + return thisDate; +} +xs_dateTime_to_date.visible = false; + +function scheme(url) { + var s = url.substring(0, url.indexOf(':')); + return s; +} +scheme.visible = false; + +function domain(url) { + var d = url.substring(url.indexOf('://') + 3, url.indexOf('/', url.indexOf('://') + 3)); + return d; +} +domain.visible = false; + +function domainNoPort(url) { + var d = domain(url); + if (d.indexOf(":") >= 0) + d = d.substring(0, d.indexOf(':')); + return d; +} +domainNoPort.visible = false; + +try { + var secureEndpoint = ""; + var pageUrl = document.URL; + var pageScheme = scheme(pageUrl); + // only attempt fixup if we're from an http/https domain ('file:' works fine on IE without fixup) + if (pageScheme == "http" || pageScheme == "https") { + var pageDomain = domain(pageUrl); + var pageDomainNoPort = domainNoPort(pageUrl); + var endpoints = ProcessManagementService._endpointDetails; + // loop through each available endpoint + for (var i in endpoints) { + var address = endpoints[i].address; + // if we're in a secure domain, set the endpoint to the first secure endpoint we come across + if (secureEndpoint == "" && pageScheme == "https" && scheme(address) == "https") { + secureEndpoint = i; + ProcessManagementService.endpoint = secureEndpoint; + } + // if we're in a known localhost domain, rewrite the endpoint domain so that we won't get + // a bogus xss violation + if (pageDomainNoPort.indexOf('localhost') == 0 || pageDomainNoPort.indexOf('127.0.0.1') == 0) { + endpoints[i].address = address.replace(domainNoPort(address), pageDomainNoPort); + } + } + } +} catch (e) { +} +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/WSRequest.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/WSRequest.js new file mode 100644 index 0000000..d35c99f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/WSRequest.js
@@ -0,0 +1,1196 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + +// This file introduces two classes: WSRequest for invoking a Web Service, and WebServiceError to encapsulate failure information. + +var WSRequest = function() { + // properties and usage mirror XMLHTTPRequest + this.readyState = 0; + this.responseText = null; + this.responseXML = null; + this.error = null; + this.onreadystatechange = null; + // Some internal properties + this._xmlhttp = WSRequest.util._createXMLHttpRequestObject(); + this._soapVer = null; + this._async = true; + this._optionSet = null; + this._uri = null; + this._username = null; + this._password = null; +}; + +var WebServiceError = function(reason, detail, code) { + this.reason = reason; + this.detail = detail; + this.code = code; + this.toString = function() { return this.reason; }; +}; + +/** + * @description Prepare a Web Service Request . + * @method open + * @public + * @static + * @param {object} options + * @param {string} URL + * @param {boolean} asyncFlag + * @param {string} username + * @param {string} password + */ +WSRequest.prototype.open = function(options, URL, asnycFlag, username, password) { + if (arguments.length < 2 || arguments.length > 6) + { + throw new WebServiceError("Invalid input argument", "WSRequest.open method requires 2 to 6 arguments, but " + arguments.length + (arguments.length == 1 ? " was" : " were") + " specified."); + } + + if (typeof(options) == "string") { + this._optionSet = new Array(); + this._optionSet["HTTPMethod"] = options; + } else { + this._optionSet = options; + } + + this._uri = URL; + this._async = asnycFlag; + if (username != null && password == null) + throw new WebServiceError("User name should be accompanied by a password", "WSRequest.open invocation specified username: '" + username + "' without a corresponding password."); + else + { + this._username = username; + this._password = password; + } + + this.readyState = 1; + if (this.onreadystatechange != null) + this.onreadystatechange(); + this.responseText = null; + this.responseXML = null; + this.error = null; +}; + +/** + * @description Send the payload to the Web Service. + * @method send + * @public + * @static + * @param {dom} response xml payload + */ +WSRequest.prototype.send = function(payload) { + if (arguments.length > 1) { + throw new WebServiceError("Invalid input argument.", "WSRequest.send() only accepts a single argument, " + arguments.length + " were specified."); + } + + // request body formatted as a string + var req = null; + + var method; + if (this._optionSet["HTTPMethod"] != null) + method = this._optionSet["HTTPMethod"]; + else + method = "POST"; + + this._soapVer = WSRequest.util._bindingVersion(this._optionSet); + + if (payload != null) + { + // seralize the dom to string + var content = WSRequest.util._serializeToString(payload); + if (typeof(content) == "boolean" && content == false) { + throw new WebServiceError("Invalid input argument.", "WSRequest.send() unable to serialize XML payload."); + } + + } + + // formulate the message envelope + if (this._soapVer == 0) { + var processed = WSRequest.util._buildHTTPpayload(this._optionSet, this._uri, content); + req = processed["body"]; + this._uri = processed["url"]; + } else { + req = WSRequest.util._buildSOAPEnvelope(this._soapVer, this._optionSet, this._uri, content, this._username, this._password); + } + + // Note that we infer soapAction from the "action" parameter - also used for wsa:Action. + // WS-A recommends keeping these two items in sync. + var soapAction = this._optionSet["action"]; + + try { + netscape.security.PrivilegeManager.enablePrivilege("UniversalBrowserRead"); + } catch(e) { + } + + var accessibleDomain = true; // assume so for now + try { + this._xmlhttp.open(method, this._uri, this._async, this._username, this._password); + + // Process protocol-specific details + switch (this._soapVer) { + case 1.1: + soapAction = (soapAction == undefined ? '""' : '"' + soapAction + '"'); + this._xmlhttp.setRequestHeader("SOAPAction", soapAction); + this._xmlhttp.setRequestHeader("Content-Type", "text/xml; charset=UTF-8"); + break; + case 1.2: + this._xmlhttp.setRequestHeader("Content-Type", "application/soap+xml;charset=UTF-8" + (soapAction == undefined ? "" : ";action=" + soapAction)); + break; + case 0: + var contentType; + if (this._optionSet["HTTPInputSerialization"] != null) { + contentType = this._optionSet["HTTPInputSerialization"] + } else { + if (method == "GET" | method == "DELETE") { + contentType = "application/x-www-form-urlencoded"; + } else { + contentType = "application/xml"; + } + } + this._xmlhttp.setRequestHeader("Content-Type", contentType); + break; + } + } catch (e) { + // If we received an error, see if it's an XSS error, if so don't fail - there still might be hope! + if (e.description == "Access is denied.\r\n" || e.toString() == "Permission denied to call method XMLHttpRequest.open") { + try { + // Are we in the context of a Google Gadget? + accessibleDomain = _IG_FetchXmlContent == undefined; + } catch (d) { + throw e; + } + } else throw e; + } + + if (accessibleDomain) { + if (this._async) { + // async call + this._xmlhttp.onreadystatechange = WSRequest.util._bind(this._handleReadyState, this); + this._xmlhttp.send(req); + } else { + // sync call + this.readyState = 2; + if (this.onreadystatechange != null) + this.onreadystatechange(); + + this._xmlhttp.send(req); + + this._processResult(); + if (this.error != null) + throw (this.error); + + this.readyState = 4; + if (this.onreadystatechange != null) + this.onreadystatechange(); + } + } else { + // Fallback to a Google Gadget, if we're able too. + if (!this._async) + throw ("Can only access Web service from within a Google Gadget when a callback is defined."); + if (this._soapVer != 0 || method.toUpperCase() != "GET") + throw ("Can only access Web service from within a Google Gadget through the HTTP binding, using the GET method."); + + this.readyState = 2; + if (this.onreadystatechange != null) + this.onreadystatechange(); + + _IG_FetchXmlContent(this._uri, WSRequest.util._bind(this._FetchXMLContentCallback, this)); + } +} + +/** + * @description Google Gadget request callback - simulate an XMLHttp callback and return to normal processing. + * @method _FetchXMLContentCallback + * @private + * @static + * @param {dom} response xml payload + */ +WSRequest.prototype._FetchXMLContentCallback = function (response) { + if (response != null && typeof(response) == "object") { + this._xmlhttp = { + "responseXML" : response, + "responseText" : WSRequest.util._serializeToString(response), + "status" : "200", + "readyState" : 4 + }; + } else { + this._xmlhttp = { + "responseXML" : null, + "responseText" : response, + "status" : "", + "statusText" : "_IG_FetchXMLContent failed to return valid XML.", + "readyState" : 4 + }; + } + this._handleReadyState(); +} + +/** + * @description Set responseText, responseXML, and error of WSRequest. + * @method _processResult + * @private + * @static + */ +WSRequest.prototype._processResult = function () { + var httpstatus; + if (this._soapVer == 0) { + this.responseText = this._xmlhttp.responseText; + this.responseXML = this._xmlhttp.responseXML; + + httpstatus = this._xmlhttp.status; + if (httpstatus == '200' || httpstatus == '202') { + this.error = null; + } else { + this.error = new WebServiceError(this._xmlhttp.statusText, this.responseText, "HTTP " + this._xmlhttp.status); + } + } else { + var browser = WSRequest.util._getBrowser(); + + if (this._xmlhttp.responseText != "") { + var response; + var responseXMLdoc; + if (browser == "ie" || browser == "ie7") { + if (this._xmlhttp.responseXML.documentElement == null) { + // unrecognized media type (probably application/soap+xml) + responseXMLdoc = new ActiveXObject("Microsoft.XMLDOM"); + responseXMLdoc.loadXML(this._xmlhttp.responseText); + response = responseXMLdoc.documentElement; + } else { + response = this._xmlhttp.responseXML.documentElement; + } + } else { + var parser = new DOMParser(); + responseXMLdoc = parser.parseFromString(this._xmlhttp.responseText,"text/xml"); + response = responseXMLdoc.documentElement; + response.normalize(); //fixes data getting truncated at 4096 characters + } + var soapNamespace; + if (this._soapVer == 1.1) + soapNamespace = "http://schemas.xmlsoap.org/soap/envelope/"; + else + soapNamespace = "http://www.w3.org/2003/05/soap-envelope"; + + var soapBody = WSRequest.util._firstElement(response, soapNamespace, "Body"); + if (soapBody != null && soapBody.hasChildNodes()) { + var newDoc; + if (browser == "ie" || browser == "ie7") { + newDoc = new ActiveXObject("Microsoft.XMLDOM"); + newDoc.appendChild(soapBody.firstChild); + } else { + newDoc = document.implementation.createDocument("", "", null); + newDoc.appendChild(soapBody.firstChild.cloneNode(true)); + } + + this.responseXML = newDoc; + this.responseText = WSRequest.util._serializeToString(newDoc); + + fault = WSRequest.util._firstElement(newDoc, soapNamespace, "Fault"); + if (fault != undefined) { + this.error = new WebServiceError(); + if (this._soapVer == 1.2) { + this.error.code = WSRequest.util._stringValue(WSRequest.util._firstElement(fault, soapNamespace, "Value")); + this.error.reason = WSRequest.util._stringValue(WSRequest.util._firstElement(fault, soapNamespace, "Text")); + this.error.detail = WSRequest.util._firstElement(fault, soapNamespace, "Detail"); + } else { + this.error.code = WSRequest.util._stringValue(fault.getElementsByTagName("faultcode")[0]); + this.error.reason = WSRequest.util._stringValue(fault.getElementsByTagName("faultstring")[0]); + this.error.detail = fault.getElementsByTagName("detail")[0]; + } + } + } else { + // empty SOAP body - not necessarily an error + this.responseXML = null; + this.responseText = ""; + this.error = null; + } + } else { + // If this block being executed; it's due to server connection has falied. + this.responseXML = null; + this.responseText = ""; + try { + httpstatus = this._xmlhttp.status; + if (httpstatus == '200' || httpstatus == '202') { + this.error = null; + } else { + this.error = new WebServiceError(); + this.error.code = "HTTP " + this._xmlhttp.status; + this.error.reason = "Server connection has failed."; + this.error.detail = this._xmlhttp.statusText; + } + } catch (e) { + this.error = new WebServiceError(); + this.error.code = null; + this.error.reason = "Server connection has failed."; + this.error.detail = e.toString(); + } + } + } +} + +/** + * @description XMLHttp callback handler. + * @method _handleReadyState + * @private + * @static + */ +WSRequest.prototype._handleReadyState = function() { + if (this._xmlhttp.readyState == 2) { + this.readyState = 2; + if (this.onreadystatechange != null) + this.onreadystatechange(); + } + + if (this._xmlhttp.readyState == 3) { + this.readyState = 3; + if (this.onreadystatechange != null) + this.onreadystatechange(); + } + + if (this._xmlhttp.readyState == 4) { + this._processResult(); + + this.readyState = 4; + if (this.onreadystatechange != null) + this.onreadystatechange(); + } +}; + + +// Utility functions + +WSRequest.util = { + + _msxml : [ + 'MSXML2.XMLHTTP.3.0', + 'MSXML2.XMLHTTP', + 'Microsoft.XMLHTTP' + ], + + /** + * @description Instantiates a XMLHttpRequest object and returns it. + * @method _createXMLHttpRequestObject + * @private + * @static + * @return object + */ + _createXMLHttpRequestObject : function() { + var xhrObject; + + try { + xhrObject = new XMLHttpRequest(); + } catch(e) { + for (var i = 0; i < this._msxml.length; ++i) { + try + { + // Instantiates XMLHttpRequest for IE and assign to http. + xhrObject = new ActiveXObject(this._msxml[i]); + break; + } + catch(e) { + // do nothing + } + } + } finally { + return xhrObject; + } + }, + + /** + * @description Serialize payload to string. + * @method _serializeToString + * @private + * @static + * @param {dom} payload xml payload + * @return string + */ + _serializeToString : function(payload) { + if (payload == null) return null; + if (typeof(payload) == "string") { + return payload; + } else if (typeof(payload) == "object") { + var browser = WSRequest.util._getBrowser(); + switch (browser) { + case "gecko": + case "safari": + var serializer = new XMLSerializer(); + return serializer.serializeToString(payload); + break; + case "ie": + case "ie7": + return payload.xml; + break; + case "opera": + var xmlSerializer = document.implementation.createLSSerializer(); + return xmlSerializer.writeToString(payload); + break; + case "undefined": + throw new WebServiceError("Unknown browser", "WSRequest.util._serializeToString doesn't recognize the browser, to invoke browser-specific serialization code."); + } + } else { + return false; + } + }, + + + /** + * @description get the character element children in a browser-independent way. + * @method _stringValue + * @private + * @static + * @param {dom element} node + * @return string + */ + _stringValue : function(node) { + var browser = WSRequest.util._getBrowser(); + switch (browser) { + case "ie": + case "ie7": + return node.text; + break; + case "gecko": + case "opera": + case "safari": + case "undefined": + var value = ""; + if (node.nodeType == 3) { + value = node.nodeValue; + } else { + for (var i = 0; i < node.childNodes.length; i++) { + value += WSRequest.util._stringValue(node.childNodes[i]); + } + } + return value; + break; + } + }, + + + /** + * @description Determines which binding to use (SOAP 1.1, SOAP 1.2, or HTTP) from the various options. + * @method _bindingVersion + * @private + * @static + * @param {Array} options Options given by user + * @return string + */ + _bindingVersion : function(options) { + var soapVer; + switch (options["useBindng"]) { + case "SOAP 1.2": + soapVer = 1.2; + break; + case "SOAP 1.1": + soapVer = 1.1; + break; + case "HTTP": + soapVer = 0; + break; + case undefined: + var useSOAP = options["useSOAP"]; + switch (useSOAP) { + case 1.2: + soapVer = 1.2; + break; + case "1.2": + soapVer = 1.2; + break; + case 1.1: + soapVer = 1.1; + break; + case "1.1": + soapVer = 1.1; + break; + case true: + soapVer = 1.2; + break; + case false: + soapVer = 0; + break; + case undefined: + throw("Unspecified binding type: set useBinding = 'SOAP 1.1' | 'SOAP 1.2' | 'HTTP'."); + break; + default: + throw("Unsupported useSOAP value '" + useSOAP + "'; set 'useBinding' option instead."); + } + break; + default: + throw("Unsupported useBinding value '" + options["useBinding"] + "': must be 'SOAP 1.2' | 'SOAP 1.1' | 'HTTP'."); + } + return soapVer; + }, + + + /** + * @description Determine which browser we're running. + * @method _getBrowser + * @private + * @static + * @return string + */ + _getBrowser : function() { + var ua = navigator.userAgent.toLowerCase(); + if (ua.indexOf('opera') != -1) { // Opera (check first in case of spoof) + return 'opera'; + } else if (ua.indexOf('msie 7') != -1) { // IE7 + return 'ie7'; + } else if (ua.indexOf('msie') != -1) { // IE + return 'ie'; + } else if (ua.indexOf('safari') != -1) { // Safari (check before Gecko because it includes "like Gecko") + return 'safari'; + } else if (ua.indexOf('gecko') != -1) { // Gecko + return 'gecko'; + } else { + return false; + } + }, + + + /** + * @description Build HTTP payload using given parameters. + * @method _buildHTTPpayload + * @private + * @static + * @param {Array} options Options given by user + * @param {string} url Address the request will be sent to. + * @param {string} content SOAP payload in string format. + * @return {array} Containing the processed URL and request body. + */ + _buildHTTPpayload : function(options, url, content) { + // Create array to hold request uri and body. + var resultValues = new Array(); + resultValues["url"] = ""; + resultValues["body"] = ""; + var paramSeparator = "&"; + var inputSerialization; + + var HTTPQueryParameterSeparator = "HTTPQueryParameterSeparator"; + var HTTPInputSerialization = "HTTPInputSerialization"; + var HTTPLocation = "HTTPLocation"; + var HTTPMethod = "HTTPMethod"; + + // If a parameter separator has been identified, use it instead of the default &. + if (options[HTTPQueryParameterSeparator] != null) { + paramSeparator = options[HTTPQueryParameterSeparator]; + } + + // If input serialization is not specified, default based on HTTP Method. + if (options[HTTPInputSerialization] == null) { + if (options[HTTPMethod] == "GET" | options[HTTPMethod] == "DELETE") { + inputSerialization = "application/x-www-form-urlencoded"; + } else { + inputSerialization = "application/xml"; + } + } else { + inputSerialization = options[HTTPInputSerialization]; + } + + //create new document from string + var xmlDoc; + + // Parser is browser specific. + var browser = WSRequest.util._getBrowser(); + if (browser == "ie" || browser == "ie7") { + //create a DOM from content string. + xmlDoc = new ActiveXObject("Microsoft.XMLDOM"); + if (content != null && content != "") + xmlDoc.loadXML(content); + } else { + //create a DOMParser to get DOM from content string. + var xmlParser = new DOMParser(); + if (content != null && content != "") + xmlDoc = xmlParser.parseFromString(content, "text/xml"); + } + + // If the payload is to be URL encoded, other options have to be examined. + if (inputSerialization == "application/x-www-form-urlencoded" || inputSerialization == "application/xml") { + + resultValues["url"] = options[HTTPLocation]; + + // If templates are specified and a valid payload is available, process, else just return original URI. + if (options[HTTPLocation] != null && xmlDoc != null && xmlDoc.hasChildNodes()) { + // Ideally .documentElement should be used instead of .firstChild, but this does not work. + var rootNode = xmlDoc.firstChild; + + // Process payload, distributing content across the URL and body as specified. + resultValues = WSRequest.util._processNode(options, resultValues, rootNode, paramSeparator, + inputSerialization); + + } + // Globally replace any remaining template tags with empty strings. + var allTemplateRegex = new RegExp("\{.*\}", "ig"); + resultValues["url"] = resultValues["url"].replace(allTemplateRegex, ""); + + // Append processed HTTPLocation value to URL. + resultValues["url"] = WSRequest.util._joinUrlToLocation(url, resultValues["url"]); + + // Sending the XML in the request body. + if (content != null && inputSerialization == "application/xml") { + resultValues["body"] = content; + } + } else if (inputSerialization == "multipart/form-data") { + // Just throw an exception for now - will try to use browser features in a later release. + throw new WebServiceError("Unsupported serialization option.", "WSRequest.util._buildHTTPpayload doesn't yet support multipart/form-data serialization."); + } + return resultValues; + }, + + /** + * @description Traverse the DOM tree below a given node, retreiving the content of each node and appending it to the + * URL or the body of the request based on the options specified. + * @method _processNode + * @private + * @static + * @param {Array} options Options given by user. + * @param {Array} resultValues HTTP Location content and request body. + * @param {XML} node SOAP payload as an XML object. + * @param {string} paramSeparator Separator character for URI parameters. + * @return {array} Containing the processed HTTP Location content and request body. + */ + _processNode : function(options, resultValues, node, paramSeparator, inputSerialization) { + var queryStringSep = '?'; + var HTTPLocationIgnoreUncited = "HTTPLocationIgnoreUncited"; + var HTTPMethod = "HTTPMethod"; + + // Traverse the XML and add the contents of each node to the URL or body. + do { + + // Recurse if node has children. + if (node.hasChildNodes()) + { + resultValues = WSRequest.util._processNode(options, resultValues, node.firstChild, paramSeparator, + inputSerialization); + } + + // Check for availability of node name and data before processing. + if (node.nodeValue != null) { + var tokenName = WSRequest.util._nameForValue(node); + + // Create a regex to look for the token. + var templateRegex = new RegExp("\{" + tokenName + "\}", "i"); + var unencTmpltRegex = new RegExp("\{!" + tokenName + "\}", "i"); + var tokenLocn; + + // If the token is in the URL - swap tokens with values. + if ((tokenLocn = resultValues["url"].search(templateRegex)) != -1) { + // Replace the token with the URL encoded node value. + var isQuery = resultValues["url"].substring(0, tokenLocn).indexOf('?') != -1; + resultValues["url"] = resultValues["url"].replace(templateRegex, + WSRequest.util._encodeString(node.nodeValue, isQuery)); + } else if (resultValues["url"].search(unencTmpltRegex) != -1) { + // Replace the token with the node value, witout encoding. + resultValues["url"] = resultValues["url"].replace(templateRegex, node.nodeValue); + } else { + var parameter = ""; + + // If the node has a list, create a bunch of name/value pairs, otherwise a single pair. + if (WSRequest.util._attributesContain(node.parentNode, "xsd:list")) { + var valueList = new Array(); + valueList = node.nodeValue.split(' '); + for (var valueNum = 0; valueNum < valueList.length; valueNum++) { + parameter = parameter + tokenName + "=" + WSRequest.util._encodeString(valueList[valueNum], + true); + + // Add the parameter separator after each list value except the last. + if (valueNum < (valueList.length - 1)) { + parameter += paramSeparator; + } + } + } else { + parameter = tokenName + "=" + WSRequest.util._encodeString(node.nodeValue, true); + } + + // If ignore uncited option has been set, append parameters to body else to the url. + if (options[HTTPLocationIgnoreUncited] != null && options[HTTPLocationIgnoreUncited]) { + + // Add to request body if the serialization option and request type allows it. + if (inputSerialization == "application/x-www-form-urlencoded" && (options[HTTPMethod] == "POST" + || options[HTTPMethod] == "PUT")) { + + // Assign or append additional parameters. + if (resultValues["body"] == "") { + resultValues["body"] = parameter; + } else { + resultValues["body"] = resultValues["body"] + paramSeparator + parameter; + } + } + + } else { + // If he URL does not contain ? add it and then the parameter. + if (resultValues["url"].indexOf(queryStringSep) == -1) { + resultValues["url"] = resultValues["url"] + queryStringSep + parameter; + } else { + // ...otherwise just append the uncited value. + resultValues["url"] = resultValues["url"] + paramSeparator + parameter; + } + } + } + } + } while (node = node.nextSibling) + + return resultValues; + }, + + /** + * @description Build soap message using given parameters. + * @method _buildSoapEnvelope + * @private + * @static + * @param {string} soapVer SOAP version (1.1 or 1.2) + * @param {Array} options Options given by user + * @param {string} url Address the request will be sent to. + * @param {string} content SOAP payload + * @param {string} username Optional username + * @param {string} password Optional password + * @return string + */ + _buildSOAPEnvelope : function(soapVer, options, url, content, username, password) { + var ns; + if (soapVer == 1.1) + ns = "http://schemas.xmlsoap.org/soap/envelope/"; + else + ns = "http://www.w3.org/2003/05/soap-envelope"; + + var headers = ""; + + // addressing version/namespace + var useWSA = options["useWSA"]; + var wsaNs = ""; + var wsaNsDecl = ""; + var usingWSA = false; + if (useWSA != undefined && useWSA) { + var standardversion; + if (useWSA == "1.0" || useWSA) { + wsaNs = "http://www.w3.org/2005/08/addressing"; + standardversion = true; + } else if (useWSA == "submission") { + wsaNs = "http://schemas.xmlsoap.org/ws/2004/08/addressing"; + standardversion = false; + } else throw ("Unknown WS-Addressing version '" + useWSA + "': must be '1.0' | 'submission' | true | false."); + wsaNsDecl = ' xmlns:wsa="' + wsaNs + '"'; + headers = this._buildWSAHeaders(standardversion, options, url); + usingWSA = true; + } + var useWSS = options["useWSS"]; + if (useWSS != undefined && useWSS) { + if (!usingWSA) { + throw ('In order to use WS Security, WS Addressing should be enabled. Please set "options["useWSA"] = true"'); + } + var created = new Date(); + headers += '<o:Security s:mustUnderstand="1" xmlns:u="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" ' + + 'xmlns:o="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd">' + + '<u:Timestamp u:Id="uuid-c3cdb38b-e4aa-4467-9d0e-dd30f081e08d-5">' + + '<u:Created>' + WSRequest.util._toXSdateTime(created) + '</u:Created>' + + '<u:Expires>' + WSRequest.util._toXSdateTime(created, 5) + '</u:Expires>' + + '</u:Timestamp>' + + '<o:UsernameToken u:Id="Me" >' + + '<o:Username>' + username + '</o:Username>' + + '<o:Password Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">' + password + '</o:Password>' + + '</o:UsernameToken>' + + '</o:Security>'; + } + + var request = '<?xml version="1.0" encoding="UTF-8"?>\n' + + '<s:Envelope xmlns:s="' + ns + '"' + + wsaNsDecl + '>\n' + + '<s:Header>' + headers + '</s:Header>\n' + + '<s:Body>' + (content != null ? content : '') + '</s:Body>\n' + + '</s:Envelope>'; + return request; + }, + + /** + * @description Build WS-Addressing headers using given parameters. + * @method _buildWSAHeaders + * @private + * @static + * @param {boolean} standardversion true for 1.0, false for submission + * @param {Array} options Options given by user + * @param {string} address Address the request will be sent to. + * @return string + */ + _buildWSAHeaders : function(standardversion, options, address) { + if (options['action'] == null) + throw("'Action' option must be specified when WS-Addressing is engaged."); + + // wsa:To (required) + var headers = "<wsa:To>" + address + "</wsa:To>\n"; + + // wsa:From (optional) + // Note: reference parameters and metadata aren't supported. + if (options['from'] != null) + headers += "<wsa:From><wsa:Address>" + options['From'] + "</wsa:Address></wsa:From>\n"; + + // wsa:ReplyTo (optional) + // Note: reference parameters and metadata aren't supported. + // Note: No way to specify that wsa:ReplyTo should be omitted (e.g., only in-out MEPs are supported). + if (options['replyto'] != null) { + headers += "<wsa:ReplyTo><wsa:Address>" + options['ReplyTo'] + "</wsa:Address></wsa:ReplyTo>\n"; + } else { + // Note: although wsa:ReplyTo is optional on in-out MEPs in the standard version, we put it in + // explicitly for convenience. + headers += "<wsa:ReplyTo><wsa:Address>" + + ( standardversion ? + "http://www.w3.org/2005/08/addressing/anonymous" : + "http://schemas.xmlsoap.org/ws/2004/08/addressing/role/anonymous" + ) + + "</wsa:Address></wsa:ReplyTo>\n"; + } + + // wsa:MessageID (required if a response is expected, e.g. wsa:ReplyTo is specified, which is always for us.) + // If user doesn't supply an identifier, we'll make one up. + var id; + if (options['messageid'] != null) { + id = options['messageid']; + } else { + // coin a unique identifier based on the time (in milliseconds) and a 10-digit random number. + var now = (new Date()).valueOf(); + var randomToken = Math.floor(Math.random() * 10000000000); + id = "http://identifiers.wso2.com/messageid/" + now + "/" + randomToken; + } + headers += "<wsa:MessageID>" + id + "</wsa:MessageID>\n"; + + // wsa:FaultTo (optional) + // Note: reference parameters and metadata aren't supported. + if (options['faultto'] != null) + headers += "<wsa:FaultTo><wsa:Address>" + options['FaultTo'] + "</wsa:Address></wsa:FaultTo>\n"; + + // wsa:Action (required) + headers += "<wsa:Action>" + options['action'] + "</wsa:Action>\n" + + return headers; + } + , + + /** + * @description Set scope for callbacks. + * @method _getRealScope + * @private + * @static + * @param {Function} fn + * @return Function + */ + _getRealScope : function(fn) { + var scope = window; + if (fn._cscope) scope = fn._cscope; + return function() { + return fn.apply(scope, arguments); + } + }, + + /** + * @description Bind a function to the correct scope for callbacks + * @method _bind + * @private + * @static + * @param {Function} fn + * @param {Object} obj + * @return Function + */ + _bind : function(fn, obj) { + fn._cscope = obj; + return this._getRealScope(fn); + + }, + + + /** + * @description Normalize browser-specific differences in getElementsByTagName + * @method _firstElement + * @private + * @static + * @param {dom} node + * @param {string} namespace + * @param {string} localName + * @return element + */ + _firstElement : function (node, namespace, localName) { + if (node == null) return null; + var browser = WSRequest.util._getBrowser(); + var doc, el; + if (browser == "ie" || browser == "ie7") { + if (node.nodeType == 9) + doc = node; + else + doc = node.ownerDocument; + doc.setProperty("SelectionNamespaces", "xmlns:soap='" + namespace + "'"); + el = node.selectSingleNode(".//soap:" + localName); + } else { + // Some Firefox DOMs recognize namespaces ... + el = node.getElementsByTagNameNS(namespace, localName)[0]; + if (el == undefined) + // ... and some don't. + el = node.getElementsByTagName(localName)[0]; + } + return el; + }, + + + /** + * @description Returns the name of a given DOM text node, managing browser issues + * @method _nameForValue + * @private + * @static + * @param {dom} node + * @return string + */ + _nameForValue : function(node) { + var browser = WSRequest.util._getBrowser(); + var nodeNameVal; + + // IE localName property does not work, so extract from node name. + if (browser == "ie" || browser == "ie7") { + var fullName = WSRequest.util._isEmpty(node.nodeName) ? node.parentNode.nodeName : node.nodeName; + nodeNameVal = fullName.substring(fullName.indexOf(":") + 1, fullName.length); + } else { + nodeNameVal = WSRequest.util._isEmpty(node.localName) ? node.parentNode.localName : node.localName; + } + return nodeNameVal; + }, + + + /** + * @description Determins if a node string value is null or empty, managing browser issues + * @method _isEmpty + * @private + * @static + * @param {*} value + * @return boolean + */ + _isEmpty : function(value) { + // Regex for determining if a given string is empty. + var emptyRegEx = /^[\s]*$/; + + // Short circuit if null, otherwise check for empty. + return (value == null || value == "#text" || emptyRegEx.test(value)); + }, + + + /** + * @description Returns true if the attributes of the node contain a given value. + * @method _attributeContain + * @private + * @static + * @param {dom node} node + * @param {string} value + * @return boolean + */ + _attributesContain : function(node, value) { + var hasValue = false; + + // If node has attributes... + if (node.attributes.length > 0) { + // ...cycle through them and check for the value. + for (var attNum = 0; attNum < node.attributes.length; attNum++) { + if (node.attributes[attNum].nodeValue == value) { + hasValue = true; + break; + } + } + } + return hasValue; + }, + + + /** + * @description Appends the template string to the URI, ensuring that the two are separated by a ? or a /. Performs a + * merge if the start of the template is the same as the end of the URI, which will resolve at joining until a + * full resolution function can be developed. + * @method _joinUrlToLocation + * @private + * @static + * @param {string} endpointUri Base URI. + * @param {string} templateString Processed contents of the HTTPLocation option. + * @return string URI with the template string appended. + */ + _joinUrlToLocation : function(endpointUri, templateString) { + + // JS implementation of pseudo-code found at http://www.ietf.org/rfc/rfc3986.txt sec 5.2.2 + function parse(url) { + var result = {"scheme" : null, "authority" : null, "path" : null, "query": null, "fragment" : null}; + + result.fragment = url.indexOf("#") < 0 ? null : url.substring(url.indexOf("#") + 1); + url = result.fragment == null ? url : url.substring(0, url.indexOf("#")); + result.query = url.indexOf("?") < 0 ? null : url.substring(url.indexOf("?") + 1); + url = result.query == null ? url : url.substring(0, url.indexOf("?")); + if (url.indexOf(':') > 0) { + result.scheme = url.substring(0, url.indexOf(":")); + url = url.substring(url.indexOf(":") + 1); + } + if (url.indexOf("//") == 0){ + url = url.substring(2); + result.authority = url.substring(0, url.indexOf("/")); + result.path = url.substring(url.indexOf("/")); + } else result.path = url; + return result; + } + + function merge(base, relative) { + if (base.authority != null && base.path == "") { + return "/" + relative.path; + } else { + if (base.path.indexOf("/") < 0) { + return relative.path; + } else { + var path = base.path.substring(0, base.path.lastIndexOf("/") + 1); + return path + relative.path; + } + } + } + + function removeDotSegments (path) { + var input = path; + var output = ""; + + while (input.length > 0) { + if (input.indexOf("../") == 0 || input.indexOf("./") == 0) { + input = input.substring(input.indexOf("./")); + } else { + if (input.indexOf("/./") == 0 || (input.indexOf("/.") == 0 && input.length == 2)) { + input = input.substring(2); + if (input.length == 0) input = "/"; + } else { + if (input.indexOf("/../") == 0 || (input.indexOf("/..") == 0 && input.length == 3)) { + input = input.substring(3); + if (input.length == 0) input = "/"; + output = output.substring(0, output.lastIndexOf("/")); + } else { + if (input == "." || input == "..") { + input=""; + } else { + if (input.indexOf("/") == 0) { + output += "/"; + input = input.substring(1); + } + var i = input.indexOf("/"); + if (i < 0) i = 10000; + output += input.substring(0, i); + input = input.substring(i); + } + } + } + } + } + return output; + } + + var base = parse(endpointUri); + var relative = parse(templateString); + var result = {"scheme" : null, "authority" : null, "path" : null, "query": null, "fragment" : null}; + + if (relative.scheme != null) { + result.scheme = relative.scheme; + result.authority = relative.authority; + result.path = removeDotSegments(relative.path); + result.query = relative.query; + } else { + if (relative.authority != null) { + result.authority = relative.authority; + result.path = removeDotSegments(relative.path); + result.query = relative.query; + } else { + if (relative.path == "") { + result.path = base.path; + if (relative.query != null) { + result.query = relative.query; + } else { + result.query = base.query; + } + } else { + if (relative.path.indexOf("/") == 0) { + result.path = removeDotSegments(relative.path); + } else { + result.path = merge(base, relative); + result.path = removeDotSegments(result.path); + } + result.query = relative.query; + } + result.authority = base.authority; + } + result.scheme = base.scheme; + } + result.fragment = relative.fragment; + + var resultURI = ""; + if (result.scheme != null) resultURI += result.scheme + ":"; + if (result.authority != null) resultURI += "//" + result.authority; + resultURI += result.path; + if (result.query != null) resultURI += "?" + result.query; + if (result.fragment != null) resultURI += "#" + result.fragment; + return resultURI; + }, + + + /** + * @description Encodes a given string in either path or query parameter format. + * @method _encodeString + * @private + * @static + * @param {string} srcString String to be encoded. + * @param {boolean} queryParm Indicates that the string is a query parameter and not a part of the path. + * @return string URL encoded string. + */ + _encodeString : function (srcString, queryParm) { + var legalInPath = "-._~!$'()*+,;=:@"; + var legalInQuery = "-._~!$'()*+,;=:@/?"; + + var legal = queryParm ? legalInQuery : legalInPath; + var encodedString = ""; + for (var i = 0; i < srcString.length; i++) { + var ch = srcString.charAt(i); + if ((ch >= 'a' && ch <= 'z') + || (ch >= 'A' && ch <= 'Z') + || (ch >= '0' && ch <= '9') + || legal.indexOf(ch) > -1) { + encodedString += ch; + } else { + // Function encodeURIComponent will not encode ~!*()' but they are legal anyway. + encodedString += encodeURIComponent(ch); + } + } + return encodedString; + }, + + + /** + * @description Convert a Date to an xs:dateTime string + * @method _toXSdateTime + * @private + * @static + * @param {Date} thisDate Date to be serialized. + * @param {number} delta Optional offset to serialize a time delta seconds in the future. + * @return string + */ + _toXSdateTime : function (thisDate, delta) { + if (delta == null) delta = 0; + + var year = thisDate.getUTCFullYear(); + var month = thisDate.getUTCMonth() + 1; + var day = thisDate.getUTCDate(); + var hours = thisDate.getUTCHours(); + var minutes = thisDate.getUTCMinutes(); + var seconds = thisDate.getUTCSeconds() + delta; + var milliseconds = thisDate.getUTCMilliseconds(); + + return year + "-" + + (month < 10 ? "0" : "") + month + "-" + + (day < 10 ? "0" : "") + day + "T" + + (hours < 10 ? "0" : "") + hours + ":" + + (minutes < 10 ? "0" : "") + minutes + ":" + + (seconds < 10 ? "0" : "") + seconds + + (milliseconds == 0 ? "" : (milliseconds/1000).toString().substring(1)) + "Z"; + } +}; +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/accordion.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/accordion.js new file mode 100644 index 0000000..4241058 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/accordion.js
@@ -0,0 +1,395 @@ +/* +Copyright (c) 2007, Caridy Patino. All rights reserved. +Portions Copyright (c) 2007, Yahoo!, Inc. All rights reserved. +Code licensed under the BSD License: +http://www.bubbling-library.com/eng/licence +version: 1.5.0 +*/ +(function() { + + var $B = YAHOO.Bubbling, + $L = YAHOO.lang, + $E = YAHOO.util.Event, + $D = YAHOO.util.Dom; + + /** + * @singleton Accordion Manager - Creating accordion controls based on the markup. + * Apply visual enhanced to an area + * @constructor + */ + YAHOO.widget.AccordionManager = function() { + var obj = {}, + _selector = 'selected', + _sliding = 'sliding', + _anims = {}; + + // on click action behaviors... + $B.addDefaultAction('accordionToggleItem', function (layer, args) { + if (!args[1].decrepitate) { + // switching the slidable area and reclaiming the behavior + return obj.toggle(args[1].target); + } + }); + $B.addDefaultAction('accordionRemoveItem', function (layer, args) { + if (!args[1].decrepitate) { + // removing an item from the accordion and reclaiming the behavior + return obj.remove(args[1].target); + } + }); + + // on event arrive + // behaviors for the second accordion (ADVANCED AJAX APPLICATION) + // Tagline: One behavior that will rule them all (based on the slide's rel attribute) + $B.on('accordionOpenItem', function (layer, args) { + var reLink = /.*#/; + // if can be loaded thru AJAX + if ($D.hasClass(args[1].slide, 'ajax') && $L.isObject(YAHOO.plugin.Dispatcher)) { + var trigger = $D.getElementsByClassName('accordionToggleItem','*',args[1].el); + trigger = (trigger.length>0?trigger[0]:null); + if (trigger && (trigger = trigger.getAttribute('href',2))) { + YAHOO.plugin.Dispatcher.fetch ( args[1].slide, trigger.replace(reLink,''), { + onLoad: function (el) { + $D.removeClass(args[1].slide, 'ajax'); + } + }); + } + } + }); + + // on keyboad action behavior... + $B.on('key', function (layer, args) { + var o = args[1], item = null, result = false; + if (!o.decrepitate && (o.type == 'keyup')) { + if (((o.keyCode === 39) && obj.open (o.target)) || + ((o.keyCode === 37) && obj.close (o.target))) { // Shortcut: cursor -> or cursor <- + // reclaiming the event & stoping the event propagation + o.decrepitate = true; + o.stop = true; + } + } + }); + + // on rollover action behavior... + $B.on('rollover', function (layer, args) { + var list, item, onWayOut; + if (item = _getItem(args[1].target)) { + if ((list = _getList(item)) && list.rollover) { + if (!list.selected) { + $D.addClass(list.el, _selector); + onWayOut = function (e) { + var l = _getList ({el:$E.getTarget(e)}); + if (l && !$B.virtualTarget(e, l.el) && !l.persistent) { + _reset(l, {force:true}); + } + }; + if (!list.persistent) { + $E.removeListener ( list.el, 'mouseout', onWayOut ); + $E.addListener ( list.el, 'mouseout', onWayOut, obj, true ); + } + } + if (!item.selected) { + // is over a new item... + _openItem(item, list); + } + } + } + }); + + // creating the most common message (behavior layer) + $B.addLayer (['accordionOpenItem', 'accordionCloseItem', 'accordionRemoveItem'], obj); + + function _getEffect ( el ) { + var effect = el.getAttribute('rel') || null; + if (effect) { + effect = YAHOO.util.Easing[effect] || null; + } + return effect; + } + function _getTimer ( el ) { + var t = ($D.hasClass(el, 'fast')?0.1:null) || ($D.hasClass(el, 'slow')?0.6:null) || 0.4; + return t; + } + function _getItem ( elem ) { + if (elem && ($L.isObject(elem) || (elem = $D.get (elem)))) { + var item, el = $B.getOwnerByClassName (elem, 'yui-cms-item'); + if ($L.isObject(el)) { + item = { + el: el, + triger: elem, + selected: $D.hasClass(el, _selector), + sliding: $D.hasClass(el, _sliding), + size: {width:0, Height: 0} + }; + // getting the slidable element + var slide = $D.getElementsByClassName('bd','*',el); + slide = (slide.length>0?slide[0]:null); + item.slide = slide; + var h = parseInt($D.getStyle(slide, 'height'), 10); + var w = parseInt($D.getStyle(slide, 'width'), 10); + // forcing to number... to avoid misbehavior on "auto" height/width... + if (!$L.isNumber(h)) { + $D.setStyle(slide, 'height', slide.scrollHeight+'px'); + } + if (!$L.isNumber(w)) { + $D.setStyle(slide, 'width', slide.scrollWidth+'px'); + } + item.size.height = slide.scrollHeight; + item.size.width = slide.scrollWidth; + } + return item; + } + } + function _getList ( item ) { + var list = null, el = item.el; + if (el && ($L.isObject(el) || (el = $D.get (el)))) { + if (el = $B.getOwnerByClassName (el, 'yui-cms-accordion')) { + // creating the list literal based on the classnames defined for the accordion wrapper + list = { + el: el, + effect: _getEffect(el), + orientation: ($D.hasClass(el, 'vertical')?'width':'height'), + selected: $D.hasClass(el, _selector), + fade: $D.hasClass(el, 'fade'), + manually: $D.hasClass(el, 'manually'), + fixIE: ($E.isIE && $D.hasClass(el, 'fixIE')), // hack for IE and quirk mode... + multiple: $D.hasClass(el, 'multiple'), + rollover: $D.hasClass(el, 'rollover'), + persistent: $D.hasClass(el, 'persistent'), + dispatcher: $D.hasClass(el, 'dispatcher'), + wizard: $D.hasClass(el, 'wizard'), + timer: _getTimer(el), + items: [] + }; + // searching for items childs... + $D.batch ($D.getElementsByClassName('bd','*',el), function(elem){ + // adding an item to the list + list.items.push (_getItem(elem)); + }); + } + return list; + } + } + function _reset ( list, params ) { + params = params || {}; + var conf = [], i, + force = params.force || false, + item = params.item || null; + if (list) { + if (!list.multiple || force) { + // closing all the selected items + for (i=0; i<list.items.length; i++) { + // is the element is not equal to item, or if the item is under an animation... + if ((!item || (list.items[i].el !== item.el)) && (list.items[i].selected || list.items[i].sliding || params.expand)) { + if (params.expand) { + _openItem (list.items[i], list, params.grouping); + } else { + _closeItem (list.items[i], list, params.grouping); + if (params.mirror) { + // hack for get the mirror element in persistent and !mutiples accordions + params.mirror.push(list.items[i]); + } + } + } + } + } + } + } + function _openItem ( item, list ) { + var conf = [], anim, i, g = [], m = [], fs, onFinish; + if (list || (list = _getList (item))) { + // if the item is not already opened + if (!item.selected) { + // closing all the selected items if neccesary + if (!list.multiple) { + _reset ( list, {item: item, grouping: g, mirror: m} ); + } + // if the animation is underway: we need to stop it... + anim = _anims[$E.generateId(item.slide)]; + if ((anim) && (anim.isAnimated())) {anim.stop();} + // opening the selected element, based on the list's orientation, timer and effect attribute... + conf[list.orientation] = {to: item.size[list.orientation]}; + // scrolling effect + if (!list.manually) { + conf['scroll'] = {from: (list.orientation=='width'?[item.size[list.orientation],0]:[0,item.size[list.orientation]]), to: [0,0]}; + } + if (list.fade) { // appliying fadeIn + conf['opacity'] = {to: 1}; + } + anim = new YAHOO.util.Scroll(item.slide, conf, list.timer, list.effect); + $D.addClass(item.el, _sliding); + onFinish = function() { + $D.removeClass(item.el, _sliding); + $D.addClass(item.el, _selector); + // broadcasting the corresponding event... + $B.fire ('accordionOpenItem', item); + }; + anim.onComplete.subscribe(onFinish); + _anims[$E.generateId(item.slide)] = anim; + if (list.manually) { + // manually animation... + m = m[0] || null; + // getting the desired dimension from the mirror or from the current item + fs = (m?m.size[list.orientation]:item.size[list.orientation]); + for (i=1;i<=fs;i++){ + if (m) { + $D.setStyle (m.slide, list.orientation, (fs-i)+'px'); + } + $D.setStyle (item.slide, list.orientation, i+'px'); + } + onFinish(); + } else { + // creating an animation thread + for (i=0; i<g.length; i++) { + YAHOO.util.AnimMgr.registerElement(g[i]); + } + YAHOO.util.AnimMgr.registerElement(anim); + } + } + return true; + } + return false; + } + function _closeItem ( item, list, grouping ) { + var conf = [], anim, fs; + if (item && (list || (list = _getList (item)))) { + // closing the item, based on the list's orientation, timer and effect attribute... + conf[list.orientation] = {to: ((list.orientation=='width'||list.fixIE)?1:0)}; // hack for vertical accordion issue on Safari and Opera + if (list.fade) { // appliying fadeIn + conf['opacity'] = {to: 0}; + } + // scrolling effect + if (!list.manually) { + conf['scroll'] = {to: (list.orientation=='width'?[item.size[list.orientation],0]:[0,item.size[list.orientation]])}; + } + // if the animation is underway: we need to stop it... + anim = _anims[$E.generateId(item.slide)]; + if ((anim) && (anim.isAnimated())) {anim.stop();} + anim = new YAHOO.util.Scroll(item.slide, conf, list.timer, list.effect); + $D.addClass(item.el, _sliding); + onFinish = function() { + $D.removeClass(item.el, _sliding); + $D.removeClass(item.el, _selector); + // broadcasting the corresponding event... + $B.fire ('accordionOpenItem', item); + }; + anim.onComplete.subscribe(onFinish); + if ($L.isArray(grouping)) { + grouping.push(anim); + } else { + anim.animate(); + } + if (list.manually) { + // animation manually + fs = item.size[list.orientation]; + for (i=fs;i>=conf[list.orientation].to;i--){ + $D.setStyle (item.slide, list.orientation, i+'px'); + } + onFinish(); + } + _anims[$E.generateId(item.slide)] = anim; + return true; + } + return false; + } + function _removeItem ( item, list ) { + if (item && (list || (list = _getList (item)))) { + // closing element + _closeItem (item, list); + // removing listeners... + $E.purgeElement ( item.el, true ); + // hack, removing the element after close it... + window.setTimeout (function(){ + item.el.parentNode.removeChild(item.el); + $B.fire ('accordionRemoveItem', item); + }, list.timer+0.1); + return true; + } + return false; + } + + // public vars + // public methods + /** + * * Expanding all the elements in the accordion... + * @public + * @param {object} el DOM reference + * @return boolean + */ + obj.expand = function ( el ) { + var list; + if (list = _getList ({el:el})) { + return _reset (list, {force:true, expand:true}); + } + }; + /** + * * Collapsing all the elements in the accordion... + * @public + * @param {object} el DOM reference + * @return boolean + */ + obj.collapse = function ( el ) { + var list; + if (list = _getList ({el:el})) { + return _reset (list, {force:true}); + } + }; + /** + * * Open a certain item inside an area... + * @public + * @param {object} el DOM reference + * @return boolean + */ + obj.open = function ( el ) { + var item; + if (item = _getItem(el)) { + return _openItem (item); + } + }; + /** + * * Close a certain item inside an area... + * @public + * @param {object} el DOM reference + * @return boolean + */ + obj.close = function ( el ) { + var item, list; + if (item = _getItem(el)) { + if (list = _getList (item)) { + // if the item is already opened, and is multiple and not persistent + return ((item.selected && (list.multiple || !list.persistent))?_closeItem (item, list):false); + } + } + }; + /** + * * toggle a certain item inside an area... + * @public + * @param {object} el DOM reference + * @return boolean + */ + obj.toggle = function ( el ) { + var item, list; + if (item = _getItem(el)) { + if (list = _getList (item)) { + // if the item is already opened, and is multiple and not persistent + return ((item.selected && (list.multiple || !list.persistent))?_closeItem (item, list):_openItem (item, list)); + } + } + }; + /** + * * remove a certain item from the area... + * @public + * @param {object} el DOM reference + * @return boolean + */ + obj.remove = function ( el ) { + var item, list; + if (item = _getItem(el)) { + if (list = _getList (item)) { + return _removeItem (item, list); + } + } + }; + return obj; + }(); +})(); +YAHOO.register("accordion", YAHOO.widget.AccordionManager, {version: "1.5.0", build: "203"}); \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/assets/accordion.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/assets/accordion.css new file mode 100644 index 0000000..405eb2d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/assets/accordion.css
@@ -0,0 +1,79 @@ +/* +Copyright (c) 2007, Caridy Pati�o. All rights reserved. +Portions Copyright (c) 2007, Yahoo!, Inc. All rights reserved. +Code licensed under the BSD License: +http://www.bubbling-library.com/eng/licence +version: 1.3.3 +*/ +.yui-skin-sam .yui-cms-accordion .yui-cms-item .bd { + height: 0; + padding: 0; + overflow: hidden; +} +.yui-skin-sam .yui-cms-accordion.vertical .yui-cms-item .bd { + height: auto; + width: 1px; +} + .yui-skin-sam .yui-cms-accordion .yui-cms-item .bd .fixed { + padding: 5px; + } + +.yui-skin-sam .yui-cms-accordion .yui-cms-item .actions { + position: absolute; + top: 5px; + right: 2px; + text-align: right; +} +.yui-skin-sam .yui-cms-accordion .yui-cms-item .actions a { + margin-right: 4px; + text-decoration: none; + font-size: 50%; + float: left; +} + +.yui-skin-sam .yui-cms-accordion .yui-cms-item .actions .accordionToggleItem { + width: 14px; + height: 14px; + background: url(http://yui.yahooapis.com/2.3.1/build/assets/skins/sam/sprite.png) no-repeat 0 -350px; + cursor: pointer; +} + +.yui-skin-sam .yui-cms-accordion .yui-cms-item.selected .actions .accordionToggleItem { + background: url(http://yui.yahooapis.com/2.3.1/build/assets/skins/sam/sprite.png) no-repeat 0 -400px; +} + +.yui-skin-sam .yui-cms-accordion.persistent .yui-cms-item.selected .actions .accordionToggleItem { + display: none; +} + +.yui-skin-sam .yui-cms-accordion.vertical .yui-cms-item .actions .accordionToggleItem { + width: 25px; + height: 15px; + background: url(http://yui.yahooapis.com/2.3.1/build/assets/skins/sam/sprite.png) no-repeat 0 -450px; +} + +.yui-skin-sam .yui-cms-accordion.vertical .yui-cms-item.selected .actions .accordionToggleItem { + background: url(http://yui.yahooapis.com/2.3.1/build/assets/skins/sam/sprite.png) no-repeat 0 -500px; +} + +.yui-skin-sam .yui-cms-accordion .yui-cms-item .actions .accordionRemoveItem { + width: 25px; + height: 15px; + background: url(http://yui.yahooapis.com/2.3.1/build/assets/skins/sam/sprite.png) no-repeat 0 -300px; +} +.yui-skin-sam .yui-cms-accordion .yui-cms-item .ajax .fixed { + background: url(loading.gif) no-repeat 50% 50%; +} + +.yui-skin-sam .yui-cms-accordion .yui-cms-item .bd { + height: 0px; +} +.yui-skin-sam .yui-cms-accordion.fixIE .yui-cms-item .bd { + *height: 1px; /* IE Hack */ +} +.yui-skin-sam .yui-cms-accordion .yui-cms-item.selected .bd { + height: auto; + background: + +#fff; +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/assets/loading.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/assets/loading.gif new file mode 100644 index 0000000..0bbf3bc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/assets/loading.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/bubbling.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/bubbling.js new file mode 100644 index 0000000..e6805f7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/bubbling/bubbling.js
@@ -0,0 +1,387 @@ +/* +Copyright (c) 2007, Caridy Patiño. All rights reserved. +Portions Copyright (c) 2007, Yahoo!, Inc. All rights reserved. +Code licensed under the BSD License: +http://www.bubbling-library.com/eng/licence +version: 1.5.0 +*/ +YAHOO.namespace("plugin","behavior"); +(function() { + var $Y = YAHOO.util, + $E = YAHOO.util.Event, + $D = YAHOO.util.Dom, + $L = YAHOO.lang, + $ = YAHOO.util.Dom.get; + + /** + * @class Bubbling + */ + YAHOO.Bubbling = function () { + var obj = {}, + ua = navigator.userAgent.toLowerCase(), + isOpera = (ua.indexOf('opera') > -1); + // private stuff + var navRelExternal = function (layer, args) { + var el = args[1].anchor; + if (!(args[1].flagged || args[1].decrepitate) && el) { + var r = el.getAttribute("rel"), + t = el.getAttribute("target"); + if ((!t || (t === '')) && (r == 'external')) { + el.setAttribute("target", "blank"); + } + } + }; + var defaultActionsControl = function (layer, args) { + obj.processingAction (layer, args, obj.defaultActions); + }; + var _searchYUIButton = function (t) { + var el = obj.getOwnerByClassName( t, 'yui-button' ), bt = null, id = null; + if ($L.isObject(el) && YAHOO.widget.Button) { + bt = YAHOO.widget.Button.getButton(el.id); + } + return bt; + }; + + // public vars + obj.ready = false; + obj.force2alfa = false; + obj.bubble = {}; // CustomEvent Handles + obj.onReady = new $Y.CustomEvent('bubblingOnReady', obj, true); + + // mapping external methods... + obj.getOwnerByClassName = function(node, className) { + return ($D.hasClass(node, className)?node:$D.getAncestorByClassName (node, className)); + }; + obj.getOwnerByTagName = function(node, tagName) { + node = $D.get(node); + if (!node) { + return null; + } + return (node.tagName && node.tagName.toUpperCase() == tagName.toUpperCase()?node:$D.getAncestorByTagName (node, tagName)); + }; + // Deprecated in favor of getOwnerByClassName and getOwnerByTagName + obj.getAncestorByClassName = obj.getOwnerByClassName; + obj.getAncestorByTagName = obj.getOwnerByTagName; + + // public methods + obj.onKeyPressedTrigger = function(args, e, m){ + var b = 'key'; + e = e || $E.getEvent(); + m = m || {}; + m.action = b; + m.target = args.target || (e?$E.getTarget(e):null); + m.flagged = false; m.decrepitate = false; + m.event = e; + m.stop = false; + m.type = args.type; + m.keyCode = args.keyCode; + m.charCode = args.charCode; + m.ctrlKey = args.ctrlKey; + m.shiftKey = args.shiftKey; + m.altKey = args.altKey; + this.bubble.key.fire(e, m); + if (m.stop) { + $E.stopEvent(e); + } + return m.stop; + }; + obj.onEventTrigger = function(b, e, m){ + e = e || $E.getEvent(); + m = m || {}; + m.action = b; + m.target = (e?$E.getTarget(e):null); + m.flagged = false; m.decrepitate = false; + m.event = e; + m.stop = false; + this.bubble[b].fire(e, m); + if (m.stop) { + $E.stopEvent(e); + } + return m.stop; + }; + obj.onNavigate = function(e){ + var conf = { + anchor: this.getOwnerByTagName( $E.getTarget(e), 'A' ), + button: _searchYUIButton($E.getTarget(e)) + }; + if (!conf.anchor && !conf.button) { + conf.input = this.getOwnerByTagName( $E.getTarget(e), 'INPUT' ); + } + if (conf.button) { + conf.value = conf.button.get('value'); + } else if (conf.input) { + conf.value = conf.input.getAttribute('value'); + } + if (!this.onEventTrigger ('navigate', e, conf)) { + this.onEventTrigger ('god', e, conf); // if nobody claim the event, god can handle it... + } + }; + obj.onProperty = function(e){ + this.onEventTrigger ('property', e, { + anchor: this.getOwnerByTagName( $E.getTarget(e), 'A' ), + button: _searchYUIButton($E.getTarget(e)) + }); + }; + obj._timeoutId = 0; + obj.onRepaint = function(e){ + // Downshift Your Code (canÂ’t let something happen multiple times in a second) + // http://yuiblog.com/blog/2007/07/09/downshift-your-code/ + clearTimeout(obj._timeoutId); + obj._timeoutId = setTimeout(function(){ + var b = 'repaint', + e = {target:document.body}, + m = { + action: b, + target: null, + event: e, + flagged: false, + decrepitate: false, + stop: false + }; + obj.bubble[b].fire(e, m); + if (m.stop) { + $E.stopEvent(e); + } + }, 150 + ); + }; + obj.onRollOver = function(e){ + this.onEventTrigger ('rollover', e, { + anchor: this.getOwnerByTagName( $E.getTarget(e), 'A' ) + }); + }; + obj.onRollOut = function(e){ + this.onEventTrigger ('rollout', e, { + anchor: this.getOwnerByTagName( $E.getTarget(e), 'A' ) + }); + }; + obj.onKeyPressed = function(args){ + this.onKeyPressedTrigger(args); + }; + /** + * * Este método determina la acción por defecto para un elemento + * @public + * @param {object} el element reference + * @param {object} actions object with the list of posibles actions + * @return void + */ + obj.getActionName = function (el, depot) { + depot = depot || {}; + var b = null, r = null, + f = ($D.inDocument(el)?function(b){return $D.hasClass(el, b)}:function(b){return el.hasClass(b);}); // f: check is certain object has a classname + if (el && ($L.isObject(el) || (el = $( el )))) { + try{ + r = el.getAttribute("rel"); // if rel is available... + }catch(e){}; + for (b in depot) { // behaviors in the depot... + if ((depot.hasOwnProperty(b)) && (f(b) || (b === r))) { + return b; + } + } + } + return null; + }; + /** + * * Este método determina el primer tab hijo basado en el tabName + * @public + * @param {object} el Child element reference + * @param {object} c ClassName of the Ancestor + * @return void + */ + obj.getFirstChildByTagName = function (el, t) { + if (el && ($L.isObject(el) || (el = $( el ))) && t) { + var l = el.getElementsByTagName(t); + if (l.length > 0) { + return l[0]; + } + } + return null; + }; + /** + * * Este método determina si un evento es interno o no a un contenedor... + * @public + * @param {object} e Referencia al evento + * @param {object} el Referencia al contendor + * @return void + */ + obj.virtualTarget = function (e, el) { + if (el && ($L.isObject(el) || (el = $( el ))) && $L.isObject(e)) { + var t = $E.getRelatedTarget ( e ); // target element + if ($L.isObject(t)) { + while((t.parentNode) && $L.isObject(t.parentNode) && (t.parentNode.tagName !== "BODY")) { + if (t.parentNode === el) { + return true; + } + t = t.parentNode; + } + } + } + return false; + }; + + /** + * * Creating a new behaviors layer... + * @public + * @param {string||array} layers Behaviors layers GUID + * @param {object} scope Custom Event default execution scope + * @return boolean if not exists... + */ + obj.addLayer = function (layers, scope) { + var result = false; + layers = ($L.isArray(layers)?layers:[layers]); + scope = scope || window; + for (var i = 0; i < layers.length; ++i) { + if (layers[i] && !this.bubble.hasOwnProperty(layers[i])) { + this.bubble[layers[i]] = new $Y.CustomEvent(layers[i], scope, true); + result = true; + } + } + return result; + }; + /** + * * Subcribing an bahavior to certain bahaviors layer... + * @public + * @param {string} layer Behavior layer GUID + * @param {object} bh The function that represent the behavior + * @return boolean if it is the first listener + */ + obj.subscribe = function (layer, bh, scope) { + var first = this.addLayer(layer); // return true if it's the first listener + if (layer) { + if ($L.isObject(scope)) { + this.bubble[layer].subscribe(bh, scope, true); // correcting the default scope + } else { + this.bubble[layer].subscribe(bh); // use the default scope + } + } + return first; + }; + obj.on = obj.subscribe; // defining an alias... + /** + * * Broadcasting the message in the corresponding behavior layer... + * @public + * @param {string} layer Behavior layer GUID + * @param {object} obj The function that represent the behavior + * @return boolean if someone has claim the event + */ + obj.fire = function (layer, obj) { + obj = obj || {}; + obj.action = layer; + obj.flagged = false; obj.decrepitate = false; + obj.stop = false; + if (this.bubble.hasOwnProperty(layer)) { + this.bubble[layer].fire(null, obj); + } + return obj.stop; + }; + /** + * * Processing an action based on the classname of the target element... + * @public + * @param {string} layer Behavior layer GUID + * @param {object} args Event object (extended) + * @param {object} actions List of availables behaviors... + * @param {boolean} force Proccess the actions without worry about the flagged value... + * @return void + */ + obj.processingAction = function (layer, args, actions, force) { + var behavior = null, t; + if (!(args[1].flagged || args[1].decrepitate) || force) { + // checking for anchor, input or button + t = args[1].anchor || args[1].input || args[1].button; + if (t) { + behavior = this.getActionName ( t, actions ); + args[1].el = t; + } + if (behavior && (actions[behavior].apply(args[1], [layer, args]))) { + $E.stopEvent(args[0]); + args[1].flagged = true; + args[1].decrepitate = true; + args[1].stop = true; + } + } + }; + obj.defaultActions = {}; + obj.addDefaultAction = function (n, f, force) { + if (n && f && (!this.defaultActions.hasOwnProperty(n) || force)) { + this.defaultActions[n] = f; + } + }; + + // default behaviors + $E.addListener(window, "resize", obj.onRepaint, obj, true); + + // default Suscriptions + obj.on('navigate', navRelExternal); + obj.on('navigate', defaultActionsControl); + + // initialization of the font and scroll monitors + obj.initMonitors = function ( config ) { + var fMonitors = function () { + var oMonitors = new YAHOO.widget.Module('yui-cms-font-monitor', { + monitorresize:true, + visible:false + }); + oMonitors.render(document.body); + // monitoring font-size... + YAHOO.widget.Module.textResizeEvent.subscribe(obj.onRepaint, obj, true); + // monitoring scroll actions... + YAHOO.widget.Overlay.windowScrollEvent.subscribe(obj.onRepaint, obj, true); + }; + if ($L.isFunction(YAHOO.widget.Module)) { + $E.onDOMReady (fMonitors, obj, true); + } + }; + // initialization inside the selfconstructor + obj.init = function () { + if (!this.ready) { + var el = document.body; + $E.addListener(el, + "click", + obj.onNavigate, + obj, + true + ); + /* + Listen for the "mousedown" event in Opera b/c it does not + support the "contextmenu" event + */ + $E.addListener( + el, + (isOpera ? "mousedown" : "contextmenu"), + obj.onProperty, + obj, + true + ); + /* + Assign a "click" event handler to the trigger element(s) for + Opera to prevent default browser behaviors. + */ + if(isOpera) { + $E.addListener( + el, + "click", + obj.onProperty, + obj, + true + ); + } + $E.addListener(el, "mouseover", obj.onRollOver, obj, true); + $E.addListener(el, "mouseout", obj.onRollOut, obj, true); + + // keys... + $E.addListener(document, "keyup", obj.onKeyPressed, obj, true); + $E.addListener(document, "keydown", obj.onKeyPressed, obj, true); + + this.ready = true; + obj.onReady.fire(); + } + }; + $E.onDOMReady(obj.init, obj, true); + + // creating the default layers... + obj.addLayer (['navigate','god','property','key','repaint','rollover', 'rollout']); // god layer - hack: the layer after the common navigate layer... + + return obj; + }(); +})(); +YAHOO.register("bubbling", YAHOO.Bubbling, {version: "1.5.0", build: "222"}); \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/animation.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/animation.js new file mode 100644 index 0000000..f764bfc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/animation.js
@@ -0,0 +1,1380 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +(function() { + +var Y = YAHOO.util; + +/* +Copyright (c) 2006, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +*/ + +/** + * The animation module provides allows effects to be added to HTMLElements. + * @module animation + * @requires yahoo, event, dom + */ + +/** + * + * Base animation class that provides the interface for building animated effects. + * <p>Usage: var myAnim = new YAHOO.util.Anim(el, { width: { from: 10, to: 100 } }, 1, YAHOO.util.Easing.easeOut);</p> + * @class Anim + * @namespace YAHOO.util + * @requires YAHOO.util.AnimMgr + * @requires YAHOO.util.Easing + * @requires YAHOO.util.Dom + * @requires YAHOO.util.Event + * @requires YAHOO.util.CustomEvent + * @constructor + * @param {String | HTMLElement} el Reference to the element that will be animated + * @param {Object} attributes The attribute(s) to be animated. + * Each attribute is an object with at minimum a "to" or "by" member defined. + * Additional optional members are "from" (defaults to current value), "units" (defaults to "px"). + * All attribute names use camelCase. + * @param {Number} duration (optional, defaults to 1 second) Length of animation (frames or seconds), defaults to time-based + * @param {Function} method (optional, defaults to YAHOO.util.Easing.easeNone) Computes the values that are applied to the attributes per frame (generally a YAHOO.util.Easing method) + */ + +var Anim = function(el, attributes, duration, method) { + if (!el) { + } + this.init(el, attributes, duration, method); +}; + +Anim.NAME = 'Anim'; + +Anim.prototype = { + /** + * Provides a readable name for the Anim instance. + * @method toString + * @return {String} + */ + toString: function() { + var el = this.getEl() || {}; + var id = el.id || el.tagName; + return (this.constructor.NAME + ': ' + id); + }, + + patterns: { // cached for performance + noNegatives: /width|height|opacity|padding/i, // keep at zero or above + offsetAttribute: /^((width|height)|(top|left))$/, // use offsetValue as default + defaultUnit: /width|height|top$|bottom$|left$|right$/i, // use 'px' by default + offsetUnit: /\d+(em|%|en|ex|pt|in|cm|mm|pc)$/i // IE may return these, so convert these to offset + }, + + /** + * Returns the value computed by the animation's "method". + * @method doMethod + * @param {String} attr The name of the attribute. + * @param {Number} start The value this attribute should start from for this animation. + * @param {Number} end The value this attribute should end at for this animation. + * @return {Number} The Value to be applied to the attribute. + */ + doMethod: function(attr, start, end) { + return this.method(this.currentFrame, start, end - start, this.totalFrames); + }, + + /** + * Applies a value to an attribute. + * @method setAttribute + * @param {String} attr The name of the attribute. + * @param {Number} val The value to be applied to the attribute. + * @param {String} unit The unit ('px', '%', etc.) of the value. + */ + setAttribute: function(attr, val, unit) { + if ( this.patterns.noNegatives.test(attr) ) { + val = (val > 0) ? val : 0; + } + + Y.Dom.setStyle(this.getEl(), attr, val + unit); + }, + + /** + * Returns current value of the attribute. + * @method getAttribute + * @param {String} attr The name of the attribute. + * @return {Number} val The current value of the attribute. + */ + getAttribute: function(attr) { + var el = this.getEl(); + var val = Y.Dom.getStyle(el, attr); + + if (val !== 'auto' && !this.patterns.offsetUnit.test(val)) { + return parseFloat(val); + } + + var a = this.patterns.offsetAttribute.exec(attr) || []; + var pos = !!( a[3] ); // top or left + var box = !!( a[2] ); // width or height + + // use offsets for width/height and abs pos top/left + if ( box || (Y.Dom.getStyle(el, 'position') == 'absolute' && pos) ) { + val = el['offset' + a[0].charAt(0).toUpperCase() + a[0].substr(1)]; + } else { // default to zero for other 'auto' + val = 0; + } + + return val; + }, + + /** + * Returns the unit to use when none is supplied. + * @method getDefaultUnit + * @param {attr} attr The name of the attribute. + * @return {String} The default unit to be used. + */ + getDefaultUnit: function(attr) { + if ( this.patterns.defaultUnit.test(attr) ) { + return 'px'; + } + + return ''; + }, + + /** + * Sets the actual values to be used during the animation. Should only be needed for subclass use. + * @method setRuntimeAttribute + * @param {Object} attr The attribute object + * @private + */ + setRuntimeAttribute: function(attr) { + var start; + var end; + var attributes = this.attributes; + + this.runtimeAttributes[attr] = {}; + + var isset = function(prop) { + return (typeof prop !== 'undefined'); + }; + + if ( !isset(attributes[attr]['to']) && !isset(attributes[attr]['by']) ) { + return false; // note return; nothing to animate to + } + + start = ( isset(attributes[attr]['from']) ) ? attributes[attr]['from'] : this.getAttribute(attr); + + // To beats by, per SMIL 2.1 spec + if ( isset(attributes[attr]['to']) ) { + end = attributes[attr]['to']; + } else if ( isset(attributes[attr]['by']) ) { + if (start.constructor == Array) { + end = []; + for (var i = 0, len = start.length; i < len; ++i) { + end[i] = start[i] + attributes[attr]['by'][i] * 1; // times 1 to cast "by" + } + } else { + end = start + attributes[attr]['by'] * 1; + } + } + + this.runtimeAttributes[attr].start = start; + this.runtimeAttributes[attr].end = end; + + // set units if needed + this.runtimeAttributes[attr].unit = ( isset(attributes[attr].unit) ) ? + attributes[attr]['unit'] : this.getDefaultUnit(attr); + return true; + }, + + /** + * Constructor for Anim instance. + * @method init + * @param {String | HTMLElement} el Reference to the element that will be animated + * @param {Object} attributes The attribute(s) to be animated. + * Each attribute is an object with at minimum a "to" or "by" member defined. + * Additional optional members are "from" (defaults to current value), "units" (defaults to "px"). + * All attribute names use camelCase. + * @param {Number} duration (optional, defaults to 1 second) Length of animation (frames or seconds), defaults to time-based + * @param {Function} method (optional, defaults to YAHOO.util.Easing.easeNone) Computes the values that are applied to the attributes per frame (generally a YAHOO.util.Easing method) + */ + init: function(el, attributes, duration, method) { + /** + * Whether or not the animation is running. + * @property isAnimated + * @private + * @type Boolean + */ + var isAnimated = false; + + /** + * A Date object that is created when the animation begins. + * @property startTime + * @private + * @type Date + */ + var startTime = null; + + /** + * The number of frames this animation was able to execute. + * @property actualFrames + * @private + * @type Int + */ + var actualFrames = 0; + + /** + * The element to be animated. + * @property el + * @private + * @type HTMLElement + */ + el = Y.Dom.get(el); + + /** + * The collection of attributes to be animated. + * Each attribute must have at least a "to" or "by" defined in order to animate. + * If "to" is supplied, the animation will end with the attribute at that value. + * If "by" is supplied, the animation will end at that value plus its starting value. + * If both are supplied, "to" is used, and "by" is ignored. + * Optional additional member include "from" (the value the attribute should start animating from, defaults to current value), and "unit" (the units to apply to the values). + * @property attributes + * @type Object + */ + this.attributes = attributes || {}; + + /** + * The length of the animation. Defaults to "1" (second). + * @property duration + * @type Number + */ + this.duration = !YAHOO.lang.isUndefined(duration) ? duration : 1; + + /** + * The method that will provide values to the attribute(s) during the animation. + * Defaults to "YAHOO.util.Easing.easeNone". + * @property method + * @type Function + */ + this.method = method || Y.Easing.easeNone; + + /** + * Whether or not the duration should be treated as seconds. + * Defaults to true. + * @property useSeconds + * @type Boolean + */ + this.useSeconds = true; // default to seconds + + /** + * The location of the current animation on the timeline. + * In time-based animations, this is used by AnimMgr to ensure the animation finishes on time. + * @property currentFrame + * @type Int + */ + this.currentFrame = 0; + + /** + * The total number of frames to be executed. + * In time-based animations, this is used by AnimMgr to ensure the animation finishes on time. + * @property totalFrames + * @type Int + */ + this.totalFrames = Y.AnimMgr.fps; + + /** + * Changes the animated element + * @method setEl + */ + this.setEl = function(element) { + el = Y.Dom.get(element); + }; + + /** + * Returns a reference to the animated element. + * @method getEl + * @return {HTMLElement} + */ + this.getEl = function() { return el; }; + + /** + * Checks whether the element is currently animated. + * @method isAnimated + * @return {Boolean} current value of isAnimated. + */ + this.isAnimated = function() { + return isAnimated; + }; + + /** + * Returns the animation start time. + * @method getStartTime + * @return {Date} current value of startTime. + */ + this.getStartTime = function() { + return startTime; + }; + + this.runtimeAttributes = {}; + + + + /** + * Starts the animation by registering it with the animation manager. + * @method animate + */ + this.animate = function() { + if ( this.isAnimated() ) { + return false; + } + + this.currentFrame = 0; + + this.totalFrames = ( this.useSeconds ) ? Math.ceil(Y.AnimMgr.fps * this.duration) : this.duration; + + if (this.duration === 0 && this.useSeconds) { // jump to last frame if zero second duration + this.totalFrames = 1; + } + Y.AnimMgr.registerElement(this); + return true; + }; + + /** + * Stops the animation. Normally called by AnimMgr when animation completes. + * @method stop + * @param {Boolean} finish (optional) If true, animation will jump to final frame. + */ + this.stop = function(finish) { + if (!this.isAnimated()) { // nothing to stop + return false; + } + + if (finish) { + this.currentFrame = this.totalFrames; + this._onTween.fire(); + } + Y.AnimMgr.stop(this); + }; + + var onStart = function() { + this.onStart.fire(); + + this.runtimeAttributes = {}; + for (var attr in this.attributes) { + this.setRuntimeAttribute(attr); + } + + isAnimated = true; + actualFrames = 0; + startTime = new Date(); + }; + + /** + * Feeds the starting and ending values for each animated attribute to doMethod once per frame, then applies the resulting value to the attribute(s). + * @private + */ + + var onTween = function() { + var data = { + duration: new Date() - this.getStartTime(), + currentFrame: this.currentFrame + }; + + data.toString = function() { + return ( + 'duration: ' + data.duration + + ', currentFrame: ' + data.currentFrame + ); + }; + + this.onTween.fire(data); + + var runtimeAttributes = this.runtimeAttributes; + + for (var attr in runtimeAttributes) { + this.setAttribute(attr, this.doMethod(attr, runtimeAttributes[attr].start, runtimeAttributes[attr].end), runtimeAttributes[attr].unit); + } + + actualFrames += 1; + }; + + var onComplete = function() { + var actual_duration = (new Date() - startTime) / 1000 ; + + var data = { + duration: actual_duration, + frames: actualFrames, + fps: actualFrames / actual_duration + }; + + data.toString = function() { + return ( + 'duration: ' + data.duration + + ', frames: ' + data.frames + + ', fps: ' + data.fps + ); + }; + + isAnimated = false; + actualFrames = 0; + this.onComplete.fire(data); + }; + + /** + * Custom event that fires after onStart, useful in subclassing + * @private + */ + this._onStart = new Y.CustomEvent('_start', this, true); + + /** + * Custom event that fires when animation begins + * Listen via subscribe method (e.g. myAnim.onStart.subscribe(someFunction) + * @event onStart + */ + this.onStart = new Y.CustomEvent('start', this); + + /** + * Custom event that fires between each frame + * Listen via subscribe method (e.g. myAnim.onTween.subscribe(someFunction) + * @event onTween + */ + this.onTween = new Y.CustomEvent('tween', this); + + /** + * Custom event that fires after onTween + * @private + */ + this._onTween = new Y.CustomEvent('_tween', this, true); + + /** + * Custom event that fires when animation ends + * Listen via subscribe method (e.g. myAnim.onComplete.subscribe(someFunction) + * @event onComplete + */ + this.onComplete = new Y.CustomEvent('complete', this); + /** + * Custom event that fires after onComplete + * @private + */ + this._onComplete = new Y.CustomEvent('_complete', this, true); + + this._onStart.subscribe(onStart); + this._onTween.subscribe(onTween); + this._onComplete.subscribe(onComplete); + } +}; + + Y.Anim = Anim; +})(); +/** + * Handles animation queueing and threading. + * Used by Anim and subclasses. + * @class AnimMgr + * @namespace YAHOO.util + */ +YAHOO.util.AnimMgr = new function() { + /** + * Reference to the animation Interval. + * @property thread + * @private + * @type Int + */ + var thread = null; + + /** + * The current queue of registered animation objects. + * @property queue + * @private + * @type Array + */ + var queue = []; + + /** + * The number of active animations. + * @property tweenCount + * @private + * @type Int + */ + var tweenCount = 0; + + /** + * Base frame rate (frames per second). + * Arbitrarily high for better x-browser calibration (slower browsers drop more frames). + * @property fps + * @type Int + * + */ + this.fps = 1000; + + /** + * Interval delay in milliseconds, defaults to fastest possible. + * @property delay + * @type Int + * + */ + this.delay = 1; + + /** + * Adds an animation instance to the animation queue. + * All animation instances must be registered in order to animate. + * @method registerElement + * @param {object} tween The Anim instance to be be registered + */ + this.registerElement = function(tween) { + queue[queue.length] = tween; + tweenCount += 1; + tween._onStart.fire(); + this.start(); + }; + + /** + * removes an animation instance from the animation queue. + * All animation instances must be registered in order to animate. + * @method unRegister + * @param {object} tween The Anim instance to be be registered + * @param {Int} index The index of the Anim instance + * @private + */ + this.unRegister = function(tween, index) { + index = index || getIndex(tween); + if (!tween.isAnimated() || index == -1) { + return false; + } + + tween._onComplete.fire(); + queue.splice(index, 1); + + tweenCount -= 1; + if (tweenCount <= 0) { + this.stop(); + } + + return true; + }; + + /** + * Starts the animation thread. + * Only one thread can run at a time. + * @method start + */ + this.start = function() { + if (thread === null) { + thread = setInterval(this.run, this.delay); + } + }; + + /** + * Stops the animation thread or a specific animation instance. + * @method stop + * @param {object} tween A specific Anim instance to stop (optional) + * If no instance given, Manager stops thread and all animations. + */ + this.stop = function(tween) { + if (!tween) { + clearInterval(thread); + + for (var i = 0, len = queue.length; i < len; ++i) { + this.unRegister(queue[0], 0); + } + + queue = []; + thread = null; + tweenCount = 0; + } + else { + this.unRegister(tween); + } + }; + + /** + * Called per Interval to handle each animation frame. + * @method run + */ + this.run = function() { + for (var i = 0, len = queue.length; i < len; ++i) { + var tween = queue[i]; + if ( !tween || !tween.isAnimated() ) { continue; } + + if (tween.currentFrame < tween.totalFrames || tween.totalFrames === null) + { + tween.currentFrame += 1; + + if (tween.useSeconds) { + correctFrame(tween); + } + tween._onTween.fire(); + } + else { YAHOO.util.AnimMgr.stop(tween, i); } + } + }; + + var getIndex = function(anim) { + for (var i = 0, len = queue.length; i < len; ++i) { + if (queue[i] == anim) { + return i; // note return; + } + } + return -1; + }; + + /** + * On the fly frame correction to keep animation on time. + * @method correctFrame + * @private + * @param {Object} tween The Anim instance being corrected. + */ + var correctFrame = function(tween) { + var frames = tween.totalFrames; + var frame = tween.currentFrame; + var expected = (tween.currentFrame * tween.duration * 1000 / tween.totalFrames); + var elapsed = (new Date() - tween.getStartTime()); + var tweak = 0; + + if (elapsed < tween.duration * 1000) { // check if falling behind + tweak = Math.round((elapsed / expected - 1) * tween.currentFrame); + } else { // went over duration, so jump to end + tweak = frames - (frame + 1); + } + if (tweak > 0 && isFinite(tweak)) { // adjust if needed + if (tween.currentFrame + tweak >= frames) {// dont go past last frame + tweak = frames - (frame + 1); + } + + tween.currentFrame += tweak; + } + }; +}; +/** + * Used to calculate Bezier splines for any number of control points. + * @class Bezier + * @namespace YAHOO.util + * + */ +YAHOO.util.Bezier = new function() { + /** + * Get the current position of the animated element based on t. + * Each point is an array of "x" and "y" values (0 = x, 1 = y) + * At least 2 points are required (start and end). + * First point is start. Last point is end. + * Additional control points are optional. + * @method getPosition + * @param {Array} points An array containing Bezier points + * @param {Number} t A number between 0 and 1 which is the basis for determining current position + * @return {Array} An array containing int x and y member data + */ + this.getPosition = function(points, t) { + var n = points.length; + var tmp = []; + + for (var i = 0; i < n; ++i){ + tmp[i] = [points[i][0], points[i][1]]; // save input + } + + for (var j = 1; j < n; ++j) { + for (i = 0; i < n - j; ++i) { + tmp[i][0] = (1 - t) * tmp[i][0] + t * tmp[parseInt(i + 1, 10)][0]; + tmp[i][1] = (1 - t) * tmp[i][1] + t * tmp[parseInt(i + 1, 10)][1]; + } + } + + return [ tmp[0][0], tmp[0][1] ]; + + }; +}; +(function() { +/** + * Anim subclass for color transitions. + * <p>Usage: <code>var myAnim = new Y.ColorAnim(el, { backgroundColor: { from: '#FF0000', to: '#FFFFFF' } }, 1, Y.Easing.easeOut);</code> Color values can be specified with either 112233, #112233, + * [255,255,255], or rgb(255,255,255)</p> + * @class ColorAnim + * @namespace YAHOO.util + * @requires YAHOO.util.Anim + * @requires YAHOO.util.AnimMgr + * @requires YAHOO.util.Easing + * @requires YAHOO.util.Bezier + * @requires YAHOO.util.Dom + * @requires YAHOO.util.Event + * @constructor + * @extends YAHOO.util.Anim + * @param {HTMLElement | String} el Reference to the element that will be animated + * @param {Object} attributes The attribute(s) to be animated. + * Each attribute is an object with at minimum a "to" or "by" member defined. + * Additional optional members are "from" (defaults to current value), "units" (defaults to "px"). + * All attribute names use camelCase. + * @param {Number} duration (optional, defaults to 1 second) Length of animation (frames or seconds), defaults to time-based + * @param {Function} method (optional, defaults to YAHOO.util.Easing.easeNone) Computes the values that are applied to the attributes per frame (generally a YAHOO.util.Easing method) + */ + var ColorAnim = function(el, attributes, duration, method) { + ColorAnim.superclass.constructor.call(this, el, attributes, duration, method); + }; + + ColorAnim.NAME = 'ColorAnim'; + + // shorthand + var Y = YAHOO.util; + YAHOO.extend(ColorAnim, Y.Anim); + + var superclass = ColorAnim.superclass; + var proto = ColorAnim.prototype; + + proto.patterns.color = /color$/i; + proto.patterns.rgb = /^rgb\(([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\)$/i; + proto.patterns.hex = /^#?([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})$/i; + proto.patterns.hex3 = /^#?([0-9A-F]{1})([0-9A-F]{1})([0-9A-F]{1})$/i; + proto.patterns.transparent = /^transparent|rgba\(0, 0, 0, 0\)$/; // need rgba for safari + + /** + * Attempts to parse the given string and return a 3-tuple. + * @method parseColor + * @param {String} s The string to parse. + * @return {Array} The 3-tuple of rgb values. + */ + proto.parseColor = function(s) { + if (s.length == 3) { return s; } + + var c = this.patterns.hex.exec(s); + if (c && c.length == 4) { + return [ parseInt(c[1], 16), parseInt(c[2], 16), parseInt(c[3], 16) ]; + } + + c = this.patterns.rgb.exec(s); + if (c && c.length == 4) { + return [ parseInt(c[1], 10), parseInt(c[2], 10), parseInt(c[3], 10) ]; + } + + c = this.patterns.hex3.exec(s); + if (c && c.length == 4) { + return [ parseInt(c[1] + c[1], 16), parseInt(c[2] + c[2], 16), parseInt(c[3] + c[3], 16) ]; + } + + return null; + }; + + proto.getAttribute = function(attr) { + var el = this.getEl(); + if ( this.patterns.color.test(attr) ) { + var val = YAHOO.util.Dom.getStyle(el, attr); + + if (this.patterns.transparent.test(val)) { // bgcolor default + var parent = el.parentNode; // try and get from an ancestor + val = Y.Dom.getStyle(parent, attr); + + while (parent && this.patterns.transparent.test(val)) { + parent = parent.parentNode; + val = Y.Dom.getStyle(parent, attr); + if (parent.tagName.toUpperCase() == 'HTML') { + val = '#fff'; + } + } + } + } else { + val = superclass.getAttribute.call(this, attr); + } + + return val; + }; + + proto.doMethod = function(attr, start, end) { + var val; + + if ( this.patterns.color.test(attr) ) { + val = []; + for (var i = 0, len = start.length; i < len; ++i) { + val[i] = superclass.doMethod.call(this, attr, start[i], end[i]); + } + + val = 'rgb('+Math.floor(val[0])+','+Math.floor(val[1])+','+Math.floor(val[2])+')'; + } + else { + val = superclass.doMethod.call(this, attr, start, end); + } + + return val; + }; + + proto.setRuntimeAttribute = function(attr) { + superclass.setRuntimeAttribute.call(this, attr); + + if ( this.patterns.color.test(attr) ) { + var attributes = this.attributes; + var start = this.parseColor(this.runtimeAttributes[attr].start); + var end = this.parseColor(this.runtimeAttributes[attr].end); + // fix colors if going "by" + if ( typeof attributes[attr]['to'] === 'undefined' && typeof attributes[attr]['by'] !== 'undefined' ) { + end = this.parseColor(attributes[attr].by); + + for (var i = 0, len = start.length; i < len; ++i) { + end[i] = start[i] + end[i]; + } + } + + this.runtimeAttributes[attr].start = start; + this.runtimeAttributes[attr].end = end; + } + }; + + Y.ColorAnim = ColorAnim; +})(); +/*! +TERMS OF USE - EASING EQUATIONS +Open source under the BSD License. +Copyright 2001 Robert Penner All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + * Neither the name of the author nor the names of contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +*/ + +/** + * Singleton that determines how an animation proceeds from start to end. + * @class Easing + * @namespace YAHOO.util +*/ + +YAHOO.util.Easing = { + + /** + * Uniform speed between points. + * @method easeNone + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeNone: function (t, b, c, d) { + return c*t/d + b; + }, + + /** + * Begins slowly and accelerates towards end. (quadratic) + * @method easeIn + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeIn: function (t, b, c, d) { + return c*(t/=d)*t + b; + }, + + /** + * Begins quickly and decelerates towards end. (quadratic) + * @method easeOut + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeOut: function (t, b, c, d) { + return -c *(t/=d)*(t-2) + b; + }, + + /** + * Begins slowly and decelerates towards end. (quadratic) + * @method easeBoth + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeBoth: function (t, b, c, d) { + if ((t/=d/2) < 1) { + return c/2*t*t + b; + } + + return -c/2 * ((--t)*(t-2) - 1) + b; + }, + + /** + * Begins slowly and accelerates towards end. (quartic) + * @method easeInStrong + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeInStrong: function (t, b, c, d) { + return c*(t/=d)*t*t*t + b; + }, + + /** + * Begins quickly and decelerates towards end. (quartic) + * @method easeOutStrong + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeOutStrong: function (t, b, c, d) { + return -c * ((t=t/d-1)*t*t*t - 1) + b; + }, + + /** + * Begins slowly and decelerates towards end. (quartic) + * @method easeBothStrong + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + easeBothStrong: function (t, b, c, d) { + if ((t/=d/2) < 1) { + return c/2*t*t*t*t + b; + } + + return -c/2 * ((t-=2)*t*t*t - 2) + b; + }, + + /** + * Snap in elastic effect. + * @method elasticIn + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @param {Number} a Amplitude (optional) + * @param {Number} p Period (optional) + * @return {Number} The computed value for the current animation frame + */ + + elasticIn: function (t, b, c, d, a, p) { + if (t == 0) { + return b; + } + if ( (t /= d) == 1 ) { + return b+c; + } + if (!p) { + p=d*.3; + } + + if (!a || a < Math.abs(c)) { + a = c; + var s = p/4; + } + else { + var s = p/(2*Math.PI) * Math.asin (c/a); + } + + return -(a*Math.pow(2,10*(t-=1)) * Math.sin( (t*d-s)*(2*Math.PI)/p )) + b; + }, + + /** + * Snap out elastic effect. + * @method elasticOut + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @param {Number} a Amplitude (optional) + * @param {Number} p Period (optional) + * @return {Number} The computed value for the current animation frame + */ + elasticOut: function (t, b, c, d, a, p) { + if (t == 0) { + return b; + } + if ( (t /= d) == 1 ) { + return b+c; + } + if (!p) { + p=d*.3; + } + + if (!a || a < Math.abs(c)) { + a = c; + var s = p / 4; + } + else { + var s = p/(2*Math.PI) * Math.asin (c/a); + } + + return a*Math.pow(2,-10*t) * Math.sin( (t*d-s)*(2*Math.PI)/p ) + c + b; + }, + + /** + * Snap both elastic effect. + * @method elasticBoth + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @param {Number} a Amplitude (optional) + * @param {Number} p Period (optional) + * @return {Number} The computed value for the current animation frame + */ + elasticBoth: function (t, b, c, d, a, p) { + if (t == 0) { + return b; + } + + if ( (t /= d/2) == 2 ) { + return b+c; + } + + if (!p) { + p = d*(.3*1.5); + } + + if ( !a || a < Math.abs(c) ) { + a = c; + var s = p/4; + } + else { + var s = p/(2*Math.PI) * Math.asin (c/a); + } + + if (t < 1) { + return -.5*(a*Math.pow(2,10*(t-=1)) * + Math.sin( (t*d-s)*(2*Math.PI)/p )) + b; + } + return a*Math.pow(2,-10*(t-=1)) * + Math.sin( (t*d-s)*(2*Math.PI)/p )*.5 + c + b; + }, + + + /** + * Backtracks slightly, then reverses direction and moves to end. + * @method backIn + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @param {Number} s Overshoot (optional) + * @return {Number} The computed value for the current animation frame + */ + backIn: function (t, b, c, d, s) { + if (typeof s == 'undefined') { + s = 1.70158; + } + return c*(t/=d)*t*((s+1)*t - s) + b; + }, + + /** + * Overshoots end, then reverses and comes back to end. + * @method backOut + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @param {Number} s Overshoot (optional) + * @return {Number} The computed value for the current animation frame + */ + backOut: function (t, b, c, d, s) { + if (typeof s == 'undefined') { + s = 1.70158; + } + return c*((t=t/d-1)*t*((s+1)*t + s) + 1) + b; + }, + + /** + * Backtracks slightly, then reverses direction, overshoots end, + * then reverses and comes back to end. + * @method backBoth + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @param {Number} s Overshoot (optional) + * @return {Number} The computed value for the current animation frame + */ + backBoth: function (t, b, c, d, s) { + if (typeof s == 'undefined') { + s = 1.70158; + } + + if ((t /= d/2 ) < 1) { + return c/2*(t*t*(((s*=(1.525))+1)*t - s)) + b; + } + return c/2*((t-=2)*t*(((s*=(1.525))+1)*t + s) + 2) + b; + }, + + /** + * Bounce off of start. + * @method bounceIn + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + bounceIn: function (t, b, c, d) { + return c - YAHOO.util.Easing.bounceOut(d-t, 0, c, d) + b; + }, + + /** + * Bounces off end. + * @method bounceOut + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + bounceOut: function (t, b, c, d) { + if ((t/=d) < (1/2.75)) { + return c*(7.5625*t*t) + b; + } else if (t < (2/2.75)) { + return c*(7.5625*(t-=(1.5/2.75))*t + .75) + b; + } else if (t < (2.5/2.75)) { + return c*(7.5625*(t-=(2.25/2.75))*t + .9375) + b; + } + return c*(7.5625*(t-=(2.625/2.75))*t + .984375) + b; + }, + + /** + * Bounces off start and end. + * @method bounceBoth + * @param {Number} t Time value used to compute current value + * @param {Number} b Starting value + * @param {Number} c Delta between start and end values + * @param {Number} d Total length of animation + * @return {Number} The computed value for the current animation frame + */ + bounceBoth: function (t, b, c, d) { + if (t < d/2) { + return YAHOO.util.Easing.bounceIn(t*2, 0, c, d) * .5 + b; + } + return YAHOO.util.Easing.bounceOut(t*2-d, 0, c, d) * .5 + c*.5 + b; + } +}; + +(function() { +/** + * Anim subclass for moving elements along a path defined by the "points" + * member of "attributes". All "points" are arrays with x, y coordinates. + * <p>Usage: <code>var myAnim = new YAHOO.util.Motion(el, { points: { to: [800, 800] } }, 1, YAHOO.util.Easing.easeOut);</code></p> + * @class Motion + * @namespace YAHOO.util + * @requires YAHOO.util.Anim + * @requires YAHOO.util.AnimMgr + * @requires YAHOO.util.Easing + * @requires YAHOO.util.Bezier + * @requires YAHOO.util.Dom + * @requires YAHOO.util.Event + * @requires YAHOO.util.CustomEvent + * @constructor + * @extends YAHOO.util.ColorAnim + * @param {String | HTMLElement} el Reference to the element that will be animated + * @param {Object} attributes The attribute(s) to be animated. + * Each attribute is an object with at minimum a "to" or "by" member defined. + * Additional optional members are "from" (defaults to current value), "units" (defaults to "px"). + * All attribute names use camelCase. + * @param {Number} duration (optional, defaults to 1 second) Length of animation (frames or seconds), defaults to time-based + * @param {Function} method (optional, defaults to YAHOO.util.Easing.easeNone) Computes the values that are applied to the attributes per frame (generally a YAHOO.util.Easing method) + */ + var Motion = function(el, attributes, duration, method) { + if (el) { // dont break existing subclasses not using YAHOO.extend + Motion.superclass.constructor.call(this, el, attributes, duration, method); + } + }; + + + Motion.NAME = 'Motion'; + + // shorthand + var Y = YAHOO.util; + YAHOO.extend(Motion, Y.ColorAnim); + + var superclass = Motion.superclass; + var proto = Motion.prototype; + + proto.patterns.points = /^points$/i; + + proto.setAttribute = function(attr, val, unit) { + if ( this.patterns.points.test(attr) ) { + unit = unit || 'px'; + superclass.setAttribute.call(this, 'left', val[0], unit); + superclass.setAttribute.call(this, 'top', val[1], unit); + } else { + superclass.setAttribute.call(this, attr, val, unit); + } + }; + + proto.getAttribute = function(attr) { + if ( this.patterns.points.test(attr) ) { + var val = [ + superclass.getAttribute.call(this, 'left'), + superclass.getAttribute.call(this, 'top') + ]; + } else { + val = superclass.getAttribute.call(this, attr); + } + + return val; + }; + + proto.doMethod = function(attr, start, end) { + var val = null; + + if ( this.patterns.points.test(attr) ) { + var t = this.method(this.currentFrame, 0, 100, this.totalFrames) / 100; + val = Y.Bezier.getPosition(this.runtimeAttributes[attr], t); + } else { + val = superclass.doMethod.call(this, attr, start, end); + } + return val; + }; + + proto.setRuntimeAttribute = function(attr) { + if ( this.patterns.points.test(attr) ) { + var el = this.getEl(); + var attributes = this.attributes; + var start; + var control = attributes['points']['control'] || []; + var end; + var i, len; + + if (control.length > 0 && !(control[0] instanceof Array) ) { // could be single point or array of points + control = [control]; + } else { // break reference to attributes.points.control + var tmp = []; + for (i = 0, len = control.length; i< len; ++i) { + tmp[i] = control[i]; + } + control = tmp; + } + + if (Y.Dom.getStyle(el, 'position') == 'static') { // default to relative + Y.Dom.setStyle(el, 'position', 'relative'); + } + + if ( isset(attributes['points']['from']) ) { + Y.Dom.setXY(el, attributes['points']['from']); // set position to from point + } + else { Y.Dom.setXY( el, Y.Dom.getXY(el) ); } // set it to current position + + start = this.getAttribute('points'); // get actual top & left + + // TO beats BY, per SMIL 2.1 spec + if ( isset(attributes['points']['to']) ) { + end = translateValues.call(this, attributes['points']['to'], start); + + var pageXY = Y.Dom.getXY(this.getEl()); + for (i = 0, len = control.length; i < len; ++i) { + control[i] = translateValues.call(this, control[i], start); + } + + + } else if ( isset(attributes['points']['by']) ) { + end = [ start[0] + attributes['points']['by'][0], start[1] + attributes['points']['by'][1] ]; + + for (i = 0, len = control.length; i < len; ++i) { + control[i] = [ start[0] + control[i][0], start[1] + control[i][1] ]; + } + } + + this.runtimeAttributes[attr] = [start]; + + if (control.length > 0) { + this.runtimeAttributes[attr] = this.runtimeAttributes[attr].concat(control); + } + + this.runtimeAttributes[attr][this.runtimeAttributes[attr].length] = end; + } + else { + superclass.setRuntimeAttribute.call(this, attr); + } + }; + + var translateValues = function(val, start) { + var pageXY = Y.Dom.getXY(this.getEl()); + val = [ val[0] - pageXY[0] + start[0], val[1] - pageXY[1] + start[1] ]; + + return val; + }; + + var isset = function(prop) { + return (typeof prop !== 'undefined'); + }; + + Y.Motion = Motion; +})(); +(function() { +/** + * Anim subclass for scrolling elements to a position defined by the "scroll" + * member of "attributes". All "scroll" members are arrays with x, y scroll positions. + * <p>Usage: <code>var myAnim = new YAHOO.util.Scroll(el, { scroll: { to: [0, 800] } }, 1, YAHOO.util.Easing.easeOut);</code></p> + * @class Scroll + * @namespace YAHOO.util + * @requires YAHOO.util.Anim + * @requires YAHOO.util.AnimMgr + * @requires YAHOO.util.Easing + * @requires YAHOO.util.Bezier + * @requires YAHOO.util.Dom + * @requires YAHOO.util.Event + * @requires YAHOO.util.CustomEvent + * @extends YAHOO.util.ColorAnim + * @constructor + * @param {String or HTMLElement} el Reference to the element that will be animated + * @param {Object} attributes The attribute(s) to be animated. + * Each attribute is an object with at minimum a "to" or "by" member defined. + * Additional optional members are "from" (defaults to current value), "units" (defaults to "px"). + * All attribute names use camelCase. + * @param {Number} duration (optional, defaults to 1 second) Length of animation (frames or seconds), defaults to time-based + * @param {Function} method (optional, defaults to YAHOO.util.Easing.easeNone) Computes the values that are applied to the attributes per frame (generally a YAHOO.util.Easing method) + */ + var Scroll = function(el, attributes, duration, method) { + if (el) { // dont break existing subclasses not using YAHOO.extend + Scroll.superclass.constructor.call(this, el, attributes, duration, method); + } + }; + + Scroll.NAME = 'Scroll'; + + // shorthand + var Y = YAHOO.util; + YAHOO.extend(Scroll, Y.ColorAnim); + + var superclass = Scroll.superclass; + var proto = Scroll.prototype; + + proto.doMethod = function(attr, start, end) { + var val = null; + + if (attr == 'scroll') { + val = [ + this.method(this.currentFrame, start[0], end[0] - start[0], this.totalFrames), + this.method(this.currentFrame, start[1], end[1] - start[1], this.totalFrames) + ]; + + } else { + val = superclass.doMethod.call(this, attr, start, end); + } + return val; + }; + + proto.getAttribute = function(attr) { + var val = null; + var el = this.getEl(); + + if (attr == 'scroll') { + val = [ el.scrollLeft, el.scrollTop ]; + } else { + val = superclass.getAttribute.call(this, attr); + } + + return val; + }; + + proto.setAttribute = function(attr, val, unit) { + var el = this.getEl(); + + if (attr == 'scroll') { + el.scrollLeft = val[0]; + el.scrollTop = val[1]; + } else { + superclass.setAttribute.call(this, attr, val, unit); + } + }; + + Y.Scroll = Scroll; +})(); +YAHOO.register("animation", YAHOO.util.Anim, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/button.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/button.js new file mode 100644 index 0000000..d368071 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/button.js
@@ -0,0 +1,4696 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/** +* @module button +* @description <p>The Button Control enables the creation of rich, graphical +* buttons that function like traditional HTML form buttons. <em>Unlike</em> +* tradition HTML form buttons, buttons created with the Button Control can have +* a label that is different from its value. With the inclusion of the optional +* <a href="module_menu.html">Menu Control</a>, the Button Control can also be +* used to create menu buttons and split buttons, controls that are not +* available natively in HTML. The Button Control can also be thought of as a +* way to create more visually engaging implementations of the browser's +* default radio-button and check-box controls.</p> +* <p>The Button Control supports the following types:</p> +* <dl> +* <dt>push</dt> +* <dd>Basic push button that can execute a user-specified command when +* pressed.</dd> +* <dt>link</dt> +* <dd>Navigates to a specified url when pressed.</dd> +* <dt>submit</dt> +* <dd>Submits the parent form when pressed.</dd> +* <dt>reset</dt> +* <dd>Resets the parent form when pressed.</dd> +* <dt>checkbox</dt> +* <dd>Maintains a "checked" state that can be toggled on and off.</dd> +* <dt>radio</dt> +* <dd>Maintains a "checked" state that can be toggled on and off. Use with +* the ButtonGroup class to create a set of controls that are mutually +* exclusive; checking one button in the set will uncheck all others in +* the group.</dd> +* <dt>menu</dt> +* <dd>When pressed will show/hide a menu.</dd> +* <dt>split</dt> +* <dd>Can execute a user-specified command or display a menu when pressed.</dd> +* </dl> +* @title Button +* @namespace YAHOO.widget +* @requires yahoo, dom, element, event +* @optional container, menu +*/ + + +(function () { + + + /** + * The Button class creates a rich, graphical button. + * @param {String} p_oElement String specifying the id attribute of the + * <code><input></code>, <code><button></code>, + * <code><a></code>, or <code><span></code> element to + * be used to create the button. + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level- + * one-html.html#ID-6043025">HTMLInputElement</a>|<a href="http://www.w3.org + * /TR/2000/WD-DOM-Level-1-20000929/level-one-html.html#ID-34812697"> + * HTMLButtonElement</a>|<a href=" + * http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level-one-html.html# + * ID-33759296">HTMLElement</a>} p_oElement Object reference for the + * <code><input></code>, <code><button></code>, + * <code><a></code>, or <code><span></code> element to be + * used to create the button. + * @param {Object} p_oElement Object literal specifying a set of + * configuration attributes used to create the button. + * @param {Object} p_oAttributes Optional. Object literal specifying a set + * of configuration attributes used to create the button. + * @namespace YAHOO.widget + * @class Button + * @constructor + * @extends YAHOO.util.Element + */ + + + + // Shorthard for utilities + + var Dom = YAHOO.util.Dom, + Event = YAHOO.util.Event, + Lang = YAHOO.lang, + UA = YAHOO.env.ua, + Overlay = YAHOO.widget.Overlay, + Menu = YAHOO.widget.Menu, + + + // Private member variables + + m_oButtons = {}, // Collection of all Button instances + m_oOverlayManager = null, // YAHOO.widget.OverlayManager instance + m_oSubmitTrigger = null, // The button that submitted the form + m_oFocusedButton = null; // The button that has focus + + + + // Private methods + + + + /** + * @method createInputElement + * @description Creates an <code><input></code> element of the + * specified type. + * @private + * @param {String} p_sType String specifying the type of + * <code><input></code> element to create. + * @param {String} p_sName String specifying the name of + * <code><input></code> element to create. + * @param {String} p_sValue String specifying the value of + * <code><input></code> element to create. + * @param {String} p_bChecked Boolean specifying if the + * <code><input></code> element is to be checked. + * @return {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level- + * one-html.html#ID-6043025">HTMLInputElement</a>} + */ + function createInputElement(p_sType, p_sName, p_sValue, p_bChecked) { + + var oInput, + sInput; + + if (Lang.isString(p_sType) && Lang.isString(p_sName)) { + + if (UA.ie) { + + /* + For IE it is necessary to create the element with the + "type," "name," "value," and "checked" properties set all + at once. + */ + + sInput = "<input type=\"" + p_sType + "\" name=\"" + + p_sName + "\""; + + if (p_bChecked) { + + sInput += " checked"; + + } + + sInput += ">"; + + oInput = document.createElement(sInput); + + } + else { + + oInput = document.createElement("input"); + oInput.name = p_sName; + oInput.type = p_sType; + + if (p_bChecked) { + + oInput.checked = true; + + } + + } + + oInput.value = p_sValue; + + return oInput; + + } + + } + + + /** + * @method setAttributesFromSrcElement + * @description Gets the values for all the attributes of the source element + * (either <code><input></code> or <code><a></code>) that + * map to Button configuration attributes and sets them into a collection + * that is passed to the Button constructor. + * @private + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level- + * one-html.html#ID-6043025">HTMLInputElement</a>|<a href="http://www.w3.org/ + * TR/2000/WD-DOM-Level-1-20000929/level-one-html.html#ID- + * 48250443">HTMLAnchorElement</a>} p_oElement Object reference to the HTML + * element (either <code><input></code> or <code><span> + * </code>) used to create the button. + * @param {Object} p_oAttributes Object reference for the collection of + * configuration attributes used to create the button. + */ + function setAttributesFromSrcElement(p_oElement, p_oAttributes) { + + var sSrcElementNodeName = p_oElement.nodeName.toUpperCase(), + me = this, + oAttribute, + oRootNode, + sText; + + + /** + * @method setAttributeFromDOMAttribute + * @description Gets the value of the specified DOM attribute and sets it + * into the collection of configuration attributes used to configure + * the button. + * @private + * @param {String} p_sAttribute String representing the name of the + * attribute to retrieve from the DOM element. + */ + function setAttributeFromDOMAttribute(p_sAttribute) { + + if (!(p_sAttribute in p_oAttributes)) { + + /* + Need to use "getAttributeNode" instead of "getAttribute" + because using "getAttribute," IE will return the innerText + of a <code><button></code> for the value attribute + rather than the value of the "value" attribute. + */ + + oAttribute = p_oElement.getAttributeNode(p_sAttribute); + + + if (oAttribute && ("value" in oAttribute)) { + + + p_oAttributes[p_sAttribute] = oAttribute.value; + + } + + } + + } + + + /** + * @method setFormElementProperties + * @description Gets the value of the attributes from the form element + * and sets them into the collection of configuration attributes used to + * configure the button. + * @private + */ + function setFormElementProperties() { + + setAttributeFromDOMAttribute("type"); + + if (p_oAttributes.type == "button") { + + p_oAttributes.type = "push"; + + } + + if (!("disabled" in p_oAttributes)) { + + p_oAttributes.disabled = p_oElement.disabled; + + } + + setAttributeFromDOMAttribute("name"); + setAttributeFromDOMAttribute("value"); + setAttributeFromDOMAttribute("title"); + + } + + + switch (sSrcElementNodeName) { + + case "A": + + p_oAttributes.type = "link"; + + setAttributeFromDOMAttribute("href"); + setAttributeFromDOMAttribute("target"); + + break; + + case "INPUT": + + setFormElementProperties(); + + if (!("checked" in p_oAttributes)) { + + p_oAttributes.checked = p_oElement.checked; + + } + + break; + + case "BUTTON": + + setFormElementProperties(); + + oRootNode = p_oElement.parentNode.parentNode; + + if (Dom.hasClass(oRootNode, this.CSS_CLASS_NAME + "-checked")) { + + p_oAttributes.checked = true; + + } + + if (Dom.hasClass(oRootNode, this.CSS_CLASS_NAME + "-disabled")) { + + p_oAttributes.disabled = true; + + } + + p_oElement.removeAttribute("value"); + + p_oElement.setAttribute("type", "button"); + + break; + + } + + p_oElement.removeAttribute("id"); + p_oElement.removeAttribute("name"); + + if (!("tabindex" in p_oAttributes)) { + + p_oAttributes.tabindex = p_oElement.tabIndex; + + } + + if (!("label" in p_oAttributes)) { + + // Set the "label" property + + sText = sSrcElementNodeName == "INPUT" ? + p_oElement.value : p_oElement.innerHTML; + + + if (sText && sText.length > 0) { + + p_oAttributes.label = sText; + + } + + } + + } + + + /** + * @method initConfig + * @description Initializes the set of configuration attributes that are + * used to instantiate the button. + * @private + * @param {Object} Object representing the button's set of + * configuration attributes. + */ + function initConfig(p_oConfig) { + + var oAttributes = p_oConfig.attributes, + oSrcElement = oAttributes.srcelement, + sSrcElementNodeName = oSrcElement.nodeName.toUpperCase(), + me = this; + + + if (sSrcElementNodeName == this.NODE_NAME) { + + p_oConfig.element = oSrcElement; + p_oConfig.id = oSrcElement.id; + + Dom.getElementsBy(function (p_oElement) { + + switch (p_oElement.nodeName.toUpperCase()) { + + case "BUTTON": + case "A": + case "INPUT": + + setAttributesFromSrcElement.call(me, p_oElement, + oAttributes); + + break; + + } + + }, "*", oSrcElement); + + } + else { + + switch (sSrcElementNodeName) { + + case "BUTTON": + case "A": + case "INPUT": + + setAttributesFromSrcElement.call(this, oSrcElement, + oAttributes); + + break; + + } + + } + + } + + + + // Constructor + + YAHOO.widget.Button = function (p_oElement, p_oAttributes) { + + if (!Overlay && YAHOO.widget.Overlay) { + + Overlay = YAHOO.widget.Overlay; + + } + + + if (!Menu && YAHOO.widget.Menu) { + + Menu = YAHOO.widget.Menu; + + } + + + var fnSuperClass = YAHOO.widget.Button.superclass.constructor, + oConfig, + oElement; + + if (arguments.length == 1 && !Lang.isString(p_oElement) && + !p_oElement.nodeName) { + + if (!p_oElement.id) { + + p_oElement.id = Dom.generateId(); + + + } + + + + fnSuperClass.call(this, + (this.createButtonElement(p_oElement.type)), + p_oElement); + + } + else { + + oConfig = { element: null, attributes: (p_oAttributes || {}) }; + + + if (Lang.isString(p_oElement)) { + + oElement = Dom.get(p_oElement); + + if (oElement) { + + if (!oConfig.attributes.id) { + + oConfig.attributes.id = p_oElement; + + } + + + + + oConfig.attributes.srcelement = oElement; + + initConfig.call(this, oConfig); + + + if (!oConfig.element) { + + + oConfig.element = + this.createButtonElement(oConfig.attributes.type); + + } + + fnSuperClass.call(this, oConfig.element, + oConfig.attributes); + + } + + } + else if (p_oElement.nodeName) { + + if (!oConfig.attributes.id) { + + if (p_oElement.id) { + + oConfig.attributes.id = p_oElement.id; + + } + else { + + oConfig.attributes.id = Dom.generateId(); + + + } + + } + + + + + + oConfig.attributes.srcelement = p_oElement; + + initConfig.call(this, oConfig); + + + if (!oConfig.element) { + + + oConfig.element = + this.createButtonElement(oConfig.attributes.type); + + } + + fnSuperClass.call(this, oConfig.element, oConfig.attributes); + + } + + } + + }; + + + + YAHOO.extend(YAHOO.widget.Button, YAHOO.util.Element, { + + + // Protected properties + + + /** + * @property _button + * @description Object reference to the button's internal + * <code><a></code> or <code><button></code> element. + * @default null + * @protected + * @type <a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-48250443">HTMLAnchorElement</a>|<a href=" + * http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level-one-html.html + * #ID-34812697">HTMLButtonElement</a> + */ + _button: null, + + + /** + * @property _menu + * @description Object reference to the button's menu. + * @default null + * @protected + * @type {<a href="YAHOO.widget.Overlay.html">YAHOO.widget.Overlay</a>| + * <a href="YAHOO.widget.Menu.html">YAHOO.widget.Menu</a>} + */ + _menu: null, + + + /** + * @property _hiddenFields + * @description Object reference to the <code><input></code> + * element, or array of HTML form elements used to represent the button + * when its parent form is submitted. + * @default null + * @protected + * @type <a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-6043025">HTMLInputElement</a>|Array + */ + _hiddenFields: null, + + + /** + * @property _onclickAttributeValue + * @description Object reference to the button's current value for the + * "onclick" configuration attribute. + * @default null + * @protected + * @type Object + */ + _onclickAttributeValue: null, + + + /** + * @property _activationKeyPressed + * @description Boolean indicating if the key(s) that toggle the button's + * "active" state have been pressed. + * @default false + * @protected + * @type Boolean + */ + _activationKeyPressed: false, + + + /** + * @property _activationButtonPressed + * @description Boolean indicating if the mouse button that toggles + * the button's "active" state has been pressed. + * @default false + * @protected + * @type Boolean + */ + _activationButtonPressed: false, + + + /** + * @property _hasKeyEventHandlers + * @description Boolean indicating if the button's "blur", "keydown" and + * "keyup" event handlers are assigned + * @default false + * @protected + * @type Boolean + */ + _hasKeyEventHandlers: false, + + + /** + * @property _hasMouseEventHandlers + * @description Boolean indicating if the button's "mouseout," + * "mousedown," and "mouseup" event handlers are assigned + * @default false + * @protected + * @type Boolean + */ + _hasMouseEventHandlers: false, + + + + // Constants + + + /** + * @property NODE_NAME + * @description The name of the node to be used for the button's + * root element. + * @default "SPAN" + * @final + * @type String + */ + NODE_NAME: "SPAN", + + + /** + * @property CHECK_ACTIVATION_KEYS + * @description Array of numbers representing keys that (when pressed) + * toggle the button's "checked" attribute. + * @default [32] + * @final + * @type Array + */ + CHECK_ACTIVATION_KEYS: [32], + + + /** + * @property ACTIVATION_KEYS + * @description Array of numbers representing keys that (when presed) + * toggle the button's "active" state. + * @default [13, 32] + * @final + * @type Array + */ + ACTIVATION_KEYS: [13, 32], + + + /** + * @property OPTION_AREA_WIDTH + * @description Width (in pixels) of the area of a split button that + * when pressed will display a menu. + * @default 20 + * @final + * @type Number + */ + OPTION_AREA_WIDTH: 20, + + + /** + * @property CSS_CLASS_NAME + * @description String representing the CSS class(es) to be applied to + * the button's root element. + * @default "yui-button" + * @final + * @type String + */ + CSS_CLASS_NAME: "yui-button", + + + /** + * @property RADIO_DEFAULT_TITLE + * @description String representing the default title applied to buttons + * of type "radio." + * @default "Unchecked. Click to check." + * @final + * @type String + */ + RADIO_DEFAULT_TITLE: "Unchecked. Click to check.", + + + /** + * @property RADIO_CHECKED_TITLE + * @description String representing the title applied to buttons of + * type "radio" when checked. + * @default "Checked. Click another button to uncheck" + * @final + * @type String + */ + RADIO_CHECKED_TITLE: "Checked. Click another button to uncheck", + + + /** + * @property CHECKBOX_DEFAULT_TITLE + * @description String representing the default title applied to + * buttons of type "checkbox." + * @default "Unchecked. Click to check." + * @final + * @type String + */ + CHECKBOX_DEFAULT_TITLE: "Unchecked. Click to check.", + + + /** + * @property CHECKBOX_CHECKED_TITLE + * @description String representing the title applied to buttons of type + * "checkbox" when checked. + * @default "Checked. Click to uncheck." + * @final + * @type String + */ + CHECKBOX_CHECKED_TITLE: "Checked. Click to uncheck.", + + + /** + * @property MENUBUTTON_DEFAULT_TITLE + * @description String representing the default title applied to + * buttons of type "menu." + * @default "Menu collapsed. Click to expand." + * @final + * @type String + */ + MENUBUTTON_DEFAULT_TITLE: "Menu collapsed. Click to expand.", + + + /** + * @property MENUBUTTON_MENU_VISIBLE_TITLE + * @description String representing the title applied to buttons of type + * "menu" when the button's menu is visible. + * @default "Menu expanded. Click or press Esc to collapse." + * @final + * @type String + */ + MENUBUTTON_MENU_VISIBLE_TITLE: + "Menu expanded. Click or press Esc to collapse.", + + + /** + * @property SPLITBUTTON_DEFAULT_TITLE + * @description String representing the default title applied to + * buttons of type "split." + * @default "Menu collapsed. Click inside option region or press + * Ctrl + Shift + M to show the menu." + * @final + * @type String + */ + SPLITBUTTON_DEFAULT_TITLE: ("Menu collapsed. Click inside option " + + "region or press Ctrl + Shift + M to show the menu."), + + + /** + * @property SPLITBUTTON_OPTION_VISIBLE_TITLE + * @description String representing the title applied to buttons of type + * "split" when the button's menu is visible. + * @default "Menu expanded. Press Esc or Ctrl + Shift + M to hide + * the menu." + * @final + * @type String + */ + SPLITBUTTON_OPTION_VISIBLE_TITLE: + "Menu expanded. Press Esc or Ctrl + Shift + M to hide the menu.", + + + /** + * @property SUBMIT_TITLE + * @description String representing the title applied to buttons of + * type "submit." + * @default "Click to submit form." + * @final + * @type String + */ + SUBMIT_TITLE: "Click to submit form.", + + + + // Protected attribute setter methods + + + /** + * @method _setType + * @description Sets the value of the button's "type" attribute. + * @protected + * @param {String} p_sType String indicating the value for the button's + * "type" attribute. + */ + _setType: function (p_sType) { + + if (p_sType == "split") { + + this.on("option", this._onOption); + + } + + }, + + + /** + * @method _setLabel + * @description Sets the value of the button's "label" attribute. + * @protected + * @param {String} p_sLabel String indicating the value for the button's + * "label" attribute. + */ + _setLabel: function (p_sLabel) { + + this._button.innerHTML = p_sLabel; + + + /* + Remove and add the default class name from the root element + for Gecko to ensure that the button shrinkwraps to the label. + Without this the button will not be rendered at the correct + width when the label changes. The most likely cause for this + bug is button's use of the Gecko-specific CSS display type of + "-moz-inline-box" to simulate "inline-block" supported by IE, + Safari and Opera. + */ + + var sClass, + nGeckoVersion = UA.gecko; + + + if (nGeckoVersion && nGeckoVersion < 1.9 && Dom.inDocument(this.get("element"))) { + + sClass = this.CSS_CLASS_NAME; + + this.removeClass(sClass); + + Lang.later(0, this, this.addClass, sClass); + + } + + }, + + + /** + * @method _setTabIndex + * @description Sets the value of the button's "tabindex" attribute. + * @protected + * @param {Number} p_nTabIndex Number indicating the value for the + * button's "tabindex" attribute. + */ + _setTabIndex: function (p_nTabIndex) { + + this._button.tabIndex = p_nTabIndex; + + }, + + + /** + * @method _setTitle + * @description Sets the value of the button's "title" attribute. + * @protected + * @param {String} p_nTabIndex Number indicating the value for + * the button's "title" attribute. + */ + _setTitle: function (p_sTitle) { + + var sTitle = p_sTitle; + + if (this.get("type") != "link") { + + if (!sTitle) { + + switch (this.get("type")) { + + case "radio": + + sTitle = this.RADIO_DEFAULT_TITLE; + + break; + + case "checkbox": + + sTitle = this.CHECKBOX_DEFAULT_TITLE; + + break; + + case "menu": + + sTitle = this.MENUBUTTON_DEFAULT_TITLE; + + break; + + case "split": + + sTitle = this.SPLITBUTTON_DEFAULT_TITLE; + + break; + + case "submit": + + sTitle = this.SUBMIT_TITLE; + + break; + + } + + } + + this._button.title = sTitle; + + } + + }, + + + /** + * @method _setDisabled + * @description Sets the value of the button's "disabled" attribute. + * @protected + * @param {Boolean} p_bDisabled Boolean indicating the value for + * the button's "disabled" attribute. + */ + _setDisabled: function (p_bDisabled) { + + if (this.get("type") != "link") { + + if (p_bDisabled) { + + if (this._menu) { + + this._menu.hide(); + + } + + if (this.hasFocus()) { + + this.blur(); + + } + + this._button.setAttribute("disabled", "disabled"); + + this.addStateCSSClasses("disabled"); + + this.removeStateCSSClasses("hover"); + this.removeStateCSSClasses("active"); + this.removeStateCSSClasses("focus"); + + } + else { + + this._button.removeAttribute("disabled"); + + this.removeStateCSSClasses("disabled"); + + } + + } + + }, + + + /** + * @method _setHref + * @description Sets the value of the button's "href" attribute. + * @protected + * @param {String} p_sHref String indicating the value for the button's + * "href" attribute. + */ + _setHref: function (p_sHref) { + + if (this.get("type") == "link") { + + this._button.href = p_sHref; + + } + + }, + + + /** + * @method _setTarget + * @description Sets the value of the button's "target" attribute. + * @protected + * @param {String} p_sTarget String indicating the value for the button's + * "target" attribute. + */ + _setTarget: function (p_sTarget) { + + if (this.get("type") == "link") { + + this._button.setAttribute("target", p_sTarget); + + } + + }, + + + /** + * @method _setChecked + * @description Sets the value of the button's "target" attribute. + * @protected + * @param {Boolean} p_bChecked Boolean indicating the value for + * the button's "checked" attribute. + */ + _setChecked: function (p_bChecked) { + + var sType = this.get("type"), + sTitle; + + if (sType == "checkbox" || sType == "radio") { + + if (p_bChecked) { + + this.addStateCSSClasses("checked"); + + sTitle = (sType == "radio") ? + this.RADIO_CHECKED_TITLE : + this.CHECKBOX_CHECKED_TITLE; + + } + else { + + this.removeStateCSSClasses("checked"); + + sTitle = (sType == "radio") ? + this.RADIO_DEFAULT_TITLE : + this.CHECKBOX_DEFAULT_TITLE; + + } + + this.set("title", sTitle); + + } + + }, + + + /** + * @method _setMenu + * @description Sets the value of the button's "menu" attribute. + * @protected + * @param {Object} p_oMenu Object indicating the value for the button's + * "menu" attribute. + */ + _setMenu: function (p_oMenu) { + + var bLazyLoad = this.get("lazyloadmenu"), + oButtonElement = this.get("element"), + sMenuCSSClassName, + + /* + Boolean indicating if the value of p_oMenu is an instance + of YAHOO.widget.Menu or YAHOO.widget.Overlay. + */ + + bInstance = false, + + + oMenu, + oMenuElement, + oSrcElement, + aItems, + nItems, + oItem, + i; + + + if (!Overlay) { + + + return false; + + } + + + if (Menu) { + + sMenuCSSClassName = Menu.prototype.CSS_CLASS_NAME; + + } + + + function onAppendTo() { + + oMenu.render(oButtonElement.parentNode); + + this.removeListener("appendTo", onAppendTo); + + } + + + function initMenu() { + + if (oMenu) { + + Dom.addClass(oMenu.element, this.get("menuclassname")); + Dom.addClass(oMenu.element, + "yui-" + this.get("type") + "-button-menu"); + + oMenu.showEvent.subscribe(this._onMenuShow, null, this); + oMenu.hideEvent.subscribe(this._onMenuHide, null, this); + oMenu.renderEvent.subscribe(this._onMenuRender, null, this); + + + if (Menu && oMenu instanceof Menu) { + + oMenu.keyDownEvent.subscribe(this._onMenuKeyDown, + this, true); + + oMenu.subscribe("click", this._onMenuClick, + this, true); + + oMenu.itemAddedEvent.subscribe(this._onMenuItemAdded, + this, true); + + oSrcElement = oMenu.srcElement; + + if (oSrcElement && + oSrcElement.nodeName.toUpperCase() == "SELECT") { + + oSrcElement.style.display = "none"; + oSrcElement.parentNode.removeChild(oSrcElement); + + } + + } + else if (Overlay && oMenu instanceof Overlay) { + + if (!m_oOverlayManager) { + + m_oOverlayManager = + new YAHOO.widget.OverlayManager(); + + } + + m_oOverlayManager.register(oMenu); + + } + + + this._menu = oMenu; + + + if (!bInstance) { + + if (bLazyLoad && Menu && !(oMenu instanceof Menu)) { + + /* + Mimic Menu's "lazyload" functionality by adding + a "beforeshow" event listener that renders the + Overlay instance before it is made visible by + the button. + */ + + oMenu.beforeShowEvent.subscribe( + this._onOverlayBeforeShow, null, this); + + } + else if (!bLazyLoad) { + + if (Dom.inDocument(oButtonElement)) { + + oMenu.render(oButtonElement.parentNode); + + } + else { + + this.on("appendTo", onAppendTo); + + } + + } + + } + + } + + } + + + if (p_oMenu && Menu && (p_oMenu instanceof Menu)) { + + oMenu = p_oMenu; + aItems = oMenu.getItems(); + nItems = aItems.length; + bInstance = true; + + + if (nItems > 0) { + + i = nItems - 1; + + do { + + oItem = aItems[i]; + + if (oItem) { + + oItem.cfg.subscribeToConfigEvent("selected", + this._onMenuItemSelected, + oItem, + this); + + } + + } + while (i--); + + } + + initMenu.call(this); + + } + else if (Overlay && p_oMenu && (p_oMenu instanceof Overlay)) { + + oMenu = p_oMenu; + bInstance = true; + + oMenu.cfg.setProperty("visible", false); + oMenu.cfg.setProperty("context", [oButtonElement, "tl", "bl"]); + + initMenu.call(this); + + } + else if (Menu && Lang.isArray(p_oMenu)) { + + this.on("appendTo", function () { + + oMenu = new Menu(Dom.generateId(), { lazyload: bLazyLoad, + itemdata: p_oMenu }); + + initMenu.call(this); + + }); + + } + else if (Lang.isString(p_oMenu)) { + + oMenuElement = Dom.get(p_oMenu); + + if (oMenuElement) { + + if (Menu && Dom.hasClass(oMenuElement, sMenuCSSClassName) || + oMenuElement.nodeName.toUpperCase() == "SELECT") { + + oMenu = new Menu(p_oMenu, { lazyload: bLazyLoad }); + + initMenu.call(this); + + } + else if (Overlay) { + + oMenu = new Overlay(p_oMenu, { visible: false, + context: [oButtonElement, "tl", "bl"] }); + + initMenu.call(this); + + } + + } + + } + else if (p_oMenu && p_oMenu.nodeName) { + + if (Menu && Dom.hasClass(p_oMenu, sMenuCSSClassName) || + p_oMenu.nodeName.toUpperCase() == "SELECT") { + + oMenu = new Menu(p_oMenu, { lazyload: bLazyLoad }); + + initMenu.call(this); + + } + else if (Overlay) { + + if (!p_oMenu.id) { + + Dom.generateId(p_oMenu); + + } + + oMenu = new Overlay(p_oMenu, { visible: false, + context: [oButtonElement, "tl", "bl"] }); + + initMenu.call(this); + + } + + } + + }, + + + /** + * @method _setOnClick + * @description Sets the value of the button's "onclick" attribute. + * @protected + * @param {Object} p_oObject Object indicating the value for the button's + * "onclick" attribute. + */ + _setOnClick: function (p_oObject) { + + /* + Remove any existing listeners if a "click" event handler + has already been specified. + */ + + if (this._onclickAttributeValue && + (this._onclickAttributeValue != p_oObject)) { + + this.removeListener("click", this._onclickAttributeValue.fn); + + this._onclickAttributeValue = null; + + } + + + if (!this._onclickAttributeValue && + Lang.isObject(p_oObject) && + Lang.isFunction(p_oObject.fn)) { + + this.on("click", p_oObject.fn, p_oObject.obj, p_oObject.scope); + + this._onclickAttributeValue = p_oObject; + + } + + }, + + + /** + * @method _setSelectedMenuItem + * @description Sets the value of the button's + * "selectedMenuItem" attribute. + * @protected + * @param {Number} p_nIndex Number representing the index of the item + * in the button's menu that is currently selected. + */ + _setSelectedMenuItem: function (p_nIndex) { + + var oMenu = this._menu, + oMenuItem; + + + if (Menu && oMenu && oMenu instanceof Menu) { + + oMenuItem = oMenu.getItem(p_nIndex); + + + if (oMenuItem && !oMenuItem.cfg.getProperty("selected")) { + + oMenuItem.cfg.setProperty("selected", true); + + } + + } + + }, + + + // Protected methods + + + + /** + * @method _isActivationKey + * @description Determines if the specified keycode is one that toggles + * the button's "active" state. + * @protected + * @param {Number} p_nKeyCode Number representing the keycode to + * be evaluated. + * @return {Boolean} + */ + _isActivationKey: function (p_nKeyCode) { + + var sType = this.get("type"), + aKeyCodes = (sType == "checkbox" || sType == "radio") ? + this.CHECK_ACTIVATION_KEYS : this.ACTIVATION_KEYS, + + nKeyCodes = aKeyCodes.length, + i; + + if (nKeyCodes > 0) { + + i = nKeyCodes - 1; + + do { + + if (p_nKeyCode == aKeyCodes[i]) { + + return true; + + } + + } + while (i--); + + } + + }, + + + /** + * @method _isSplitButtonOptionKey + * @description Determines if the specified keycode is one that toggles + * the display of the split button's menu. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + * @return {Boolean} + */ + _isSplitButtonOptionKey: function (p_oEvent) { + + var bShowMenu = (p_oEvent.ctrlKey && p_oEvent.shiftKey && + Event.getCharCode(p_oEvent) == 77); + + + function onKeyPress(p_oEvent) { + + Event.preventDefault(p_oEvent); + + this.removeListener("keypress", onKeyPress); + + } + + + /* + It is necessary to add a "keypress" event listener to prevent Opera's default + browser context menu from appearing when the user presses Ctrl + Shift + M. + */ + + if (bShowMenu && UA.opera) { + + this.on("keypress", onKeyPress); + + } + + return bShowMenu; + + }, + + + /** + * @method _addListenersToForm + * @description Adds event handlers to the button's form. + * @protected + */ + _addListenersToForm: function () { + + var oForm = this.getForm(), + onFormKeyPress = YAHOO.widget.Button.onFormKeyPress, + bHasKeyPressListener, + oSrcElement, + aListeners, + nListeners, + i; + + + if (oForm) { + + Event.on(oForm, "reset", this._onFormReset, null, this); + Event.on(oForm, "submit", this.createHiddenFields, null, this); + + oSrcElement = this.get("srcelement"); + + + if (this.get("type") == "submit" || + (oSrcElement && oSrcElement.type == "submit")) + { + + aListeners = Event.getListeners(oForm, "keypress"); + bHasKeyPressListener = false; + + if (aListeners) { + + nListeners = aListeners.length; + + if (nListeners > 0) { + + i = nListeners - 1; + + do { + + if (aListeners[i].fn == onFormKeyPress) { + + bHasKeyPressListener = true; + break; + + } + + } + while (i--); + + } + + } + + + if (!bHasKeyPressListener) { + + Event.on(oForm, "keypress", onFormKeyPress); + + } + + } + + } + + }, + + + + /** + * @method _showMenu + * @description Shows the button's menu. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event) that triggered + * the display of the menu. + */ + _showMenu: function (p_oEvent) { + + if (YAHOO.widget.MenuManager) { + + YAHOO.widget.MenuManager.hideVisible(); + + } + + + if (m_oOverlayManager) { + + m_oOverlayManager.hideAll(); + + } + + + var nViewportOffset = Overlay.VIEWPORT_OFFSET, + + oMenu = this._menu, + oButton = this, + oButtonEL = oButton.get("element"), + bMenuFlipped = false, + nButtonY = Dom.getY(oButtonEL), + nScrollTop = Dom.getDocumentScrollTop(), + nMenuMinScrollHeight, + nMenuHeight, + oMenuShadow; + + + if (nScrollTop) { + + nButtonY = nButtonY - nScrollTop; + + } + + + var nTopRegion = nButtonY, + nBottomRegion = (Dom.getViewportHeight() - + (nButtonY + oButtonEL.offsetHeight)); + + + /* + Uses the Button's position to calculate the availble height + above and below it to display its corresponding Menu. + */ + + function getMenuDisplayRegionHeight() { + + if (bMenuFlipped) { + + return (nTopRegion - nViewportOffset); + + } + else { + + return (nBottomRegion - nViewportOffset); + + } + + } + + + + /* + Sets the Menu's "maxheight" configuration property and trys to + place the Menu in the best possible position (either above or + below its corresponding Button). + */ + + function sizeAndPositionMenu() { + + var nDisplayRegionHeight = getMenuDisplayRegionHeight(); + + + if (nMenuHeight > nDisplayRegionHeight) { + + nMenuMinScrollHeight = oMenu.cfg.getProperty("minscrollheight"); + + + if (nDisplayRegionHeight > nMenuMinScrollHeight) { + + oMenu.cfg.setProperty("maxheight", + nDisplayRegionHeight); + + + if (bMenuFlipped) { + + oMenu.align("bl", "tl"); + + } + else { + + oMenu.align("tl", "bl"); + + } + + } + + + if (nDisplayRegionHeight < nMenuMinScrollHeight) { + + if (bMenuFlipped) { + + /* + All possible positions and values for the + "maxheight" configuration property have been + tried, but none were successful, so fall back + to the original size and position. + */ + + oMenu.cfg.setProperty("context", + [oButtonEL, "tl", "bl"], true); + + oMenu.align("tl", "bl"); + + } + else { + + oMenu.cfg.setProperty("context", + [oButtonEL, "bl", "tl"], true); + + oMenu.align("bl", "tl"); + + bMenuFlipped = true; + + return sizeAndPositionMenu(); + + } + + } + + } + + } + + + if (Menu && oMenu && (oMenu instanceof Menu)) { + + oMenu.cfg.applyConfig({ context: [oButtonEL, "tl", "bl"], clicktohide: false }); + + oMenu.cfg.fireQueue(); + + oMenu.show(); + + oMenu.cfg.setProperty("maxheight", 0); + + oMenu.align("tl", "bl"); + + + /* + Stop the propagation of the event so that the MenuManager + doesn't blur the menu after it gets focus. + */ + + if (p_oEvent.type == "mousedown") { + + Event.stopPropagation(p_oEvent); + + } + + + nMenuHeight = oMenu.element.offsetHeight; + + oMenuShadow = oMenu.element.lastChild; + + sizeAndPositionMenu(); + + if (this.get("focusmenu")) { + + this._menu.focus(); + + } + + } + else if (Overlay && oMenu && (oMenu instanceof Overlay)) { + + oMenu.show(); + oMenu.align("tl", "bl"); + + var nDisplayRegionHeight = getMenuDisplayRegionHeight(); + + nMenuHeight = oMenu.element.offsetHeight; + + + if (nDisplayRegionHeight < nMenuHeight) { + + oMenu.align("bl", "tl"); + + bMenuFlipped = true; + + nDisplayRegionHeight = getMenuDisplayRegionHeight(); + + if (nDisplayRegionHeight < nMenuHeight) { + + oMenu.align("tl", "bl"); + + } + + } + + } + + }, + + + /** + * @method _hideMenu + * @description Hides the button's menu. + * @protected + */ + _hideMenu: function () { + + var oMenu = this._menu; + + if (oMenu) { + + oMenu.hide(); + + } + + }, + + + + + // Protected event handlers + + + /** + * @method _onMouseOver + * @description "mouseover" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onMouseOver: function (p_oEvent) { + + if (!this._hasMouseEventHandlers) { + + this.on("mouseout", this._onMouseOut); + this.on("mousedown", this._onMouseDown); + this.on("mouseup", this._onMouseUp); + + this._hasMouseEventHandlers = true; + + } + + this.addStateCSSClasses("hover"); + + if (this._activationButtonPressed) { + + this.addStateCSSClasses("active"); + + } + + + if (this._bOptionPressed) { + + this.addStateCSSClasses("activeoption"); + + } + + + if (this._activationButtonPressed || this._bOptionPressed) { + + Event.removeListener(document, "mouseup", this._onDocumentMouseUp); + + } + + }, + + + /** + * @method _onMouseOut + * @description "mouseout" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onMouseOut: function (p_oEvent) { + + this.removeStateCSSClasses("hover"); + + if (this.get("type") != "menu") { + + this.removeStateCSSClasses("active"); + + } + + if (this._activationButtonPressed || this._bOptionPressed) { + + Event.on(document, "mouseup", this._onDocumentMouseUp, + null, this); + + } + + }, + + + /** + * @method _onDocumentMouseUp + * @description "mouseup" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onDocumentMouseUp: function (p_oEvent) { + + this._activationButtonPressed = false; + this._bOptionPressed = false; + + var sType = this.get("type"), + oTarget, + oMenuElement; + + if (sType == "menu" || sType == "split") { + + oTarget = Event.getTarget(p_oEvent); + oMenuElement = this._menu.element; + + if (oTarget != oMenuElement && + !Dom.isAncestor(oMenuElement, oTarget)) { + + this.removeStateCSSClasses((sType == "menu" ? + "active" : "activeoption")); + + this._hideMenu(); + + } + + } + + Event.removeListener(document, "mouseup", this._onDocumentMouseUp); + + }, + + + /** + * @method _onMouseDown + * @description "mousedown" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onMouseDown: function (p_oEvent) { + + var sType, + oElement, + nX, + me; + + + function onMouseUp() { + + this._hideMenu(); + this.removeListener("mouseup", onMouseUp); + + } + + + if ((p_oEvent.which || p_oEvent.button) == 1) { + + + if (!this.hasFocus()) { + + this.focus(); + + } + + + sType = this.get("type"); + + + if (sType == "split") { + + oElement = this.get("element"); + nX = Event.getPageX(p_oEvent) - Dom.getX(oElement); + + if ((oElement.offsetWidth - this.OPTION_AREA_WIDTH) < nX) { + + this.fireEvent("option", p_oEvent); + + } + else { + + this.addStateCSSClasses("active"); + + this._activationButtonPressed = true; + + } + + } + else if (sType == "menu") { + + if (this.isActive()) { + + this._hideMenu(); + + this._activationButtonPressed = false; + + } + else { + + this._showMenu(p_oEvent); + + this._activationButtonPressed = true; + + } + + } + else { + + this.addStateCSSClasses("active"); + + this._activationButtonPressed = true; + + } + + + + if (sType == "split" || sType == "menu") { + + me = this; + + this._hideMenuTimerId = window.setTimeout(function () { + + me.on("mouseup", onMouseUp); + + }, 250); + + } + + } + + }, + + + /** + * @method _onMouseUp + * @description "mouseup" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onMouseUp: function (p_oEvent) { + + var sType = this.get("type"); + + + if (this._hideMenuTimerId) { + + window.clearTimeout(this._hideMenuTimerId); + + } + + + if (sType == "checkbox" || sType == "radio") { + + this.set("checked", !(this.get("checked"))); + + } + + + this._activationButtonPressed = false; + + + if (this.get("type") != "menu") { + + this.removeStateCSSClasses("active"); + + } + + }, + + + /** + * @method _onFocus + * @description "focus" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onFocus: function (p_oEvent) { + + var oElement; + + this.addStateCSSClasses("focus"); + + if (this._activationKeyPressed) { + + this.addStateCSSClasses("active"); + + } + + m_oFocusedButton = this; + + + if (!this._hasKeyEventHandlers) { + + oElement = this._button; + + Event.on(oElement, "blur", this._onBlur, null, this); + Event.on(oElement, "keydown", this._onKeyDown, null, this); + Event.on(oElement, "keyup", this._onKeyUp, null, this); + + this._hasKeyEventHandlers = true; + + } + + + this.fireEvent("focus", p_oEvent); + + }, + + + /** + * @method _onBlur + * @description "blur" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onBlur: function (p_oEvent) { + + this.removeStateCSSClasses("focus"); + + if (this.get("type") != "menu") { + + this.removeStateCSSClasses("active"); + + } + + if (this._activationKeyPressed) { + + Event.on(document, "keyup", this._onDocumentKeyUp, null, this); + + } + + + m_oFocusedButton = null; + + this.fireEvent("blur", p_oEvent); + + }, + + + /** + * @method _onDocumentKeyUp + * @description "keyup" event handler for the document. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onDocumentKeyUp: function (p_oEvent) { + + if (this._isActivationKey(Event.getCharCode(p_oEvent))) { + + this._activationKeyPressed = false; + + Event.removeListener(document, "keyup", this._onDocumentKeyUp); + + } + + }, + + + /** + * @method _onKeyDown + * @description "keydown" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onKeyDown: function (p_oEvent) { + + var oMenu = this._menu; + + + if (this.get("type") == "split" && + this._isSplitButtonOptionKey(p_oEvent)) { + + this.fireEvent("option", p_oEvent); + + } + else if (this._isActivationKey(Event.getCharCode(p_oEvent))) { + + if (this.get("type") == "menu") { + + this._showMenu(p_oEvent); + + } + else { + + this._activationKeyPressed = true; + + this.addStateCSSClasses("active"); + + } + + } + + + if (oMenu && oMenu.cfg.getProperty("visible") && + Event.getCharCode(p_oEvent) == 27) { + + oMenu.hide(); + this.focus(); + + } + + }, + + + /** + * @method _onKeyUp + * @description "keyup" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onKeyUp: function (p_oEvent) { + + var sType; + + if (this._isActivationKey(Event.getCharCode(p_oEvent))) { + + sType = this.get("type"); + + if (sType == "checkbox" || sType == "radio") { + + this.set("checked", !(this.get("checked"))); + + } + + this._activationKeyPressed = false; + + if (this.get("type") != "menu") { + + this.removeStateCSSClasses("active"); + + } + + } + + }, + + + /** + * @method _onClick + * @description "click" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onClick: function (p_oEvent) { + + var sType = this.get("type"), + sTitle, + oForm, + oSrcElement, + oElement, + nX; + + + switch (sType) { + + case "radio": + case "checkbox": + + if (this.get("checked")) { + + sTitle = (sType == "radio") ? + this.RADIO_CHECKED_TITLE : + this.CHECKBOX_CHECKED_TITLE; + + } + else { + + sTitle = (sType == "radio") ? + this.RADIO_DEFAULT_TITLE : + this.CHECKBOX_DEFAULT_TITLE; + + } + + this.set("title", sTitle); + + break; + + case "submit": + + this.submitForm(); + + break; + + case "reset": + + oForm = this.getForm(); + + if (oForm) { + + oForm.reset(); + + } + + break; + + case "menu": + + sTitle = this._menu.cfg.getProperty("visible") ? + this.MENUBUTTON_MENU_VISIBLE_TITLE : + this.MENUBUTTON_DEFAULT_TITLE; + + this.set("title", sTitle); + + break; + + case "split": + + oElement = this.get("element"); + nX = Event.getPageX(p_oEvent) - Dom.getX(oElement); + + if ((oElement.offsetWidth - this.OPTION_AREA_WIDTH) < nX) { + + return false; + + } + else { + + this._hideMenu(); + + oSrcElement = this.get("srcelement"); + + if (oSrcElement && oSrcElement.type == "submit") { + + this.submitForm(); + + } + + } + + sTitle = this._menu.cfg.getProperty("visible") ? + this.SPLITBUTTON_OPTION_VISIBLE_TITLE : + this.SPLITBUTTON_DEFAULT_TITLE; + + this.set("title", sTitle); + + break; + + } + + }, + + + /** + * @method _onAppendTo + * @description "appendTo" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onAppendTo: function (p_oEvent) { + + /* + It is necessary to call "_addListenersToForm" using + "setTimeout" to make sure that the button's "form" property + returns a node reference. Sometimes, if you try to get the + reference immediately after appending the field, it is null. + */ + + var me = this; + + window.setTimeout(function () { + + me._addListenersToForm(); + + }, 0); + + }, + + + /** + * @method _onFormReset + * @description "reset" event handler for the button's form. + * @protected + * @param {Event} p_oEvent Object representing the DOM event + * object passed back by the event utility (YAHOO.util.Event). + */ + _onFormReset: function (p_oEvent) { + + var sType = this.get("type"), + oMenu = this._menu; + + if (sType == "checkbox" || sType == "radio") { + + this.resetValue("checked"); + + } + + + if (Menu && oMenu && (oMenu instanceof Menu)) { + + this.resetValue("selectedMenuItem"); + + } + + }, + + + /** + * @method _onDocumentMouseDown + * @description "mousedown" event handler for the document. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onDocumentMouseDown: function (p_oEvent) { + + var oTarget = Event.getTarget(p_oEvent), + oButtonElement = this.get("element"), + oMenuElement = this._menu.element; + + + if (oTarget != oButtonElement && + !Dom.isAncestor(oButtonElement, oTarget) && + oTarget != oMenuElement && + !Dom.isAncestor(oMenuElement, oTarget)) { + + this._hideMenu(); + + Event.removeListener(document, "mousedown", + this._onDocumentMouseDown); + + } + + }, + + + /** + * @method _onOption + * @description "option" event handler for the button. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onOption: function (p_oEvent) { + + if (this.hasClass("yui-split-button-activeoption")) { + + this._hideMenu(); + + this._bOptionPressed = false; + + } + else { + + this._showMenu(p_oEvent); + + this._bOptionPressed = true; + + } + + }, + + + /** + * @method _onOverlayBeforeShow + * @description "beforeshow" event handler for the + * <a href="YAHOO.widget.Overlay.html">YAHOO.widget.Overlay</a> instance + * serving as the button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + */ + _onOverlayBeforeShow: function (p_sType) { + + var oMenu = this._menu; + + oMenu.render(this.get("element").parentNode); + + oMenu.beforeShowEvent.unsubscribe(this._onOverlayBeforeShow); + + }, + + + /** + * @method _onMenuShow + * @description "show" event handler for the button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + */ + _onMenuShow: function (p_sType) { + + Event.on(document, "mousedown", this._onDocumentMouseDown, + null, this); + + var sTitle, + sState; + + if (this.get("type") == "split") { + + sTitle = this.SPLITBUTTON_OPTION_VISIBLE_TITLE; + sState = "activeoption"; + + } + else { + + sTitle = this.MENUBUTTON_MENU_VISIBLE_TITLE; + sState = "active"; + + } + + this.addStateCSSClasses(sState); + this.set("title", sTitle); + + }, + + + /** + * @method _onMenuHide + * @description "hide" event handler for the button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + */ + _onMenuHide: function (p_sType) { + + var oMenu = this._menu, + sTitle, + sState; + + + if (this.get("type") == "split") { + + sTitle = this.SPLITBUTTON_DEFAULT_TITLE; + sState = "activeoption"; + + } + else { + + sTitle = this.MENUBUTTON_DEFAULT_TITLE; + sState = "active"; + } + + + this.removeStateCSSClasses(sState); + this.set("title", sTitle); + + + if (this.get("type") == "split") { + + this._bOptionPressed = false; + + } + + }, + + + /** + * @method _onMenuKeyDown + * @description "keydown" event handler for the button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + * @param {Array} p_aArgs Array of arguments sent when the event + * was fired. + */ + _onMenuKeyDown: function (p_sType, p_aArgs) { + + var oEvent = p_aArgs[0]; + + if (Event.getCharCode(oEvent) == 27) { + + this.focus(); + + if (this.get("type") == "split") { + + this._bOptionPressed = false; + + } + + } + + }, + + + /** + * @method _onMenuRender + * @description "render" event handler for the button's menu. + * @private + * @param {String} p_sType String representing the name of the + * event thatwas fired. + */ + _onMenuRender: function (p_sType) { + + var oButtonElement = this.get("element"), + oButtonParent = oButtonElement.parentNode, + oMenuElement = this._menu.element; + + + if (oButtonParent != oMenuElement.parentNode) { + + oButtonParent.appendChild(oMenuElement); + + } + + this.set("selectedMenuItem", this.get("selectedMenuItem")); + + }, + + + /** + * @method _onMenuItemSelected + * @description "selectedchange" event handler for each item in the + * button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + * @param {Array} p_aArgs Array of arguments sent when the event + * was fired. + * @param {MenuItem} p_oItem Object representing the menu item that + * subscribed to the event. + */ + _onMenuItemSelected: function (p_sType, p_aArgs, p_oItem) { + + var bSelected = p_aArgs[0]; + + if (bSelected) { + + this.set("selectedMenuItem", p_oItem); + + } + + }, + + + /** + * @method _onMenuItemAdded + * @description "itemadded" event handler for the button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + * @param {Array} p_aArgs Array of arguments sent when the event + * was fired. + * @param {<a href="YAHOO.widget.MenuItem.html"> + * YAHOO.widget.MenuItem</a>} p_oItem Object representing the menu + * item that subscribed to the event. + */ + _onMenuItemAdded: function (p_sType, p_aArgs, p_oItem) { + + var oItem = p_aArgs[0]; + + oItem.cfg.subscribeToConfigEvent("selected", + this._onMenuItemSelected, oItem, this); + + }, + + + /** + * @method _onMenuClick + * @description "click" event handler for the button's menu. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + * @param {Array} p_aArgs Array of arguments sent when the event + * was fired. + */ + _onMenuClick: function (p_sType, p_aArgs) { + + var oItem = p_aArgs[1], + oSrcElement; + + if (oItem) { + + oSrcElement = this.get("srcelement"); + + if (oSrcElement && oSrcElement.type == "submit") { + + this.submitForm(); + + } + + this._hideMenu(); + + } + + }, + + + + // Public methods + + + /** + * @method createButtonElement + * @description Creates the button's HTML elements. + * @param {String} p_sType String indicating the type of element + * to create. + * @return {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-58190037">HTMLElement</a>} + */ + createButtonElement: function (p_sType) { + + var sNodeName = this.NODE_NAME, + oElement = document.createElement(sNodeName); + + oElement.innerHTML = "<" + sNodeName + " class=\"first-child\">" + + (p_sType == "link" ? "<a></a>" : + "<button type=\"button\"></button>") + "</" + sNodeName + ">"; + + return oElement; + + }, + + + /** + * @method addStateCSSClasses + * @description Appends state-specific CSS classes to the button's root + * DOM element. + */ + addStateCSSClasses: function (p_sState) { + + var sType = this.get("type"); + + if (Lang.isString(p_sState)) { + + if (p_sState != "activeoption") { + + this.addClass(this.CSS_CLASS_NAME + ("-" + p_sState)); + + } + + this.addClass("yui-" + sType + ("-button-" + p_sState)); + + } + + }, + + + /** + * @method removeStateCSSClasses + * @description Removes state-specific CSS classes to the button's root + * DOM element. + */ + removeStateCSSClasses: function (p_sState) { + + var sType = this.get("type"); + + if (Lang.isString(p_sState)) { + + this.removeClass(this.CSS_CLASS_NAME + ("-" + p_sState)); + this.removeClass("yui-" + sType + ("-button-" + p_sState)); + + } + + }, + + + /** + * @method createHiddenFields + * @description Creates the button's hidden form field and appends it + * to its parent form. + * @return {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-6043025">HTMLInputElement</a>|Array} + */ + createHiddenFields: function () { + + this.removeHiddenFields(); + + var oForm = this.getForm(), + oButtonField, + sType, + bCheckable, + oMenu, + oMenuItem, + sName, + oValue, + oMenuField; + + + if (oForm && !this.get("disabled")) { + + sType = this.get("type"); + bCheckable = (sType == "checkbox" || sType == "radio"); + + + if (bCheckable || (m_oSubmitTrigger == this)) { + + + oButtonField = createInputElement( + (bCheckable ? sType : "hidden"), + this.get("name"), + this.get("value"), + this.get("checked")); + + + if (oButtonField) { + + if (bCheckable) { + + oButtonField.style.display = "none"; + + } + + oForm.appendChild(oButtonField); + + } + + } + + + oMenu = this._menu; + + + if (Menu && oMenu && (oMenu instanceof Menu)) { + + + oMenuField = oMenu.srcElement; + oMenuItem = this.get("selectedMenuItem"); + + if (oMenuItem) { + + if (oMenuField && + oMenuField.nodeName.toUpperCase() == "SELECT") { + + oForm.appendChild(oMenuField); + oMenuField.selectedIndex = oMenuItem.index; + + } + else { + + oValue = (oMenuItem.value === null || + oMenuItem.value === "") ? + oMenuItem.cfg.getProperty("text") : + oMenuItem.value; + + sName = this.get("name"); + + if (oValue && sName) { + + oMenuField = createInputElement("hidden", + (sName + "_options"), + oValue); + + oForm.appendChild(oMenuField); + + } + + } + + } + + } + + + if (oButtonField && oMenuField) { + + this._hiddenFields = [oButtonField, oMenuField]; + + } + else if (!oButtonField && oMenuField) { + + this._hiddenFields = oMenuField; + + } + else if (oButtonField && !oMenuField) { + + this._hiddenFields = oButtonField; + + } + + + return this._hiddenFields; + + } + + }, + + + /** + * @method removeHiddenFields + * @description Removes the button's hidden form field(s) from its + * parent form. + */ + removeHiddenFields: function () { + + var oField = this._hiddenFields, + nFields, + i; + + function removeChild(p_oElement) { + + if (Dom.inDocument(p_oElement)) { + + p_oElement.parentNode.removeChild(p_oElement); + + } + + } + + + if (oField) { + + if (Lang.isArray(oField)) { + + nFields = oField.length; + + if (nFields > 0) { + + i = nFields - 1; + + do { + + removeChild(oField[i]); + + } + while (i--); + + } + + } + else { + + removeChild(oField); + + } + + this._hiddenFields = null; + + } + + }, + + + /** + * @method submitForm + * @description Submits the form to which the button belongs. Returns + * true if the form was submitted successfully, false if the submission + * was cancelled. + * @protected + * @return {Boolean} + */ + submitForm: function () { + + var oForm = this.getForm(), + + oSrcElement = this.get("srcelement"), + + /* + Boolean indicating if the event fired successfully + (was not cancelled by any handlers) + */ + + bSubmitForm = false, + + oEvent; + + + if (oForm) { + + if (this.get("type") == "submit" || + (oSrcElement && oSrcElement.type == "submit")) + { + + m_oSubmitTrigger = this; + + } + + + if (UA.ie) { + + bSubmitForm = oForm.fireEvent("onsubmit"); + + } + else { // Gecko, Opera, and Safari + + oEvent = document.createEvent("HTMLEvents"); + oEvent.initEvent("submit", true, true); + + bSubmitForm = oForm.dispatchEvent(oEvent); + + } + + + /* + In IE and Safari, dispatching a "submit" event to a form + WILL cause the form's "submit" event to fire, but WILL NOT + submit the form. Therefore, we need to call the "submit" + method as well. + */ + + if ((UA.ie || UA.webkit) && bSubmitForm) { + + oForm.submit(); + + } + + } + + return bSubmitForm; + + }, + + + /** + * @method init + * @description The Button class's initialization method. + * @param {String} p_oElement String specifying the id attribute of the + * <code><input></code>, <code><button></code>, + * <code><a></code>, or <code><span></code> element to + * be used to create the button. + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-6043025">HTMLInputElement</a>|<a href="http:// + * www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level-one-html.html + * #ID-34812697">HTMLButtonElement</a>|<a href="http://www.w3.org/TR + * /2000/WD-DOM-Level-1-20000929/level-one-html.html#ID-33759296"> + * HTMLElement</a>} p_oElement Object reference for the + * <code><input></code>, <code><button></code>, + * <code><a></code>, or <code><span></code> element to be + * used to create the button. + * @param {Object} p_oElement Object literal specifying a set of + * configuration attributes used to create the button. + * @param {Object} p_oAttributes Optional. Object literal specifying a + * set of configuration attributes used to create the button. + */ + init: function (p_oElement, p_oAttributes) { + + var sNodeName = p_oAttributes.type == "link" ? "a" : "button", + oSrcElement = p_oAttributes.srcelement, + oButton = p_oElement.getElementsByTagName(sNodeName)[0], + oInput; + + + if (!oButton) { + + oInput = p_oElement.getElementsByTagName("input")[0]; + + + if (oInput) { + + oButton = document.createElement("button"); + oButton.setAttribute("type", "button"); + + oInput.parentNode.replaceChild(oButton, oInput); + + } + + } + + this._button = oButton; + + + YAHOO.widget.Button.superclass.init.call(this, p_oElement, + p_oAttributes); + + + m_oButtons[this.get("id")] = this; + + + this.addClass(this.CSS_CLASS_NAME); + + this.addClass("yui-" + this.get("type") + "-button"); + + Event.on(this._button, "focus", this._onFocus, null, this); + this.on("mouseover", this._onMouseOver); + this.on("click", this._onClick); + this.on("appendTo", this._onAppendTo); + + + var oContainer = this.get("container"), + oElement = this.get("element"), + bElInDoc = Dom.inDocument(oElement), + oParentNode; + + + if (oContainer) { + + if (oSrcElement && oSrcElement != oElement) { + + oParentNode = oSrcElement.parentNode; + + if (oParentNode) { + + oParentNode.removeChild(oSrcElement); + + } + + } + + if (Lang.isString(oContainer)) { + + Event.onContentReady(oContainer, function () { + + this.appendTo(oContainer); + + }, null, this); + + } + else { + + this.appendTo(oContainer); + + } + + } + else if (!bElInDoc && oSrcElement && oSrcElement != oElement) { + + oParentNode = oSrcElement.parentNode; + + if (oParentNode) { + + this.fireEvent("beforeAppendTo", { + type: "beforeAppendTo", + target: oParentNode + }); + + oParentNode.replaceChild(oElement, oSrcElement); + + this.fireEvent("appendTo", { + type: "appendTo", + target: oParentNode + }); + + } + + } + else if (this.get("type") != "link" && bElInDoc && oSrcElement && + oSrcElement == oElement) { + + this._addListenersToForm(); + + } + + + }, + + + /** + * @method initAttributes + * @description Initializes all of the configuration attributes used to + * create the button. + * @param {Object} p_oAttributes Object literal specifying a set of + * configuration attributes used to create the button. + */ + initAttributes: function (p_oAttributes) { + + var oAttributes = p_oAttributes || {}; + + YAHOO.widget.Button.superclass.initAttributes.call(this, + oAttributes); + + + /** + * @attribute type + * @description String specifying the button's type. Possible + * values are: "push," "link," "submit," "reset," "checkbox," + * "radio," "menu," and "split." + * @default "push" + * @type String + */ + this.setAttributeConfig("type", { + + value: (oAttributes.type || "push"), + validator: Lang.isString, + writeOnce: true, + method: this._setType + + }); + + + /** + * @attribute label + * @description String specifying the button's text label + * or innerHTML. + * @default null + * @type String + */ + this.setAttributeConfig("label", { + + value: oAttributes.label, + validator: Lang.isString, + method: this._setLabel + + }); + + + /** + * @attribute value + * @description Object specifying the value for the button. + * @default null + * @type Object + */ + this.setAttributeConfig("value", { + + value: oAttributes.value + + }); + + + /** + * @attribute name + * @description String specifying the name for the button. + * @default null + * @type String + */ + this.setAttributeConfig("name", { + + value: oAttributes.name, + validator: Lang.isString + + }); + + + /** + * @attribute tabindex + * @description Number specifying the tabindex for the button. + * @default null + * @type Number + */ + this.setAttributeConfig("tabindex", { + + value: oAttributes.tabindex, + validator: Lang.isNumber, + method: this._setTabIndex + + }); + + + /** + * @attribute title + * @description String specifying the title for the button. + * @default null + * @type String + */ + this.configureAttribute("title", { + + value: oAttributes.title, + validator: Lang.isString, + method: this._setTitle + + }); + + + /** + * @attribute disabled + * @description Boolean indicating if the button should be disabled. + * (Disabled buttons are dimmed and will not respond to user input + * or fire events. Does not apply to button's of type "link.") + * @default false + * @type Boolean + */ + this.setAttributeConfig("disabled", { + + value: (oAttributes.disabled || false), + validator: Lang.isBoolean, + method: this._setDisabled + + }); + + + /** + * @attribute href + * @description String specifying the href for the button. Applies + * only to buttons of type "link." + * @type String + */ + this.setAttributeConfig("href", { + + value: oAttributes.href, + validator: Lang.isString, + method: this._setHref + + }); + + + /** + * @attribute target + * @description String specifying the target for the button. + * Applies only to buttons of type "link." + * @type String + */ + this.setAttributeConfig("target", { + + value: oAttributes.target, + validator: Lang.isString, + method: this._setTarget + + }); + + + /** + * @attribute checked + * @description Boolean indicating if the button is checked. + * Applies only to buttons of type "radio" and "checkbox." + * @default false + * @type Boolean + */ + this.setAttributeConfig("checked", { + + value: (oAttributes.checked || false), + validator: Lang.isBoolean, + method: this._setChecked + + }); + + + /** + * @attribute container + * @description HTML element reference or string specifying the id + * attribute of the HTML element that the button's markup should be + * rendered into. + * @type <a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-58190037">HTMLElement</a>|String + * @default null + */ + this.setAttributeConfig("container", { + + value: oAttributes.container, + writeOnce: true + + }); + + + /** + * @attribute srcelement + * @description Object reference to the HTML element (either + * <code><input></code> or <code><span></code>) + * used to create the button. + * @type <a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-58190037">HTMLElement</a>|String + * @default null + */ + this.setAttributeConfig("srcelement", { + + value: oAttributes.srcelement, + writeOnce: true + + }); + + + /** + * @attribute menu + * @description Object specifying the menu for the button. + * The value can be one of the following: + * <ul> + * <li>Object specifying a <a href="YAHOO.widget.Menu.html"> + * YAHOO.widget.Menu</a> instance.</li> + * <li>Object specifying a <a href="YAHOO.widget.Overlay.html"> + * YAHOO.widget.Overlay</a> instance.</li> + * <li>String specifying the id attribute of the <code><div> + * </code> element used to create the menu. By default the menu + * will be created as an instance of + * <a href="YAHOO.widget.Overlay.html">YAHOO.widget.Overlay</a>. + * If the <a href="YAHOO.widget.Menu.html#CSS_CLASS_NAME"> + * default CSS class name for YAHOO.widget.Menu</a> is applied to + * the <code><div></code> element, it will be created as an + * instance of <a href="YAHOO.widget.Menu.html">YAHOO.widget.Menu + * </a>.</li><li>String specifying the id attribute of the + * <code><select></code> element used to create the menu. + * </li><li>Object specifying the <code><div></code> element + * used to create the menu.</li> + * <li>Object specifying the <code><select></code> element + * used to create the menu.</li> + * <li>Array of object literals, each representing a set of + * <a href="YAHOO.widget.MenuItem.html">YAHOO.widget.MenuItem</a> + * configuration attributes.</li> + * <li>Array of strings representing the text labels for each menu + * item in the menu.</li> + * </ul> + * @type <a href="YAHOO.widget.Menu.html">YAHOO.widget.Menu</a>|<a + * href="YAHOO.widget.Overlay.html">YAHOO.widget.Overlay</a>|<a + * href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level- + * one-html.html#ID-58190037">HTMLElement</a>|String|Array + * @default null + */ + this.setAttributeConfig("menu", { + + value: null, + method: this._setMenu, + writeOnce: true + + }); + + + /** + * @attribute lazyloadmenu + * @description Boolean indicating the value to set for the + * <a href="YAHOO.widget.Menu.html#lazyLoad">"lazyload"</a> + * configuration property of the button's menu. Setting + * "lazyloadmenu" to <code>true </code> will defer rendering of + * the button's menu until the first time it is made visible. + * If "lazyloadmenu" is set to <code>false</code>, the button's + * menu will be rendered immediately if the button is in the + * document, or in response to the button's "appendTo" event if + * the button is not yet in the document. In either case, the + * menu is rendered into the button's parent HTML element. + * <em>This attribute does not apply if a + * <a href="YAHOO.widget.Menu.html">YAHOO.widget.Menu</a> or + * <a href="YAHOO.widget.Overlay.html">YAHOO.widget.Overlay</a> + * instance is passed as the value of the button's "menu" + * configuration attribute. <a href="YAHOO.widget.Menu.html"> + * YAHOO.widget.Menu</a> or <a href="YAHOO.widget.Overlay.html"> + * YAHOO.widget.Overlay</a> instances should be rendered before + * being set as the value for the "menu" configuration + * attribute.</em> + * @default true + * @type Boolean + */ + this.setAttributeConfig("lazyloadmenu", { + + value: (oAttributes.lazyloadmenu === false ? false : true), + validator: Lang.isBoolean, + writeOnce: true + + }); + + + /** + * @attribute menuclassname + * @description String representing the CSS class name to be + * applied to the root element of the button's menu. + * @type String + * @default "yui-button-menu" + */ + this.setAttributeConfig("menuclassname", { + + value: (oAttributes.menuclassname || "yui-button-menu"), + validator: Lang.isString, + method: this._setMenuClassName, + writeOnce: true + + }); + + + /** + * @attribute selectedMenuItem + * @description Object representing the item in the button's menu + * that is currently selected. + * @type Number + * @default null + */ + this.setAttributeConfig("selectedMenuItem", { + + value: null, + method: this._setSelectedMenuItem + + }); + + + /** + * @attribute onclick + * @description Object literal representing the code to be executed + * when the button is clicked. Format:<br> <code> {<br> + * <strong>fn:</strong> Function, // The handler to call + * when the event fires.<br> <strong>obj:</strong> Object, + * // An object to pass back to the handler.<br> + * <strong>scope:</strong> Object // The object to use + * for the scope of the handler.<br> } </code> + * @type Object + * @default null + */ + this.setAttributeConfig("onclick", { + + value: oAttributes.onclick, + method: this._setOnClick + + }); + + + /** + * @attribute focusmenu + * @description Boolean indicating whether or not the button's menu + * should be focused when it is made visible. + * @type Boolean + * @default true + */ + this.setAttributeConfig("focusmenu", { + + value: (oAttributes.focusmenu === false ? false : true), + validator: Lang.isBoolean + + }); + + }, + + + /** + * @method focus + * @description Causes the button to receive the focus and fires the + * button's "focus" event. + */ + focus: function () { + + if (!this.get("disabled")) { + + this._button.focus(); + + } + + }, + + + /** + * @method blur + * @description Causes the button to lose focus and fires the button's + * "blur" event. + */ + blur: function () { + + if (!this.get("disabled")) { + + this._button.blur(); + + } + + }, + + + /** + * @method hasFocus + * @description Returns a boolean indicating whether or not the button + * has focus. + * @return {Boolean} + */ + hasFocus: function () { + + return (m_oFocusedButton == this); + + }, + + + /** + * @method isActive + * @description Returns a boolean indicating whether or not the button + * is active. + * @return {Boolean} + */ + isActive: function () { + + return this.hasClass(this.CSS_CLASS_NAME + "-active"); + + }, + + + /** + * @method getMenu + * @description Returns a reference to the button's menu. + * @return {<a href="YAHOO.widget.Overlay.html"> + * YAHOO.widget.Overlay</a>|<a + * href="YAHOO.widget.Menu.html">YAHOO.widget.Menu</a>} + */ + getMenu: function () { + + return this._menu; + + }, + + + /** + * @method getForm + * @description Returns a reference to the button's parent form. + * @return {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1- + * 20000929/level-one-html.html#ID-40002357">HTMLFormElement</a>} + */ + getForm: function () { + + return this._button.form; + + }, + + + /** + * @method getHiddenFields + * @description Returns an <code><input></code> element or + * array of form elements used to represent the button when its parent + * form is submitted. + * @return {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-6043025">HTMLInputElement</a>|Array} + */ + getHiddenFields: function () { + + return this._hiddenFields; + + }, + + + /** + * @method destroy + * @description Removes the button's element from its parent element and + * removes all event handlers. + */ + destroy: function () { + + + var oElement = this.get("element"), + oParentNode = oElement.parentNode, + oMenu = this._menu, + aButtons; + + if (oMenu) { + + + if (m_oOverlayManager && m_oOverlayManager.find(oMenu)) { + + m_oOverlayManager.remove(oMenu); + + } + + oMenu.destroy(); + + } + + + Event.purgeElement(oElement); + Event.purgeElement(this._button); + Event.removeListener(document, "mouseup", this._onDocumentMouseUp); + Event.removeListener(document, "keyup", this._onDocumentKeyUp); + Event.removeListener(document, "mousedown", + this._onDocumentMouseDown); + + + var oForm = this.getForm(); + + if (oForm) { + + Event.removeListener(oForm, "reset", this._onFormReset); + Event.removeListener(oForm, "submit", this.createHiddenFields); + + } + + + this.unsubscribeAll(); + + if (oParentNode) { + + oParentNode.removeChild(oElement); + + } + + + delete m_oButtons[this.get("id")]; + + aButtons = Dom.getElementsByClassName(this.CSS_CLASS_NAME, + this.NODE_NAME, oForm); + + if (Lang.isArray(aButtons) && aButtons.length === 0) { + + Event.removeListener(oForm, "keypress", + YAHOO.widget.Button.onFormKeyPress); + + } + + + }, + + + fireEvent: function (p_sType , p_aArgs) { + + var sType = arguments[0]; + + // Disabled buttons should not respond to DOM events + + if (this.DOM_EVENTS[sType] && this.get("disabled")) { + + return; + + } + + return YAHOO.widget.Button.superclass.fireEvent.apply(this, arguments); + + }, + + + /** + * @method toString + * @description Returns a string representing the button. + * @return {String} + */ + toString: function () { + + return ("Button " + this.get("id")); + + } + + }); + + + /** + * @method YAHOO.widget.Button.onFormKeyPress + * @description "keypress" event handler for the button's form. + * @param {Event} p_oEvent Object representing the DOM event object passed + * back by the event utility (YAHOO.util.Event). + */ + YAHOO.widget.Button.onFormKeyPress = function (p_oEvent) { + + var oTarget = Event.getTarget(p_oEvent), + nCharCode = Event.getCharCode(p_oEvent), + sNodeName = oTarget.nodeName && oTarget.nodeName.toUpperCase(), + sType = oTarget.type, + + /* + Boolean indicating if the form contains any enabled or + disabled YUI submit buttons + */ + + bFormContainsYUIButtons = false, + + oButton, + + oYUISubmitButton, // The form's first, enabled YUI submit button + + /* + The form's first, enabled HTML submit button that precedes any + YUI submit button + */ + + oPrecedingSubmitButton, + + + /* + The form's first, enabled HTML submit button that follows a + YUI button + */ + + oFollowingSubmitButton; + + + function isSubmitButton(p_oElement) { + + var sId, + oSrcElement; + + switch (p_oElement.nodeName.toUpperCase()) { + + case "INPUT": + case "BUTTON": + + if (p_oElement.type == "submit" && !p_oElement.disabled) { + + if (!bFormContainsYUIButtons && + !oPrecedingSubmitButton) { + + oPrecedingSubmitButton = p_oElement; + + } + + if (oYUISubmitButton && !oFollowingSubmitButton) { + + oFollowingSubmitButton = p_oElement; + + } + + } + + break; + + + default: + + sId = p_oElement.id; + + if (sId) { + + oButton = m_oButtons[sId]; + + if (oButton) { + + bFormContainsYUIButtons = true; + + if (!oButton.get("disabled")) { + + oSrcElement = oButton.get("srcelement"); + + if (!oYUISubmitButton && + (oButton.get("type") == "submit" || + (oSrcElement && oSrcElement.type == "submit"))) + { + + oYUISubmitButton = oButton; + + } + + } + + } + + } + + break; + + } + + } + + + if (nCharCode == 13 && ((sNodeName == "INPUT" && (sType == "text" || + sType == "password" || sType == "checkbox" || sType == "radio" || + sType == "file")) || sNodeName == "SELECT")) + { + + Dom.getElementsBy(isSubmitButton, "*", this); + + + if (oPrecedingSubmitButton) { + + /* + Need to set focus to the first enabled submit button + to make sure that IE includes its name and value + in the form's data set. + */ + + oPrecedingSubmitButton.focus(); + + } + else if (!oPrecedingSubmitButton && oYUISubmitButton) { + + if (oFollowingSubmitButton) { + + /* + Need to call "preventDefault" to ensure that + the name and value of the regular submit button + following the YUI button doesn't get added to the + form's data set when it is submitted. + */ + + Event.preventDefault(p_oEvent); + + } + + oYUISubmitButton.submitForm(); + + } + + } + + }; + + + /** + * @method YAHOO.widget.Button.addHiddenFieldsToForm + * @description Searches the specified form and adds hidden fields for + * instances of YAHOO.widget.Button that are of type "radio," "checkbox," + * "menu," and "split." + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level- + * one-html.html#ID-40002357">HTMLFormElement</a>} p_oForm Object reference + * for the form to search. + */ + YAHOO.widget.Button.addHiddenFieldsToForm = function (p_oForm) { + + var aButtons = Dom.getElementsByClassName( + YAHOO.widget.Button.prototype.CSS_CLASS_NAME, + "*", + p_oForm), + + nButtons = aButtons.length, + oButton, + sId, + i; + + if (nButtons > 0) { + + + for (i = 0; i < nButtons; i++) { + + sId = aButtons[i].id; + + if (sId) { + + oButton = m_oButtons[sId]; + + if (oButton) { + + oButton.createHiddenFields(); + + } + + } + + } + + } + + }; + + + /** + * @method YAHOO.widget.Button.getButton + * @description Returns a button with the specified id. + * @param {String} p_sId String specifying the id of the root node of the + * HTML element representing the button to be retrieved. + * @return {YAHOO.widget.Button} + */ + YAHOO.widget.Button.getButton = function (p_sId) { + + var oButton = m_oButtons[p_sId]; + + if (oButton) { + + return oButton; + + } + + }; + + + // Events + + + /** + * @event focus + * @description Fires when the menu item receives focus. Passes back a + * single object representing the original DOM event object passed back by + * the event utility (YAHOO.util.Event) when the event was fired. See + * <a href="YAHOO.util.Element.html#addListener">Element.addListener</a> + * for more information on listening for this event. + * @type YAHOO.util.CustomEvent + */ + + + /** + * @event blur + * @description Fires when the menu item loses the input focus. Passes back + * a single object representing the original DOM event object passed back by + * the event utility (YAHOO.util.Event) when the event was fired. See + * <a href="YAHOO.util.Element.html#addListener">Element.addListener</a> for + * more information on listening for this event. + * @type YAHOO.util.CustomEvent + */ + + + /** + * @event option + * @description Fires when the user invokes the button's option. Passes + * back a single object representing the original DOM event (either + * "mousedown" or "keydown") that caused the "option" event to fire. See + * <a href="YAHOO.util.Element.html#addListener">Element.addListener</a> + * for more information on listening for this event. + * @type YAHOO.util.CustomEvent + */ + +})(); +(function () { + + // Shorthard for utilities + + var Dom = YAHOO.util.Dom, + Event = YAHOO.util.Event, + Lang = YAHOO.lang, + Button = YAHOO.widget.Button, + + // Private collection of radio buttons + + m_oButtons = {}; + + + + /** + * The ButtonGroup class creates a set of buttons that are mutually + * exclusive; checking one button in the set will uncheck all others in the + * button group. + * @param {String} p_oElement String specifying the id attribute of the + * <code><div></code> element of the button group. + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-22445964">HTMLDivElement</a>} p_oElement Object + * specifying the <code><div></code> element of the button group. + * @param {Object} p_oElement Object literal specifying a set of + * configuration attributes used to create the button group. + * @param {Object} p_oAttributes Optional. Object literal specifying a set + * of configuration attributes used to create the button group. + * @namespace YAHOO.widget + * @class ButtonGroup + * @constructor + * @extends YAHOO.util.Element + */ + YAHOO.widget.ButtonGroup = function (p_oElement, p_oAttributes) { + + var fnSuperClass = YAHOO.widget.ButtonGroup.superclass.constructor, + sNodeName, + oElement, + sId; + + if (arguments.length == 1 && !Lang.isString(p_oElement) && + !p_oElement.nodeName) { + + if (!p_oElement.id) { + + sId = Dom.generateId(); + + p_oElement.id = sId; + + + } + + + + fnSuperClass.call(this, (this._createGroupElement()), p_oElement); + + } + else if (Lang.isString(p_oElement)) { + + oElement = Dom.get(p_oElement); + + if (oElement) { + + if (oElement.nodeName.toUpperCase() == this.NODE_NAME) { + + + fnSuperClass.call(this, oElement, p_oAttributes); + + } + + } + + } + else { + + sNodeName = p_oElement.nodeName.toUpperCase(); + + if (sNodeName && sNodeName == this.NODE_NAME) { + + if (!p_oElement.id) { + + p_oElement.id = Dom.generateId(); + + + } + + + fnSuperClass.call(this, p_oElement, p_oAttributes); + + } + + } + + }; + + + YAHOO.extend(YAHOO.widget.ButtonGroup, YAHOO.util.Element, { + + + // Protected properties + + + /** + * @property _buttons + * @description Array of buttons in the button group. + * @default null + * @protected + * @type Array + */ + _buttons: null, + + + + // Constants + + + /** + * @property NODE_NAME + * @description The name of the tag to be used for the button + * group's element. + * @default "DIV" + * @final + * @type String + */ + NODE_NAME: "DIV", + + + /** + * @property CSS_CLASS_NAME + * @description String representing the CSS class(es) to be applied + * to the button group's element. + * @default "yui-buttongroup" + * @final + * @type String + */ + CSS_CLASS_NAME: "yui-buttongroup", + + + + // Protected methods + + + /** + * @method _createGroupElement + * @description Creates the button group's element. + * @protected + * @return {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-22445964">HTMLDivElement</a>} + */ + _createGroupElement: function () { + + var oElement = document.createElement(this.NODE_NAME); + + return oElement; + + }, + + + + // Protected attribute setter methods + + + /** + * @method _setDisabled + * @description Sets the value of the button groups's + * "disabled" attribute. + * @protected + * @param {Boolean} p_bDisabled Boolean indicating the value for + * the button group's "disabled" attribute. + */ + _setDisabled: function (p_bDisabled) { + + var nButtons = this.getCount(), + i; + + if (nButtons > 0) { + + i = nButtons - 1; + + do { + + this._buttons[i].set("disabled", p_bDisabled); + + } + while (i--); + + } + + }, + + + + // Protected event handlers + + + /** + * @method _onKeyDown + * @description "keydown" event handler for the button group. + * @protected + * @param {Event} p_oEvent Object representing the DOM event object + * passed back by the event utility (YAHOO.util.Event). + */ + _onKeyDown: function (p_oEvent) { + + var oTarget = Event.getTarget(p_oEvent), + nCharCode = Event.getCharCode(p_oEvent), + sId = oTarget.parentNode.parentNode.id, + oButton = m_oButtons[sId], + nIndex = -1; + + + if (nCharCode == 37 || nCharCode == 38) { + + nIndex = (oButton.index === 0) ? + (this._buttons.length - 1) : (oButton.index - 1); + + } + else if (nCharCode == 39 || nCharCode == 40) { + + nIndex = (oButton.index === (this._buttons.length - 1)) ? + 0 : (oButton.index + 1); + + } + + + if (nIndex > -1) { + + this.check(nIndex); + this.getButton(nIndex).focus(); + + } + + }, + + + /** + * @method _onAppendTo + * @description "appendTo" event handler for the button group. + * @protected + * @param {Event} p_oEvent Object representing the event that was fired. + */ + _onAppendTo: function (p_oEvent) { + + var aButtons = this._buttons, + nButtons = aButtons.length, + i; + + for (i = 0; i < nButtons; i++) { + + aButtons[i].appendTo(this.get("element")); + + } + + }, + + + /** + * @method _onButtonCheckedChange + * @description "checkedChange" event handler for each button in the + * button group. + * @protected + * @param {Event} p_oEvent Object representing the event that was fired. + * @param {<a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a>} + * p_oButton Object representing the button that fired the event. + */ + _onButtonCheckedChange: function (p_oEvent, p_oButton) { + + var bChecked = p_oEvent.newValue, + oCheckedButton = this.get("checkedButton"); + + if (bChecked && oCheckedButton != p_oButton) { + + if (oCheckedButton) { + + oCheckedButton.set("checked", false, true); + + } + + this.set("checkedButton", p_oButton); + this.set("value", p_oButton.get("value")); + + } + else if (oCheckedButton && !oCheckedButton.set("checked")) { + + oCheckedButton.set("checked", true, true); + + } + + }, + + + + // Public methods + + + /** + * @method init + * @description The ButtonGroup class's initialization method. + * @param {String} p_oElement String specifying the id attribute of the + * <code><div></code> element of the button group. + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-22445964">HTMLDivElement</a>} p_oElement Object + * specifying the <code><div></code> element of the button group. + * @param {Object} p_oElement Object literal specifying a set of + * configuration attributes used to create the button group. + * @param {Object} p_oAttributes Optional. Object literal specifying a + * set of configuration attributes used to create the button group. + */ + init: function (p_oElement, p_oAttributes) { + + this._buttons = []; + + YAHOO.widget.ButtonGroup.superclass.init.call(this, p_oElement, + p_oAttributes); + + this.addClass(this.CSS_CLASS_NAME); + + + var aButtons = this.getElementsByClassName("yui-radio-button"); + + + if (aButtons.length > 0) { + + + this.addButtons(aButtons); + + } + + + + function isRadioButton(p_oElement) { + + return (p_oElement.type == "radio"); + + } + + aButtons = + Dom.getElementsBy(isRadioButton, "input", this.get("element")); + + + if (aButtons.length > 0) { + + + this.addButtons(aButtons); + + } + + this.on("keydown", this._onKeyDown); + this.on("appendTo", this._onAppendTo); + + + var oContainer = this.get("container"); + + if (oContainer) { + + if (Lang.isString(oContainer)) { + + Event.onContentReady(oContainer, function () { + + this.appendTo(oContainer); + + }, null, this); + + } + else { + + this.appendTo(oContainer); + + } + + } + + + + }, + + + /** + * @method initAttributes + * @description Initializes all of the configuration attributes used to + * create the button group. + * @param {Object} p_oAttributes Object literal specifying a set of + * configuration attributes used to create the button group. + */ + initAttributes: function (p_oAttributes) { + + var oAttributes = p_oAttributes || {}; + + YAHOO.widget.ButtonGroup.superclass.initAttributes.call( + this, oAttributes); + + + /** + * @attribute name + * @description String specifying the name for the button group. + * This name will be applied to each button in the button group. + * @default null + * @type String + */ + this.setAttributeConfig("name", { + + value: oAttributes.name, + validator: Lang.isString + + }); + + + /** + * @attribute disabled + * @description Boolean indicating if the button group should be + * disabled. Disabling the button group will disable each button + * in the button group. Disabled buttons are dimmed and will not + * respond to user input or fire events. + * @default false + * @type Boolean + */ + this.setAttributeConfig("disabled", { + + value: (oAttributes.disabled || false), + validator: Lang.isBoolean, + method: this._setDisabled + + }); + + + /** + * @attribute value + * @description Object specifying the value for the button group. + * @default null + * @type Object + */ + this.setAttributeConfig("value", { + + value: oAttributes.value + + }); + + + /** + * @attribute container + * @description HTML element reference or string specifying the id + * attribute of the HTML element that the button group's markup + * should be rendered into. + * @type <a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-58190037">HTMLElement</a>|String + * @default null + */ + this.setAttributeConfig("container", { + + value: oAttributes.container, + writeOnce: true + + }); + + + /** + * @attribute checkedButton + * @description Reference for the button in the button group that + * is checked. + * @type {<a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a>} + * @default null + */ + this.setAttributeConfig("checkedButton", { + + value: null + + }); + + }, + + + /** + * @method addButton + * @description Adds the button to the button group. + * @param {<a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a>} + * p_oButton Object reference for the <a href="YAHOO.widget.Button.html"> + * YAHOO.widget.Button</a> instance to be added to the button group. + * @param {String} p_oButton String specifying the id attribute of the + * <code><input></code> or <code><span></code> element + * to be used to create the button to be added to the button group. + * @param {<a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-6043025">HTMLInputElement</a>|<a href=" + * http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/level-one-html.html# + * ID-33759296">HTMLElement</a>} p_oButton Object reference for the + * <code><input></code> or <code><span></code> element + * to be used to create the button to be added to the button group. + * @param {Object} p_oButton Object literal specifying a set of + * <a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a> + * configuration attributes used to configure the button to be added to + * the button group. + * @return {<a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a>} + */ + addButton: function (p_oButton) { + + var oButton, + oButtonElement, + oGroupElement, + nIndex, + sButtonName, + sGroupName; + + + if (p_oButton instanceof Button && + p_oButton.get("type") == "radio") { + + oButton = p_oButton; + + } + else if (!Lang.isString(p_oButton) && !p_oButton.nodeName) { + + p_oButton.type = "radio"; + + oButton = new Button(p_oButton); + + } + else { + + oButton = new Button(p_oButton, { type: "radio" }); + + } + + + if (oButton) { + + nIndex = this._buttons.length; + sButtonName = oButton.get("name"); + sGroupName = this.get("name"); + + oButton.index = nIndex; + + this._buttons[nIndex] = oButton; + m_oButtons[oButton.get("id")] = oButton; + + + if (sButtonName != sGroupName) { + + oButton.set("name", sGroupName); + + } + + + if (this.get("disabled")) { + + oButton.set("disabled", true); + + } + + + if (oButton.get("checked")) { + + this.set("checkedButton", oButton); + + } + + + oButtonElement = oButton.get("element"); + oGroupElement = this.get("element"); + + if (oButtonElement.parentNode != oGroupElement) { + + oGroupElement.appendChild(oButtonElement); + + } + + + oButton.on("checkedChange", + this._onButtonCheckedChange, oButton, this); + + + return oButton; + + } + + }, + + + /** + * @method addButtons + * @description Adds the array of buttons to the button group. + * @param {Array} p_aButtons Array of <a href="YAHOO.widget.Button.html"> + * YAHOO.widget.Button</a> instances to be added + * to the button group. + * @param {Array} p_aButtons Array of strings specifying the id + * attribute of the <code><input></code> or <code><span> + * </code> elements to be used to create the buttons to be added to the + * button group. + * @param {Array} p_aButtons Array of object references for the + * <code><input></code> or <code><span></code> elements + * to be used to create the buttons to be added to the button group. + * @param {Array} p_aButtons Array of object literals, each containing + * a set of <a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a> + * configuration attributes used to configure each button to be added + * to the button group. + * @return {Array} + */ + addButtons: function (p_aButtons) { + + var nButtons, + oButton, + aButtons, + i; + + if (Lang.isArray(p_aButtons)) { + + nButtons = p_aButtons.length; + aButtons = []; + + if (nButtons > 0) { + + for (i = 0; i < nButtons; i++) { + + oButton = this.addButton(p_aButtons[i]); + + if (oButton) { + + aButtons[aButtons.length] = oButton; + + } + + } + + if (aButtons.length > 0) { + + + return aButtons; + + } + + } + + } + + }, + + + /** + * @method removeButton + * @description Removes the button at the specified index from the + * button group. + * @param {Number} p_nIndex Number specifying the index of the button + * to be removed from the button group. + */ + removeButton: function (p_nIndex) { + + var oButton = this.getButton(p_nIndex), + nButtons, + i; + + if (oButton) { + + + this._buttons.splice(p_nIndex, 1); + delete m_oButtons[oButton.get("id")]; + + oButton.removeListener("checkedChange", + this._onButtonCheckedChange); + + oButton.destroy(); + + + nButtons = this._buttons.length; + + if (nButtons > 0) { + + i = this._buttons.length - 1; + + do { + + this._buttons[i].index = i; + + } + while (i--); + + } + + + } + + }, + + + /** + * @method getButton + * @description Returns the button at the specified index. + * @param {Number} p_nIndex The index of the button to retrieve from the + * button group. + * @return {<a href="YAHOO.widget.Button.html">YAHOO.widget.Button</a>} + */ + getButton: function (p_nIndex) { + + if (Lang.isNumber(p_nIndex)) { + + return this._buttons[p_nIndex]; + + } + + }, + + + /** + * @method getButtons + * @description Returns an array of the buttons in the button group. + * @return {Array} + */ + getButtons: function () { + + return this._buttons; + + }, + + + /** + * @method getCount + * @description Returns the number of buttons in the button group. + * @return {Number} + */ + getCount: function () { + + return this._buttons.length; + + }, + + + /** + * @method focus + * @description Sets focus to the button at the specified index. + * @param {Number} p_nIndex Number indicating the index of the button + * to focus. + */ + focus: function (p_nIndex) { + + var oButton, + nButtons, + i; + + if (Lang.isNumber(p_nIndex)) { + + oButton = this._buttons[p_nIndex]; + + if (oButton) { + + oButton.focus(); + + } + + } + else { + + nButtons = this.getCount(); + + for (i = 0; i < nButtons; i++) { + + oButton = this._buttons[i]; + + if (!oButton.get("disabled")) { + + oButton.focus(); + break; + + } + + } + + } + + }, + + + /** + * @method check + * @description Checks the button at the specified index. + * @param {Number} p_nIndex Number indicating the index of the button + * to check. + */ + check: function (p_nIndex) { + + var oButton = this.getButton(p_nIndex); + + if (oButton) { + + oButton.set("checked", true); + + } + + }, + + + /** + * @method destroy + * @description Removes the button group's element from its parent + * element and removes all event handlers. + */ + destroy: function () { + + + var nButtons = this._buttons.length, + oElement = this.get("element"), + oParentNode = oElement.parentNode, + i; + + if (nButtons > 0) { + + i = this._buttons.length - 1; + + do { + + this._buttons[i].destroy(); + + } + while (i--); + + } + + + Event.purgeElement(oElement); + + + oParentNode.removeChild(oElement); + + }, + + + /** + * @method toString + * @description Returns a string representing the button group. + * @return {String} + */ + toString: function () { + + return ("ButtonGroup " + this.get("id")); + + } + + }); + +})(); +YAHOO.register("button", YAHOO.widget.Button, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/charts-experimental-min.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/charts-experimental-min.js new file mode 100644 index 0000000..d3c57a2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/charts-experimental-min.js
@@ -0,0 +1,16 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/* + * SWFObject v1.5: Flash Player detection and embed - http://blog.deconcept.com/swfobject/ + * + * SWFObject is (c) 2007 Geoff Stearns and is released under the MIT License: + * http://www.opensource.org/licenses/mit-license.php + */ +var deconcept=deconcept||{};if(typeof deconcept.util=="undefined"||!deconcept.util){deconcept.util={};}if(typeof deconcept.SWFObjectUtil=="undefined"||!deconcept.SWFObjectUtil){deconcept.SWFObjectUtil={};}deconcept.SWFObject=function(E,C,K,F,H,J,L,G,A,D){if(!document.getElementById){return ;}this.DETECT_KEY=D?D:"detectflash";this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);this.params={};this.variables={};this.attributes=[];if(E){this.setAttribute("swf",E);}if(C){this.setAttribute("id",C);}if(K){this.setAttribute("width",K);}if(F){this.setAttribute("height",F);}if(H){this.setAttribute("version",new deconcept.PlayerVersion(H.toString().split(".")));}this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion();if(!window.opera&&document.all&&this.installedVer.major>7){deconcept.SWFObject.doPrepUnload=true;}if(J){this.addParam("bgcolor",J);}var B=L?L:"high";this.addParam("quality",B);this.setAttribute("useExpressInstall",false);this.setAttribute("doExpressInstall",false);var I=(G)?G:window.location;this.setAttribute("xiRedirectUrl",I);this.setAttribute("redirectUrl","");if(A){this.setAttribute("redirectUrl",A);}};deconcept.SWFObject.prototype={useExpressInstall:function(A){this.xiSWFPath=!A?"expressinstall.swf":A;this.setAttribute("useExpressInstall",true);},setAttribute:function(A,B){this.attributes[A]=B;},getAttribute:function(A){return this.attributes[A];},addParam:function(A,B){this.params[A]=B;},getParams:function(){return this.params;},addVariable:function(A,B){this.variables[A]=B;},getVariable:function(A){return this.variables[A];},getVariables:function(){return this.variables;},getVariablePairs:function(){var A=[];var B;var C=this.getVariables();for(B in C){A[A.length]=B+"="+C[B];}return A;},getSWFHTML:function(){var D="";var C={};var A="";var B="";if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");this.setAttribute("swf",this.xiSWFPath);}D='<embed type="application/x-shockwave-flash" src="'+this.getAttribute("swf")+'" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'" style="'+this.getAttribute("style")+'"';D+=' id="'+this.getAttribute("id")+'" name="'+this.getAttribute("id")+'" ';C=this.getParams();for(A in C){D+=[A]+'="'+C[A]+'" ';}B=this.getVariablePairs().join("&");if(B.length>0){D+='flashvars="'+B+'"';}D+="/>";}else{if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");this.setAttribute("swf",this.xiSWFPath);}D='<object id="'+this.getAttribute("id")+'" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" width="'+this.getAttribute("width")+'" height="'+this.getAttribute("height")+'" style="'+this.getAttribute("style")+'">';D+='<param name="movie" value="'+this.getAttribute("swf")+'" />';C=this.getParams();for(A in C){D+='<param name="'+A+'" value="'+C[A]+'" />';}B=this.getVariablePairs().join("&");if(B.length>0){D+='<param name="flashvars" value="'+B+'" />';}D+="</object>";}return D;},write:function(A){if(this.getAttribute("useExpressInstall")){var B=new deconcept.PlayerVersion([6,0,65]);if(this.installedVer.versionIsValid(B)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){this.setAttribute("doExpressInstall",true);this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));document.title=document.title.slice(0,47)+" - Flash Player Installation";this.addVariable("MMdoctitle",document.title);}}if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){var C=(typeof A=="string")?document.getElementById(A):A;C.innerHTML=this.getSWFHTML();return true;}else{if(this.getAttribute("redirectUrl")!==""){document.location.replace(this.getAttribute("redirectUrl"));}}return false;}};deconcept.SWFObjectUtil.getPlayerVersion=function(){var D=null;var C=new deconcept.PlayerVersion([0,0,0]);if(navigator.plugins&&navigator.mimeTypes.length){var A=navigator.plugins["Shockwave Flash"];if(A&&A.description){C=new deconcept.PlayerVersion(A.description.replace(/([a-zA-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}}else{if(navigator.userAgent&&navigator.userAgent.indexOf("Windows CE")>=0){var B=3;while(D){try{B++;D=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+B);C=new deconcept.PlayerVersion([B,0,0]);}catch(E){D=null;}}}else{try{D=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7");}catch(E){try{D=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6");C=new deconcept.PlayerVersion([6,0,21]);D.AllowScriptAccess="always";}catch(E){if(C.major==6){return C;}}try{D=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");}catch(E){}}if(D!==null){C=new deconcept.PlayerVersion(D.GetVariable("$version").split(" ")[1].split(","));}}}return C;};deconcept.PlayerVersion=function(A){this.major=A[0]!==null?parseInt(A[0],0):0;this.minor=A[1]!==null?parseInt(A[1],0):0;this.rev=A[2]!==null?parseInt(A[2],0):0;};deconcept.PlayerVersion.prototype.versionIsValid=function(A){if(this.major<A.major){return false;}if(this.major>A.major){return true;}if(this.minor<A.minor){return false;}if(this.minor>A.minor){return true;}if(this.rev<A.rev){return false;}return true;};deconcept.util={getRequestParameter:function(D){var C=document.location.search||document.location.hash;if(D===null){return C;}if(C){var B=C.substring(1).split("&");for(var A=0;A<B.length;A++){if(B[A].substring(0,B[A].indexOf("="))==D){return B[A].substring((B[A].indexOf("=")+1));}}}return"";}};deconcept.SWFObjectUtil.cleanupSWFs=function(){var C=document.getElementsByTagName("OBJECT");for(var B=C.length-1;B>=0;B--){C[B].style.display="none";for(var A in C[B]){if(typeof C[B][A]=="function"){C[B][A]=function(){};}}}};if(deconcept.SWFObject.doPrepUnload){if(!deconcept.unloadSet){deconcept.SWFObjectUtil.prepUnload=function(){__flash_unloadHandler=function(){}; +__flash_savedUnloadHandler=function(){};window.attachEvent("onunload",deconcept.SWFObjectUtil.cleanupSWFs);};window.attachEvent("onbeforeunload",deconcept.SWFObjectUtil.prepUnload);deconcept.unloadSet=true;}}if(!document.getElementById&&document.all){document.getElementById=function(A){return document.all[A];};}var getQueryParamValue=deconcept.util.getRequestParameter;var FlashObject=deconcept.SWFObject;var SWFObject=deconcept.SWFObject;YAHOO.widget.FlashAdapter=function(C,A,B){this._queue=this._queue||[];this._events=this._events||{};this._configs=this._configs||{};B=B||{};this._id=B.id=B.id||YAHOO.util.Dom.generateId(null,"yuigen");B.version=B.version||"9.0.45";B.backgroundColor=B.backgroundColor||"#ffffff";this._attributes=B;this._swfURL=C;this._containerID=A;this._embedSWF(this._swfURL,this._containerID,B.id,B.version,B.backgroundColor,B.expressInstall,B.wmode);this.createEvent("contentReady");};YAHOO.extend(YAHOO.widget.FlashAdapter,YAHOO.util.AttributeProvider,{_swfURL:null,_containerID:null,_swf:null,_id:null,_attributes:null,toString:function(){return"FlashAdapter "+this._id;},destroy:function(){if(this._swf){var B=YAHOO.util.Dom.get(this._containerID);B.removeChild(this._swf);}var A=this._id;for(var C in this){if(YAHOO.lang.hasOwnProperty(this,C)){this[C]=null;}}},_embedSWF:function(I,H,D,C,F,G,B){var E=new deconcept.SWFObject(I,D,"100%","100%",C,F);if(G){E.useExpressInstall(G);}E.addParam("allowScriptAccess","always");if(B!==null){E.addParam("wmode",B);}E.addVariable("allowedDomain",document.location.hostname);E.addVariable("elementID",D);E.addVariable("eventHandler","YAHOO.widget.FlashAdapter.eventHandler");var A=YAHOO.util.Dom.get(H);var J=E.write(A);if(J){this._swf=YAHOO.util.Dom.get(D);this._swf.owner=this;}else{}},_eventHandler:function(B){var A=B.type;switch(A){case"swfReady":this._loadHandler();return ;case"log":return ;}this.fireEvent(A,B);},_loadHandler:function(){this._initAttributes(this._attributes);this.setAttributes(this._attributes,true);this._attributes=null;this.fireEvent("contentReady");},_initAttributes:function(A){this.getAttributeConfig("swfURL",{method:this._getSWFURL});},_getSWFURL:function(){return this._swfURL;}});YAHOO.widget.FlashAdapter.eventHandler=function(A,C){var B=YAHOO.util.Dom.get(A);if(!B.owner){setTimeout(function(){YAHOO.widget.FlashAdapter.eventHandler(A,C);},0);}else{B.owner._eventHandler(C);}};YAHOO.widget.FlashAdapter.proxyFunctionCount=0;YAHOO.widget.FlashAdapter.createProxyFunction=function(B){var A=YAHOO.widget.FlashAdapter.proxyFunctionCount;YAHOO.widget.FlashAdapter["proxyFunction"+A]=function(){return B.apply(null,arguments);};YAHOO.widget.FlashAdapter.proxyFunctionCount++;return"YAHOO.widget.FlashAdapter.proxyFunction"+A.toString();};YAHOO.widget.FlashAdapter.removeProxyFunction=function(A){if(!A||A.indexOf("YAHOO.widget.FlashAdapter.proxyFunction")<0){return ;}A=A.substr(26);YAHOO.widget.FlashAdapter[A]=null;};YAHOO.widget.Chart=function(C,A,D,B){YAHOO.widget.Chart.superclass.constructor.call(this,YAHOO.widget.Chart.SWFURL,A,B);this._type=C;this._dataSource=D;this.createEvent("itemMouseOverEvent");this.createEvent("itemMouseOutEvent");this.createEvent("itemClickEvent");this.createEvent("itemDoubleClickEvent");this.createEvent("itemDragStartEvent");this.createEvent("itemDragEvent");this.createEvent("itemDragEndEvent");};YAHOO.extend(YAHOO.widget.Chart,YAHOO.widget.FlashAdapter,{_type:null,_pollingID:null,_pollingInterval:null,_initialized:false,_dataTipFunction:null,toString:function(){return"Chart "+this._id;},setStyle:function(A,B){B=YAHOO.lang.JSON.stringify(B);this._swf.setStyle(A,B);},setStyles:function(A){A=YAHOO.lang.JSON.stringify(A);this._swf.setStyles(A);},setSeriesStyles:function(B){for(var A=0;A<B.length;A++){B[A]=YAHOO.lang.JSON.stringify(B[A]);}this._swf.setSeriesStyles(B);},destroy:function(){if(this._dataSource!==null){if(this._pollingID!==null){this._dataSource.clearInterval(this._pollingID);this._pollingID=null;}}if(this._dataTipFunction){YAHOO.widget.FlashAdapter.removeProxyFunction(this._dataTipFunction);}YAHOO.widget.Chart.superclass.destroy.call(this);},_initAttributes:function(A){YAHOO.widget.Chart.superclass._initAttributes.call(this,A);this.getAttributeConfig("request",{method:this._getRequest});this.setAttributeConfig("request",{method:this._setRequest});this.getAttributeConfig("dataSource",{method:this._getDataSource});this.setAttributeConfig("dataSource",{method:this._setDataSource});this.getAttributeConfig("series",{method:this._getSeriesDefs});this.setAttributeConfig("series",{method:this._setSeriesDefs});this.getAttributeConfig("categoryNames",{method:this._getCategoryNames});this.setAttributeConfig("categoryNames",{validator:YAHOO.lang.isArray,method:this._setCategoryNames});this.getAttributeConfig("dataTipFunction",{method:this._getDataTipFunction});this.setAttributeConfig("dataTipFunction",{method:this._setDataTipFunction});this.getAttributeConfig("polling",{method:this._getPolling});this.setAttributeConfig("polling",{method:this._setPolling});},_loadHandler:function(){this._swf.setType(this._type);if(this._attributes.style){var A=this._attributes.style;this.setStyles(A);}YAHOO.widget.Chart.superclass._loadHandler.call(this);this._initialized=true;if(this._dataSource){this.set("dataSource",this._dataSource);}},_refreshData:function(){if(!this._initialized){return ;}if(this._dataSource!==null){if(this._pollingID!==null){this._dataSource.clearInterval(this._pollingID);this._pollingID=null;}if(this._pollingInterval>0){this._pollingID=this._dataSource.setInterval(this._pollingInterval,this._request,this._loadDataHandler,this);}this._dataSource.sendRequest(this._request,this._loadDataHandler,this);}},_loadDataHandler:function(D,C,J){if(J){}else{var I=false;var F=[];var E=0;var K=null;var H=0;if(this._seriesDefs!==null){E=this._seriesDefs.length;for(H=0;H<E;H++){K=this._seriesDefs[H];var B={};for(var A in K){if(YAHOO.lang.hasOwnProperty(K,A)){if(A=="style"&&K.style!==null){B.style=YAHOO.lang.JSON.stringify(K.style); +I=true;K.style=null;}else{B[A]=K[A];}}}F.push(B);}}if(E>0){for(H=0;H<E;H++){K=F[H];if(!K.type){K.type=this._type;}K.dataProvider=C.results;}}else{var G={type:this._type,dataProvider:C.results};F.push(G);}this._swf.setDataProvider(F,I);}},_request:"",_getRequest:function(){return this._request;},_setRequest:function(A){this._request=A;this._refreshData();},_dataSource:null,_getDataSource:function(){return this._dataSource;},_setDataSource:function(A){this._dataSource=A;this._refreshData();},_seriesDefs:null,_getSeriesDefs:function(){return this._seriesDefs;},_setSeriesDefs:function(A){this._seriesDefs=A;this._refreshData();},_getCategoryNames:function(){this._swf.getCategoryNames();},_setCategoryNames:function(A){this._swf.setCategoryNames(A);},_setDataTipFunction:function(A){if(this._dataTipFunction){YAHOO.widget.FlashAdapter.removeProxyFunction(this._dataTipFunction);}if(A&&typeof A=="function"){A=YAHOO.widget.FlashAdapter.createProxyFunction(A);this._dataTipFunction=A;}this._swf.setDataTipFunction(A);},_getPolling:function(){return this._pollingInterval;},_setPolling:function(A){this._pollingInterval=A;this._refreshData();}});YAHOO.widget.Chart.SWFURL="assets/charts.swf";YAHOO.widget.PieChart=function(A,C,B){YAHOO.widget.PieChart.superclass.constructor.call(this,"pie",A,C,B);};YAHOO.lang.extend(YAHOO.widget.PieChart,YAHOO.widget.Chart,{_initAttributes:function(A){YAHOO.widget.PieChart.superclass._initAttributes.call(this,A);this.getAttributeConfig("dataField",{method:this._getDataField});this.setAttributeConfig("dataField",{validator:YAHOO.lang.isString,method:this._setDataField});this.getAttributeConfig("categoryField",{method:this._getCategoryField});this.setAttributeConfig("categoryField",{validator:YAHOO.lang.isString,method:this._setCategoryField});},_getDataField:function(){return this._swf.getDataField();},_setDataField:function(A){this._swf.setDataField(A);},_getCategoryField:function(){return this._swf.getCategoryField();},_setCategoryField:function(A){this._swf.setCategoryField(A);}});YAHOO.widget.CartesianChart=function(C,A,D,B){YAHOO.widget.CartesianChart.superclass.constructor.call(this,C,A,D,B);};YAHOO.lang.extend(YAHOO.widget.CartesianChart,YAHOO.widget.Chart,{_xAxisLabelFunction:null,_yAxisLabelFunction:null,destroy:function(){if(this._xAxisLabelFunction){YAHOO.widget.FlashAdapter.removeProxyFunction(this._xAxisLabelFunction);this._xAxisLabelFunction=null;}if(this._yAxisLabelFunction){YAHOO.widget.FlashAdapter.removeProxyFunction(this._yAxisLabelFunction);this._yAxisLabelFunction=null;}YAHOO.widget.CartesianChart.superclass.destroy.call(this);},_initAttributes:function(A){YAHOO.widget.CartesianChart.superclass._initAttributes.call(this,A);this.getAttributeConfig("xField",{method:this._getXField});this.setAttributeConfig("xField",{validator:YAHOO.lang.isString,method:this._setXField});this.getAttributeConfig("yField",{method:this._getYField});this.setAttributeConfig("yField",{validator:YAHOO.lang.isString,method:this._setYField});this.setAttributeConfig("xAxis",{method:this._setXAxis});this.setAttributeConfig("yAxis",{method:this._setYAxis});},_getXField:function(){return this._swf.getHorizontalField();},_setXField:function(A){this._swf.setHorizontalField(A);},_getYField:function(){return this._swf.getVerticalField();},_setYField:function(A){this._swf.setVerticalField(A);},_setXAxis:function(A){if(this._xAxisLabelFunction){YAHOO.widget.FlashAdapter.removeProxyFunction(this._xAxisLabelFunction);}if(A.labelFunction&&typeof A.labelFunction=="function"){A.labelFunction=YAHOO.widget.FlashAdapter.createProxyFunction(A);this._xAxisLabelFunction=A.labelFunction;}this._swf.setHorizontalAxis(A);},_setYAxis:function(A){if(this._yAxisLabelFunction){YAHOO.widget.FlashAdapter.removeProxyFunction(this._yAxisLabelFunction);}if(A.labelFunction&&typeof A.labelFunction=="function"){A.labelFunction=YAHOO.widget.FlashAdapter.createProxyFunction(A.labelFunction);this._yAxisLabelFunction=A.labelFunction;}this._swf.setVerticalAxis(A);}});YAHOO.widget.LineChart=function(A,C,B){YAHOO.widget.LineChart.superclass.constructor.call(this,"line",A,C,B);};YAHOO.lang.extend(YAHOO.widget.LineChart,YAHOO.widget.CartesianChart);YAHOO.widget.ColumnChart=function(A,C,B){YAHOO.widget.ColumnChart.superclass.constructor.call(this,"column",A,C,B);};YAHOO.lang.extend(YAHOO.widget.ColumnChart,YAHOO.widget.CartesianChart);YAHOO.widget.BarChart=function(A,C,B){YAHOO.widget.BarChart.superclass.constructor.call(this,"bar",A,C,B);};YAHOO.lang.extend(YAHOO.widget.BarChart,YAHOO.widget.CartesianChart);YAHOO.widget.Axis=function(){};YAHOO.widget.Axis.prototype={type:null,orientation:"horizontal",reverse:false,labelFunction:null,hideOverlappingLabels:true};YAHOO.widget.NumericAxis=function(){YAHOO.widget.NumericAxis.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.NumericAxis,YAHOO.widget.Axis,{type:"numeric",minimum:NaN,maximum:NaN,majorUnit:NaN,minorUnit:NaN,snapToUnits:true,alwaysShowZero:true,scale:"linear"});YAHOO.widget.TimeAxis=function(){YAHOO.widget.TimeAxis.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.TimeAxis,YAHOO.widget.Axis,{type:"time",minimum:null,maximum:null,majorUnit:NaN,majorTimeUnit:null,minorUnit:NaN,minorTimeUnit:null,snapToUnits:true});YAHOO.widget.CategoryAxis=function(){YAHOO.widget.CategoryAxis.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.CategoryAxis,YAHOO.widget.Axis,{type:"category",categoryNames:null});YAHOO.widget.Series=function(){};YAHOO.widget.Series.prototype={type:null,displayName:null};YAHOO.widget.CartesianSeries=function(){YAHOO.widget.CartesianSeries.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.CartesianSeries,YAHOO.widget.Series,{xField:null,yField:null});YAHOO.widget.ColumnSeries=function(){YAHOO.widget.ColumnSeries.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.ColumnSeries,YAHOO.widget.CartesianSeries,{type:"column"});YAHOO.widget.LineSeries=function(){YAHOO.widget.LineSeries.superclass.constructor.call(this); +};YAHOO.lang.extend(YAHOO.widget.LineSeries,YAHOO.widget.CartesianSeries,{type:"line"});YAHOO.widget.BarSeries=function(){YAHOO.widget.BarSeries.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.BarSeries,YAHOO.widget.CartesianSeries,{type:"bar"});YAHOO.widget.PieSeries=function(){YAHOO.widget.PieSeries.superclass.constructor.call(this);};YAHOO.lang.extend(YAHOO.widget.PieSeries,YAHOO.widget.Series,{type:"pie",dataField:null,categoryField:null});YAHOO.register("charts",YAHOO.widget.Chart,{version:"2.5.2",build:"1076"}); \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/charts.swf b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/charts.swf new file mode 100644 index 0000000..4de1458 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/charts.swf Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/container.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/container.js new file mode 100644 index 0000000..ad10e85 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/container.js
@@ -0,0 +1,7832 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +(function () { + + /** + * Config is a utility used within an Object to allow the implementer to + * maintain a list of local configuration properties and listen for changes + * to those properties dynamically using CustomEvent. The initial values are + * also maintained so that the configuration can be reset at any given point + * to its initial state. + * @namespace YAHOO.util + * @class Config + * @constructor + * @param {Object} owner The owner Object to which this Config Object belongs + */ + YAHOO.util.Config = function (owner) { + + if (owner) { + this.init(owner); + } + + + }; + + + var Lang = YAHOO.lang, + CustomEvent = YAHOO.util.CustomEvent, + Config = YAHOO.util.Config; + + + /** + * Constant representing the CustomEvent type for the config changed event. + * @property YAHOO.util.Config.CONFIG_CHANGED_EVENT + * @private + * @static + * @final + */ + Config.CONFIG_CHANGED_EVENT = "configChanged"; + + /** + * Constant representing the boolean type string + * @property YAHOO.util.Config.BOOLEAN_TYPE + * @private + * @static + * @final + */ + Config.BOOLEAN_TYPE = "boolean"; + + Config.prototype = { + + /** + * Object reference to the owner of this Config Object + * @property owner + * @type Object + */ + owner: null, + + /** + * Boolean flag that specifies whether a queue is currently + * being executed + * @property queueInProgress + * @type Boolean + */ + queueInProgress: false, + + /** + * Maintains the local collection of configuration property objects and + * their specified values + * @property config + * @private + * @type Object + */ + config: null, + + /** + * Maintains the local collection of configuration property objects as + * they were initially applied. + * This object is used when resetting a property. + * @property initialConfig + * @private + * @type Object + */ + initialConfig: null, + + /** + * Maintains the local, normalized CustomEvent queue + * @property eventQueue + * @private + * @type Object + */ + eventQueue: null, + + /** + * Custom Event, notifying subscribers when Config properties are set + * (setProperty is called without the silent flag + * @event configChangedEvent + */ + configChangedEvent: null, + + /** + * Initializes the configuration Object and all of its local members. + * @method init + * @param {Object} owner The owner Object to which this Config + * Object belongs + */ + init: function (owner) { + + this.owner = owner; + + this.configChangedEvent = + this.createEvent(Config.CONFIG_CHANGED_EVENT); + + this.configChangedEvent.signature = CustomEvent.LIST; + this.queueInProgress = false; + this.config = {}; + this.initialConfig = {}; + this.eventQueue = []; + + }, + + /** + * Validates that the value passed in is a Boolean. + * @method checkBoolean + * @param {Object} val The value to validate + * @return {Boolean} true, if the value is valid + */ + checkBoolean: function (val) { + return (typeof val == Config.BOOLEAN_TYPE); + }, + + /** + * Validates that the value passed in is a number. + * @method checkNumber + * @param {Object} val The value to validate + * @return {Boolean} true, if the value is valid + */ + checkNumber: function (val) { + return (!isNaN(val)); + }, + + /** + * Fires a configuration property event using the specified value. + * @method fireEvent + * @private + * @param {String} key The configuration property's name + * @param {value} Object The value of the correct type for the property + */ + fireEvent: function ( key, value ) { + var property = this.config[key]; + + if (property && property.event) { + property.event.fire(value); + } + }, + + /** + * Adds a property to the Config Object's private config hash. + * @method addProperty + * @param {String} key The configuration property's name + * @param {Object} propertyObject The Object containing all of this + * property's arguments + */ + addProperty: function ( key, propertyObject ) { + key = key.toLowerCase(); + + this.config[key] = propertyObject; + + propertyObject.event = this.createEvent(key, { scope: this.owner }); + propertyObject.event.signature = CustomEvent.LIST; + + + propertyObject.key = key; + + if (propertyObject.handler) { + propertyObject.event.subscribe(propertyObject.handler, + this.owner); + } + + this.setProperty(key, propertyObject.value, true); + + if (! propertyObject.suppressEvent) { + this.queueProperty(key, propertyObject.value); + } + + }, + + /** + * Returns a key-value configuration map of the values currently set in + * the Config Object. + * @method getConfig + * @return {Object} The current config, represented in a key-value map + */ + getConfig: function () { + + var cfg = {}, + prop, + property; + + for (prop in this.config) { + property = this.config[prop]; + if (property && property.event) { + cfg[prop] = property.value; + } + } + + return cfg; + }, + + /** + * Returns the value of specified property. + * @method getProperty + * @param {String} key The name of the property + * @return {Object} The value of the specified property + */ + getProperty: function (key) { + var property = this.config[key.toLowerCase()]; + if (property && property.event) { + return property.value; + } else { + return undefined; + } + }, + + /** + * Resets the specified property's value to its initial value. + * @method resetProperty + * @param {String} key The name of the property + * @return {Boolean} True is the property was reset, false if not + */ + resetProperty: function (key) { + + key = key.toLowerCase(); + + var property = this.config[key]; + + if (property && property.event) { + + if (this.initialConfig[key] && + !Lang.isUndefined(this.initialConfig[key])) { + + this.setProperty(key, this.initialConfig[key]); + + return true; + + } + + } else { + + return false; + } + + }, + + /** + * Sets the value of a property. If the silent property is passed as + * true, the property's event will not be fired. + * @method setProperty + * @param {String} key The name of the property + * @param {String} value The value to set the property to + * @param {Boolean} silent Whether the value should be set silently, + * without firing the property event. + * @return {Boolean} True, if the set was successful, false if it failed. + */ + setProperty: function (key, value, silent) { + + var property; + + key = key.toLowerCase(); + + if (this.queueInProgress && ! silent) { + // Currently running through a queue... + this.queueProperty(key,value); + return true; + + } else { + property = this.config[key]; + if (property && property.event) { + if (property.validator && !property.validator(value)) { + return false; + } else { + property.value = value; + if (! silent) { + this.fireEvent(key, value); + this.configChangedEvent.fire([key, value]); + } + return true; + } + } else { + return false; + } + } + }, + + /** + * Sets the value of a property and queues its event to execute. If the + * event is already scheduled to execute, it is + * moved from its current position to the end of the queue. + * @method queueProperty + * @param {String} key The name of the property + * @param {String} value The value to set the property to + * @return {Boolean} true, if the set was successful, false if + * it failed. + */ + queueProperty: function (key, value) { + + key = key.toLowerCase(); + + var property = this.config[key], + foundDuplicate = false, + iLen, + queueItem, + queueItemKey, + queueItemValue, + sLen, + supercedesCheck, + qLen, + queueItemCheck, + queueItemCheckKey, + queueItemCheckValue, + i, + s, + q; + + if (property && property.event) { + + if (!Lang.isUndefined(value) && property.validator && + !property.validator(value)) { // validator + return false; + } else { + + if (!Lang.isUndefined(value)) { + property.value = value; + } else { + value = property.value; + } + + foundDuplicate = false; + iLen = this.eventQueue.length; + + for (i = 0; i < iLen; i++) { + queueItem = this.eventQueue[i]; + + if (queueItem) { + queueItemKey = queueItem[0]; + queueItemValue = queueItem[1]; + + if (queueItemKey == key) { + + /* + found a dupe... push to end of queue, null + current item, and break + */ + + this.eventQueue[i] = null; + + this.eventQueue.push( + [key, (!Lang.isUndefined(value) ? + value : queueItemValue)]); + + foundDuplicate = true; + break; + } + } + } + + // this is a refire, or a new property in the queue + + if (! foundDuplicate && !Lang.isUndefined(value)) { + this.eventQueue.push([key, value]); + } + } + + if (property.supercedes) { + + sLen = property.supercedes.length; + + for (s = 0; s < sLen; s++) { + + supercedesCheck = property.supercedes[s]; + qLen = this.eventQueue.length; + + for (q = 0; q < qLen; q++) { + queueItemCheck = this.eventQueue[q]; + + if (queueItemCheck) { + queueItemCheckKey = queueItemCheck[0]; + queueItemCheckValue = queueItemCheck[1]; + + if (queueItemCheckKey == + supercedesCheck.toLowerCase() ) { + + this.eventQueue.push([queueItemCheckKey, + queueItemCheckValue]); + + this.eventQueue[q] = null; + break; + + } + } + } + } + } + + + return true; + } else { + return false; + } + }, + + /** + * Fires the event for a property using the property's current value. + * @method refireEvent + * @param {String} key The name of the property + */ + refireEvent: function (key) { + + key = key.toLowerCase(); + + var property = this.config[key]; + + if (property && property.event && + + !Lang.isUndefined(property.value)) { + + if (this.queueInProgress) { + + this.queueProperty(key); + + } else { + + this.fireEvent(key, property.value); + + } + + } + }, + + /** + * Applies a key-value Object literal to the configuration, replacing + * any existing values, and queueing the property events. + * Although the values will be set, fireQueue() must be called for their + * associated events to execute. + * @method applyConfig + * @param {Object} userConfig The configuration Object literal + * @param {Boolean} init When set to true, the initialConfig will + * be set to the userConfig passed in, so that calling a reset will + * reset the properties to the passed values. + */ + applyConfig: function (userConfig, init) { + + var sKey, + oConfig; + + if (init) { + oConfig = {}; + for (sKey in userConfig) { + if (Lang.hasOwnProperty(userConfig, sKey)) { + oConfig[sKey.toLowerCase()] = userConfig[sKey]; + } + } + this.initialConfig = oConfig; + } + + for (sKey in userConfig) { + if (Lang.hasOwnProperty(userConfig, sKey)) { + this.queueProperty(sKey, userConfig[sKey]); + } + } + }, + + /** + * Refires the events for all configuration properties using their + * current values. + * @method refresh + */ + refresh: function () { + + var prop; + + for (prop in this.config) { + this.refireEvent(prop); + } + }, + + /** + * Fires the normalized list of queued property change events + * @method fireQueue + */ + fireQueue: function () { + + var i, + queueItem, + key, + value, + property; + + this.queueInProgress = true; + for (i = 0;i < this.eventQueue.length; i++) { + queueItem = this.eventQueue[i]; + if (queueItem) { + + key = queueItem[0]; + value = queueItem[1]; + property = this.config[key]; + + property.value = value; + + this.fireEvent(key,value); + } + } + + this.queueInProgress = false; + this.eventQueue = []; + }, + + /** + * Subscribes an external handler to the change event for any + * given property. + * @method subscribeToConfigEvent + * @param {String} key The property name + * @param {Function} handler The handler function to use subscribe to + * the property's event + * @param {Object} obj The Object to use for scoping the event handler + * (see CustomEvent documentation) + * @param {Boolean} override Optional. If true, will override "this" + * within the handler to map to the scope Object passed into the method. + * @return {Boolean} True, if the subscription was successful, + * otherwise false. + */ + subscribeToConfigEvent: function (key, handler, obj, override) { + + var property = this.config[key.toLowerCase()]; + + if (property && property.event) { + if (!Config.alreadySubscribed(property.event, handler, obj)) { + property.event.subscribe(handler, obj, override); + } + return true; + } else { + return false; + } + + }, + + /** + * Unsubscribes an external handler from the change event for any + * given property. + * @method unsubscribeFromConfigEvent + * @param {String} key The property name + * @param {Function} handler The handler function to use subscribe to + * the property's event + * @param {Object} obj The Object to use for scoping the event + * handler (see CustomEvent documentation) + * @return {Boolean} True, if the unsubscription was successful, + * otherwise false. + */ + unsubscribeFromConfigEvent: function (key, handler, obj) { + var property = this.config[key.toLowerCase()]; + if (property && property.event) { + return property.event.unsubscribe(handler, obj); + } else { + return false; + } + }, + + /** + * Returns a string representation of the Config object + * @method toString + * @return {String} The Config object in string format. + */ + toString: function () { + var output = "Config"; + if (this.owner) { + output += " [" + this.owner.toString() + "]"; + } + return output; + }, + + /** + * Returns a string representation of the Config object's current + * CustomEvent queue + * @method outputEventQueue + * @return {String} The string list of CustomEvents currently queued + * for execution + */ + outputEventQueue: function () { + + var output = "", + queueItem, + q, + nQueue = this.eventQueue.length; + + for (q = 0; q < nQueue; q++) { + queueItem = this.eventQueue[q]; + if (queueItem) { + output += queueItem[0] + "=" + queueItem[1] + ", "; + } + } + return output; + }, + + /** + * Sets all properties to null, unsubscribes all listeners from each + * property's change event and all listeners from the configChangedEvent. + * @method destroy + */ + destroy: function () { + + var oConfig = this.config, + sProperty, + oProperty; + + + for (sProperty in oConfig) { + + if (Lang.hasOwnProperty(oConfig, sProperty)) { + + oProperty = oConfig[sProperty]; + + oProperty.event.unsubscribeAll(); + oProperty.event = null; + + } + + } + + this.configChangedEvent.unsubscribeAll(); + + this.configChangedEvent = null; + this.owner = null; + this.config = null; + this.initialConfig = null; + this.eventQueue = null; + + } + + }; + + + + /** + * Checks to determine if a particular function/Object pair are already + * subscribed to the specified CustomEvent + * @method YAHOO.util.Config.alreadySubscribed + * @static + * @param {YAHOO.util.CustomEvent} evt The CustomEvent for which to check + * the subscriptions + * @param {Function} fn The function to look for in the subscribers list + * @param {Object} obj The execution scope Object for the subscription + * @return {Boolean} true, if the function/Object pair is already subscribed + * to the CustomEvent passed in + */ + Config.alreadySubscribed = function (evt, fn, obj) { + + var nSubscribers = evt.subscribers.length, + subsc, + i; + + if (nSubscribers > 0) { + i = nSubscribers - 1; + do { + subsc = evt.subscribers[i]; + if (subsc && subsc.obj == obj && subsc.fn == fn) { + return true; + } + } + while (i--); + } + + return false; + + }; + + YAHOO.lang.augmentProto(Config, YAHOO.util.EventProvider); + +}()); + +(function () { + + /** + * The Container family of components is designed to enable developers to + * create different kinds of content-containing modules on the web. Module + * and Overlay are the most basic containers, and they can be used directly + * or extended to build custom containers. Also part of the Container family + * are four UI controls that extend Module and Overlay: Tooltip, Panel, + * Dialog, and SimpleDialog. + * @module container + * @title Container + * @requires yahoo, dom, event + * @optional dragdrop, animation, button + */ + + /** + * Module is a JavaScript representation of the Standard Module Format. + * Standard Module Format is a simple standard for markup containers where + * child nodes representing the header, body, and footer of the content are + * denoted using the CSS classes "hd", "bd", and "ft" respectively. + * Module is the base class for all other classes in the YUI + * Container package. + * @namespace YAHOO.widget + * @class Module + * @constructor + * @param {String} el The element ID representing the Module <em>OR</em> + * @param {HTMLElement} el The element representing the Module + * @param {Object} userConfig The configuration Object literal containing + * the configuration that should be set for this module. See configuration + * documentation for more details. + */ + YAHOO.widget.Module = function (el, userConfig) { + if (el) { + this.init(el, userConfig); + } else { + } + }; + + var Dom = YAHOO.util.Dom, + Config = YAHOO.util.Config, + Event = YAHOO.util.Event, + CustomEvent = YAHOO.util.CustomEvent, + Module = YAHOO.widget.Module, + + m_oModuleTemplate, + m_oHeaderTemplate, + m_oBodyTemplate, + m_oFooterTemplate, + + /** + * Constant representing the name of the Module's events + * @property EVENT_TYPES + * @private + * @final + * @type Object + */ + EVENT_TYPES = { + "BEFORE_INIT": "beforeInit", + "INIT": "init", + "APPEND": "append", + "BEFORE_RENDER": "beforeRender", + "RENDER": "render", + "CHANGE_HEADER": "changeHeader", + "CHANGE_BODY": "changeBody", + "CHANGE_FOOTER": "changeFooter", + "CHANGE_CONTENT": "changeContent", + "DESTORY": "destroy", + "BEFORE_SHOW": "beforeShow", + "SHOW": "show", + "BEFORE_HIDE": "beforeHide", + "HIDE": "hide" + }, + + /** + * Constant representing the Module's configuration properties + * @property DEFAULT_CONFIG + * @private + * @final + * @type Object + */ + DEFAULT_CONFIG = { + + "VISIBLE": { + key: "visible", + value: true, + validator: YAHOO.lang.isBoolean + }, + + "EFFECT": { + key: "effect", + suppressEvent: true, + supercedes: ["visible"] + }, + + "MONITOR_RESIZE": { + key: "monitorresize", + value: true + }, + + "APPEND_TO_DOCUMENT_BODY": { + key: "appendtodocumentbody", + value: false + } + }; + + /** + * Constant representing the prefix path to use for non-secure images + * @property YAHOO.widget.Module.IMG_ROOT + * @static + * @final + * @type String + */ + Module.IMG_ROOT = null; + + /** + * Constant representing the prefix path to use for securely served images + * @property YAHOO.widget.Module.IMG_ROOT_SSL + * @static + * @final + * @type String + */ + Module.IMG_ROOT_SSL = null; + + /** + * Constant for the default CSS class name that represents a Module + * @property YAHOO.widget.Module.CSS_MODULE + * @static + * @final + * @type String + */ + Module.CSS_MODULE = "yui-module"; + + /** + * Constant representing the module header + * @property YAHOO.widget.Module.CSS_HEADER + * @static + * @final + * @type String + */ + Module.CSS_HEADER = "hd"; + + /** + * Constant representing the module body + * @property YAHOO.widget.Module.CSS_BODY + * @static + * @final + * @type String + */ + Module.CSS_BODY = "bd"; + + /** + * Constant representing the module footer + * @property YAHOO.widget.Module.CSS_FOOTER + * @static + * @final + * @type String + */ + Module.CSS_FOOTER = "ft"; + + /** + * Constant representing the url for the "src" attribute of the iframe + * used to monitor changes to the browser's base font size + * @property YAHOO.widget.Module.RESIZE_MONITOR_SECURE_URL + * @static + * @final + * @type String + */ + Module.RESIZE_MONITOR_SECURE_URL = "javascript:false;"; + + /** + * Singleton CustomEvent fired when the font size is changed in the browser. + * Opera's "zoom" functionality currently does not support text + * size detection. + * @event YAHOO.widget.Module.textResizeEvent + */ + Module.textResizeEvent = new CustomEvent("textResize"); + + function createModuleTemplate() { + + if (!m_oModuleTemplate) { + m_oModuleTemplate = document.createElement("div"); + + m_oModuleTemplate.innerHTML = ("<div class=\"" + + Module.CSS_HEADER + "\"></div>" + "<div class=\"" + + Module.CSS_BODY + "\"></div><div class=\"" + + Module.CSS_FOOTER + "\"></div>"); + + m_oHeaderTemplate = m_oModuleTemplate.firstChild; + m_oBodyTemplate = m_oHeaderTemplate.nextSibling; + m_oFooterTemplate = m_oBodyTemplate.nextSibling; + } + + return m_oModuleTemplate; + } + + function createHeader() { + if (!m_oHeaderTemplate) { + createModuleTemplate(); + } + return (m_oHeaderTemplate.cloneNode(false)); + } + + function createBody() { + if (!m_oBodyTemplate) { + createModuleTemplate(); + } + return (m_oBodyTemplate.cloneNode(false)); + } + + function createFooter() { + if (!m_oFooterTemplate) { + createModuleTemplate(); + } + return (m_oFooterTemplate.cloneNode(false)); + } + + Module.prototype = { + + /** + * The class's constructor function + * @property contructor + * @type Function + */ + constructor: Module, + + /** + * The main module element that contains the header, body, and footer + * @property element + * @type HTMLElement + */ + element: null, + + /** + * The header element, denoted with CSS class "hd" + * @property header + * @type HTMLElement + */ + header: null, + + /** + * The body element, denoted with CSS class "bd" + * @property body + * @type HTMLElement + */ + body: null, + + /** + * The footer element, denoted with CSS class "ft" + * @property footer + * @type HTMLElement + */ + footer: null, + + /** + * The id of the element + * @property id + * @type String + */ + id: null, + + /** + * A string representing the root path for all images created by + * a Module instance. + * @deprecated It is recommend that any images for a Module be applied + * via CSS using the "background-image" property. + * @property imageRoot + * @type String + */ + imageRoot: Module.IMG_ROOT, + + /** + * Initializes the custom events for Module which are fired + * automatically at appropriate times by the Module class. + * @method initEvents + */ + initEvents: function () { + + var SIGNATURE = CustomEvent.LIST; + + /** + * CustomEvent fired prior to class initalization. + * @event beforeInitEvent + * @param {class} classRef class reference of the initializing + * class, such as this.beforeInitEvent.fire(Module) + */ + this.beforeInitEvent = this.createEvent(EVENT_TYPES.BEFORE_INIT); + this.beforeInitEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after class initalization. + * @event initEvent + * @param {class} classRef class reference of the initializing + * class, such as this.beforeInitEvent.fire(Module) + */ + this.initEvent = this.createEvent(EVENT_TYPES.INIT); + this.initEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the Module is appended to the DOM + * @event appendEvent + */ + this.appendEvent = this.createEvent(EVENT_TYPES.APPEND); + this.appendEvent.signature = SIGNATURE; + + /** + * CustomEvent fired before the Module is rendered + * @event beforeRenderEvent + */ + this.beforeRenderEvent = this.createEvent(EVENT_TYPES.BEFORE_RENDER); + this.beforeRenderEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after the Module is rendered + * @event renderEvent + */ + this.renderEvent = this.createEvent(EVENT_TYPES.RENDER); + this.renderEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the header content of the Module + * is modified + * @event changeHeaderEvent + * @param {String/HTMLElement} content String/element representing + * the new header content + */ + this.changeHeaderEvent = this.createEvent(EVENT_TYPES.CHANGE_HEADER); + this.changeHeaderEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the body content of the Module is modified + * @event changeBodyEvent + * @param {String/HTMLElement} content String/element representing + * the new body content + */ + this.changeBodyEvent = this.createEvent(EVENT_TYPES.CHANGE_BODY); + this.changeBodyEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the footer content of the Module + * is modified + * @event changeFooterEvent + * @param {String/HTMLElement} content String/element representing + * the new footer content + */ + this.changeFooterEvent = this.createEvent(EVENT_TYPES.CHANGE_FOOTER); + this.changeFooterEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the content of the Module is modified + * @event changeContentEvent + */ + this.changeContentEvent = this.createEvent(EVENT_TYPES.CHANGE_CONTENT); + this.changeContentEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the Module is destroyed + * @event destroyEvent + */ + this.destroyEvent = this.createEvent(EVENT_TYPES.DESTORY); + this.destroyEvent.signature = SIGNATURE; + + /** + * CustomEvent fired before the Module is shown + * @event beforeShowEvent + */ + this.beforeShowEvent = this.createEvent(EVENT_TYPES.BEFORE_SHOW); + this.beforeShowEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after the Module is shown + * @event showEvent + */ + this.showEvent = this.createEvent(EVENT_TYPES.SHOW); + this.showEvent.signature = SIGNATURE; + + /** + * CustomEvent fired before the Module is hidden + * @event beforeHideEvent + */ + this.beforeHideEvent = this.createEvent(EVENT_TYPES.BEFORE_HIDE); + this.beforeHideEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after the Module is hidden + * @event hideEvent + */ + this.hideEvent = this.createEvent(EVENT_TYPES.HIDE); + this.hideEvent.signature = SIGNATURE; + }, + + /** + * String representing the current user-agent platform + * @property platform + * @type String + */ + platform: function () { + var ua = navigator.userAgent.toLowerCase(); + + if (ua.indexOf("windows") != -1 || ua.indexOf("win32") != -1) { + return "windows"; + } else if (ua.indexOf("macintosh") != -1) { + return "mac"; + } else { + return false; + } + }(), + + /** + * String representing the user-agent of the browser + * @deprecated Use YAHOO.env.ua + * @property browser + * @type String + */ + browser: function () { + var ua = navigator.userAgent.toLowerCase(); + /* + Check Opera first in case of spoof and check Safari before + Gecko since Safari's user agent string includes "like Gecko" + */ + if (ua.indexOf('opera') != -1) { + return 'opera'; + } else if (ua.indexOf('msie 7') != -1) { + return 'ie7'; + } else if (ua.indexOf('msie') != -1) { + return 'ie'; + } else if (ua.indexOf('safari') != -1) { + return 'safari'; + } else if (ua.indexOf('gecko') != -1) { + return 'gecko'; + } else { + return false; + } + }(), + + /** + * Boolean representing whether or not the current browsing context is + * secure (https) + * @property isSecure + * @type Boolean + */ + isSecure: function () { + if (window.location.href.toLowerCase().indexOf("https") === 0) { + return true; + } else { + return false; + } + }(), + + /** + * Initializes the custom events for Module which are fired + * automatically at appropriate times by the Module class. + */ + initDefaultConfig: function () { + // Add properties // + /** + * Specifies whether the Module is visible on the page. + * @config visible + * @type Boolean + * @default true + */ + this.cfg.addProperty(DEFAULT_CONFIG.VISIBLE.key, { + handler: this.configVisible, + value: DEFAULT_CONFIG.VISIBLE.value, + validator: DEFAULT_CONFIG.VISIBLE.validator + }); + + /** + * Object or array of objects representing the ContainerEffect + * classes that are active for animating the container. + * @config effect + * @type Object + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.EFFECT.key, { + suppressEvent: DEFAULT_CONFIG.EFFECT.suppressEvent, + supercedes: DEFAULT_CONFIG.EFFECT.supercedes + }); + + /** + * Specifies whether to create a special proxy iframe to monitor + * for user font resizing in the document + * @config monitorresize + * @type Boolean + * @default true + */ + this.cfg.addProperty(DEFAULT_CONFIG.MONITOR_RESIZE.key, { + handler: this.configMonitorResize, + value: DEFAULT_CONFIG.MONITOR_RESIZE.value + }); + + /** + * Specifies if the module should be rendered as the first child + * of document.body or appended as the last child when render is called + * with document.body as the "appendToNode". + * <p> + * Appending to the body while the DOM is still being constructed can + * lead to Operation Aborted errors in IE hence this flag is set to + * false by default. + * </p> + * + * @config appendtodocumentbody + * @type Boolean + * @default false + */ + this.cfg.addProperty(DEFAULT_CONFIG.APPEND_TO_DOCUMENT_BODY.key, { + value: DEFAULT_CONFIG.APPEND_TO_DOCUMENT_BODY.value + }); + }, + + /** + * The Module class's initialization method, which is executed for + * Module and all of its subclasses. This method is automatically + * called by the constructor, and sets up all DOM references for + * pre-existing markup, and creates required markup if it is not + * already present. + * @method init + * @param {String} el The element ID representing the Module <em>OR</em> + * @param {HTMLElement} el The element representing the Module + * @param {Object} userConfig The configuration Object literal + * containing the configuration that should be set for this module. + * See configuration documentation for more details. + */ + init: function (el, userConfig) { + + var elId, child; + + this.initEvents(); + this.beforeInitEvent.fire(Module); + + /** + * The Module's Config object used for monitoring + * configuration properties. + * @property cfg + * @type YAHOO.util.Config + */ + this.cfg = new Config(this); + + if (this.isSecure) { + this.imageRoot = Module.IMG_ROOT_SSL; + } + + if (typeof el == "string") { + elId = el; + el = document.getElementById(el); + if (! el) { + el = (createModuleTemplate()).cloneNode(false); + el.id = elId; + } + } + + this.element = el; + + if (el.id) { + this.id = el.id; + } + + child = this.element.firstChild; + + if (child) { + var fndHd = false, fndBd = false, fndFt = false; + do { + // We're looking for elements + if (1 == child.nodeType) { + if (!fndHd && Dom.hasClass(child, Module.CSS_HEADER)) { + this.header = child; + fndHd = true; + } else if (!fndBd && Dom.hasClass(child, Module.CSS_BODY)) { + this.body = child; + fndBd = true; + } else if (!fndFt && Dom.hasClass(child, Module.CSS_FOOTER)){ + this.footer = child; + fndFt = true; + } + } + } while ((child = child.nextSibling)); + } + + this.initDefaultConfig(); + + Dom.addClass(this.element, Module.CSS_MODULE); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + + /* + Subscribe to the fireQueue() method of Config so that any + queued configuration changes are excecuted upon render of + the Module + */ + + if (!Config.alreadySubscribed(this.renderEvent, this.cfg.fireQueue, this.cfg)) { + this.renderEvent.subscribe(this.cfg.fireQueue, this.cfg, true); + } + + this.initEvent.fire(Module); + }, + + /** + * Initialize an empty IFRAME that is placed out of the visible area + * that can be used to detect text resize. + * @method initResizeMonitor + */ + initResizeMonitor: function () { + + var isGeckoWin = (YAHOO.env.ua.gecko && this.platform == "windows"); + if (isGeckoWin) { + // Help prevent spinning loading icon which + // started with FireFox 2.0.0.8/Win + var self = this; + setTimeout(function(){self._initResizeMonitor();}, 0); + } else { + this._initResizeMonitor(); + } + }, + + /** + * Create and initialize the text resize monitoring iframe. + * + * @protected + * @method _initResizeMonitor + */ + _initResizeMonitor : function() { + + var oDoc, + oIFrame, + sHTML; + + function fireTextResize() { + Module.textResizeEvent.fire(); + } + + if (!YAHOO.env.ua.opera) { + oIFrame = Dom.get("_yuiResizeMonitor"); + + var supportsCWResize = this._supportsCWResize(); + + if (!oIFrame) { + oIFrame = document.createElement("iframe"); + + if (this.isSecure && Module.RESIZE_MONITOR_SECURE_URL && YAHOO.env.ua.ie) { + oIFrame.src = Module.RESIZE_MONITOR_SECURE_URL; + } + + if (!supportsCWResize) { + // Can't monitor on contentWindow, so fire from inside iframe + sHTML = ["<html><head><script ", + "type=\"text/javascript\">", + "window.onresize=function(){window.parent.", + "YAHOO.widget.Module.textResizeEvent.", + "fire();};<", + "\/script></head>", + "<body></body></html>"].join(''); + + oIFrame.src = "data:text/html;charset=utf-8," + encodeURIComponent(sHTML); + } + + oIFrame.id = "_yuiResizeMonitor"; + /* + Need to set "position" property before inserting the + iframe into the document or Safari's status bar will + forever indicate the iframe is loading + (See SourceForge bug #1723064) + */ + oIFrame.style.position = "absolute"; + oIFrame.style.visibility = "hidden"; + + var db = document.body, + fc = db.firstChild; + if (fc) { + db.insertBefore(oIFrame, fc); + } else { + db.appendChild(oIFrame); + } + + oIFrame.style.width = "10em"; + oIFrame.style.height = "10em"; + oIFrame.style.top = (-1 * oIFrame.offsetHeight) + "px"; + oIFrame.style.left = (-1 * oIFrame.offsetWidth) + "px"; + oIFrame.style.borderWidth = "0"; + oIFrame.style.visibility = "visible"; + + /* + Don't open/close the document for Gecko like we used to, since it + leads to duplicate cookies. (See SourceForge bug #1721755) + */ + if (YAHOO.env.ua.webkit) { + oDoc = oIFrame.contentWindow.document; + oDoc.open(); + oDoc.close(); + } + } + + if (oIFrame && oIFrame.contentWindow) { + Module.textResizeEvent.subscribe(this.onDomResize, this, true); + + if (!Module.textResizeInitialized) { + if (supportsCWResize) { + if (!Event.on(oIFrame.contentWindow, "resize", fireTextResize)) { + /* + This will fail in IE if document.domain has + changed, so we must change the listener to + use the oIFrame element instead + */ + Event.on(oIFrame, "resize", fireTextResize); + } + } + Module.textResizeInitialized = true; + } + this.resizeMonitor = oIFrame; + } + } + }, + + /** + * Text resize monitor helper method. + * Determines if the browser supports resize events on iframe content windows. + * + * @private + * @method _supportsCWResize + */ + _supportsCWResize : function() { + /* + Gecko 1.8.0 (FF1.5), 1.8.1.0-5 (FF2) won't fire resize on contentWindow. + Gecko 1.8.1.6+ (FF2.0.0.6+) and all other browsers will fire resize on contentWindow. + + We don't want to start sniffing for patch versions, so fire textResize the same + way on all FF, until 1.9 (3.x) is out + */ + var bSupported = true; + if (YAHOO.env.ua.gecko && YAHOO.env.ua.gecko <= 1.8) { + bSupported = false; + /* + var v = navigator.userAgent.match(/rv:([^\s\)]*)/); // From YAHOO.env.ua + if (v && v[0]) { + var sv = v[0].match(/\d\.\d\.(\d)/); + if (sv && sv[1]) { + if (parseInt(sv[1], 10) > 0) { + bSupported = true; + } + } + } + */ + } + return bSupported; + }, + + /** + * Event handler fired when the resize monitor element is resized. + * @method onDomResize + * @param {DOMEvent} e The DOM resize event + * @param {Object} obj The scope object passed to the handler + */ + onDomResize: function (e, obj) { + + var nLeft = -1 * this.resizeMonitor.offsetWidth, + nTop = -1 * this.resizeMonitor.offsetHeight; + + this.resizeMonitor.style.top = nTop + "px"; + this.resizeMonitor.style.left = nLeft + "px"; + + }, + + /** + * Sets the Module's header content to the string specified, or appends + * the passed element to the header. If no header is present, one will + * be automatically created. An empty string can be passed to the method + * to clear the contents of the header. + * + * @method setHeader + * @param {String} headerContent The string used to set the header. + * As a convenience, non HTMLElement objects can also be passed into + * the method, and will be treated as strings, with the header innerHTML + * set to their default toString implementations. + * <em>OR</em> + * @param {HTMLElement} headerContent The HTMLElement to append to + * <em>OR</em> + * @param {DocumentFragment} headerContent The document fragment + * containing elements which are to be added to the header + */ + setHeader: function (headerContent) { + var oHeader = this.header || (this.header = createHeader()); + + if (headerContent.nodeName) { + oHeader.innerHTML = ""; + oHeader.appendChild(headerContent); + } else { + oHeader.innerHTML = headerContent; + } + + this.changeHeaderEvent.fire(headerContent); + this.changeContentEvent.fire(); + + }, + + /** + * Appends the passed element to the header. If no header is present, + * one will be automatically created. + * @method appendToHeader + * @param {HTMLElement | DocumentFragment} element The element to + * append to the header. In the case of a document fragment, the + * children of the fragment will be appended to the header. + */ + appendToHeader: function (element) { + var oHeader = this.header || (this.header = createHeader()); + + oHeader.appendChild(element); + + this.changeHeaderEvent.fire(element); + this.changeContentEvent.fire(); + + }, + + /** + * Sets the Module's body content to the HTML specified, or appends the + * passed element to the body. If no body is present, one will be + * automatically created. An empty string can be passed to the method + * to clear the contents of the body. + * @method setBody + * @param {String} bodyContent The HTML used to set the body. + * As a convenience, non HTMLElement objects can also be passed into + * the method, and will be treated as strings, with the body innerHTML + * set to their default toString implementations. + * <em>OR</em> + * @param {HTMLElement} bodyContent The HTMLElement to append to the body + * <em>OR</em> + * @param {DocumentFragment} bodyContent The document fragment + * containing elements which are to be added to the body + */ + setBody: function (bodyContent) { + var oBody = this.body || (this.body = createBody()); + + if (bodyContent.nodeName) { + oBody.innerHTML = ""; + oBody.appendChild(bodyContent); + } else { + oBody.innerHTML = bodyContent; + } + + this.changeBodyEvent.fire(bodyContent); + this.changeContentEvent.fire(); + }, + + /** + * Appends the passed element to the body. If no body is present, one + * will be automatically created. + * @method appendToBody + * @param {HTMLElement | DocumentFragment} element The element to + * append to the body. In the case of a document fragment, the + * children of the fragment will be appended to the body. + * + */ + appendToBody: function (element) { + var oBody = this.body || (this.body = createBody()); + + oBody.appendChild(element); + + this.changeBodyEvent.fire(element); + this.changeContentEvent.fire(); + + }, + + /** + * Sets the Module's footer content to the HTML specified, or appends + * the passed element to the footer. If no footer is present, one will + * be automatically created. An empty string can be passed to the method + * to clear the contents of the footer. + * @method setFooter + * @param {String} footerContent The HTML used to set the footer + * As a convenience, non HTMLElement objects can also be passed into + * the method, and will be treated as strings, with the footer innerHTML + * set to their default toString implementations. + * <em>OR</em> + * @param {HTMLElement} footerContent The HTMLElement to append to + * the footer + * <em>OR</em> + * @param {DocumentFragment} footerContent The document fragment containing + * elements which are to be added to the footer + */ + setFooter: function (footerContent) { + + var oFooter = this.footer || (this.footer = createFooter()); + + if (footerContent.nodeName) { + oFooter.innerHTML = ""; + oFooter.appendChild(footerContent); + } else { + oFooter.innerHTML = footerContent; + } + + this.changeFooterEvent.fire(footerContent); + this.changeContentEvent.fire(); + }, + + /** + * Appends the passed element to the footer. If no footer is present, + * one will be automatically created. + * @method appendToFooter + * @param {HTMLElement | DocumentFragment} element The element to + * append to the footer. In the case of a document fragment, the + * children of the fragment will be appended to the footer + */ + appendToFooter: function (element) { + + var oFooter = this.footer || (this.footer = createFooter()); + + oFooter.appendChild(element); + + this.changeFooterEvent.fire(element); + this.changeContentEvent.fire(); + + }, + + /** + * Renders the Module by inserting the elements that are not already + * in the main Module into their correct places. Optionally appends + * the Module to the specified node prior to the render's execution. + * <p> + * For Modules without existing markup, the appendToNode argument + * is REQUIRED. If this argument is ommitted and the current element is + * not present in the document, the function will return false, + * indicating that the render was a failure. + * </p> + * <p> + * NOTE: As of 2.3.1, if the appendToNode is the document's body element + * then the module is rendered as the first child of the body element, + * and not appended to it, to avoid Operation Aborted errors in IE when + * rendering the module before window's load event is fired. You can + * use the appendtodocumentbody configuration property to change this + * to append to document.body if required. + * </p> + * @method render + * @param {String} appendToNode The element id to which the Module + * should be appended to prior to rendering <em>OR</em> + * @param {HTMLElement} appendToNode The element to which the Module + * should be appended to prior to rendering + * @param {HTMLElement} moduleElement OPTIONAL. The element that + * represents the actual Standard Module container. + * @return {Boolean} Success or failure of the render + */ + render: function (appendToNode, moduleElement) { + + var me = this, + firstChild; + + function appendTo(parentNode) { + if (typeof parentNode == "string") { + parentNode = document.getElementById(parentNode); + } + + if (parentNode) { + me._addToParent(parentNode, me.element); + me.appendEvent.fire(); + } + } + + this.beforeRenderEvent.fire(); + + if (! moduleElement) { + moduleElement = this.element; + } + + if (appendToNode) { + appendTo(appendToNode); + } else { + // No node was passed in. If the element is not already in the Dom, this fails + if (! Dom.inDocument(this.element)) { + return false; + } + } + + // Need to get everything into the DOM if it isn't already + if (this.header && ! Dom.inDocument(this.header)) { + // There is a header, but it's not in the DOM yet. Need to add it. + firstChild = moduleElement.firstChild; + if (firstChild) { + moduleElement.insertBefore(this.header, firstChild); + } else { + moduleElement.appendChild(this.header); + } + } + + if (this.body && ! Dom.inDocument(this.body)) { + // There is a body, but it's not in the DOM yet. Need to add it. + if (this.footer && Dom.isAncestor(this.moduleElement, this.footer)) { + moduleElement.insertBefore(this.body, this.footer); + } else { + moduleElement.appendChild(this.body); + } + } + + if (this.footer && ! Dom.inDocument(this.footer)) { + // There is a footer, but it's not in the DOM yet. Need to add it. + moduleElement.appendChild(this.footer); + } + + this.renderEvent.fire(); + return true; + }, + + /** + * Removes the Module element from the DOM and sets all child elements + * to null. + * @method destroy + */ + destroy: function () { + + var parent, + e; + + if (this.element) { + Event.purgeElement(this.element, true); + parent = this.element.parentNode; + } + + if (parent) { + parent.removeChild(this.element); + } + + this.element = null; + this.header = null; + this.body = null; + this.footer = null; + + Module.textResizeEvent.unsubscribe(this.onDomResize, this); + + this.cfg.destroy(); + this.cfg = null; + + this.destroyEvent.fire(); + + for (e in this) { + if (e instanceof CustomEvent) { + e.unsubscribeAll(); + } + } + + }, + + /** + * Shows the Module element by setting the visible configuration + * property to true. Also fires two events: beforeShowEvent prior to + * the visibility change, and showEvent after. + * @method show + */ + show: function () { + this.cfg.setProperty("visible", true); + }, + + /** + * Hides the Module element by setting the visible configuration + * property to false. Also fires two events: beforeHideEvent prior to + * the visibility change, and hideEvent after. + * @method hide + */ + hide: function () { + this.cfg.setProperty("visible", false); + }, + + // BUILT-IN EVENT HANDLERS FOR MODULE // + /** + * Default event handler for changing the visibility property of a + * Module. By default, this is achieved by switching the "display" style + * between "block" and "none". + * This method is responsible for firing showEvent and hideEvent. + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + * @method configVisible + */ + configVisible: function (type, args, obj) { + var visible = args[0]; + if (visible) { + this.beforeShowEvent.fire(); + Dom.setStyle(this.element, "display", "block"); + this.showEvent.fire(); + } else { + this.beforeHideEvent.fire(); + Dom.setStyle(this.element, "display", "none"); + this.hideEvent.fire(); + } + }, + + /** + * Default event handler for the "monitorresize" configuration property + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + * @method configMonitorResize + */ + configMonitorResize: function (type, args, obj) { + var monitor = args[0]; + if (monitor) { + this.initResizeMonitor(); + } else { + Module.textResizeEvent.unsubscribe(this.onDomResize, this, true); + this.resizeMonitor = null; + } + }, + + /** + * This method is a protected helper, used when constructing the DOM structure for the module + * to account for situations which may cause Operation Aborted errors in IE. It should not + * be used for general DOM construction. + * <p> + * If the parentNode is not document.body, the element is appended as the last element. + * </p> + * <p> + * If the parentNode is document.body the element is added as the first child to help + * prevent Operation Aborted errors in IE. + * </p> + * + * @param {parentNode} The HTML element to which the element will be added + * @param {element} The HTML element to be added to parentNode's children + * @method _addToParent + * @protected + */ + _addToParent: function(parentNode, element) { + if (!this.cfg.getProperty("appendtodocumentbody") && parentNode === document.body && parentNode.firstChild) { + parentNode.insertBefore(element, parentNode.firstChild); + } else { + parentNode.appendChild(element); + } + }, + + /** + * Returns a String representation of the Object. + * @method toString + * @return {String} The string representation of the Module + */ + toString: function () { + return "Module " + this.id; + } + }; + + YAHOO.lang.augmentProto(Module, YAHOO.util.EventProvider); + +}()); + +(function () { + + /** + * Overlay is a Module that is absolutely positioned above the page flow. It + * has convenience methods for positioning and sizing, as well as options for + * controlling zIndex and constraining the Overlay's position to the current + * visible viewport. Overlay also contains a dynamicly generated IFRAME which + * is placed beneath it for Internet Explorer 6 and 5.x so that it will be + * properly rendered above SELECT elements. + * @namespace YAHOO.widget + * @class Overlay + * @extends YAHOO.widget.Module + * @param {String} el The element ID representing the Overlay <em>OR</em> + * @param {HTMLElement} el The element representing the Overlay + * @param {Object} userConfig The configuration object literal containing + * the configuration that should be set for this Overlay. See configuration + * documentation for more details. + * @constructor + */ + YAHOO.widget.Overlay = function (el, userConfig) { + YAHOO.widget.Overlay.superclass.constructor.call(this, el, userConfig); + }; + + var Lang = YAHOO.lang, + CustomEvent = YAHOO.util.CustomEvent, + Module = YAHOO.widget.Module, + Event = YAHOO.util.Event, + Dom = YAHOO.util.Dom, + Config = YAHOO.util.Config, + Overlay = YAHOO.widget.Overlay, + + m_oIFrameTemplate, + + /** + * Constant representing the name of the Overlay's events + * @property EVENT_TYPES + * @private + * @final + * @type Object + */ + EVENT_TYPES = { + "BEFORE_MOVE": "beforeMove", + "MOVE": "move" + }, + + /** + * Constant representing the Overlay's configuration properties + * @property DEFAULT_CONFIG + * @private + * @final + * @type Object + */ + DEFAULT_CONFIG = { + + "X": { + key: "x", + validator: Lang.isNumber, + suppressEvent: true, + supercedes: ["iframe"] + }, + + "Y": { + key: "y", + validator: Lang.isNumber, + suppressEvent: true, + supercedes: ["iframe"] + }, + + "XY": { + key: "xy", + suppressEvent: true, + supercedes: ["iframe"] + }, + + "CONTEXT": { + key: "context", + suppressEvent: true, + supercedes: ["iframe"] + }, + + "FIXED_CENTER": { + key: "fixedcenter", + value: false, + validator: Lang.isBoolean, + supercedes: ["iframe", "visible"] + }, + + "WIDTH": { + key: "width", + suppressEvent: true, + supercedes: ["context", "fixedcenter", "iframe"] + }, + + "HEIGHT": { + key: "height", + suppressEvent: true, + supercedes: ["context", "fixedcenter", "iframe"] + }, + + "ZINDEX": { + key: "zindex", + value: null + }, + + "CONSTRAIN_TO_VIEWPORT": { + key: "constraintoviewport", + value: false, + validator: Lang.isBoolean, + supercedes: ["iframe", "x", "y", "xy"] + }, + + "IFRAME": { + key: "iframe", + value: (YAHOO.env.ua.ie == 6 ? true : false), + validator: Lang.isBoolean, + supercedes: ["zindex"] + } + }; + + /** + * The URL that will be placed in the iframe + * @property YAHOO.widget.Overlay.IFRAME_SRC + * @static + * @final + * @type String + */ + Overlay.IFRAME_SRC = "javascript:false;"; + + /** + * Number representing how much the iframe shim should be offset from each + * side of an Overlay instance, in pixels. + * @property YAHOO.widget.Overlay.IFRAME_SRC + * @default 3 + * @static + * @final + * @type Number + */ + Overlay.IFRAME_OFFSET = 3; + + /** + * Number representing the minimum distance an Overlay instance should be + * positioned relative to the boundaries of the browser's viewport, in pixels. + * @property YAHOO.widget.Overlay.VIEWPORT_OFFSET + * @default 10 + * @static + * @final + * @type Number + */ + Overlay.VIEWPORT_OFFSET = 10; + + /** + * Constant representing the top left corner of an element, used for + * configuring the context element alignment + * @property YAHOO.widget.Overlay.TOP_LEFT + * @static + * @final + * @type String + */ + Overlay.TOP_LEFT = "tl"; + + /** + * Constant representing the top right corner of an element, used for + * configuring the context element alignment + * @property YAHOO.widget.Overlay.TOP_RIGHT + * @static + * @final + * @type String + */ + Overlay.TOP_RIGHT = "tr"; + + /** + * Constant representing the top bottom left corner of an element, used for + * configuring the context element alignment + * @property YAHOO.widget.Overlay.BOTTOM_LEFT + * @static + * @final + * @type String + */ + Overlay.BOTTOM_LEFT = "bl"; + + /** + * Constant representing the bottom right corner of an element, used for + * configuring the context element alignment + * @property YAHOO.widget.Overlay.BOTTOM_RIGHT + * @static + * @final + * @type String + */ + Overlay.BOTTOM_RIGHT = "br"; + + /** + * Constant representing the default CSS class used for an Overlay + * @property YAHOO.widget.Overlay.CSS_OVERLAY + * @static + * @final + * @type String + */ + Overlay.CSS_OVERLAY = "yui-overlay"; + + /** + * A singleton CustomEvent used for reacting to the DOM event for + * window scroll + * @event YAHOO.widget.Overlay.windowScrollEvent + */ + Overlay.windowScrollEvent = new CustomEvent("windowScroll"); + + /** + * A singleton CustomEvent used for reacting to the DOM event for + * window resize + * @event YAHOO.widget.Overlay.windowResizeEvent + */ + Overlay.windowResizeEvent = new CustomEvent("windowResize"); + + /** + * The DOM event handler used to fire the CustomEvent for window scroll + * @method YAHOO.widget.Overlay.windowScrollHandler + * @static + * @param {DOMEvent} e The DOM scroll event + */ + Overlay.windowScrollHandler = function (e) { + + if (YAHOO.env.ua.ie) { + + if (! window.scrollEnd) { + window.scrollEnd = -1; + } + + clearTimeout(window.scrollEnd); + + window.scrollEnd = setTimeout(function () { + Overlay.windowScrollEvent.fire(); + }, 1); + + } else { + Overlay.windowScrollEvent.fire(); + } + }; + + /** + * The DOM event handler used to fire the CustomEvent for window resize + * @method YAHOO.widget.Overlay.windowResizeHandler + * @static + * @param {DOMEvent} e The DOM resize event + */ + Overlay.windowResizeHandler = function (e) { + + if (YAHOO.env.ua.ie) { + if (! window.resizeEnd) { + window.resizeEnd = -1; + } + + clearTimeout(window.resizeEnd); + + window.resizeEnd = setTimeout(function () { + Overlay.windowResizeEvent.fire(); + }, 100); + } else { + Overlay.windowResizeEvent.fire(); + } + }; + + /** + * A boolean that indicated whether the window resize and scroll events have + * already been subscribed to. + * @property YAHOO.widget.Overlay._initialized + * @private + * @type Boolean + */ + Overlay._initialized = null; + + if (Overlay._initialized === null) { + Event.on(window, "scroll", Overlay.windowScrollHandler); + Event.on(window, "resize", Overlay.windowResizeHandler); + + Overlay._initialized = true; + } + + YAHOO.extend(Overlay, Module, { + + /** + * The Overlay initialization method, which is executed for Overlay and + * all of its subclasses. This method is automatically called by the + * constructor, and sets up all DOM references for pre-existing markup, + * and creates required markup if it is not already present. + * @method init + * @param {String} el The element ID representing the Overlay <em>OR</em> + * @param {HTMLElement} el The element representing the Overlay + * @param {Object} userConfig The configuration object literal + * containing the configuration that should be set for this Overlay. + * See configuration documentation for more details. + */ + init: function (el, userConfig) { + + /* + Note that we don't pass the user config in here yet because we + only want it executed once, at the lowest subclass level + */ + + Overlay.superclass.init.call(this, el/*, userConfig*/); + + this.beforeInitEvent.fire(Overlay); + + Dom.addClass(this.element, Overlay.CSS_OVERLAY); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + + if (this.platform == "mac" && YAHOO.env.ua.gecko) { + + if (! Config.alreadySubscribed(this.showEvent, + this.showMacGeckoScrollbars, this)) { + + this.showEvent.subscribe(this.showMacGeckoScrollbars, + this, true); + + } + + if (! Config.alreadySubscribed(this.hideEvent, + this.hideMacGeckoScrollbars, this)) { + + this.hideEvent.subscribe(this.hideMacGeckoScrollbars, + this, true); + + } + } + + this.initEvent.fire(Overlay); + }, + + /** + * Initializes the custom events for Overlay which are fired + * automatically at appropriate times by the Overlay class. + * @method initEvents + */ + initEvents: function () { + + Overlay.superclass.initEvents.call(this); + + var SIGNATURE = CustomEvent.LIST; + + /** + * CustomEvent fired before the Overlay is moved. + * @event beforeMoveEvent + * @param {Number} x x coordinate + * @param {Number} y y coordinate + */ + this.beforeMoveEvent = this.createEvent(EVENT_TYPES.BEFORE_MOVE); + this.beforeMoveEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after the Overlay is moved. + * @event moveEvent + * @param {Number} x x coordinate + * @param {Number} y y coordinate + */ + this.moveEvent = this.createEvent(EVENT_TYPES.MOVE); + this.moveEvent.signature = SIGNATURE; + + }, + + /** + * Initializes the class's configurable properties which can be changed + * using the Overlay's Config object (cfg). + * @method initDefaultConfig + */ + initDefaultConfig: function () { + + Overlay.superclass.initDefaultConfig.call(this); + + + // Add overlay config properties // + + /** + * The absolute x-coordinate position of the Overlay + * @config x + * @type Number + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.X.key, { + + handler: this.configX, + validator: DEFAULT_CONFIG.X.validator, + suppressEvent: DEFAULT_CONFIG.X.suppressEvent, + supercedes: DEFAULT_CONFIG.X.supercedes + + }); + + /** + * The absolute y-coordinate position of the Overlay + * @config y + * @type Number + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.Y.key, { + + handler: this.configY, + validator: DEFAULT_CONFIG.Y.validator, + suppressEvent: DEFAULT_CONFIG.Y.suppressEvent, + supercedes: DEFAULT_CONFIG.Y.supercedes + + }); + + /** + * An array with the absolute x and y positions of the Overlay + * @config xy + * @type Number[] + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.XY.key, { + + handler: this.configXY, + suppressEvent: DEFAULT_CONFIG.XY.suppressEvent, + supercedes: DEFAULT_CONFIG.XY.supercedes + + }); + + /** + * The array of context arguments for context-sensitive positioning. + * The format is: [id or element, element corner, context corner]. + * For example, setting this property to ["img1", "tl", "bl"] would + * align the Overlay's top left corner to the context element's + * bottom left corner. + * @config context + * @type Array + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.CONTEXT.key, { + + handler: this.configContext, + suppressEvent: DEFAULT_CONFIG.CONTEXT.suppressEvent, + supercedes: DEFAULT_CONFIG.CONTEXT.supercedes + + }); + + /** + * True if the Overlay should be anchored to the center of + * the viewport. + * @config fixedcenter + * @type Boolean + * @default false + */ + this.cfg.addProperty(DEFAULT_CONFIG.FIXED_CENTER.key, { + + handler: this.configFixedCenter, + value: DEFAULT_CONFIG.FIXED_CENTER.value, + validator: DEFAULT_CONFIG.FIXED_CENTER.validator, + supercedes: DEFAULT_CONFIG.FIXED_CENTER.supercedes + + }); + + /** + * CSS width of the Overlay. + * @config width + * @type String + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.WIDTH.key, { + + handler: this.configWidth, + suppressEvent: DEFAULT_CONFIG.WIDTH.suppressEvent, + supercedes: DEFAULT_CONFIG.WIDTH.supercedes + + }); + + /** + * CSS height of the Overlay. + * @config height + * @type String + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.HEIGHT.key, { + + handler: this.configHeight, + suppressEvent: DEFAULT_CONFIG.HEIGHT.suppressEvent, + supercedes: DEFAULT_CONFIG.HEIGHT.supercedes + + }); + + /** + * CSS z-index of the Overlay. + * @config zIndex + * @type Number + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.ZINDEX.key, { + + handler: this.configzIndex, + value: DEFAULT_CONFIG.ZINDEX.value + + }); + + /** + * True if the Overlay should be prevented from being positioned + * out of the viewport. + * @config constraintoviewport + * @type Boolean + * @default false + */ + this.cfg.addProperty(DEFAULT_CONFIG.CONSTRAIN_TO_VIEWPORT.key, { + + handler: this.configConstrainToViewport, + value: DEFAULT_CONFIG.CONSTRAIN_TO_VIEWPORT.value, + validator: DEFAULT_CONFIG.CONSTRAIN_TO_VIEWPORT.validator, + supercedes: DEFAULT_CONFIG.CONSTRAIN_TO_VIEWPORT.supercedes + + }); + + /** + * @config iframe + * @description Boolean indicating whether or not the Overlay should + * have an IFRAME shim; used to prevent SELECT elements from + * poking through an Overlay instance in IE6. When set to "true", + * the iframe shim is created when the Overlay instance is intially + * made visible. + * @type Boolean + * @default true for IE6 and below, false for all other browsers. + */ + this.cfg.addProperty(DEFAULT_CONFIG.IFRAME.key, { + + handler: this.configIframe, + value: DEFAULT_CONFIG.IFRAME.value, + validator: DEFAULT_CONFIG.IFRAME.validator, + supercedes: DEFAULT_CONFIG.IFRAME.supercedes + + }); + }, + + /** + * Moves the Overlay to the specified position. This function is + * identical to calling this.cfg.setProperty("xy", [x,y]); + * @method moveTo + * @param {Number} x The Overlay's new x position + * @param {Number} y The Overlay's new y position + */ + moveTo: function (x, y) { + this.cfg.setProperty("xy", [x, y]); + }, + + /** + * Adds a CSS class ("hide-scrollbars") and removes a CSS class + * ("show-scrollbars") to the Overlay to fix a bug in Gecko on Mac OS X + * (https://bugzilla.mozilla.org/show_bug.cgi?id=187435) + * @method hideMacGeckoScrollbars + */ + hideMacGeckoScrollbars: function () { + + Dom.removeClass(this.element, "show-scrollbars"); + Dom.addClass(this.element, "hide-scrollbars"); + + }, + + /** + * Adds a CSS class ("show-scrollbars") and removes a CSS class + * ("hide-scrollbars") to the Overlay to fix a bug in Gecko on Mac OS X + * (https://bugzilla.mozilla.org/show_bug.cgi?id=187435) + * @method showMacGeckoScrollbars + */ + showMacGeckoScrollbars: function () { + + Dom.removeClass(this.element, "hide-scrollbars"); + Dom.addClass(this.element, "show-scrollbars"); + + }, + + // BEGIN BUILT-IN PROPERTY EVENT HANDLERS // + /** + * The default event handler fired when the "visible" property is + * changed. This method is responsible for firing showEvent + * and hideEvent. + * @method configVisible + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configVisible: function (type, args, obj) { + + var visible = args[0], + currentVis = Dom.getStyle(this.element, "visibility"), + effect = this.cfg.getProperty("effect"), + effectInstances = [], + isMacGecko = (this.platform == "mac" && YAHOO.env.ua.gecko), + alreadySubscribed = Config.alreadySubscribed, + eff, ei, e, i, j, k, h, + nEffects, + nEffectInstances; + + if (currentVis == "inherit") { + e = this.element.parentNode; + + while (e.nodeType != 9 && e.nodeType != 11) { + currentVis = Dom.getStyle(e, "visibility"); + + if (currentVis != "inherit") { + break; + } + + e = e.parentNode; + } + + if (currentVis == "inherit") { + currentVis = "visible"; + } + } + + if (effect) { + if (effect instanceof Array) { + nEffects = effect.length; + + for (i = 0; i < nEffects; i++) { + eff = effect[i]; + effectInstances[effectInstances.length] = + eff.effect(this, eff.duration); + + } + } else { + effectInstances[effectInstances.length] = + effect.effect(this, effect.duration); + } + } + + + if (visible) { // Show + if (isMacGecko) { + this.showMacGeckoScrollbars(); + } + + if (effect) { // Animate in + if (visible) { // Animate in if not showing + if (currentVis != "visible" || currentVis === "") { + this.beforeShowEvent.fire(); + nEffectInstances = effectInstances.length; + + for (j = 0; j < nEffectInstances; j++) { + ei = effectInstances[j]; + if (j === 0 && !alreadySubscribed( + ei.animateInCompleteEvent, + this.showEvent.fire, this.showEvent)) { + + /* + Delegate showEvent until end + of animateInComplete + */ + + ei.animateInCompleteEvent.subscribe( + this.showEvent.fire, this.showEvent, true); + } + ei.animateIn(); + } + } + } + } else { // Show + if (currentVis != "visible" || currentVis === "") { + this.beforeShowEvent.fire(); + + Dom.setStyle(this.element, "visibility", "visible"); + + this.cfg.refireEvent("iframe"); + this.showEvent.fire(); + } + } + } else { // Hide + + if (isMacGecko) { + this.hideMacGeckoScrollbars(); + } + + if (effect) { // Animate out if showing + if (currentVis == "visible") { + this.beforeHideEvent.fire(); + + nEffectInstances = effectInstances.length; + for (k = 0; k < nEffectInstances; k++) { + h = effectInstances[k]; + + if (k === 0 && !alreadySubscribed( + h.animateOutCompleteEvent, this.hideEvent.fire, + this.hideEvent)) { + + /* + Delegate hideEvent until end + of animateOutComplete + */ + + h.animateOutCompleteEvent.subscribe( + this.hideEvent.fire, this.hideEvent, true); + + } + h.animateOut(); + } + + } else if (currentVis === "") { + Dom.setStyle(this.element, "visibility", "hidden"); + } + + } else { // Simple hide + + if (currentVis == "visible" || currentVis === "") { + this.beforeHideEvent.fire(); + Dom.setStyle(this.element, "visibility", "hidden"); + this.hideEvent.fire(); + } + } + } + }, + + /** + * Center event handler used for centering on scroll/resize, but only if + * the Overlay is visible + * @method doCenterOnDOMEvent + */ + doCenterOnDOMEvent: function () { + if (this.cfg.getProperty("visible")) { + this.center(); + } + }, + + /** + * The default event handler fired when the "fixedcenter" property + * is changed. + * @method configFixedCenter + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configFixedCenter: function (type, args, obj) { + + var val = args[0], + alreadySubscribed = Config.alreadySubscribed, + windowResizeEvent = Overlay.windowResizeEvent, + windowScrollEvent = Overlay.windowScrollEvent; + + if (val) { + this.center(); + + if (!alreadySubscribed(this.beforeShowEvent, this.center, this)) { + this.beforeShowEvent.subscribe(this.center); + } + + if (!alreadySubscribed(windowResizeEvent, this.doCenterOnDOMEvent, this)) { + windowResizeEvent.subscribe(this.doCenterOnDOMEvent, this, true); + } + + if (!alreadySubscribed(windowScrollEvent, this.doCenterOnDOMEvent, this)) { + windowScrollEvent.subscribe(this.doCenterOnDOMEvent, this, true); + } + + } else { + this.beforeShowEvent.unsubscribe(this.center); + + windowResizeEvent.unsubscribe(this.doCenterOnDOMEvent, this); + windowScrollEvent.unsubscribe(this.doCenterOnDOMEvent, this); + } + }, + + /** + * The default event handler fired when the "height" property is changed. + * @method configHeight + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configHeight: function (type, args, obj) { + + var height = args[0], + el = this.element; + + Dom.setStyle(el, "height", height); + this.cfg.refireEvent("iframe"); + }, + + /** + * The default event handler fired when the "width" property is changed. + * @method configWidth + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configWidth: function (type, args, obj) { + + var width = args[0], + el = this.element; + + Dom.setStyle(el, "width", width); + this.cfg.refireEvent("iframe"); + }, + + /** + * The default event handler fired when the "zIndex" property is changed. + * @method configzIndex + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configzIndex: function (type, args, obj) { + + var zIndex = args[0], + el = this.element; + + if (! zIndex) { + zIndex = Dom.getStyle(el, "zIndex"); + if (! zIndex || isNaN(zIndex)) { + zIndex = 0; + } + } + + if (this.iframe || this.cfg.getProperty("iframe") === true) { + if (zIndex <= 0) { + zIndex = 1; + } + } + + Dom.setStyle(el, "zIndex", zIndex); + this.cfg.setProperty("zIndex", zIndex, true); + + if (this.iframe) { + this.stackIframe(); + } + }, + + /** + * The default event handler fired when the "xy" property is changed. + * @method configXY + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configXY: function (type, args, obj) { + + var pos = args[0], + x = pos[0], + y = pos[1]; + + this.cfg.setProperty("x", x); + this.cfg.setProperty("y", y); + + this.beforeMoveEvent.fire([x, y]); + + x = this.cfg.getProperty("x"); + y = this.cfg.getProperty("y"); + + + this.cfg.refireEvent("iframe"); + this.moveEvent.fire([x, y]); + }, + + /** + * The default event handler fired when the "x" property is changed. + * @method configX + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configX: function (type, args, obj) { + + var x = args[0], + y = this.cfg.getProperty("y"); + + this.cfg.setProperty("x", x, true); + this.cfg.setProperty("y", y, true); + + this.beforeMoveEvent.fire([x, y]); + + x = this.cfg.getProperty("x"); + y = this.cfg.getProperty("y"); + + Dom.setX(this.element, x, true); + + this.cfg.setProperty("xy", [x, y], true); + + this.cfg.refireEvent("iframe"); + this.moveEvent.fire([x, y]); + }, + + /** + * The default event handler fired when the "y" property is changed. + * @method configY + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configY: function (type, args, obj) { + + var x = this.cfg.getProperty("x"), + y = args[0]; + + this.cfg.setProperty("x", x, true); + this.cfg.setProperty("y", y, true); + + this.beforeMoveEvent.fire([x, y]); + + x = this.cfg.getProperty("x"); + y = this.cfg.getProperty("y"); + + Dom.setY(this.element, y, true); + + this.cfg.setProperty("xy", [x, y], true); + + this.cfg.refireEvent("iframe"); + this.moveEvent.fire([x, y]); + }, + + /** + * Shows the iframe shim, if it has been enabled. + * @method showIframe + */ + showIframe: function () { + + var oIFrame = this.iframe, + oParentNode; + + if (oIFrame) { + oParentNode = this.element.parentNode; + + if (oParentNode != oIFrame.parentNode) { + this._addToParent(oParentNode, oIFrame); + } + oIFrame.style.display = "block"; + } + }, + + /** + * Hides the iframe shim, if it has been enabled. + * @method hideIframe + */ + hideIframe: function () { + if (this.iframe) { + this.iframe.style.display = "none"; + } + }, + + /** + * Syncronizes the size and position of iframe shim to that of its + * corresponding Overlay instance. + * @method syncIframe + */ + syncIframe: function () { + + var oIFrame = this.iframe, + oElement = this.element, + nOffset = Overlay.IFRAME_OFFSET, + nDimensionOffset = (nOffset * 2), + aXY; + + if (oIFrame) { + // Size <iframe> + oIFrame.style.width = (oElement.offsetWidth + nDimensionOffset + "px"); + oIFrame.style.height = (oElement.offsetHeight + nDimensionOffset + "px"); + + // Position <iframe> + aXY = this.cfg.getProperty("xy"); + + if (!Lang.isArray(aXY) || (isNaN(aXY[0]) || isNaN(aXY[1]))) { + this.syncPosition(); + aXY = this.cfg.getProperty("xy"); + } + Dom.setXY(oIFrame, [(aXY[0] - nOffset), (aXY[1] - nOffset)]); + } + }, + + /** + * Sets the zindex of the iframe shim, if it exists, based on the zindex of + * the Overlay element. The zindex of the iframe is set to be one less + * than the Overlay element's zindex. + * + * <p>NOTE: This method will not bump up the zindex of the Overlay element + * to ensure that the iframe shim has a non-negative zindex. + * If you require the iframe zindex to be 0 or higher, the zindex of + * the Overlay element should be set to a value greater than 0, before + * this method is called. + * </p> + * @method stackIframe + */ + stackIframe: function () { + if (this.iframe) { + var overlayZ = Dom.getStyle(this.element, "zIndex"); + if (!YAHOO.lang.isUndefined(overlayZ) && !isNaN(overlayZ)) { + Dom.setStyle(this.iframe, "zIndex", (overlayZ - 1)); + } + } + }, + + /** + * The default event handler fired when the "iframe" property is changed. + * @method configIframe + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configIframe: function (type, args, obj) { + + var bIFrame = args[0]; + + function createIFrame() { + + var oIFrame = this.iframe, + oElement = this.element, + oParent; + + if (!oIFrame) { + if (!m_oIFrameTemplate) { + m_oIFrameTemplate = document.createElement("iframe"); + + if (this.isSecure) { + m_oIFrameTemplate.src = Overlay.IFRAME_SRC; + } + + /* + Set the opacity of the <iframe> to 0 so that it + doesn't modify the opacity of any transparent + elements that may be on top of it (like a shadow). + */ + + if (YAHOO.env.ua.ie) { + m_oIFrameTemplate.style.filter = "alpha(opacity=0)"; + /* + Need to set the "frameBorder" property to 0 + supress the default <iframe> border in IE. + Setting the CSS "border" property alone + doesn't supress it. + */ + m_oIFrameTemplate.frameBorder = 0; + } + else { + m_oIFrameTemplate.style.opacity = "0"; + } + + m_oIFrameTemplate.style.position = "absolute"; + m_oIFrameTemplate.style.border = "none"; + m_oIFrameTemplate.style.margin = "0"; + m_oIFrameTemplate.style.padding = "0"; + m_oIFrameTemplate.style.display = "none"; + } + + oIFrame = m_oIFrameTemplate.cloneNode(false); + oParent = oElement.parentNode; + + var parentNode = oParent || document.body; + + this._addToParent(parentNode, oIFrame); + this.iframe = oIFrame; + } + + /* + Show the <iframe> before positioning it since the "setXY" + method of DOM requires the element be in the document + and visible. + */ + this.showIframe(); + + /* + Syncronize the size and position of the <iframe> to that + of the Overlay. + */ + this.syncIframe(); + this.stackIframe(); + + // Add event listeners to update the <iframe> when necessary + if (!this._hasIframeEventListeners) { + this.showEvent.subscribe(this.showIframe); + this.hideEvent.subscribe(this.hideIframe); + this.changeContentEvent.subscribe(this.syncIframe); + + this._hasIframeEventListeners = true; + } + } + + function onBeforeShow() { + createIFrame.call(this); + this.beforeShowEvent.unsubscribe(onBeforeShow); + this._iframeDeferred = false; + } + + if (bIFrame) { // <iframe> shim is enabled + + if (this.cfg.getProperty("visible")) { + createIFrame.call(this); + } else { + if (!this._iframeDeferred) { + this.beforeShowEvent.subscribe(onBeforeShow); + this._iframeDeferred = true; + } + } + + } else { // <iframe> shim is disabled + this.hideIframe(); + + if (this._hasIframeEventListeners) { + this.showEvent.unsubscribe(this.showIframe); + this.hideEvent.unsubscribe(this.hideIframe); + this.changeContentEvent.unsubscribe(this.syncIframe); + + this._hasIframeEventListeners = false; + } + } + }, + + /** + * Set's the container's XY value from DOM if not already set. + * + * Differs from syncPosition, in that the XY value is only sync'd with DOM if + * not already set. The method also refire's the XY config property event, so any + * beforeMove, Move event listeners are invoked. + * + * @method _primeXYFromDOM + * @protected + */ + _primeXYFromDOM : function() { + if (YAHOO.lang.isUndefined(this.cfg.getProperty("xy"))) { + // Set CFG XY based on DOM XY + this.syncPosition(); + // Account for XY being set silently in syncPosition (no moveTo fired/called) + this.cfg.refireEvent("xy"); + this.beforeShowEvent.unsubscribe(this._primeXYFromDOM); + } + }, + + /** + * The default event handler fired when the "constraintoviewport" + * property is changed. + * @method configConstrainToViewport + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for + * the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configConstrainToViewport: function (type, args, obj) { + var val = args[0]; + + if (val) { + if (! Config.alreadySubscribed(this.beforeMoveEvent, this.enforceConstraints, this)) { + this.beforeMoveEvent.subscribe(this.enforceConstraints, this, true); + } + if (! Config.alreadySubscribed(this.beforeShowEvent, this._primeXYFromDOM)) { + this.beforeShowEvent.subscribe(this._primeXYFromDOM); + } + } else { + this.beforeShowEvent.unsubscribe(this._primeXYFromDOM); + this.beforeMoveEvent.unsubscribe(this.enforceConstraints, this); + } + }, + + /** + * The default event handler fired when the "context" property + * is changed. + * @method configContext + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configContext: function (type, args, obj) { + + var contextArgs = args[0], + contextEl, + elementMagnetCorner, + contextMagnetCorner; + + if (contextArgs) { + contextEl = contextArgs[0]; + elementMagnetCorner = contextArgs[1]; + contextMagnetCorner = contextArgs[2]; + + if (contextEl) { + if (typeof contextEl == "string") { + this.cfg.setProperty("context", + [document.getElementById(contextEl), + elementMagnetCorner, contextMagnetCorner], + true); + } + + if (elementMagnetCorner && contextMagnetCorner) { + this.align(elementMagnetCorner, contextMagnetCorner); + } + } + } + }, + + // END BUILT-IN PROPERTY EVENT HANDLERS // + /** + * Aligns the Overlay to its context element using the specified corner + * points (represented by the constants TOP_LEFT, TOP_RIGHT, BOTTOM_LEFT, + * and BOTTOM_RIGHT. + * @method align + * @param {String} elementAlign The String representing the corner of + * the Overlay that should be aligned to the context element + * @param {String} contextAlign The corner of the context element + * that the elementAlign corner should stick to. + */ + align: function (elementAlign, contextAlign) { + + var contextArgs = this.cfg.getProperty("context"), + me = this, + context, + element, + contextRegion; + + function doAlign(v, h) { + + switch (elementAlign) { + + case Overlay.TOP_LEFT: + me.moveTo(h, v); + break; + + case Overlay.TOP_RIGHT: + me.moveTo((h - element.offsetWidth), v); + break; + + case Overlay.BOTTOM_LEFT: + me.moveTo(h, (v - element.offsetHeight)); + break; + + case Overlay.BOTTOM_RIGHT: + me.moveTo((h - element.offsetWidth), + (v - element.offsetHeight)); + break; + } + } + + + if (contextArgs) { + + context = contextArgs[0]; + element = this.element; + me = this; + + if (! elementAlign) { + elementAlign = contextArgs[1]; + } + + if (! contextAlign) { + contextAlign = contextArgs[2]; + } + + if (element && context) { + contextRegion = Dom.getRegion(context); + + switch (contextAlign) { + + case Overlay.TOP_LEFT: + doAlign(contextRegion.top, contextRegion.left); + break; + + case Overlay.TOP_RIGHT: + doAlign(contextRegion.top, contextRegion.right); + break; + + case Overlay.BOTTOM_LEFT: + doAlign(contextRegion.bottom, contextRegion.left); + break; + + case Overlay.BOTTOM_RIGHT: + doAlign(contextRegion.bottom, contextRegion.right); + break; + } + + } + + } + + }, + + /** + * The default event handler executed when the moveEvent is fired, if the + * "constraintoviewport" is set to true. + * @method enforceConstraints + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + enforceConstraints: function (type, args, obj) { + var pos = args[0]; + var cXY = this.getConstrainedXY(pos[0], pos[1]); + this.cfg.setProperty("x", cXY[0], true); + this.cfg.setProperty("y", cXY[1], true); + this.cfg.setProperty("xy", cXY, true); + }, + + /** + * Given x, y coordinate values, returns the calculated coordinates required to + * position the Overlay if it is to be constrained to the viewport, based on the + * current element size, viewport dimensions and scroll values. + * + * @param {Number} x The X coordinate value to be constrained + * @param {Number} y The Y coordinate value to be constrained + * @return {Array} The constrained x and y coordinates at index 0 and 1 respectively; + */ + getConstrainedXY: function(x, y) { + + var nViewportOffset = Overlay.VIEWPORT_OFFSET, + viewPortWidth = Dom.getViewportWidth(), + viewPortHeight = Dom.getViewportHeight(), + offsetHeight = this.element.offsetHeight, + offsetWidth = this.element.offsetWidth, + scrollX = Dom.getDocumentScrollLeft(), + scrollY = Dom.getDocumentScrollTop(); + + var xNew = x; + var yNew = y; + + if (offsetWidth + nViewportOffset < viewPortWidth) { + + var leftConstraint = scrollX + nViewportOffset; + var rightConstraint = scrollX + viewPortWidth - offsetWidth - nViewportOffset; + + if (x < leftConstraint) { + xNew = leftConstraint; + } else if (x > rightConstraint) { + xNew = rightConstraint; + } + } else { + xNew = nViewportOffset + scrollX; + } + + if (offsetHeight + nViewportOffset < viewPortHeight) { + + var topConstraint = scrollY + nViewportOffset; + var bottomConstraint = scrollY + viewPortHeight - offsetHeight - nViewportOffset; + + if (y < topConstraint) { + yNew = topConstraint; + } else if (y > bottomConstraint) { + yNew = bottomConstraint; + } + } else { + yNew = nViewportOffset + scrollY; + } + + return [xNew, yNew]; + }, + + /** + * Centers the container in the viewport. + * @method center + */ + center: function () { + + var nViewportOffset = Overlay.VIEWPORT_OFFSET, + elementWidth = this.element.offsetWidth, + elementHeight = this.element.offsetHeight, + viewPortWidth = Dom.getViewportWidth(), + viewPortHeight = Dom.getViewportHeight(), + x, + y; + + if (elementWidth < viewPortWidth) { + x = (viewPortWidth / 2) - (elementWidth / 2) + Dom.getDocumentScrollLeft(); + } else { + x = nViewportOffset + Dom.getDocumentScrollLeft(); + } + + if (elementHeight < viewPortHeight) { + y = (viewPortHeight / 2) - (elementHeight / 2) + Dom.getDocumentScrollTop(); + } else { + y = nViewportOffset + Dom.getDocumentScrollTop(); + } + + this.cfg.setProperty("xy", [parseInt(x, 10), parseInt(y, 10)]); + this.cfg.refireEvent("iframe"); + }, + + /** + * Synchronizes the Panel's "xy", "x", and "y" properties with the + * Panel's position in the DOM. This is primarily used to update + * position information during drag & drop. + * @method syncPosition + */ + syncPosition: function () { + + var pos = Dom.getXY(this.element); + + this.cfg.setProperty("x", pos[0], true); + this.cfg.setProperty("y", pos[1], true); + this.cfg.setProperty("xy", pos, true); + + }, + + /** + * Event handler fired when the resize monitor element is resized. + * @method onDomResize + * @param {DOMEvent} e The resize DOM event + * @param {Object} obj The scope object + */ + onDomResize: function (e, obj) { + + var me = this; + + Overlay.superclass.onDomResize.call(this, e, obj); + + setTimeout(function () { + me.syncPosition(); + me.cfg.refireEvent("iframe"); + me.cfg.refireEvent("context"); + }, 0); + + }, + + /** + * Places the Overlay on top of all other instances of + * YAHOO.widget.Overlay. + * @method bringToTop + */ + bringToTop: function () { + + var aOverlays = [], + oElement = this.element; + + function compareZIndexDesc(p_oOverlay1, p_oOverlay2) { + + var sZIndex1 = Dom.getStyle(p_oOverlay1, "zIndex"), + sZIndex2 = Dom.getStyle(p_oOverlay2, "zIndex"), + + nZIndex1 = (!sZIndex1 || isNaN(sZIndex1)) ? 0 : parseInt(sZIndex1, 10), + nZIndex2 = (!sZIndex2 || isNaN(sZIndex2)) ? 0 : parseInt(sZIndex2, 10); + + if (nZIndex1 > nZIndex2) { + return -1; + } else if (nZIndex1 < nZIndex2) { + return 1; + } else { + return 0; + } + } + + function isOverlayElement(p_oElement) { + + var oOverlay = Dom.hasClass(p_oElement, Overlay.CSS_OVERLAY), + Panel = YAHOO.widget.Panel; + + if (oOverlay && !Dom.isAncestor(oElement, oOverlay)) { + if (Panel && Dom.hasClass(p_oElement, Panel.CSS_PANEL)) { + aOverlays[aOverlays.length] = p_oElement.parentNode; + } else { + aOverlays[aOverlays.length] = p_oElement; + } + } + } + + Dom.getElementsBy(isOverlayElement, "DIV", document.body); + + aOverlays.sort(compareZIndexDesc); + + var oTopOverlay = aOverlays[0], + nTopZIndex; + + if (oTopOverlay) { + nTopZIndex = Dom.getStyle(oTopOverlay, "zIndex"); + + if (!isNaN(nTopZIndex)) { + var bRequiresBump = false; + + if (oTopOverlay != oElement) { + bRequiresBump = true; + } else if (aOverlays.length > 1) { + var nNextZIndex = Dom.getStyle(aOverlays[1], "zIndex"); + // Don't rely on DOM order to stack if 2 overlays are at the same zindex. + if (!isNaN(nNextZIndex) && (nTopZIndex == nNextZIndex)) { + bRequiresBump = true; + } + } + if (bRequiresBump) { + this.cfg.setProperty("zindex", (parseInt(nTopZIndex, 10) + 2)); + } + } + } + }, + + /** + * Removes the Overlay element from the DOM and sets all child + * elements to null. + * @method destroy + */ + destroy: function () { + + if (this.iframe) { + this.iframe.parentNode.removeChild(this.iframe); + } + + this.iframe = null; + + Overlay.windowResizeEvent.unsubscribe( + this.doCenterOnDOMEvent, this); + + Overlay.windowScrollEvent.unsubscribe( + this.doCenterOnDOMEvent, this); + + Overlay.superclass.destroy.call(this); + }, + + /** + * Returns a String representation of the object. + * @method toString + * @return {String} The string representation of the Overlay. + */ + toString: function () { + return "Overlay " + this.id; + } + + }); +}()); + +(function () { + + /** + * OverlayManager is used for maintaining the focus status of + * multiple Overlays. + * @namespace YAHOO.widget + * @namespace YAHOO.widget + * @class OverlayManager + * @constructor + * @param {Array} overlays Optional. A collection of Overlays to register + * with the manager. + * @param {Object} userConfig The object literal representing the user + * configuration of the OverlayManager + */ + YAHOO.widget.OverlayManager = function (userConfig) { + this.init(userConfig); + }; + + var Overlay = YAHOO.widget.Overlay, + Event = YAHOO.util.Event, + Dom = YAHOO.util.Dom, + Config = YAHOO.util.Config, + CustomEvent = YAHOO.util.CustomEvent, + OverlayManager = YAHOO.widget.OverlayManager; + + /** + * The CSS class representing a focused Overlay + * @property OverlayManager.CSS_FOCUSED + * @static + * @final + * @type String + */ + OverlayManager.CSS_FOCUSED = "focused"; + + OverlayManager.prototype = { + + /** + * The class's constructor function + * @property contructor + * @type Function + */ + constructor: OverlayManager, + + /** + * The array of Overlays that are currently registered + * @property overlays + * @type YAHOO.widget.Overlay[] + */ + overlays: null, + + /** + * Initializes the default configuration of the OverlayManager + * @method initDefaultConfig + */ + initDefaultConfig: function () { + + /** + * The collection of registered Overlays in use by + * the OverlayManager + * @config overlays + * @type YAHOO.widget.Overlay[] + * @default null + */ + this.cfg.addProperty("overlays", { suppressEvent: true } ); + + /** + * The default DOM event that should be used to focus an Overlay + * @config focusevent + * @type String + * @default "mousedown" + */ + this.cfg.addProperty("focusevent", { value: "mousedown" } ); + + }, + + /** + * Initializes the OverlayManager + * @method init + * @param {Overlay[]} overlays Optional. A collection of Overlays to + * register with the manager. + * @param {Object} userConfig The object literal representing the user + * configuration of the OverlayManager + */ + init: function (userConfig) { + + /** + * The OverlayManager's Config object used for monitoring + * configuration properties. + * @property cfg + * @type Config + */ + this.cfg = new Config(this); + + this.initDefaultConfig(); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + this.cfg.fireQueue(); + + /** + * The currently activated Overlay + * @property activeOverlay + * @private + * @type YAHOO.widget.Overlay + */ + var activeOverlay = null; + + /** + * Returns the currently focused Overlay + * @method getActive + * @return {Overlay} The currently focused Overlay + */ + this.getActive = function () { + return activeOverlay; + }; + + /** + * Focuses the specified Overlay + * @method focus + * @param {Overlay} overlay The Overlay to focus + * @param {String} overlay The id of the Overlay to focus + */ + this.focus = function (overlay) { + var o = this.find(overlay); + if (o) { + if (activeOverlay != o) { + if (activeOverlay) { + activeOverlay.blur(); + } + this.bringToTop(o); + + activeOverlay = o; + + Dom.addClass(activeOverlay.element, + OverlayManager.CSS_FOCUSED); + + o.focusEvent.fire(); + } + } + }; + + /** + * Removes the specified Overlay from the manager + * @method remove + * @param {Overlay} overlay The Overlay to remove + * @param {String} overlay The id of the Overlay to remove + */ + this.remove = function (overlay) { + var o = this.find(overlay), + originalZ; + if (o) { + if (activeOverlay == o) { + activeOverlay = null; + } + + var bDestroyed = (o.element === null && o.cfg === null) ? true : false; + + if (!bDestroyed) { + // Set it's zindex so that it's sorted to the end. + originalZ = Dom.getStyle(o.element, "zIndex"); + o.cfg.setProperty("zIndex", -1000, true); + } + + this.overlays.sort(this.compareZIndexDesc); + this.overlays = this.overlays.slice(0, (this.overlays.length - 1)); + + o.hideEvent.unsubscribe(o.blur); + o.destroyEvent.unsubscribe(this._onOverlayDestroy, o); + + if (!bDestroyed) { + Event.removeListener(o.element, + this.cfg.getProperty("focusevent"), + this._onOverlayElementFocus); + + o.cfg.setProperty("zIndex", originalZ, true); + o.cfg.setProperty("manager", null); + } + + o.focusEvent.unsubscribeAll(); + o.blurEvent.unsubscribeAll(); + + o.focusEvent = null; + o.blurEvent = null; + + o.focus = null; + o.blur = null; + } + }; + + /** + * Removes focus from all registered Overlays in the manager + * @method blurAll + */ + this.blurAll = function () { + + var nOverlays = this.overlays.length, + i; + + if (nOverlays > 0) { + i = nOverlays - 1; + + do { + this.overlays[i].blur(); + } + while(i--); + } + }; + + this._onOverlayBlur = function (p_sType, p_aArgs) { + activeOverlay = null; + }; + + var overlays = this.cfg.getProperty("overlays"); + + if (! this.overlays) { + this.overlays = []; + } + + if (overlays) { + this.register(overlays); + this.overlays.sort(this.compareZIndexDesc); + } + }, + + + /** + * @method _onOverlayElementFocus + * @description Event handler for the DOM event that is used to focus + * the Overlay instance as specified by the "focusevent" + * configuration property. + * @private + * @param {Event} p_oEvent Object representing the DOM event + * object passed back by the event utility (Event). + */ + _onOverlayElementFocus: function (p_oEvent) { + + var oTarget = Event.getTarget(p_oEvent), + oClose = this.close; + + if (oClose && (oTarget == oClose || Dom.isAncestor(oClose, oTarget))) { + this.blur(); + } else { + this.focus(); + } + }, + + + /** + * @method _onOverlayDestroy + * @description "destroy" event handler for the Overlay. + * @private + * @param {String} p_sType String representing the name of the event + * that was fired. + * @param {Array} p_aArgs Array of arguments sent when the event + * was fired. + * @param {Overlay} p_oOverlay Object representing the menu that + * fired the event. + */ + _onOverlayDestroy: function (p_sType, p_aArgs, p_oOverlay) { + this.remove(p_oOverlay); + }, + + /** + * Registers an Overlay or an array of Overlays with the manager. Upon + * registration, the Overlay receives functions for focus and blur, + * along with CustomEvents for each. + * @method register + * @param {Overlay} overlay An Overlay to register with the manager. + * @param {Overlay[]} overlay An array of Overlays to register with + * the manager. + * @return {Boolean} True if any Overlays are registered. + */ + register: function (overlay) { + + var mgr = this, + zIndex, + regcount, + i, + nOverlays; + + if (overlay instanceof Overlay) { + + overlay.cfg.addProperty("manager", { value: this } ); + + overlay.focusEvent = overlay.createEvent("focus"); + overlay.focusEvent.signature = CustomEvent.LIST; + + overlay.blurEvent = overlay.createEvent("blur"); + overlay.blurEvent.signature = CustomEvent.LIST; + + overlay.focus = function () { + mgr.focus(this); + }; + + overlay.blur = function () { + if (mgr.getActive() == this) { + Dom.removeClass(this.element, OverlayManager.CSS_FOCUSED); + this.blurEvent.fire(); + } + }; + + overlay.blurEvent.subscribe(mgr._onOverlayBlur); + overlay.hideEvent.subscribe(overlay.blur); + + overlay.destroyEvent.subscribe(this._onOverlayDestroy, overlay, this); + + Event.on(overlay.element, this.cfg.getProperty("focusevent"), + this._onOverlayElementFocus, null, overlay); + + zIndex = Dom.getStyle(overlay.element, "zIndex"); + + if (!isNaN(zIndex)) { + overlay.cfg.setProperty("zIndex", parseInt(zIndex, 10)); + } else { + overlay.cfg.setProperty("zIndex", 0); + } + + this.overlays.push(overlay); + this.bringToTop(overlay); + + return true; + + } else if (overlay instanceof Array) { + + regcount = 0; + nOverlays = overlay.length; + + for (i = 0; i < nOverlays; i++) { + if (this.register(overlay[i])) { + regcount++; + } + } + + if (regcount > 0) { + return true; + } + } else { + return false; + } + }, + + /** + * Places the specified Overlay instance on top of all other + * Overlay instances. + * @method bringToTop + * @param {YAHOO.widget.Overlay} p_oOverlay Object representing an + * Overlay instance. + * @param {String} p_oOverlay String representing the id of an + * Overlay instance. + */ + bringToTop: function (p_oOverlay) { + + var oOverlay = this.find(p_oOverlay), + nTopZIndex, + oTopOverlay, + aOverlays; + + if (oOverlay) { + + aOverlays = this.overlays; + aOverlays.sort(this.compareZIndexDesc); + + oTopOverlay = aOverlays[0]; + + if (oTopOverlay) { + nTopZIndex = Dom.getStyle(oTopOverlay.element, "zIndex"); + + if (!isNaN(nTopZIndex)) { + + var bRequiresBump = false; + + if (oTopOverlay !== oOverlay) { + bRequiresBump = true; + } else if (aOverlays.length > 1) { + var nNextZIndex = Dom.getStyle(aOverlays[1].element, "zIndex"); + // Don't rely on DOM order to stack if 2 overlays are at the same zindex. + if (!isNaN(nNextZIndex) && (nTopZIndex == nNextZIndex)) { + bRequiresBump = true; + } + } + + if (bRequiresBump) { + oOverlay.cfg.setProperty("zindex", (parseInt(nTopZIndex, 10) + 2)); + } + } + aOverlays.sort(this.compareZIndexDesc); + } + } + }, + + /** + * Attempts to locate an Overlay by instance or ID. + * @method find + * @param {Overlay} overlay An Overlay to locate within the manager + * @param {String} overlay An Overlay id to locate within the manager + * @return {Overlay} The requested Overlay, if found, or null if it + * cannot be located. + */ + find: function (overlay) { + + var aOverlays = this.overlays, + nOverlays = aOverlays.length, + i; + + if (nOverlays > 0) { + i = nOverlays - 1; + + if (overlay instanceof Overlay) { + do { + if (aOverlays[i] == overlay) { + return aOverlays[i]; + } + } + while(i--); + + } else if (typeof overlay == "string") { + do { + if (aOverlays[i].id == overlay) { + return aOverlays[i]; + } + } + while(i--); + } + return null; + } + }, + + /** + * Used for sorting the manager's Overlays by z-index. + * @method compareZIndexDesc + * @private + * @return {Number} 0, 1, or -1, depending on where the Overlay should + * fall in the stacking order. + */ + compareZIndexDesc: function (o1, o2) { + + var zIndex1 = (o1.cfg) ? o1.cfg.getProperty("zIndex") : null, // Sort invalid (destroyed) + zIndex2 = (o2.cfg) ? o2.cfg.getProperty("zIndex") : null; // objects at bottom. + + if (zIndex1 === null && zIndex2 === null) { + return 0; + } else if (zIndex1 === null){ + return 1; + } else if (zIndex2 === null) { + return -1; + } else if (zIndex1 > zIndex2) { + return -1; + } else if (zIndex1 < zIndex2) { + return 1; + } else { + return 0; + } + }, + + /** + * Shows all Overlays in the manager. + * @method showAll + */ + showAll: function () { + + var aOverlays = this.overlays, + nOverlays = aOverlays.length, + i; + + if (nOverlays > 0) { + i = nOverlays - 1; + do { + aOverlays[i].show(); + } + while(i--); + } + }, + + /** + * Hides all Overlays in the manager. + * @method hideAll + */ + hideAll: function () { + + var aOverlays = this.overlays, + nOverlays = aOverlays.length, + i; + + if (nOverlays > 0) { + i = nOverlays - 1; + do { + aOverlays[i].hide(); + } + while(i--); + } + }, + + /** + * Returns a string representation of the object. + * @method toString + * @return {String} The string representation of the OverlayManager + */ + toString: function () { + return "OverlayManager"; + } + }; + +}()); + +(function () { + + /** + * Tooltip is an implementation of Overlay that behaves like an OS tooltip, + * displaying when the user mouses over a particular element, and + * disappearing on mouse out. + * @namespace YAHOO.widget + * @class Tooltip + * @extends YAHOO.widget.Overlay + * @constructor + * @param {String} el The element ID representing the Tooltip <em>OR</em> + * @param {HTMLElement} el The element representing the Tooltip + * @param {Object} userConfig The configuration object literal containing + * the configuration that should be set for this Overlay. See configuration + * documentation for more details. + */ + YAHOO.widget.Tooltip = function (el, userConfig) { + YAHOO.widget.Tooltip.superclass.constructor.call(this, el, userConfig); + }; + + var Lang = YAHOO.lang, + Event = YAHOO.util.Event, + CustomEvent = YAHOO.util.CustomEvent, + Dom = YAHOO.util.Dom, + Tooltip = YAHOO.widget.Tooltip, + + m_oShadowTemplate, + + /** + * Constant representing the Tooltip's configuration properties + * @property DEFAULT_CONFIG + * @private + * @final + * @type Object + */ + DEFAULT_CONFIG = { + + "PREVENT_OVERLAP": { + key: "preventoverlap", + value: true, + validator: Lang.isBoolean, + supercedes: ["x", "y", "xy"] + }, + + "SHOW_DELAY": { + key: "showdelay", + value: 200, + validator: Lang.isNumber + }, + + "AUTO_DISMISS_DELAY": { + key: "autodismissdelay", + value: 5000, + validator: Lang.isNumber + }, + + "HIDE_DELAY": { + key: "hidedelay", + value: 250, + validator: Lang.isNumber + }, + + "TEXT": { + key: "text", + suppressEvent: true + }, + + "CONTAINER": { + key: "container" + }, + + "DISABLED": { + key: "disabled", + value: false, + suppressEvent: true + } + }, + + /** + * Constant representing the name of the Tooltip's events + * @property EVENT_TYPES + * @private + * @final + * @type Object + */ + EVENT_TYPES = { + "CONTEXT_MOUSE_OVER": "contextMouseOver", + "CONTEXT_MOUSE_OUT": "contextMouseOut", + "CONTEXT_TRIGGER": "contextTrigger" + }; + + /** + * Constant representing the Tooltip CSS class + * @property YAHOO.widget.Tooltip.CSS_TOOLTIP + * @static + * @final + * @type String + */ + Tooltip.CSS_TOOLTIP = "yui-tt"; + + /* + "hide" event handler that sets a Tooltip instance's "width" + configuration property back to its original value before + "setWidthToOffsetWidth" was called. + */ + function restoreOriginalWidth(p_sType, p_aArgs, p_oObject) { + + var sOriginalWidth = p_oObject[0], + sNewWidth = p_oObject[1], + oConfig = this.cfg, + sCurrentWidth = oConfig.getProperty("width"); + + if (sCurrentWidth == sNewWidth) { + oConfig.setProperty("width", sOriginalWidth); + } + + this.unsubscribe("hide", this._onHide, p_oObject); + } + + /* + "beforeShow" event handler that sets a Tooltip instance's "width" + configuration property to the value of its root HTML + elements's offsetWidth + */ + + function setWidthToOffsetWidth(p_sType, p_aArgs) { + + var oBody = document.body, + oConfig = this.cfg, + sOriginalWidth = oConfig.getProperty("width"), + sNewWidth, + oClone; + + if ((!sOriginalWidth || sOriginalWidth == "auto") && + (oConfig.getProperty("container") != oBody || + oConfig.getProperty("x") >= Dom.getViewportWidth() || + oConfig.getProperty("y") >= Dom.getViewportHeight())) { + + oClone = this.element.cloneNode(true); + oClone.style.visibility = "hidden"; + oClone.style.top = "0px"; + oClone.style.left = "0px"; + + oBody.appendChild(oClone); + + sNewWidth = (oClone.offsetWidth + "px"); + + oBody.removeChild(oClone); + oClone = null; + + oConfig.setProperty("width", sNewWidth); + oConfig.refireEvent("xy"); + + this.subscribe("hide", restoreOriginalWidth, [(sOriginalWidth || ""), sNewWidth]); + } + } + + // "onDOMReady" that renders the ToolTip + + function onDOMReady(p_sType, p_aArgs, p_oObject) { + this.render(p_oObject); + } + + // "init" event handler that automatically renders the Tooltip + + function onInit() { + Event.onDOMReady(onDOMReady, this.cfg.getProperty("container"), this); + } + + YAHOO.extend(Tooltip, YAHOO.widget.Overlay, { + + /** + * The Tooltip initialization method. This method is automatically + * called by the constructor. A Tooltip is automatically rendered by + * the init method, and it also is set to be invisible by default, + * and constrained to viewport by default as well. + * @method init + * @param {String} el The element ID representing the Tooltip <em>OR</em> + * @param {HTMLElement} el The element representing the Tooltip + * @param {Object} userConfig The configuration object literal + * containing the configuration that should be set for this Tooltip. + * See configuration documentation for more details. + */ + init: function (el, userConfig) { + + + Tooltip.superclass.init.call(this, el); + + this.beforeInitEvent.fire(Tooltip); + + Dom.addClass(this.element, Tooltip.CSS_TOOLTIP); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + + this.cfg.queueProperty("visible", false); + this.cfg.queueProperty("constraintoviewport", true); + + this.setBody(""); + + this.subscribe("beforeShow", setWidthToOffsetWidth); + this.subscribe("init", onInit); + this.subscribe("render", this.onRender); + + this.initEvent.fire(Tooltip); + }, + + /** + * Initializes the custom events for Tooltip + * @method initEvents + */ + initEvents: function () { + + Tooltip.superclass.initEvents.call(this); + var SIGNATURE = CustomEvent.LIST; + + /** + * CustomEvent fired when user mouses over a context element. Returning false from + * a subscriber to this event will prevent the tooltip from being displayed for + * the current context element. + * + * @event contextMouseOverEvent + * @param {HTMLElement} context The context element which the user just moused over + * @param {DOMEvent} e The DOM event object, associated with the mouse over + */ + this.contextMouseOverEvent = this.createEvent(EVENT_TYPES.CONTEXT_MOUSE_OVER); + this.contextMouseOverEvent.signature = SIGNATURE; + + /** + * CustomEvent fired when the user mouses out of a context element. + * + * @event contextMouseOutEvent + * @param {HTMLElement} context The context element which the user just moused out of + * @param {DOMEvent} e The DOM event object, associated with the mouse out + */ + this.contextMouseOutEvent = this.createEvent(EVENT_TYPES.CONTEXT_MOUSE_OUT); + this.contextMouseOutEvent.signature = SIGNATURE; + + /** + * CustomEvent fired just before the tooltip is displayed for the current context. + * <p> + * You can subscribe to this event if you need to set up the text for the + * tooltip based on the context element for which it is about to be displayed. + * </p> + * <p>This event differs from the beforeShow event in following respects:</p> + * <ol> + * <li> + * When moving from one context element to another, if the tooltip is not + * hidden (the <code>hidedelay</code> is not reached), the beforeShow and Show events will not + * be fired when the tooltip is displayed for the new context since it is already visible. + * However the contextTrigger event is always fired before displaying the tooltip for + * a new context. + * </li> + * <li> + * The trigger event provides access to the context element, allowing you to + * set the text of the tooltip based on context element for which the tooltip is + * triggered. + * </li> + * </ol> + * <p> + * It is not possible to prevent the tooltip from being displayed + * using this event. You can use the contextMouseOverEvent if you need to prevent + * the tooltip from being displayed. + * </p> + * @event contextTriggerEvent + * @param {HTMLElement} context The context element for which the tooltip is triggered + */ + this.contextTriggerEvent = this.createEvent(EVENT_TYPES.CONTEXT_TRIGGER); + this.contextTriggerEvent.signature = SIGNATURE; + }, + + /** + * Initializes the class's configurable properties which can be + * changed using the Overlay's Config object (cfg). + * @method initDefaultConfig + */ + initDefaultConfig: function () { + + Tooltip.superclass.initDefaultConfig.call(this); + + /** + * Specifies whether the Tooltip should be kept from overlapping + * its context element. + * @config preventoverlap + * @type Boolean + * @default true + */ + this.cfg.addProperty(DEFAULT_CONFIG.PREVENT_OVERLAP.key, { + value: DEFAULT_CONFIG.PREVENT_OVERLAP.value, + validator: DEFAULT_CONFIG.PREVENT_OVERLAP.validator, + supercedes: DEFAULT_CONFIG.PREVENT_OVERLAP.supercedes + }); + + /** + * The number of milliseconds to wait before showing a Tooltip + * on mouseover. + * @config showdelay + * @type Number + * @default 200 + */ + this.cfg.addProperty(DEFAULT_CONFIG.SHOW_DELAY.key, { + handler: this.configShowDelay, + value: 200, + validator: DEFAULT_CONFIG.SHOW_DELAY.validator + }); + + /** + * The number of milliseconds to wait before automatically + * dismissing a Tooltip after the mouse has been resting on the + * context element. + * @config autodismissdelay + * @type Number + * @default 5000 + */ + this.cfg.addProperty(DEFAULT_CONFIG.AUTO_DISMISS_DELAY.key, { + handler: this.configAutoDismissDelay, + value: DEFAULT_CONFIG.AUTO_DISMISS_DELAY.value, + validator: DEFAULT_CONFIG.AUTO_DISMISS_DELAY.validator + }); + + /** + * The number of milliseconds to wait before hiding a Tooltip + * on mouseover. + * @config hidedelay + * @type Number + * @default 250 + */ + this.cfg.addProperty(DEFAULT_CONFIG.HIDE_DELAY.key, { + handler: this.configHideDelay, + value: DEFAULT_CONFIG.HIDE_DELAY.value, + validator: DEFAULT_CONFIG.HIDE_DELAY.validator + }); + + /** + * Specifies the Tooltip's text. + * @config text + * @type String + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.TEXT.key, { + handler: this.configText, + suppressEvent: DEFAULT_CONFIG.TEXT.suppressEvent + }); + + /** + * Specifies the container element that the Tooltip's markup + * should be rendered into. + * @config container + * @type HTMLElement/String + * @default document.body + */ + this.cfg.addProperty(DEFAULT_CONFIG.CONTAINER.key, { + handler: this.configContainer, + value: document.body + }); + + /** + * Specifies whether or not the tooltip is disabled. Disabled tooltips + * will not be displayed. If the tooltip is driven by the title attribute + * of the context element, the title attribute will still be removed for + * disabled tooltips, to prevent default tooltip behavior. + * + * @config disabled + * @type Boolean + * @default false + */ + this.cfg.addProperty(DEFAULT_CONFIG.DISABLED.key, { + handler: this.configContainer, + value: DEFAULT_CONFIG.DISABLED.value, + supressEvent: DEFAULT_CONFIG.DISABLED.suppressEvent + }); + + /** + * Specifies the element or elements that the Tooltip should be + * anchored to on mouseover. + * @config context + * @type HTMLElement[]/String[] + * @default null + */ + + /** + * String representing the width of the Tooltip. <em>Please note: + * </em> As of version 2.3 if either no value or a value of "auto" + * is specified, and the Toolip's "container" configuration property + * is set to something other than <code>document.body</code> or + * its "context" element resides outside the immediately visible + * portion of the document, the width of the Tooltip will be + * calculated based on the offsetWidth of its root HTML and set just + * before it is made visible. The original value will be + * restored when the Tooltip is hidden. This ensures the Tooltip is + * rendered at a usable width. For more information see + * SourceForge bug #1685496 and SourceForge + * bug #1735423. + * @config width + * @type String + * @default null + */ + + }, + + // BEGIN BUILT-IN PROPERTY EVENT HANDLERS // + + /** + * The default event handler fired when the "text" property is changed. + * @method configText + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configText: function (type, args, obj) { + var text = args[0]; + if (text) { + this.setBody(text); + } + }, + + /** + * The default event handler fired when the "container" property + * is changed. + * @method configContainer + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For + * configuration handlers, args[0] will equal the newly applied value + * for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configContainer: function (type, args, obj) { + var container = args[0]; + + if (typeof container == 'string') { + this.cfg.setProperty("container", document.getElementById(container), true); + } + }, + + /** + * @method _removeEventListeners + * @description Removes all of the DOM event handlers from the HTML + * element(s) that trigger the display of the tooltip. + * @protected + */ + _removeEventListeners: function () { + + var aElements = this._context, + nElements, + oElement, + i; + + if (aElements) { + nElements = aElements.length; + if (nElements > 0) { + i = nElements - 1; + do { + oElement = aElements[i]; + Event.removeListener(oElement, "mouseover", this.onContextMouseOver); + Event.removeListener(oElement, "mousemove", this.onContextMouseMove); + Event.removeListener(oElement, "mouseout", this.onContextMouseOut); + } + while (i--); + } + } + }, + + /** + * The default event handler fired when the "context" property + * is changed. + * @method configContext + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configContext: function (type, args, obj) { + + var context = args[0], + aElements, + nElements, + oElement, + i; + + if (context) { + + // Normalize parameter into an array + if (! (context instanceof Array)) { + if (typeof context == "string") { + this.cfg.setProperty("context", [document.getElementById(context)], true); + } else { // Assuming this is an element + this.cfg.setProperty("context", [context], true); + } + context = this.cfg.getProperty("context"); + } + + // Remove any existing mouseover/mouseout listeners + this._removeEventListeners(); + + // Add mouseover/mouseout listeners to context elements + this._context = context; + + aElements = this._context; + + if (aElements) { + nElements = aElements.length; + if (nElements > 0) { + i = nElements - 1; + do { + oElement = aElements[i]; + Event.on(oElement, "mouseover", this.onContextMouseOver, this); + Event.on(oElement, "mousemove", this.onContextMouseMove, this); + Event.on(oElement, "mouseout", this.onContextMouseOut, this); + } + while (i--); + } + } + } + }, + + // END BUILT-IN PROPERTY EVENT HANDLERS // + + // BEGIN BUILT-IN DOM EVENT HANDLERS // + + /** + * The default event handler fired when the user moves the mouse while + * over the context element. + * @method onContextMouseMove + * @param {DOMEvent} e The current DOM event + * @param {Object} obj The object argument + */ + onContextMouseMove: function (e, obj) { + obj.pageX = Event.getPageX(e); + obj.pageY = Event.getPageY(e); + }, + + /** + * The default event handler fired when the user mouses over the + * context element. + * @method onContextMouseOver + * @param {DOMEvent} e The current DOM event + * @param {Object} obj The object argument + */ + onContextMouseOver: function (e, obj) { + var context = this; + + if (context.title) { + obj._tempTitle = context.title; + context.title = ""; + } + + // Fire first, to honor disabled set in the listner + if (obj.fireEvent("contextMouseOver", context, e) !== false + && !obj.cfg.getProperty("disabled")) { + + // Stop the tooltip from being hidden (set on last mouseout) + if (obj.hideProcId) { + clearTimeout(obj.hideProcId); + obj.hideProcId = null; + } + + Event.on(context, "mousemove", obj.onContextMouseMove, obj); + + /** + * The unique process ID associated with the thread responsible + * for showing the Tooltip. + * @type int + */ + obj.showProcId = obj.doShow(e, context); + } + }, + + /** + * The default event handler fired when the user mouses out of + * the context element. + * @method onContextMouseOut + * @param {DOMEvent} e The current DOM event + * @param {Object} obj The object argument + */ + onContextMouseOut: function (e, obj) { + var el = this; + + if (obj._tempTitle) { + el.title = obj._tempTitle; + obj._tempTitle = null; + } + + if (obj.showProcId) { + clearTimeout(obj.showProcId); + obj.showProcId = null; + } + + if (obj.hideProcId) { + clearTimeout(obj.hideProcId); + obj.hideProcId = null; + } + + obj.fireEvent("contextMouseOut", el, e); + + obj.hideProcId = setTimeout(function () { + obj.hide(); + }, obj.cfg.getProperty("hidedelay")); + }, + + // END BUILT-IN DOM EVENT HANDLERS // + + /** + * Processes the showing of the Tooltip by setting the timeout delay + * and offset of the Tooltip. + * @method doShow + * @param {DOMEvent} e The current DOM event + * @return {Number} The process ID of the timeout function associated + * with doShow + */ + doShow: function (e, context) { + + var yOffset = 25, + me = this; + + if (YAHOO.env.ua.opera && context.tagName && + context.tagName.toUpperCase() == "A") { + yOffset += 12; + } + + return setTimeout(function () { + + var txt = me.cfg.getProperty("text"); + + // title does not over-ride text + if (me._tempTitle && (txt === "" || YAHOO.lang.isUndefined(txt) || YAHOO.lang.isNull(txt))) { + me.setBody(me._tempTitle); + } else { + me.cfg.refireEvent("text"); + } + + me.moveTo(me.pageX, me.pageY + yOffset); + + if (me.cfg.getProperty("preventoverlap")) { + me.preventOverlap(me.pageX, me.pageY); + } + + Event.removeListener(context, "mousemove", me.onContextMouseMove); + + me.contextTriggerEvent.fire(context); + + me.show(); + + me.hideProcId = me.doHide(); + + }, this.cfg.getProperty("showdelay")); + }, + + /** + * Sets the timeout for the auto-dismiss delay, which by default is 5 + * seconds, meaning that a tooltip will automatically dismiss itself + * after 5 seconds of being displayed. + * @method doHide + */ + doHide: function () { + + var me = this; + + + return setTimeout(function () { + + me.hide(); + + }, this.cfg.getProperty("autodismissdelay")); + + }, + + /** + * Fired when the Tooltip is moved, this event handler is used to + * prevent the Tooltip from overlapping with its context element. + * @method preventOverlay + * @param {Number} pageX The x coordinate position of the mouse pointer + * @param {Number} pageY The y coordinate position of the mouse pointer + */ + preventOverlap: function (pageX, pageY) { + + var height = this.element.offsetHeight, + mousePoint = new YAHOO.util.Point(pageX, pageY), + elementRegion = Dom.getRegion(this.element); + + elementRegion.top -= 5; + elementRegion.left -= 5; + elementRegion.right += 5; + elementRegion.bottom += 5; + + + if (elementRegion.contains(mousePoint)) { + this.cfg.setProperty("y", (pageY - height - 5)); + } + }, + + + /** + * @method onRender + * @description "render" event handler for the Tooltip. + * @param {String} p_sType String representing the name of the event + * that was fired. + * @param {Array} p_aArgs Array of arguments sent when the event + * was fired. + */ + onRender: function (p_sType, p_aArgs) { + + function sizeShadow() { + + var oElement = this.element, + oShadow = this._shadow; + + if (oShadow) { + oShadow.style.width = (oElement.offsetWidth + 6) + "px"; + oShadow.style.height = (oElement.offsetHeight + 1) + "px"; + } + + } + + function addShadowVisibleClass() { + Dom.addClass(this._shadow, "yui-tt-shadow-visible"); + } + + + function removeShadowVisibleClass() { + Dom.removeClass(this._shadow, "yui-tt-shadow-visible"); + } + + function createShadow() { + + var oShadow = this._shadow, + oElement, + Module, + nIE, + me; + + if (!oShadow) { + + oElement = this.element; + Module = YAHOO.widget.Module; + nIE = YAHOO.env.ua.ie; + me = this; + + if (!m_oShadowTemplate) { + m_oShadowTemplate = document.createElement("div"); + m_oShadowTemplate.className = "yui-tt-shadow"; + } + + oShadow = m_oShadowTemplate.cloneNode(false); + + oElement.appendChild(oShadow); + + this._shadow = oShadow; + + addShadowVisibleClass.call(this); + + this.subscribe("beforeShow", addShadowVisibleClass); + this.subscribe("beforeHide", removeShadowVisibleClass); + + if (nIE == 6 || (nIE == 7 && document.compatMode == "BackCompat")) { + window.setTimeout(function () { + sizeShadow.call(me); + }, 0); + + this.cfg.subscribeToConfigEvent("width", sizeShadow); + this.cfg.subscribeToConfigEvent("height", sizeShadow); + this.subscribe("changeContent", sizeShadow); + + Module.textResizeEvent.subscribe(sizeShadow, this, true); + this.subscribe("destroy", function () { + Module.textResizeEvent.unsubscribe(sizeShadow, this); + }); + } + } + } + + function onBeforeShow() { + createShadow.call(this); + this.unsubscribe("beforeShow", onBeforeShow); + } + + if (this.cfg.getProperty("visible")) { + createShadow.call(this); + } else { + this.subscribe("beforeShow", onBeforeShow); + } + + }, + + /** + * Removes the Tooltip element from the DOM and sets all child + * elements to null. + * @method destroy + */ + destroy: function () { + + // Remove any existing mouseover/mouseout listeners + this._removeEventListeners(); + + Tooltip.superclass.destroy.call(this); + + }, + + /** + * Returns a string representation of the object. + * @method toString + * @return {String} The string representation of the Tooltip + */ + toString: function () { + return "Tooltip " + this.id; + } + + }); + +}()); + +(function () { + + /** + * Panel is an implementation of Overlay that behaves like an OS window, + * with a draggable header and an optional close icon at the top right. + * @namespace YAHOO.widget + * @class Panel + * @extends YAHOO.widget.Overlay + * @constructor + * @param {String} el The element ID representing the Panel <em>OR</em> + * @param {HTMLElement} el The element representing the Panel + * @param {Object} userConfig The configuration object literal containing + * the configuration that should be set for this Panel. See configuration + * documentation for more details. + */ + YAHOO.widget.Panel = function (el, userConfig) { + YAHOO.widget.Panel.superclass.constructor.call(this, el, userConfig); + }; + + var Lang = YAHOO.lang, + DD = YAHOO.util.DD, + Dom = YAHOO.util.Dom, + Event = YAHOO.util.Event, + Overlay = YAHOO.widget.Overlay, + CustomEvent = YAHOO.util.CustomEvent, + Config = YAHOO.util.Config, + Panel = YAHOO.widget.Panel, + + m_oMaskTemplate, + m_oUnderlayTemplate, + m_oCloseIconTemplate, + + /** + * Constant representing the name of the Panel's events + * @property EVENT_TYPES + * @private + * @final + * @type Object + */ + EVENT_TYPES = { + "SHOW_MASK": "showMask", + "HIDE_MASK": "hideMask", + "DRAG": "drag" + }, + + /** + * Constant representing the Panel's configuration properties + * @property DEFAULT_CONFIG + * @private + * @final + * @type Object + */ + DEFAULT_CONFIG = { + + "CLOSE": { + key: "close", + value: true, + validator: Lang.isBoolean, + supercedes: ["visible"] + }, + + "DRAGGABLE": { + key: "draggable", + value: (DD ? true : false), + validator: Lang.isBoolean, + supercedes: ["visible"] + }, + + "DRAG_ONLY" : { + key: "dragonly", + value: false, + validator: Lang.isBoolean, + supercedes: ["draggable"] + }, + + "UNDERLAY": { + key: "underlay", + value: "shadow", + supercedes: ["visible"] + }, + + "MODAL": { + key: "modal", + value: false, + validator: Lang.isBoolean, + supercedes: ["visible", "zindex"] + }, + + "KEY_LISTENERS": { + key: "keylisteners", + suppressEvent: true, + supercedes: ["visible"] + } + }; + + /** + * Constant representing the default CSS class used for a Panel + * @property YAHOO.widget.Panel.CSS_PANEL + * @static + * @final + * @type String + */ + Panel.CSS_PANEL = "yui-panel"; + + /** + * Constant representing the default CSS class used for a Panel's + * wrapping container + * @property YAHOO.widget.Panel.CSS_PANEL_CONTAINER + * @static + * @final + * @type String + */ + Panel.CSS_PANEL_CONTAINER = "yui-panel-container"; + + /** + * Constant representing the default set of focusable elements + * on the pagewhich Modal Panels will prevent access to, when + * the modal mask is displayed + * + * @property YAHOO.widget.Panel.FOCUSABLE + * @static + * @type Array + */ + Panel.FOCUSABLE = [ + "a", + "button", + "select", + "textarea", + "input" + ]; + + // Private CustomEvent listeners + + /* + "beforeRender" event handler that creates an empty header for a Panel + instance if its "draggable" configuration property is set to "true" + and no header has been created. + */ + + function createHeader(p_sType, p_aArgs) { + if (!this.header && this.cfg.getProperty("draggable")) { + this.setHeader(" "); + } + } + + /* + "hide" event handler that sets a Panel instance's "width" + configuration property back to its original value before + "setWidthToOffsetWidth" was called. + */ + + function restoreOriginalWidth(p_sType, p_aArgs, p_oObject) { + + var sOriginalWidth = p_oObject[0], + sNewWidth = p_oObject[1], + oConfig = this.cfg, + sCurrentWidth = oConfig.getProperty("width"); + + if (sCurrentWidth == sNewWidth) { + oConfig.setProperty("width", sOriginalWidth); + } + + this.unsubscribe("hide", restoreOriginalWidth, p_oObject); + } + + /* + "beforeShow" event handler that sets a Panel instance's "width" + configuration property to the value of its root HTML + elements's offsetWidth + */ + + function setWidthToOffsetWidth(p_sType, p_aArgs) { + + var nIE = YAHOO.env.ua.ie, + oConfig, + sOriginalWidth, + sNewWidth; + + if (nIE == 6 || (nIE == 7 && document.compatMode == "BackCompat")) { + + oConfig = this.cfg; + sOriginalWidth = oConfig.getProperty("width"); + + if (!sOriginalWidth || sOriginalWidth == "auto") { + + sNewWidth = (this.element.offsetWidth + "px"); + + oConfig.setProperty("width", sNewWidth); + + this.subscribe("hide", restoreOriginalWidth, + [(sOriginalWidth || ""), sNewWidth]); + + } + } + } + + YAHOO.extend(Panel, Overlay, { + + /** + * The Overlay initialization method, which is executed for Overlay and + * all of its subclasses. This method is automatically called by the + * constructor, and sets up all DOM references for pre-existing markup, + * and creates required markup if it is not already present. + * @method init + * @param {String} el The element ID representing the Overlay <em>OR</em> + * @param {HTMLElement} el The element representing the Overlay + * @param {Object} userConfig The configuration object literal + * containing the configuration that should be set for this Overlay. + * See configuration documentation for more details. + */ + init: function (el, userConfig) { + + /* + Note that we don't pass the user config in here yet because + we only want it executed once, at the lowest subclass level + */ + + Panel.superclass.init.call(this, el/*, userConfig*/); + + this.beforeInitEvent.fire(Panel); + + Dom.addClass(this.element, Panel.CSS_PANEL); + + this.buildWrapper(); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + + this.subscribe("showMask", this._addFocusHandlers); + this.subscribe("hideMask", this._removeFocusHandlers); + this.subscribe("beforeRender", createHeader); + + this.initEvent.fire(Panel); + }, + + /** + * @method _onElementFocus + * @private + * + * "focus" event handler for a focuable element. Used to automatically + * blur the element when it receives focus to ensure that a Panel + * instance's modality is not compromised. + * + * @param {Event} e The DOM event object + */ + _onElementFocus : function(e){ + this.blur(); + }, + + /** + * @method _addFocusHandlers + * @protected + * + * "showMask" event handler that adds a "focus" event handler to all + * focusable elements in the document to enforce a Panel instance's + * modality from being compromised. + * + * @param p_sType {String} Custom event type + * @param p_aArgs {Array} Custom event arguments + */ + _addFocusHandlers: function(p_sType, p_aArgs) { + var me = this, + focus = "focus", + hidden = "hidden"; + + function isFocusable(el) { + // NOTE: if e.type is undefined that's fine, want to avoid perf + // impact of tagName check to filter for inputs + if (el.type !== hidden && !Dom.isAncestor(me.element, el)) { + Event.on(el, focus, me._onElementFocus); + return true; + } + return false; + } + + var focusable = Panel.FOCUSABLE, + l = focusable.length, + arr = []; + + for (var i = 0; i < l; i++) { + arr = arr.concat(Dom.getElementsBy(isFocusable, focusable[i])); + } + + this.focusableElements = arr; + }, + + /** + * @method _removeFocusHandlers + * @protected + * + * "hideMask" event handler that removes all "focus" event handlers added + * by the "addFocusEventHandlers" method. + * + * @param p_sType {String} Event type + * @param p_aArgs {Array} Event Arguments + */ + _removeFocusHandlers: function(p_sType, p_aArgs) { + var aElements = this.focusableElements, + nElements = aElements.length, + focus = "focus"; + + if (aElements) { + for (var i = 0; i < nElements; i++) { + Event.removeListener(aElements[i], focus, this._onElementFocus); + } + } + }, + + /** + * Initializes the custom events for Module which are fired + * automatically at appropriate times by the Module class. + */ + initEvents: function () { + Panel.superclass.initEvents.call(this); + + var SIGNATURE = CustomEvent.LIST; + + /** + * CustomEvent fired after the modality mask is shown + * @event showMaskEvent + */ + this.showMaskEvent = this.createEvent(EVENT_TYPES.SHOW_MASK); + this.showMaskEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after the modality mask is hidden + * @event hideMaskEvent + */ + this.hideMaskEvent = this.createEvent(EVENT_TYPES.HIDE_MASK); + this.hideMaskEvent.signature = SIGNATURE; + + /** + * CustomEvent when the Panel is dragged + * @event dragEvent + */ + this.dragEvent = this.createEvent(EVENT_TYPES.DRAG); + this.dragEvent.signature = SIGNATURE; + + }, + + /** + * Initializes the class's configurable properties which can be changed + * using the Panel's Config object (cfg). + * @method initDefaultConfig + */ + initDefaultConfig: function () { + Panel.superclass.initDefaultConfig.call(this); + + // Add panel config properties // + + /** + * True if the Panel should display a "close" button + * @config close + * @type Boolean + * @default true + */ + this.cfg.addProperty(DEFAULT_CONFIG.CLOSE.key, { + handler: this.configClose, + value: DEFAULT_CONFIG.CLOSE.value, + validator: DEFAULT_CONFIG.CLOSE.validator, + supercedes: DEFAULT_CONFIG.CLOSE.supercedes + }); + + /** + * Boolean specifying if the Panel should be draggable. The default + * value is "true" if the Drag and Drop utility is included, + * otherwise it is "false." <strong>PLEASE NOTE:</strong> There is a + * known issue in IE 6 (Strict Mode and Quirks Mode) and IE 7 + * (Quirks Mode) where Panels that either don't have a value set for + * their "width" configuration property, or their "width" + * configuration property is set to "auto" will only be draggable by + * placing the mouse on the text of the Panel's header element. + * To fix this bug, draggable Panels missing a value for their + * "width" configuration property, or whose "width" configuration + * property is set to "auto" will have it set to the value of + * their root HTML element's offsetWidth before they are made + * visible. The calculated width is then removed when the Panel is + * hidden. <em>This fix is only applied to draggable Panels in IE 6 + * (Strict Mode and Quirks Mode) and IE 7 (Quirks Mode)</em>. For + * more information on this issue see: + * SourceForge bugs #1726972 and #1589210. + * @config draggable + * @type Boolean + * @default true + */ + this.cfg.addProperty(DEFAULT_CONFIG.DRAGGABLE.key, { + handler: this.configDraggable, + value: DEFAULT_CONFIG.DRAGGABLE.value, + validator: DEFAULT_CONFIG.DRAGGABLE.validator, + supercedes: DEFAULT_CONFIG.DRAGGABLE.supercedes + }); + + /** + * Boolean specifying if the draggable Panel should be drag only, not interacting with drop + * targets on the page. + * <p> + * When set to true, draggable Panels will not check to see if they are over drop targets, + * or fire the DragDrop events required to support drop target interaction (onDragEnter, + * onDragOver, onDragOut, onDragDrop etc.). + * If the Panel is not designed to be dropped on any target elements on the page, then this + * flag can be set to true to improve performance. + * </p> + * <p> + * When set to false, all drop target related events will be fired. + * </p> + * <p> + * The property is set to false by default to maintain backwards compatibility but should be + * set to true if drop target interaction is not required for the Panel, to improve performance.</p> + * + * @config dragOnly + * @type Boolean + * @default false + */ + this.cfg.addProperty(DEFAULT_CONFIG.DRAG_ONLY.key, { + value: DEFAULT_CONFIG.DRAG_ONLY.value, + validator: DEFAULT_CONFIG.DRAG_ONLY.validator, + supercedes: DEFAULT_CONFIG.DRAG_ONLY.supercedes + }); + + /** + * Sets the type of underlay to display for the Panel. Valid values + * are "shadow," "matte," and "none". <strong>PLEASE NOTE:</strong> + * The creation of the underlay element is deferred until the Panel + * is initially made visible. For Gecko-based browsers on Mac + * OS X the underlay elment is always created as it is used as a + * shim to prevent Aqua scrollbars below a Panel instance from poking + * through it (See SourceForge bug #836476). + * @config underlay + * @type String + * @default shadow + */ + this.cfg.addProperty(DEFAULT_CONFIG.UNDERLAY.key, { + handler: this.configUnderlay, + value: DEFAULT_CONFIG.UNDERLAY.value, + supercedes: DEFAULT_CONFIG.UNDERLAY.supercedes + }); + + /** + * True if the Panel should be displayed in a modal fashion, + * automatically creating a transparent mask over the document that + * will not be removed until the Panel is dismissed. + * @config modal + * @type Boolean + * @default false + */ + this.cfg.addProperty(DEFAULT_CONFIG.MODAL.key, { + handler: this.configModal, + value: DEFAULT_CONFIG.MODAL.value, + validator: DEFAULT_CONFIG.MODAL.validator, + supercedes: DEFAULT_CONFIG.MODAL.supercedes + }); + + /** + * A KeyListener (or array of KeyListeners) that will be enabled + * when the Panel is shown, and disabled when the Panel is hidden. + * @config keylisteners + * @type YAHOO.util.KeyListener[] + * @default null + */ + this.cfg.addProperty(DEFAULT_CONFIG.KEY_LISTENERS.key, { + handler: this.configKeyListeners, + suppressEvent: DEFAULT_CONFIG.KEY_LISTENERS.suppressEvent, + supercedes: DEFAULT_CONFIG.KEY_LISTENERS.supercedes + }); + + }, + + // BEGIN BUILT-IN PROPERTY EVENT HANDLERS // + + /** + * The default event handler fired when the "close" property is changed. + * The method controls the appending or hiding of the close icon at the + * top right of the Panel. + * @method configClose + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configClose: function (type, args, obj) { + + var val = args[0], + oClose = this.close; + + function doHide(e, obj) { + obj.body.removeChild(obj.body.firstChild); + //obj.element.removeChild(obj); + obj.element.parentNode.removeChild(obj.element); + obj.hide(); + } + + if (val) { + if (!oClose) { + if (!m_oCloseIconTemplate) { + m_oCloseIconTemplate = document.createElement("span"); + m_oCloseIconTemplate.innerHTML = " "; + m_oCloseIconTemplate.className = "container-close"; + } + + oClose = m_oCloseIconTemplate.cloneNode(true); + this.innerElement.appendChild(oClose); + Event.on(oClose, "click", doHide, this); + + this.close = oClose; + + } else { + oClose.style.display = "block"; + } + + } else { + if (oClose) { + oClose.style.display = "none"; + } + } + + }, + + /** + * The default event handler fired when the "draggable" property + * is changed. + * @method configDraggable + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configDraggable: function (type, args, obj) { + var val = args[0]; + + if (val) { + if (!DD) { + this.cfg.setProperty("draggable", false); + return; + } + + if (this.header) { + Dom.setStyle(this.header, "cursor", "move"); + this.registerDragDrop(); + } + + this.subscribe("beforeShow", setWidthToOffsetWidth); + + } else { + + if (this.dd) { + this.dd.unreg(); + } + + if (this.header) { + Dom.setStyle(this.header,"cursor","auto"); + } + + this.unsubscribe("beforeShow", setWidthToOffsetWidth); + } + }, + + /** + * The default event handler fired when the "underlay" property + * is changed. + * @method configUnderlay + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configUnderlay: function (type, args, obj) { + + var UA = YAHOO.env.ua, + bMacGecko = (this.platform == "mac" && UA.gecko), + bIEQuirks = (UA.ie == 6 || (UA.ie == 7 && document.compatMode == "BackCompat")), + sUnderlay = args[0].toLowerCase(), + oUnderlay = this.underlay, + oElement = this.element; + + function fixWebkitUnderlay() { + // Webkit 419.3 (Safari 2.x) does not update + // it's Render Tree for the Container when content changes. + // We need to force it to update using this contentChange + // listener + + // Webkit 523.6 doesn't have this problem and doesn't + // need the fix + var u = this.underlay; + Dom.addClass(u, "yui-force-redraw"); + window.setTimeout(function(){Dom.removeClass(u, "yui-force-redraw");}, 0); + } + + function createUnderlay() { + var bNew = false; + if (!oUnderlay) { // create if not already in DOM + + if (!m_oUnderlayTemplate) { + m_oUnderlayTemplate = document.createElement("div"); + m_oUnderlayTemplate.className = "underlay"; + } + + oUnderlay = m_oUnderlayTemplate.cloneNode(false); + this.element.appendChild(oUnderlay); + + this.underlay = oUnderlay; + + if (bIEQuirks) { + this.sizeUnderlay(); + this.cfg.subscribeToConfigEvent("width", this.sizeUnderlay); + this.cfg.subscribeToConfigEvent("height",this.sizeUnderlay); + this.changeContentEvent.subscribe(this.sizeUnderlay); + YAHOO.widget.Module.textResizeEvent.subscribe(this.sizeUnderlay, this, true); + } + + if (UA.webkit && UA.webkit < 420) { + this.changeContentEvent.subscribe(fixWebkitUnderlay); + } + bNew = true; + } + } + + function onBeforeShow() { + var bNew = createUnderlay.call(this); + if (!bNew && bIEQuirks) { + this.sizeUnderlay(); + } + this._underlayDeferred = false; + this.beforeShowEvent.unsubscribe(onBeforeShow); + } + + function destroyUnderlay() { + if (this._underlayDeferred) { + this.beforeShowEvent.unsubscribe(onBeforeShow); + this._underlayDeferred = false; + } + + if (oUnderlay) { + this.cfg.unsubscribeFromConfigEvent("width", this.sizeUnderlay); + this.cfg.unsubscribeFromConfigEvent("height",this.sizeUnderlay); + this.changeContentEvent.unsubscribe(this.sizeUnderlay); + this.changeContentEvent.unsubscribe(fixWebkitUnderlay); + YAHOO.widget.Module.textResizeEvent.unsubscribe(this.sizeUnderlay, this, true); + + this.element.removeChild(oUnderlay); + + this.underlay = null; + } + } + + switch (sUnderlay) { + case "shadow": + Dom.removeClass(oElement, "matte"); + Dom.addClass(oElement, "shadow"); + break; + case "matte": + if (!bMacGecko) { + destroyUnderlay.call(this); + } + Dom.removeClass(oElement, "shadow"); + Dom.addClass(oElement, "matte"); + break; + default: + if (!bMacGecko) { + destroyUnderlay.call(this); + } + Dom.removeClass(oElement, "shadow"); + Dom.removeClass(oElement, "matte"); + break; + } + + if ((sUnderlay == "shadow") || (bMacGecko && !oUnderlay)) { + if (this.cfg.getProperty("visible")) { + var bNew = createUnderlay.call(this); + if (!bNew && bIEQuirks) { + this.sizeUnderlay(); + } + } else { + if (!this._underlayDeferred) { + this.beforeShowEvent.subscribe(onBeforeShow); + this._underlayDeferred = true; + } + } + } + }, + + /** + * The default event handler fired when the "modal" property is + * changed. This handler subscribes or unsubscribes to the show and hide + * events to handle the display or hide of the modality mask. + * @method configModal + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configModal: function (type, args, obj) { + + var modal = args[0]; + if (modal) { + if (!this._hasModalityEventListeners) { + + this.subscribe("beforeShow", this.buildMask); + this.subscribe("beforeShow", this.bringToTop); + this.subscribe("beforeShow", this.showMask); + this.subscribe("hide", this.hideMask); + + Overlay.windowResizeEvent.subscribe(this.sizeMask, + this, true); + + this._hasModalityEventListeners = true; + } + } else { + if (this._hasModalityEventListeners) { + + if (this.cfg.getProperty("visible")) { + this.hideMask(); + this.removeMask(); + } + + this.unsubscribe("beforeShow", this.buildMask); + this.unsubscribe("beforeShow", this.bringToTop); + this.unsubscribe("beforeShow", this.showMask); + this.unsubscribe("hide", this.hideMask); + + Overlay.windowResizeEvent.unsubscribe(this.sizeMask, this); + + this._hasModalityEventListeners = false; + } + } + }, + + /** + * Removes the modality mask. + * @method removeMask + */ + removeMask: function () { + + var oMask = this.mask, + oParentNode; + + if (oMask) { + /* + Hide the mask before destroying it to ensure that DOM + event handlers on focusable elements get removed. + */ + this.hideMask(); + + oParentNode = oMask.parentNode; + if (oParentNode) { + oParentNode.removeChild(oMask); + } + + this.mask = null; + } + }, + + /** + * The default event handler fired when the "keylisteners" property + * is changed. + * @method configKeyListeners + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configKeyListeners: function (type, args, obj) { + + var listeners = args[0], + listener, + nListeners, + i; + + if (listeners) { + + if (listeners instanceof Array) { + + nListeners = listeners.length; + + for (i = 0; i < nListeners; i++) { + + listener = listeners[i]; + + if (!Config.alreadySubscribed(this.showEvent, + listener.enable, listener)) { + + this.showEvent.subscribe(listener.enable, + listener, true); + + } + + if (!Config.alreadySubscribed(this.hideEvent, + listener.disable, listener)) { + + this.hideEvent.subscribe(listener.disable, + listener, true); + + this.destroyEvent.subscribe(listener.disable, + listener, true); + } + + } + + } else { + + if (!Config.alreadySubscribed(this.showEvent, + listeners.enable, listeners)) { + + this.showEvent.subscribe(listeners.enable, + listeners, true); + } + + if (!Config.alreadySubscribed(this.hideEvent, + listeners.disable, listeners)) { + + this.hideEvent.subscribe(listeners.disable, + listeners, true); + + this.destroyEvent.subscribe(listeners.disable, + listeners, true); + + } + + } + + } + + }, + + /** + * The default event handler fired when the "height" property is changed. + * @method configHeight + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configHeight: function (type, args, obj) { + + var height = args[0], + el = this.innerElement; + + Dom.setStyle(el, "height", height); + this.cfg.refireEvent("iframe"); + + }, + + /** + * The default event handler fired when the "width" property is changed. + * @method configWidth + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configWidth: function (type, args, obj) { + + var width = args[0], + el = this.innerElement; + + Dom.setStyle(el, "width", width); + this.cfg.refireEvent("iframe"); + + }, + + /** + * The default event handler fired when the "zIndex" property is changed. + * @method configzIndex + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configzIndex: function (type, args, obj) { + Panel.superclass.configzIndex.call(this, type, args, obj); + + if (this.mask || this.cfg.getProperty("modal") === true) { + var panelZ = Dom.getStyle(this.element, "zIndex"); + if (!panelZ || isNaN(panelZ)) { + panelZ = 0; + } + + if (panelZ === 0) { + // Recursive call to configzindex (which should be stopped + // from going further because panelZ should no longer === 0) + this.cfg.setProperty("zIndex", 1); + } else { + this.stackMask(); + } + } + }, + + // END BUILT-IN PROPERTY EVENT HANDLERS // + /** + * Builds the wrapping container around the Panel that is used for + * positioning the shadow and matte underlays. The container element is + * assigned to a local instance variable called container, and the + * element is reinserted inside of it. + * @method buildWrapper + */ + buildWrapper: function () { + + var elementParent = this.element.parentNode, + originalElement = this.element, + wrapper = document.createElement("div"); + + wrapper.className = Panel.CSS_PANEL_CONTAINER; + wrapper.id = originalElement.id + "_c"; + + if (elementParent) { + elementParent.insertBefore(wrapper, originalElement); + } + + wrapper.appendChild(originalElement); + + this.element = wrapper; + this.innerElement = originalElement; + + Dom.setStyle(this.innerElement, "visibility", "inherit"); + }, + + /** + * Adjusts the size of the shadow based on the size of the element. + * @method sizeUnderlay + */ + sizeUnderlay: function () { + var oUnderlay = this.underlay, + oElement; + + if (oUnderlay) { + oElement = this.element; + oUnderlay.style.width = oElement.offsetWidth + "px"; + oUnderlay.style.height = oElement.offsetHeight + "px"; + } + }, + + + /** + * Registers the Panel's header for drag & drop capability. + * @method registerDragDrop + */ + registerDragDrop: function () { + + var me = this; + + if (this.header) { + + if (!DD) { + return; + } + + var bDragOnly = (this.cfg.getProperty("dragonly") === true); + this.dd = new DD(this.element.id, this.id, {dragOnly: bDragOnly}); + + if (!this.header.id) { + this.header.id = this.id + "_h"; + } + + this.dd.startDrag = function () { + + var offsetHeight, + offsetWidth, + viewPortWidth, + viewPortHeight, + scrollX, + scrollY; + + if (YAHOO.env.ua.ie == 6) { + Dom.addClass(me.element,"drag"); + } + + if (me.cfg.getProperty("constraintoviewport")) { + + var nViewportOffset = Overlay.VIEWPORT_OFFSET; + + offsetHeight = me.element.offsetHeight; + offsetWidth = me.element.offsetWidth; + + viewPortWidth = Dom.getViewportWidth(); + viewPortHeight = Dom.getViewportHeight(); + + scrollX = Dom.getDocumentScrollLeft(); + scrollY = Dom.getDocumentScrollTop(); + + if (offsetHeight + nViewportOffset < viewPortHeight) { + this.minY = scrollY + nViewportOffset; + this.maxY = scrollY + viewPortHeight - offsetHeight - nViewportOffset; + } else { + this.minY = scrollY + nViewportOffset; + this.maxY = scrollY + nViewportOffset; + } + + if (offsetWidth + nViewportOffset < viewPortWidth) { + this.minX = scrollX + nViewportOffset; + this.maxX = scrollX + viewPortWidth - offsetWidth - nViewportOffset; + } else { + this.minX = scrollX + nViewportOffset; + this.maxX = scrollX + nViewportOffset; + } + + this.constrainX = true; + this.constrainY = true; + } else { + this.constrainX = false; + this.constrainY = false; + } + + me.dragEvent.fire("startDrag", arguments); + }; + + this.dd.onDrag = function () { + me.syncPosition(); + me.cfg.refireEvent("iframe"); + if (this.platform == "mac" && YAHOO.env.ua.gecko) { + this.showMacGeckoScrollbars(); + } + + me.dragEvent.fire("onDrag", arguments); + }; + + this.dd.endDrag = function () { + + if (YAHOO.env.ua.ie == 6) { + Dom.removeClass(me.element,"drag"); + } + + me.dragEvent.fire("endDrag", arguments); + me.moveEvent.fire(me.cfg.getProperty("xy")); + + }; + + this.dd.setHandleElId(this.header.id); + this.dd.addInvalidHandleType("INPUT"); + this.dd.addInvalidHandleType("SELECT"); + this.dd.addInvalidHandleType("TEXTAREA"); + } + }, + + /** + * Builds the mask that is laid over the document when the Panel is + * configured to be modal. + * @method buildMask + */ + buildMask: function () { + var oMask = this.mask; + if (!oMask) { + if (!m_oMaskTemplate) { + m_oMaskTemplate = document.createElement("div"); + m_oMaskTemplate.className = "mask"; + m_oMaskTemplate.innerHTML = " "; + } + oMask = m_oMaskTemplate.cloneNode(true); + oMask.id = this.id + "_mask"; + + document.body.insertBefore(oMask, document.body.firstChild); + + this.mask = oMask; + + if (YAHOO.env.ua.gecko && this.platform == "mac") { + Dom.addClass(this.mask, "block-scrollbars"); + } + + // Stack mask based on the element zindex + this.stackMask(); + } + }, + + /** + * Hides the modality mask. + * @method hideMask + */ + hideMask: function () { + if (this.cfg.getProperty("modal") && this.mask) { + this.mask.style.display = "none"; + this.hideMaskEvent.fire(); + Dom.removeClass(document.body, "masked"); + } + }, + + /** + * Shows the modality mask. + * @method showMask + */ + showMask: function () { + if (this.cfg.getProperty("modal") && this.mask) { + Dom.addClass(document.body, "masked"); + this.sizeMask(); + this.mask.style.display = "block"; + this.showMaskEvent.fire(); + } + }, + + /** + * Sets the size of the modality mask to cover the entire scrollable + * area of the document + * @method sizeMask + */ + sizeMask: function () { + if (this.mask) { + this.mask.style.height = Dom.getDocumentHeight() + "px"; + this.mask.style.width = Dom.getDocumentWidth() + "px"; + } + }, + + /** + * Sets the zindex of the mask, if it exists, based on the zindex of + * the Panel element. The zindex of the mask is set to be one less + * than the Panel element's zindex. + * + * <p>NOTE: This method will not bump up the zindex of the Panel + * to ensure that the mask has a non-negative zindex. If you require the + * mask zindex to be 0 or higher, the zindex of the Panel + * should be set to a value higher than 0, before this method is called. + * </p> + * @method stackMask + */ + stackMask: function() { + if (this.mask) { + var panelZ = Dom.getStyle(this.element, "zIndex"); + if (!YAHOO.lang.isUndefined(panelZ) && !isNaN(panelZ)) { + Dom.setStyle(this.mask, "zIndex", panelZ - 1); + } + } + }, + + /** + * Renders the Panel by inserting the elements that are not already in + * the main Panel into their correct places. Optionally appends the + * Panel to the specified node prior to the render's execution. NOTE: + * For Panels without existing markup, the appendToNode argument is + * REQUIRED. If this argument is ommitted and the current element is + * not present in the document, the function will return false, + * indicating that the render was a failure. + * @method render + * @param {String} appendToNode The element id to which the Module + * should be appended to prior to rendering <em>OR</em> + * @param {HTMLElement} appendToNode The element to which the Module + * should be appended to prior to rendering + * @return {boolean} Success or failure of the render + */ + render: function (appendToNode) { + + return Panel.superclass.render.call(this, + appendToNode, this.innerElement); + + }, + + /** + * Removes the Panel element from the DOM and sets all child elements + * to null. + * @method destroy + */ + destroy: function () { + + Overlay.windowResizeEvent.unsubscribe(this.sizeMask, this); + + this.removeMask(); + + if (this.close) { + + Event.purgeElement(this.close); + + } + + Panel.superclass.destroy.call(this); + + }, + + /** + * Returns a String representation of the object. + * @method toString + * @return {String} The string representation of the Panel. + */ + toString: function () { + return "Panel " + this.id; + } + + }); + +}()); + +(function () { + + /** + * <p> + * Dialog is an implementation of Panel that can be used to submit form + * data. + * </p> + * <p> + * Built-in functionality for buttons with event handlers is included. + * If the optional YUI Button dependancy is included on the page, the buttons + * created will be instances of YAHOO.widget.Button, otherwise regular HTML buttons + * will be created. + * </p> + * <p> + * Forms can be processed in 3 ways -- via an asynchronous Connection utility call, + * a simple form POST or GET, or manually. The YUI Connection utility should be + * included if you're using the default "async" postmethod, but is not required if + * you're using any of the other postmethod values. + * </p> + * @namespace YAHOO.widget + * @class Dialog + * @extends YAHOO.widget.Panel + * @constructor + * @param {String} el The element ID representing the Dialog <em>OR</em> + * @param {HTMLElement} el The element representing the Dialog + * @param {Object} userConfig The configuration object literal containing + * the configuration that should be set for this Dialog. See configuration + * documentation for more details. + */ + YAHOO.widget.Dialog = function (el, userConfig) { + YAHOO.widget.Dialog.superclass.constructor.call(this, el, userConfig); + }; + + var Event = YAHOO.util.Event, + CustomEvent = YAHOO.util.CustomEvent, + Dom = YAHOO.util.Dom, + KeyListener = YAHOO.util.KeyListener, + Connect = YAHOO.util.Connect, + Dialog = YAHOO.widget.Dialog, + Lang = YAHOO.lang, + + /** + * Constant representing the name of the Dialog's events + * @property EVENT_TYPES + * @private + * @final + * @type Object + */ + EVENT_TYPES = { + + "BEFORE_SUBMIT": "beforeSubmit", + "SUBMIT": "submit", + "MANUAL_SUBMIT": "manualSubmit", + "ASYNC_SUBMIT": "asyncSubmit", + "FORM_SUBMIT": "formSubmit", + "CANCEL": "cancel" + + }, + + /** + * Constant representing the Dialog's configuration properties + * @property DEFAULT_CONFIG + * @private + * @final + * @type Object + */ + DEFAULT_CONFIG = { + + "POST_METHOD": { + key: "postmethod", + value: "async" + }, + + "BUTTONS": { + key: "buttons", + value: "none" + }, + + "HIDEAFTERSUBMIT" : { + key: "hideaftersubmit", + value: true + } + }; + + /** + * Constant representing the default CSS class used for a Dialog + * @property YAHOO.widget.Dialog.CSS_DIALOG + * @static + * @final + * @type String + */ + Dialog.CSS_DIALOG = "yui-dialog"; + + function removeButtonEventHandlers() { + + var aButtons = this._aButtons, + nButtons, + oButton, + i; + + if (Lang.isArray(aButtons)) { + nButtons = aButtons.length; + + if (nButtons > 0) { + i = nButtons - 1; + do { + oButton = aButtons[i]; + + if (YAHOO.widget.Button && oButton instanceof YAHOO.widget.Button) { + oButton.destroy(); + } + else if (oButton.tagName.toUpperCase() == "BUTTON") { + Event.purgeElement(oButton); + Event.purgeElement(oButton, false); + } + } + while (i--); + } + } + } + + YAHOO.extend(Dialog, YAHOO.widget.Panel, { + + /** + * @property form + * @description Object reference to the Dialog's + * <code><form></code> element. + * @default null + * @type <a href="http://www.w3.org/TR/2000/WD-DOM-Level-1-20000929/ + * level-one-html.html#ID-40002357">HTMLFormElement</a> + */ + form: null, + + /** + * Initializes the class's configurable properties which can be changed + * using the Dialog's Config object (cfg). + * @method initDefaultConfig + */ + initDefaultConfig: function () { + Dialog.superclass.initDefaultConfig.call(this); + + /** + * The internally maintained callback object for use with the + * Connection utility. The format of the callback object is + * similar to Connection Manager's callback object and is + * simply passed through to Connection Manager when the async + * request is made. + * @property callback + * @type Object + */ + this.callback = { + + /** + * The function to execute upon success of the + * Connection submission (when the form does not + * contain a file input element). + * + * @property callback.success + * @type Function + */ + success: null, + + /** + * The function to execute upon failure of the + * Connection submission + * @property callback.failure + * @type Function + */ + failure: null, + + /** + *<p> + * The function to execute upon success of the + * Connection submission, when the form contains + * a file input element. + * </p> + * <p> + * <em>NOTE:</em> Connection manager will not + * invoke the success or failure handlers for the file + * upload use case. This will be the only callback + * handler invoked. + * </p> + * <p> + * For more information, see the <a href="http://developer.yahoo.com/yui/connection/#file"> + * Connection Manager documenation on file uploads</a>. + * </p> + * @property callback.upload + * @type Function + */ + + /** + * The arbitraty argument or arguments to pass to the Connection + * callback functions + * @property callback.argument + * @type Object + */ + argument: null + + }; + + // Add form dialog config properties // + /** + * The method to use for posting the Dialog's form. Possible values + * are "async", "form", and "manual". + * @config postmethod + * @type String + * @default async + */ + this.cfg.addProperty(DEFAULT_CONFIG.POST_METHOD.key, { + handler: this.configPostMethod, + value: DEFAULT_CONFIG.POST_METHOD.value, + validator: function (val) { + if (val != "form" && val != "async" && val != "none" && + val != "manual") { + return false; + } else { + return true; + } + } + }); + + /** + * This property is used to configure whether or not the + * dialog should be automatically hidden after submit. + * + * @config hideaftersubmit + * @type Boolean + * @default true + */ + this.cfg.addProperty(DEFAULT_CONFIG.HIDEAFTERSUBMIT.key, { + value: DEFAULT_CONFIG.HIDEAFTERSUBMIT.value + }); + + /** + * Array of object literals, each containing a set of properties + * defining a button to be appended into the Dialog's footer. + * + * Each button object in the buttons array can have three properties: + * <dt>text:</dt> + * <dd>The text that will display on the face of the button. The text can + * include HTML, as long as it is compliant with HTML Button specifications. + * </dd> + * <dt>handler:</dt> + * <dd>Can be either: + * <ol> + * <li>A reference to a function that should fire when the + * button is clicked. (In this case scope of this function is + * always its Dialog instance.)</li> + * <li>An object literal representing the code to be + * executed when the button is clicked. Format:<br> <code> {<br> + * <strong>fn:</strong> Function, // The handler to call + * when the event fires.<br> <strong>obj:</strong> Object, + * // An object to pass back to the handler.<br> <strong> + * scope:</strong> Object // The object to use for the + * scope of the handler. <br> } </code> <br></li> + * </ol> + * </dd> + * <dt>isDefault:</dt> + * <dd>An optional boolean value that specifies that a button + * should be highlighted and focused by default.</dd> + * + * <em>NOTE:</em>If the YUI Button Widget is included on the page, + * the buttons created will be instances of YAHOO.widget.Button. + * Otherwise, HTML Buttons (<code><BUTTON></code>) will be + * created. + * + * @config buttons + * @type {Array|String} + * @default "none" + */ + this.cfg.addProperty(DEFAULT_CONFIG.BUTTONS.key, { + handler: this.configButtons, + value: DEFAULT_CONFIG.BUTTONS.value + }); + + }, + + /** + * Initializes the custom events for Dialog which are fired + * automatically at appropriate times by the Dialog class. + * @method initEvents + */ + initEvents: function () { + Dialog.superclass.initEvents.call(this); + + var SIGNATURE = CustomEvent.LIST; + + /** + * CustomEvent fired prior to submission + * @event beforeSubmitEvent + */ + this.beforeSubmitEvent = + this.createEvent(EVENT_TYPES.BEFORE_SUBMIT); + this.beforeSubmitEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after submission + * @event submitEvent + */ + this.submitEvent = this.createEvent(EVENT_TYPES.SUBMIT); + this.submitEvent.signature = SIGNATURE; + + /** + * CustomEvent fired prior to manual submission + * @event manualSubmitEvent + */ + this.manualSubmitEvent = + this.createEvent(EVENT_TYPES.MANUAL_SUBMIT); + this.manualSubmitEvent.signature = SIGNATURE; + + /** + * CustomEvent fired prior to asynchronous submission + * @event asyncSubmitEvent + */ + this.asyncSubmitEvent = this.createEvent(EVENT_TYPES.ASYNC_SUBMIT); + this.asyncSubmitEvent.signature = SIGNATURE; + + /** + * CustomEvent fired prior to form-based submission + * @event formSubmitEvent + */ + this.formSubmitEvent = this.createEvent(EVENT_TYPES.FORM_SUBMIT); + this.formSubmitEvent.signature = SIGNATURE; + + /** + * CustomEvent fired after cancel + * @event cancelEvent + */ + this.cancelEvent = this.createEvent(EVENT_TYPES.CANCEL); + this.cancelEvent.signature = SIGNATURE; + + }, + + /** + * The Dialog initialization method, which is executed for Dialog and + * all of its subclasses. This method is automatically called by the + * constructor, and sets up all DOM references for pre-existing markup, + * and creates required markup if it is not already present. + * @method init + * @param {String} el The element ID representing the Dialog <em>OR</em> + * @param {HTMLElement} el The element representing the Dialog + * @param {Object} userConfig The configuration object literal + * containing the configuration that should be set for this Dialog. + * See configuration documentation for more details. + */ + init: function (el, userConfig) { + + /* + Note that we don't pass the user config in here yet because + we only want it executed once, at the lowest subclass level + */ + + Dialog.superclass.init.call(this, el/*, userConfig*/); + + this.beforeInitEvent.fire(Dialog); + + Dom.addClass(this.element, Dialog.CSS_DIALOG); + + this.cfg.setProperty("visible", false); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + + this.showEvent.subscribe(this.focusFirst, this, true); + this.beforeHideEvent.subscribe(this.blurButtons, this, true); + + this.subscribe("changeBody", this.registerForm); + + this.initEvent.fire(Dialog); + }, + + /** + * Submits the Dialog's form depending on the value of the + * "postmethod" configuration property. <strong>Please note: + * </strong> As of version 2.3 this method will automatically handle + * asyncronous file uploads should the Dialog instance's form contain + * <code><input type="file"></code> elements. If a Dialog + * instance will be handling asyncronous file uploads, its + * <code>callback</code> property will need to be setup with a + * <code>upload</code> handler rather than the standard + * <code>success</code> and, or <code>failure</code> handlers. For more + * information, see the <a href="http://developer.yahoo.com/yui/ + * connection/#file">Connection Manager documenation on file uploads</a>. + * @method doSubmit + */ + doSubmit: function () { + + var oForm = this.form, + bUseFileUpload = false, + bUseSecureFileUpload = false, + aElements, + nElements, + i, + sMethod; + + switch (this.cfg.getProperty("postmethod")) { + + case "async": + + aElements = oForm.elements; + nElements = aElements.length; + + if (nElements > 0) { + i = nElements - 1; + do { + if (aElements[i].type == "file") { + bUseFileUpload = true; + break; + } + } + while(i--); + } + + if (bUseFileUpload && YAHOO.env.ua.ie && this.isSecure) { + bUseSecureFileUpload = true; + } + + sMethod = (oForm.getAttribute("method") || "POST").toUpperCase(); + + Connect.setForm(oForm, bUseFileUpload, bUseSecureFileUpload); + Connect.asyncRequest(sMethod, oForm.getAttribute("action"), this.callback); + + this.asyncSubmitEvent.fire(); + + break; + + case "form": + + oForm.submit(); + this.formSubmitEvent.fire(); + + break; + + case "none": + case "manual": + + this.manualSubmitEvent.fire(); + + break; + + } + + }, + + + /** + * Prepares the Dialog's internal FORM object, creating one if one is + * not currently present. + * @method registerForm + */ + registerForm: function () { + + var form = this.element.getElementsByTagName("form")[0], + me = this, + firstElement, + lastElement; + + + if (this.form) { + if (this.form == form && + Dom.isAncestor(this.element, this.form)) { + + return; + } else { + Event.purgeElement(this.form); + this.form = null; + } + } + + if (!form) { + form = document.createElement("form"); + form.name = "frm_" + this.id; + + this.body.appendChild(form); + } + + if (form) { + this.form = form; + + Event.on(form, "submit", function (e) { + Event.stopEvent(e); + this.submit(); + this.form.blur(); + }, this, true); + + this.firstFormElement = function () { + var f, el, nElements = form.elements.length; + + for (f = 0; f < nElements; f++) { + el = form.elements[f]; + if (el.focus && !el.disabled && el.type != "hidden") { + return el; + } + } + return null; + }(); + + this.lastFormElement = function () { + var f, el, nElements = form.elements.length; + + for (f = nElements - 1; f >= 0; f--) { + el = form.elements[f]; + if (el.focus && !el.disabled && el.type != "hidden") { + return el; + } + } + return null; + }(); + + if (this.cfg.getProperty("modal")) { + firstElement = this.firstFormElement || this.firstButton; + if (firstElement) { + this.preventBackTab = new KeyListener(firstElement, + { shift: true, keys: 9 }, + { fn: me.focusLast, scope: me, + correctScope: true }); + + this.showEvent.subscribe(this.preventBackTab.enable, + this.preventBackTab, true); + + this.hideEvent.subscribe(this.preventBackTab.disable, + this.preventBackTab, true); + } + + lastElement = this.lastButton || this.lastFormElement; + + if (lastElement) { + this.preventTabOut = new KeyListener(lastElement, + { shift: false, keys: 9 }, + { fn: me.focusFirst, scope: me, + correctScope: true }); + + this.showEvent.subscribe(this.preventTabOut.enable, + this.preventTabOut, true); + + this.hideEvent.subscribe(this.preventTabOut.disable, + this.preventTabOut, true); + } + } + } + }, + + // BEGIN BUILT-IN PROPERTY EVENT HANDLERS // + + /** + * The default event handler fired when the "close" property is + * changed. The method controls the appending or hiding of the close + * icon at the top right of the Dialog. + * @method configClose + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For + * configuration handlers, args[0] will equal the newly applied value + * for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configClose: function (type, args, obj) { + var val = args[0]; + + function doCancel(e, obj) { + obj.cancel(); + } + + if (val) { + if (! this.close) { + this.close = document.createElement("div"); + Dom.addClass(this.close, "container-close"); + + this.close.innerHTML = " "; + this.innerElement.appendChild(this.close); + Event.on(this.close, "click", doCancel, this); + } else { + this.close.style.display = "block"; + } + } else { + if (this.close) { + this.close.style.display = "none"; + } + } + }, + + /** + * The default event handler for the "buttons" configuration property + * @method configButtons + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configButtons: function (type, args, obj) { + + var Button = YAHOO.widget.Button, + aButtons = args[0], + oInnerElement = this.innerElement, + oButton, + oButtonEl, + oYUIButton, + nButtons, + oSpan, + oFooter, + i; + + removeButtonEventHandlers.call(this); + + this._aButtons = null; + + if (Lang.isArray(aButtons)) { + + oSpan = document.createElement("span"); + oSpan.className = "button-group"; + + nButtons = aButtons.length; + + this._aButtons = []; + + for (i = 0; i < nButtons; i++) { + + oButton = aButtons[i]; + + if (Button) { + + oYUIButton = new Button({ label: oButton.text, + container: oSpan }); + + oButtonEl = oYUIButton.get("element"); + + if (oButton.isDefault) { + + oYUIButton.addClass("default"); + + this.defaultHtmlButton = oButtonEl; + + } + + if (Lang.isFunction(oButton.handler)) { + + oYUIButton.set("onclick", { fn: oButton.handler, + obj: this, scope: this }); + + } + else if (Lang.isObject(oButton.handler) && + Lang.isFunction(oButton.handler.fn)) { + + oYUIButton.set("onclick", { fn: oButton.handler.fn, + obj: ((!Lang.isUndefined(oButton.handler.obj)) ? + oButton.handler.obj : this), + scope: (oButton.handler.scope || this) }); + + } + + this._aButtons[this._aButtons.length] = oYUIButton; + + } + else { + + oButtonEl = document.createElement("button"); + oButtonEl.setAttribute("type", "button"); + + if (oButton.isDefault) { + oButtonEl.className = "default"; + this.defaultHtmlButton = oButtonEl; + } + + oButtonEl.innerHTML = oButton.text; + + if (Lang.isFunction(oButton.handler)) { + + Event.on(oButtonEl, "click", oButton.handler, + this, true); + + } + else if (Lang.isObject(oButton.handler) && + Lang.isFunction(oButton.handler.fn)) { + + Event.on(oButtonEl, "click", oButton.handler.fn, + ((!Lang.isUndefined(oButton.handler.obj)) ? + oButton.handler.obj : this), + (oButton.handler.scope || this)); + + } + + oSpan.appendChild(oButtonEl); + + this._aButtons[this._aButtons.length] = oButtonEl; + + } + + oButton.htmlButton = oButtonEl; + + if (i === 0) { + this.firstButton = oButtonEl; + } + + if (i == (nButtons - 1)) { + this.lastButton = oButtonEl; + } + + } + + this.setFooter(oSpan); + + oFooter = this.footer; + + if (Dom.inDocument(this.element) && + !Dom.isAncestor(oInnerElement, oFooter)) { + + oInnerElement.appendChild(oFooter); + + } + + this.buttonSpan = oSpan; + + } else { // Do cleanup + + oSpan = this.buttonSpan; + oFooter = this.footer; + + if (oSpan && oFooter) { + + oFooter.removeChild(oSpan); + + this.buttonSpan = null; + this.firstButton = null; + this.lastButton = null; + this.defaultHtmlButton = null; + + } + + } + + this.cfg.refireEvent("iframe"); + this.cfg.refireEvent("underlay"); + }, + + /** + * @method getButtons + * @description Returns an array containing each of the Dialog's + * buttons, by default an array of HTML <code><BUTTON></code> + * elements. If the Dialog's buttons were created using the + * YAHOO.widget.Button class (via the inclusion of the optional Button + * dependancy on the page), an array of YAHOO.widget.Button instances + * is returned. + * @return {Array} + */ + getButtons: function () { + var aButtons = this._aButtons; + if (aButtons) { + return aButtons; + } + }, + + /** + * Sets focus to the first element in the Dialog's form or the first + * button defined via the "buttons" configuration property. Called + * when the Dialog is made visible. + * @method focusFirst + */ + focusFirst: function (type, args, obj) { + + var oElement = this.firstFormElement, + oEvent; + + if (args) { + oEvent = args[1]; + if (oEvent) { + Event.stopEvent(oEvent); + } + } + + if (oElement) { + /* + Place the call to the "focus" method inside a try/catch + block to prevent IE from throwing JavaScript errors if + the element is disabled or hidden. + */ + try { + oElement.focus(); + } + catch(oException) { + } + + } else { + this.focusDefaultButton(); + } + }, + + /** + * Sets focus to the last element in the Dialog's form or the last + * button defined via the "buttons" configuration property. + * @method focusLast + */ + focusLast: function (type, args, obj) { + + var aButtons = this.cfg.getProperty("buttons"), + oElement = this.lastFormElement, + oEvent; + + if (args) { + oEvent = args[1]; + if (oEvent) { + Event.stopEvent(oEvent); + } + } + + if (aButtons && Lang.isArray(aButtons)) { + this.focusLastButton(); + } else { + if (oElement) { + /* + Place the call to the "focus" method inside a try/catch + block to prevent IE from throwing JavaScript errors if + the element is disabled or hidden. + */ + + try { + oElement.focus(); + } catch(oException) { + } + } + } + }, + + /** + * Sets the focus to the button that is designated as the default via + * the "buttons" configuration property. By default, this method is + * called when the Dialog is made visible. + * @method focusDefaultButton + */ + focusDefaultButton: function () { + + var oElement = this.defaultHtmlButton; + + if (oElement) { + + /* + Place the call to the "focus" method inside a try/catch + block to prevent IE from throwing JavaScript errors if + the element is disabled or hidden. + */ + try { + oElement.focus(); + } catch(oException) { + } + + } + }, + + /** + * Blurs all the buttons defined via the "buttons" + * configuration property. + * @method blurButtons + */ + blurButtons: function () { + + var aButtons = this.cfg.getProperty("buttons"), + nButtons, + oButton, + oElement, + i; + + if (aButtons && Lang.isArray(aButtons)) { + + nButtons = aButtons.length; + + if (nButtons > 0) { + + i = (nButtons - 1); + + do { + oButton = aButtons[i]; + + if (oButton) { + + oElement = oButton.htmlButton; + + if (oElement) { + /* + Place the call to the "blur" method inside + a try/catch block to prevent IE from + throwing JavaScript errors if the element + is disabled or hidden. + */ + try { + oElement.blur(); + } catch(oException) { + } + } + } + + } while(i--); + } + } + }, + + /** + * Sets the focus to the first button created via the "buttons" + * configuration property. + * @method focusFirstButton + */ + focusFirstButton: function () { + + var aButtons = this.cfg.getProperty("buttons"), + oButton, + oElement; + + if (aButtons && Lang.isArray(aButtons)) { + + oButton = aButtons[0]; + + if (oButton) { + + oElement = oButton.htmlButton; + + if (oElement) { + + /* + Place the call to the "focus" method inside a + try/catch block to prevent IE from throwing + JavaScript errors if the element is disabled + or hidden. + */ + + try { + oElement.focus(); + } + catch(oException) { + } + } + } + } + }, + + /** + * Sets the focus to the last button created via the "buttons" + * configuration property. + * @method focusLastButton + */ + focusLastButton: function () { + + var aButtons = this.cfg.getProperty("buttons"), + nButtons, + oButton, + oElement; + + if (aButtons && Lang.isArray(aButtons)) { + + nButtons = aButtons.length; + + if (nButtons > 0) { + oButton = aButtons[(nButtons - 1)]; + + if (oButton) { + oElement = oButton.htmlButton; + if (oElement) { + /* + Place the call to the "focus" method inside a + try/catch block to prevent IE from throwing + JavaScript errors if the element is disabled + or hidden. + */ + + try { + oElement.focus(); + } catch(oException) { + } + } + } + } + } + }, + + /** + * The default event handler for the "postmethod" configuration property + * @method configPostMethod + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For + * configuration handlers, args[0] will equal the newly applied value + * for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configPostMethod: function (type, args, obj) { + this.registerForm(); + }, + + // END BUILT-IN PROPERTY EVENT HANDLERS // + + /** + * Built-in function hook for writing a validation function that will + * be checked for a "true" value prior to a submit. This function, as + * implemented by default, always returns true, so it should be + * overridden if validation is necessary. + * @method validate + */ + validate: function () { + return true; + }, + + /** + * Executes a submit of the Dialog if validation + * is successful. By default the Dialog is hidden + * after submission, but you can set the "hideaftersubmit" + * configuration property to false, to prevent the Dialog + * from being hidden. + * + * @method submit + */ + submit: function () { + if (this.validate()) { + this.beforeSubmitEvent.fire(); + this.doSubmit(); + this.submitEvent.fire(); + + if (this.cfg.getProperty("hideaftersubmit")) { + this.hide(); + } + + return true; + } else { + return false; + } + }, + + /** + * Executes the cancel of the Dialog followed by a hide. + * @method cancel + */ + cancel: function () { + this.cancelEvent.fire(); + this.hide(); + }, + + /** + * Returns a JSON-compatible data structure representing the data + * currently contained in the form. + * @method getData + * @return {Object} A JSON object reprsenting the data of the + * current form. + */ + getData: function () { + + var oForm = this.form, + aElements, + nTotalElements, + oData, + sName, + oElement, + nElements, + sType, + sTagName, + aOptions, + nOptions, + aValues, + oOption, + sValue, + oRadio, + oCheckbox, + i, + n; + + function isFormElement(p_oElement) { + + var sTag = p_oElement.tagName.toUpperCase(); + + return ((sTag == "INPUT" || sTag == "TEXTAREA" || + sTag == "SELECT") && p_oElement.name == sName); + + } + + + if (oForm) { + + aElements = oForm.elements; + nTotalElements = aElements.length; + oData = {}; + + + for (i = 0; i < nTotalElements; i++) { + + sName = aElements[i].name; + + /* + Using "Dom.getElementsBy" to safeguard user from JS + errors that result from giving a form field (or set of + fields) the same name as a native method of a form + (like "submit") or a DOM collection (such as the "item" + method). Originally tried accessing fields via the + "namedItem" method of the "element" collection, but + discovered that it won't return a collection of fields + in Gecko. + */ + + oElement = Dom.getElementsBy(isFormElement, "*", oForm); + nElements = oElement.length; + + if (nElements > 0) { + + if (nElements == 1) { + + oElement = oElement[0]; + + sType = oElement.type; + sTagName = oElement.tagName.toUpperCase(); + + switch (sTagName) { + + case "INPUT": + + if (sType == "checkbox") { + + oData[sName] = oElement.checked; + + } + else if (sType != "radio") { + + oData[sName] = oElement.value; + + } + + break; + + case "TEXTAREA": + + oData[sName] = oElement.value; + + break; + + case "SELECT": + + aOptions = oElement.options; + nOptions = aOptions.length; + aValues = []; + + for (n = 0; n < nOptions; n++) { + + oOption = aOptions[n]; + + if (oOption.selected) { + + sValue = oOption.value; + + if (!sValue || sValue === "") { + + sValue = oOption.text; + + } + + aValues[aValues.length] = sValue; + + } + + } + + oData[sName] = aValues; + + break; + + } + + + } + else { + + sType = oElement[0].type; + + switch (sType) { + + case "radio": + + for (n = 0; n < nElements; n++) { + + oRadio = oElement[n]; + + if (oRadio.checked) { + + oData[sName] = oRadio.value; + break; + + } + + } + + break; + + case "checkbox": + + aValues = []; + + for (n = 0; n < nElements; n++) { + + oCheckbox = oElement[n]; + + if (oCheckbox.checked) { + + aValues[aValues.length] = + oCheckbox.value; + + } + + } + + oData[sName] = aValues; + + break; + + } + + } + + } + + } + + } + + + return oData; + + }, + + /** + * Removes the Panel element from the DOM and sets all child elements + * to null. + * @method destroy + */ + destroy: function () { + + removeButtonEventHandlers.call(this); + + this._aButtons = null; + + var aForms = this.element.getElementsByTagName("form"), + oForm; + + if (aForms.length > 0) { + + oForm = aForms[0]; + + if (oForm) { + Event.purgeElement(oForm); + if (oForm.parentNode) { + oForm.parentNode.removeChild(oForm); + } + this.form = null; + } + } + + Dialog.superclass.destroy.call(this); + + }, + + /** + * Returns a string representation of the object. + * @method toString + * @return {String} The string representation of the Dialog + */ + toString: function () { + return "Dialog " + this.id; + } + + }); + +}()); + +(function () { + + /** + * SimpleDialog is a simple implementation of Dialog that can be used to + * submit a single value. Forms can be processed in 3 ways -- via an + * asynchronous Connection utility call, a simple form POST or GET, + * or manually. + * @namespace YAHOO.widget + * @class SimpleDialog + * @extends YAHOO.widget.Dialog + * @constructor + * @param {String} el The element ID representing the SimpleDialog + * <em>OR</em> + * @param {HTMLElement} el The element representing the SimpleDialog + * @param {Object} userConfig The configuration object literal containing + * the configuration that should be set for this SimpleDialog. See + * configuration documentation for more details. + */ + YAHOO.widget.SimpleDialog = function (el, userConfig) { + + YAHOO.widget.SimpleDialog.superclass.constructor.call(this, + el, userConfig); + + }; + + var Dom = YAHOO.util.Dom, + SimpleDialog = YAHOO.widget.SimpleDialog, + + /** + * Constant representing the SimpleDialog's configuration properties + * @property DEFAULT_CONFIG + * @private + * @final + * @type Object + */ + DEFAULT_CONFIG = { + + "ICON": { + key: "icon", + value: "none", + suppressEvent: true + }, + + "TEXT": { + key: "text", + value: "", + suppressEvent: true, + supercedes: ["icon"] + } + + }; + + /** + * Constant for the standard network icon for a blocking action + * @property YAHOO.widget.SimpleDialog.ICON_BLOCK + * @static + * @final + * @type String + */ + SimpleDialog.ICON_BLOCK = "blckicon"; + + /** + * Constant for the standard network icon for alarm + * @property YAHOO.widget.SimpleDialog.ICON_ALARM + * @static + * @final + * @type String + */ + SimpleDialog.ICON_ALARM = "alrticon"; + + /** + * Constant for the standard network icon for help + * @property YAHOO.widget.SimpleDialog.ICON_HELP + * @static + * @final + * @type String + */ + SimpleDialog.ICON_HELP = "hlpicon"; + + /** + * Constant for the standard network icon for info + * @property YAHOO.widget.SimpleDialog.ICON_INFO + * @static + * @final + * @type String + */ + SimpleDialog.ICON_INFO = "infoicon"; + + /** + * Constant for the standard network icon for warn + * @property YAHOO.widget.SimpleDialog.ICON_WARN + * @static + * @final + * @type String + */ + SimpleDialog.ICON_WARN = "warnicon"; + + /** + * Constant for the standard network icon for a tip + * @property YAHOO.widget.SimpleDialog.ICON_TIP + * @static + * @final + * @type String + */ + SimpleDialog.ICON_TIP = "tipicon"; + + /** + * Constant representing the name of the CSS class applied to the element + * created by the "icon" configuration property. + * @property YAHOO.widget.SimpleDialog.ICON_CSS_CLASSNAME + * @static + * @final + * @type String + */ + SimpleDialog.ICON_CSS_CLASSNAME = "yui-icon"; + + /** + * Constant representing the default CSS class used for a SimpleDialog + * @property YAHOO.widget.SimpleDialog.CSS_SIMPLEDIALOG + * @static + * @final + * @type String + */ + SimpleDialog.CSS_SIMPLEDIALOG = "yui-simple-dialog"; + + + YAHOO.extend(SimpleDialog, YAHOO.widget.Dialog, { + + /** + * Initializes the class's configurable properties which can be changed + * using the SimpleDialog's Config object (cfg). + * @method initDefaultConfig + */ + initDefaultConfig: function () { + + SimpleDialog.superclass.initDefaultConfig.call(this); + + // Add dialog config properties // + + /** + * Sets the informational icon for the SimpleDialog + * @config icon + * @type String + * @default "none" + */ + this.cfg.addProperty(DEFAULT_CONFIG.ICON.key, { + handler: this.configIcon, + value: DEFAULT_CONFIG.ICON.value, + suppressEvent: DEFAULT_CONFIG.ICON.suppressEvent + }); + + /** + * Sets the text for the SimpleDialog + * @config text + * @type String + * @default "" + */ + this.cfg.addProperty(DEFAULT_CONFIG.TEXT.key, { + handler: this.configText, + value: DEFAULT_CONFIG.TEXT.value, + suppressEvent: DEFAULT_CONFIG.TEXT.suppressEvent, + supercedes: DEFAULT_CONFIG.TEXT.supercedes + }); + + }, + + + /** + * The SimpleDialog initialization method, which is executed for + * SimpleDialog and all of its subclasses. This method is automatically + * called by the constructor, and sets up all DOM references for + * pre-existing markup, and creates required markup if it is not + * already present. + * @method init + * @param {String} el The element ID representing the SimpleDialog + * <em>OR</em> + * @param {HTMLElement} el The element representing the SimpleDialog + * @param {Object} userConfig The configuration object literal + * containing the configuration that should be set for this + * SimpleDialog. See configuration documentation for more details. + */ + init: function (el, userConfig) { + + /* + Note that we don't pass the user config in here yet because we + only want it executed once, at the lowest subclass level + */ + + SimpleDialog.superclass.init.call(this, el/*, userConfig*/); + + this.beforeInitEvent.fire(SimpleDialog); + + Dom.addClass(this.element, SimpleDialog.CSS_SIMPLEDIALOG); + + this.cfg.queueProperty("postmethod", "manual"); + + if (userConfig) { + this.cfg.applyConfig(userConfig, true); + } + + this.beforeRenderEvent.subscribe(function () { + if (! this.body) { + this.setBody(""); + } + }, this, true); + + this.initEvent.fire(SimpleDialog); + + }, + + /** + * Prepares the SimpleDialog's internal FORM object, creating one if one + * is not currently present, and adding the value hidden field. + * @method registerForm + */ + registerForm: function () { + + SimpleDialog.superclass.registerForm.call(this); + + this.form.innerHTML += "<input type=\"hidden\" name=\"" + + this.id + "\" value=\"\"/>"; + + }, + + // BEGIN BUILT-IN PROPERTY EVENT HANDLERS // + + /** + * Fired when the "icon" property is set. + * @method configIcon + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configIcon: function (type,args,obj) { + + var sIcon = args[0], + oBody = this.body, + sCSSClass = SimpleDialog.ICON_CSS_CLASSNAME, + oIcon, + oIconParent; + + if (sIcon && sIcon != "none") { + + oIcon = Dom.getElementsByClassName(sCSSClass, "*" , oBody); + + if (oIcon) { + + oIconParent = oIcon.parentNode; + + if (oIconParent) { + + oIconParent.removeChild(oIcon); + + oIcon = null; + + } + + } + + + if (sIcon.indexOf(".") == -1) { + + oIcon = document.createElement("span"); + oIcon.className = (sCSSClass + " " + sIcon); + oIcon.innerHTML = " "; + + } else { + + oIcon = document.createElement("img"); + oIcon.src = (this.imageRoot + sIcon); + oIcon.className = sCSSClass; + + } + + + if (oIcon) { + + oBody.insertBefore(oIcon, oBody.firstChild); + + } + + } + + }, + + /** + * Fired when the "text" property is set. + * @method configText + * @param {String} type The CustomEvent type (usually the property name) + * @param {Object[]} args The CustomEvent arguments. For configuration + * handlers, args[0] will equal the newly applied value for the property. + * @param {Object} obj The scope object. For configuration handlers, + * this will usually equal the owner. + */ + configText: function (type,args,obj) { + var text = args[0]; + if (text) { + this.setBody(text); + this.cfg.refireEvent("icon"); + } + }, + + // END BUILT-IN PROPERTY EVENT HANDLERS // + + /** + * Returns a string representation of the object. + * @method toString + * @return {String} The string representation of the SimpleDialog + */ + toString: function () { + return "SimpleDialog " + this.id; + } + + }); + +}()); + +(function () { + + /** + * ContainerEffect encapsulates animation transitions that are executed when + * an Overlay is shown or hidden. + * @namespace YAHOO.widget + * @class ContainerEffect + * @constructor + * @param {YAHOO.widget.Overlay} overlay The Overlay that the animation + * should be associated with + * @param {Object} attrIn The object literal representing the animation + * arguments to be used for the animate-in transition. The arguments for + * this literal are: attributes(object, see YAHOO.util.Anim for description), + * duration(Number), and method(i.e. Easing.easeIn). + * @param {Object} attrOut The object literal representing the animation + * arguments to be used for the animate-out transition. The arguments for + * this literal are: attributes(object, see YAHOO.util.Anim for description), + * duration(Number), and method(i.e. Easing.easeIn). + * @param {HTMLElement} targetElement Optional. The target element that + * should be animated during the transition. Defaults to overlay.element. + * @param {class} Optional. The animation class to instantiate. Defaults to + * YAHOO.util.Anim. Other options include YAHOO.util.Motion. + */ + YAHOO.widget.ContainerEffect = + + function (overlay, attrIn, attrOut, targetElement, animClass) { + + if (!animClass) { + animClass = YAHOO.util.Anim; + } + + /** + * The overlay to animate + * @property overlay + * @type YAHOO.widget.Overlay + */ + this.overlay = overlay; + + /** + * The animation attributes to use when transitioning into view + * @property attrIn + * @type Object + */ + this.attrIn = attrIn; + + /** + * The animation attributes to use when transitioning out of view + * @property attrOut + * @type Object + */ + this.attrOut = attrOut; + + /** + * The target element to be animated + * @property targetElement + * @type HTMLElement + */ + this.targetElement = targetElement || overlay.element; + + /** + * The animation class to use for animating the overlay + * @property animClass + * @type class + */ + this.animClass = animClass; + + }; + + + var Dom = YAHOO.util.Dom, + CustomEvent = YAHOO.util.CustomEvent, + Easing = YAHOO.util.Easing, + ContainerEffect = YAHOO.widget.ContainerEffect; + + + /** + * A pre-configured ContainerEffect instance that can be used for fading + * an overlay in and out. + * @method FADE + * @static + * @param {YAHOO.widget.Overlay} overlay The Overlay object to animate + * @param {Number} dur The duration of the animation + * @return {YAHOO.widget.ContainerEffect} The configured ContainerEffect object + */ + ContainerEffect.FADE = function (overlay, dur) { + + var fin = { + attributes: {opacity:{from:0, to:1}}, + duration: dur, + method: Easing.easeIn + }; + + var fout = { + attributes: {opacity:{to:0}}, + duration: dur, + method: Easing.easeOut + }; + + var fade = new ContainerEffect(overlay, fin, fout, overlay.element); + + fade.handleUnderlayStart = function() { + var underlay = this.overlay.underlay; + if (underlay && YAHOO.env.ua.ie) { + var hasFilters = (underlay.filters && underlay.filters.length > 0); + if(hasFilters) { + Dom.addClass(overlay.element, "yui-effect-fade"); + } + } + }; + + fade.handleUnderlayComplete = function() { + var underlay = this.overlay.underlay; + if (underlay && YAHOO.env.ua.ie) { + Dom.removeClass(overlay.element, "yui-effect-fade"); + } + }; + + fade.handleStartAnimateIn = function (type,args,obj) { + Dom.addClass(obj.overlay.element, "hide-select"); + + if (!obj.overlay.underlay) { + obj.overlay.cfg.refireEvent("underlay"); + } + + obj.handleUnderlayStart(); + + Dom.setStyle(obj.overlay.element, "visibility", "visible"); + Dom.setStyle(obj.overlay.element, "opacity", 0); + }; + + fade.handleCompleteAnimateIn = function (type,args,obj) { + Dom.removeClass(obj.overlay.element, "hide-select"); + + if (obj.overlay.element.style.filter) { + obj.overlay.element.style.filter = null; + } + + obj.handleUnderlayComplete(); + + obj.overlay.cfg.refireEvent("iframe"); + obj.animateInCompleteEvent.fire(); + }; + + fade.handleStartAnimateOut = function (type, args, obj) { + Dom.addClass(obj.overlay.element, "hide-select"); + obj.handleUnderlayStart(); + }; + + fade.handleCompleteAnimateOut = function (type, args, obj) { + Dom.removeClass(obj.overlay.element, "hide-select"); + if (obj.overlay.element.style.filter) { + obj.overlay.element.style.filter = null; + } + Dom.setStyle(obj.overlay.element, "visibility", "hidden"); + Dom.setStyle(obj.overlay.element, "opacity", 1); + + obj.handleUnderlayComplete(); + + obj.overlay.cfg.refireEvent("iframe"); + obj.animateOutCompleteEvent.fire(); + }; + + fade.init(); + return fade; + }; + + + /** + * A pre-configured ContainerEffect instance that can be used for sliding an + * overlay in and out. + * @method SLIDE + * @static + * @param {YAHOO.widget.Overlay} overlay The Overlay object to animate + * @param {Number} dur The duration of the animation + * @return {YAHOO.widget.ContainerEffect} The configured ContainerEffect object + */ + ContainerEffect.SLIDE = function (overlay, dur) { + + var x = overlay.cfg.getProperty("x") || Dom.getX(overlay.element), + + y = overlay.cfg.getProperty("y") || Dom.getY(overlay.element), + + clientWidth = Dom.getClientWidth(), + + offsetWidth = overlay.element.offsetWidth, + + slide = new ContainerEffect(overlay, + + { attributes: { points: { to: [x, y] } }, + duration: dur, + method: Easing.easeIn }, + + { attributes: { points: { to: [(clientWidth + 25), y] } }, + duration: dur, + method: Easing.easeOut }, + + overlay.element, YAHOO.util.Motion); + + + slide.handleStartAnimateIn = function (type,args,obj) { + obj.overlay.element.style.left = ((-25) - offsetWidth) + "px"; + obj.overlay.element.style.top = y + "px"; + }; + + slide.handleTweenAnimateIn = function (type, args, obj) { + + var pos = Dom.getXY(obj.overlay.element), + currentX = pos[0], + currentY = pos[1]; + + if (Dom.getStyle(obj.overlay.element, "visibility") == + "hidden" && currentX < x) { + + Dom.setStyle(obj.overlay.element, "visibility", "visible"); + + } + + obj.overlay.cfg.setProperty("xy", [currentX, currentY], true); + obj.overlay.cfg.refireEvent("iframe"); + }; + + slide.handleCompleteAnimateIn = function (type, args, obj) { + obj.overlay.cfg.setProperty("xy", [x, y], true); + obj.startX = x; + obj.startY = y; + obj.overlay.cfg.refireEvent("iframe"); + obj.animateInCompleteEvent.fire(); + }; + + slide.handleStartAnimateOut = function (type, args, obj) { + + var vw = Dom.getViewportWidth(), + pos = Dom.getXY(obj.overlay.element), + yso = pos[1]; + + obj.animOut.attributes.points.to = [(vw + 25), yso]; + }; + + slide.handleTweenAnimateOut = function (type, args, obj) { + + var pos = Dom.getXY(obj.overlay.element), + xto = pos[0], + yto = pos[1]; + + obj.overlay.cfg.setProperty("xy", [xto, yto], true); + obj.overlay.cfg.refireEvent("iframe"); + }; + + slide.handleCompleteAnimateOut = function (type, args, obj) { + Dom.setStyle(obj.overlay.element, "visibility", "hidden"); + + obj.overlay.cfg.setProperty("xy", [x, y]); + obj.animateOutCompleteEvent.fire(); + }; + + slide.init(); + return slide; + }; + + ContainerEffect.prototype = { + + /** + * Initializes the animation classes and events. + * @method init + */ + init: function () { + + this.beforeAnimateInEvent = this.createEvent("beforeAnimateIn"); + this.beforeAnimateInEvent.signature = CustomEvent.LIST; + + this.beforeAnimateOutEvent = this.createEvent("beforeAnimateOut"); + this.beforeAnimateOutEvent.signature = CustomEvent.LIST; + + this.animateInCompleteEvent = this.createEvent("animateInComplete"); + this.animateInCompleteEvent.signature = CustomEvent.LIST; + + this.animateOutCompleteEvent = + this.createEvent("animateOutComplete"); + this.animateOutCompleteEvent.signature = CustomEvent.LIST; + + this.animIn = new this.animClass(this.targetElement, + this.attrIn.attributes, this.attrIn.duration, + this.attrIn.method); + + this.animIn.onStart.subscribe(this.handleStartAnimateIn, this); + this.animIn.onTween.subscribe(this.handleTweenAnimateIn, this); + + this.animIn.onComplete.subscribe(this.handleCompleteAnimateIn, + this); + + this.animOut = new this.animClass(this.targetElement, + this.attrOut.attributes, this.attrOut.duration, + this.attrOut.method); + + this.animOut.onStart.subscribe(this.handleStartAnimateOut, this); + this.animOut.onTween.subscribe(this.handleTweenAnimateOut, this); + this.animOut.onComplete.subscribe(this.handleCompleteAnimateOut, + this); + + }, + + /** + * Triggers the in-animation. + * @method animateIn + */ + animateIn: function () { + this.beforeAnimateInEvent.fire(); + this.animIn.animate(); + }, + + /** + * Triggers the out-animation. + * @method animateOut + */ + animateOut: function () { + this.beforeAnimateOutEvent.fire(); + this.animOut.animate(); + }, + + /** + * The default onStart handler for the in-animation. + * @method handleStartAnimateIn + * @param {String} type The CustomEvent type + * @param {Object[]} args The CustomEvent arguments + * @param {Object} obj The scope object + */ + handleStartAnimateIn: function (type, args, obj) { }, + + /** + * The default onTween handler for the in-animation. + * @method handleTweenAnimateIn + * @param {String} type The CustomEvent type + * @param {Object[]} args The CustomEvent arguments + * @param {Object} obj The scope object + */ + handleTweenAnimateIn: function (type, args, obj) { }, + + /** + * The default onComplete handler for the in-animation. + * @method handleCompleteAnimateIn + * @param {String} type The CustomEvent type + * @param {Object[]} args The CustomEvent arguments + * @param {Object} obj The scope object + */ + handleCompleteAnimateIn: function (type, args, obj) { }, + + /** + * The default onStart handler for the out-animation. + * @method handleStartAnimateOut + * @param {String} type The CustomEvent type + * @param {Object[]} args The CustomEvent arguments + * @param {Object} obj The scope object + */ + handleStartAnimateOut: function (type, args, obj) { }, + + /** + * The default onTween handler for the out-animation. + * @method handleTweenAnimateOut + * @param {String} type The CustomEvent type + * @param {Object[]} args The CustomEvent arguments + * @param {Object} obj The scope object + */ + handleTweenAnimateOut: function (type, args, obj) { }, + + /** + * The default onComplete handler for the out-animation. + * @method handleCompleteAnimateOut + * @param {String} type The CustomEvent type + * @param {Object[]} args The CustomEvent arguments + * @param {Object} obj The scope object + */ + handleCompleteAnimateOut: function (type, args, obj) { }, + + /** + * Returns a string representation of the object. + * @method toString + * @return {String} The string representation of the ContainerEffect + */ + toString: function () { + var output = "ContainerEffect"; + if (this.overlay) { + output += " [" + this.overlay.toString() + "]"; + } + return output; + } + + }; + + YAHOO.lang.augmentProto(ContainerEffect, YAHOO.util.EventProvider); + +})(); + +YAHOO.register("container", YAHOO.widget.Module, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/asc.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/asc.gif new file mode 100644 index 0000000..a1fe738 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/asc.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/autocomplete.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/autocomplete.css new file mode 100644 index 0000000..40ad715 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/autocomplete.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-skin-sam .yui-ac{position:relative;font-family:arial;font-size:100%;}.yui-skin-sam .yui-ac-input{position:absolute;width:100%;}.yui-skin-sam .yui-ac-container{position:absolute;top:1.6em;width:100%;}.yui-skin-sam .yui-ac-content{position:absolute;width:100%;border:1px solid #808080;background:#fff;overflow:hidden;z-index:9050;}.yui-skin-sam .yui-ac-shadow{position:absolute;margin:.3em;width:100%;background:#000;-moz-opacity:0.10;opacity:.10;filter:alpha(opacity=10);z-index:9049;}.yui-skin-sam .yui-ac-content ul{margin:0;padding:0;width:100%;}.yui-skin-sam .yui-ac-content li{margin:0;padding:2px 5px;cursor:default;white-space:nowrap;}.yui-skin-sam .yui-ac-content li.yui-ac-prehighlight{background:#B3D4FF;}.yui-skin-sam .yui-ac-content li.yui-ac-highlight{background:#426FD9;color:#FFF;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/blankimage.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/blankimage.png new file mode 100644 index 0000000..b87bb24 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/blankimage.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/button.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/button.css new file mode 100644 index 0000000..8334ec8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/button.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-button{display:-moz-inline-box;display:inline-block;vertical-align:text-bottom;}.yui-button .first-child{display:block;*display:inline-block;}.yui-button button,.yui-button a{display:block;*display:inline-block;border:none;margin:0;}.yui-button button{background-color:transparent;*overflow:visible;cursor:pointer;}.yui-button a{text-decoration:none;}.yui-skin-sam .yui-button{border-width:1px 0;border-style:solid;border-color:#808080;background:url(sprite.png) repeat-x 0 0;margin:auto .25em;}.yui-skin-sam .yui-button .first-child{border-width:0 1px;border-style:solid;border-color:#808080;margin:0 -1px;*position:relative;*left:-1px;}.yui-skin-sam .yui-button button,.yui-skin-sam .yui-button a{padding:0 10px;font-size:93%;line-height:2;*line-height:1.7;min-height:2em;*min-height:auto;color:#000;}.yui-skin-sam .yui-button a{*line-height:2;}.yui-skin-sam .yui-split-button button,.yui-skin-sam .yui-menu-button button{padding-right:20px;background-position:right center;background-repeat:no-repeat;}.yui-skin-sam .yui-menu-button button{background-image:url(menu-button-arrow.png);}.yui-skin-sam .yui-split-button button{background-image:url(split-button-arrow.png);}.yui-skin-sam .yui-button-focus{border-color:#7D98B8;background-position:0 -1300px;}.yui-skin-sam .yui-button-focus .first-child{border-color:#7D98B8;}.yui-skin-sam .yui-button-focus button,.yui-skin-sam .yui-button-focus a{color:#000;}.yui-skin-sam .yui-split-button-focus button{background-image:url(split-button-arrow-focus.png);}.yui-skin-sam .yui-button-hover{border-color:#7D98B8;background-position:0 -1300px;}.yui-skin-sam .yui-button-hover .first-child{border-color:#7D98B8;}.yui-skin-sam .yui-button-hover button,.yui-skin-sam .yui-button-hover a{color:#000;}.yui-skin-sam .yui-split-button-hover button{background-image:url(split-button-arrow-hover.png);}.yui-skin-sam .yui-button-active{border-color:#7D98B8;background-position:0 -1700px;}.yui-skin-sam .yui-button-active .first-child{border-color:#7D98B8;}.yui-skin-sam .yui-button-active button,.yui-skin-sam .yui-button-active a{color:#000;}.yui-skin-sam .yui-split-button-activeoption{border-color:#808080;background-position:0 0;}.yui-skin-sam .yui-split-button-activeoption .first-child{border-color:#808080;}.yui-skin-sam .yui-split-button-activeoption button{background-image:url(split-button-arrow-active.png);}.yui-skin-sam .yui-radio-button-checked,.yui-skin-sam .yui-checkbox-button-checked{border-color:#304369;background-position:0 -1400px;}.yui-skin-sam .yui-radio-button-checked .first-child,.yui-skin-sam .yui-checkbox-button-checked .first-child{border-color:#304369;}.yui-skin-sam .yui-radio-button-checked button,.yui-skin-sam .yui-checkbox-button-checked button{color:#fff;}.yui-skin-sam .yui-button-disabled{border-color:#ccc;background-position:0 -1500px;}.yui-skin-sam .yui-button-disabled .first-child{border-color:#ccc;}.yui-skin-sam .yui-button-disabled button,.yui-skin-sam .yui-button-disabled a{color:#A6A6A6;cursor:default;}.yui-skin-sam .yui-menu-button-disabled button{background-image:url(menu-button-arrow-disabled.png);}.yui-skin-sam .yui-split-button-disabled button{background-image:url(split-button-arrow-disabled.png);}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/calendar.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/calendar.css new file mode 100644 index 0000000..7b1c778a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/calendar.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-calcontainer{position:relative;float:left;_overflow:hidden;}.yui-calcontainer iframe{position:absolute;border:none;margin:0;padding:0;z-index:0;width:100%;height:100%;left:0px;top:0px;}.yui-calcontainer iframe.fixedsize{width:50em;height:50em;top:-1px;left:-1px;}.yui-calcontainer.multi .groupcal{z-index:1;float:left;position:relative;}.yui-calcontainer .title{position:relative;z-index:1;}.yui-calcontainer .close-icon{position:absolute;z-index:1;}.yui-calendar{position:relative;}.yui-calendar .calnavleft{position:absolute;z-index:1;}.yui-calendar .calnavright{position:absolute;z-index:1;}.yui-calendar .calheader{position:relative;width:100%;text-align:center;}.yui-calcontainer .yui-cal-nav-mask{position:absolute;z-index:2;margin:0;padding:0;width:100%;height:100%;_width:0;_height:0;left:0;top:0;display:none;}.yui-calcontainer .yui-cal-nav{position:absolute;z-index:3;top:0;display:none;}.yui-calcontainer .yui-cal-nav .yui-cal-nav-btn{display:-moz-inline-box;display:inline-block;}.yui-calcontainer .yui-cal-nav .yui-cal-nav-btn button{display:block;*display:inline-block;*overflow:visible;border:none;background-color:transparent;cursor:pointer;}.yui-calendar .calbody a:hover{background:inherit;}p#clear{clear:left;padding-top:10px;}.yui-skin-sam .yui-calcontainer{background-color:#f2f2f2;border:1px solid #808080;padding:10px;}.yui-skin-sam .yui-calcontainer.multi{padding:0 5px 0 5px;}.yui-skin-sam .yui-calcontainer.multi .groupcal{background-color:transparent;border:none;padding:10px 5px 10px 5px;margin:0;}.yui-skin-sam .yui-calcontainer .title{background:url(sprite.png) repeat-x 0 0;border-bottom:1px solid #cccccc;font:100% sans-serif;color:#000;font-weight:bold;height:auto;padding:.4em;margin:0 -10px 10px -10px;top:0;left:0;text-align:left;}.yui-skin-sam .yui-calcontainer.multi .title{margin:0 -5px 0 -5px;}.yui-skin-sam .yui-calcontainer.withtitle{padding-top:0;}.yui-skin-sam .yui-calcontainer .calclose{background:url(sprite.png) no-repeat 0 -300px;width:25px;height:15px;top:.4em;right:.4em;cursor:pointer;}.yui-skin-sam .yui-calendar{border-spacing:0;border-collapse:collapse;font:100% sans-serif;text-align:center;margin:0;}.yui-skin-sam .yui-calendar .calhead{background:transparent;border:none;vertical-align:middle;padding:0;}.yui-skin-sam .yui-calendar .calheader{background:transparent;font-weight:bold;padding:0 0 .6em 0;text-align:center;}.yui-skin-sam .yui-calendar .calheader img{border:none;}.yui-skin-sam .yui-calendar .calnavleft{background:url(sprite.png) no-repeat 0 -450px;width:25px;height:15px;top:0;bottom:0;left:-10px;margin-left:.4em;cursor:pointer;}.yui-skin-sam .yui-calendar .calnavright{background:url(sprite.png) no-repeat 0 -500px;width:25px;height:15px;top:0;bottom:0;right:-10px;margin-right:.4em;cursor:pointer;}.yui-skin-sam .yui-calendar .calweekdayrow{height:2em;}.yui-skin-sam .yui-calendar .calweekdayrow th{padding:0;border:none;}.yui-skin-sam .yui-calendar .calweekdaycell{color:#000;font-weight:bold;text-align:center;width:2em;}.yui-skin-sam .yui-calendar .calfoot{background-color:#f2f2f2;}.yui-skin-sam .yui-calendar .calrowhead,.yui-skin-sam .yui-calendar .calrowfoot{color:#a6a6a6;font-size:85%;font-style:normal;font-weight:normal;border:none;}.yui-skin-sam .yui-calendar .calrowhead{text-align:right;padding:0 2px 0 0;}.yui-skin-sam .yui-calendar .calrowfoot{text-align:left;padding:0 0 0 2px;}.yui-skin-sam .yui-calendar td.calcell{border:1px solid #cccccc;background:#fff;padding:1px;height:1.6em;line-height:1.6em;text-align:center;white-space:nowrap;}.yui-skin-sam .yui-calendar td.calcell a{color:#0066cc;display:block;height:100%;text-decoration:none;}.yui-skin-sam .yui-calendar td.calcell.today{background-color:#000;}.yui-skin-sam .yui-calendar td.calcell.today a{background-color:#fff;}.yui-skin-sam .yui-calendar td.calcell.oom{background-color:#cccccc;color:#a6a6a6;cursor:default;}.yui-skin-sam .yui-calendar td.calcell.selected{background-color:#fff;color:#000;}.yui-skin-sam .yui-calendar td.calcell.selected a{background-color:#b3d4ff;color:#000;}.yui-skin-sam .yui-calendar td.calcell.calcellhover{background-color:#426fd9;color:#fff;cursor:pointer;}.yui-skin-sam .yui-calendar td.calcell.calcellhover a{background-color:#426fd9;color:#fff;}.yui-skin-sam .yui-calendar td.calcell.previous{color:#e0e0e0;}.yui-skin-sam .yui-calendar td.calcell.restricted{text-decoration:line-through;}.yui-skin-sam .yui-calendar td.calcell.highlight1{background-color:#ccff99;}.yui-skin-sam .yui-calendar td.calcell.highlight2{background-color:#99ccff;}.yui-skin-sam .yui-calendar td.calcell.highlight3{background-color:#ffcccc;}.yui-skin-sam .yui-calendar td.calcell.highlight4{background-color:#ccff99;}.yui-skin-sam .yui-calendar a.calnav{border:1px solid #f2f2f2;padding:0 4px;text-decoration:none;color:#000;zoom:1;}.yui-skin-sam .yui-calendar a.calnav:hover{background:url(sprite.png) repeat-x 0 0;border-color:#A0A0A0;cursor:pointer;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-mask{background-color:#000;opacity:0.25;*filter:alpha(opacity=25);}.yui-skin-sam .yui-calcontainer .yui-cal-nav{font-family:arial,helvetica,clean,sans-serif;font-size:93%;border:1px solid #808080;left:50%;margin-left:-7em;width:14em;padding:0;top:2.5em;background-color:#f2f2f2;}.yui-skin-sam .yui-calcontainer.withtitle .yui-cal-nav{top:4.5em;}.yui-skin-sam .yui-calcontainer.multi .yui-cal-nav{width:16em;margin-left:-8em;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-y,.yui-skin-sam .yui-calcontainer .yui-cal-nav-m,.yui-skin-sam .yui-calcontainer .yui-cal-nav-b{padding:5px 10px 5px 10px;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-b{text-align:center;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-e{margin-top:5px;padding:5px;background-color:#EDF5FF;border-top:1px solid black;display:none;}.yui-skin-sam .yui-calcontainer .yui-cal-nav label{display:block;font-weight:bold;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-mc{width:100%;_width:auto;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-y input.yui-invalid{background-color:#FFEE69;border:1px solid #000;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-yc{width:4em;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn{border:1px solid #808080;background:url(sprite.png) repeat-x 0 0;background-color:#ccc;margin:auto .15em;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn button{padding:0 8px;font-size:93%;line-height:2;*line-height:1.7;min-height:2em;*min-height:auto;color:#000;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn.yui-default{border:1px solid #304369;background-color:#426fd9;background:url(sprite.png) repeat-x 0 -1400px;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn.yui-default button{color:#fff;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/colorpicker.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/colorpicker.css new file mode 100644 index 0000000..041ae13 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/colorpicker.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-picker-panel{background:#e3e3e3;border-color:#888;}.yui-picker-panel .hd{background-color:#ccc;font-size:100%;line-height:100%;border:1px solid #e3e3e3;font-weight:bold;overflow:hidden;padding:6px;color:#000;}.yui-picker-panel .bd{background:#e8e8e8;margin:1px;height:200px;}.yui-picker-panel .ft{background:#e8e8e8;margin:1px;padding:1px;}.yui-picker{position:relative;}.yui-picker-hue-thumb{cursor:default;width:18px;height:18px;top:-8px;left:-2px;z-index:9;position:absolute;}.yui-picker-hue-bg{-moz-outline:none;outline:0px none;position:absolute;left:200px;height:183px;width:14px;background:url(hue_bg.png) no-repeat;top:4px;}.yui-picker-bg{-moz-outline:none;outline:0px none;position:absolute;top:4px;left:4px;height:182px;width:182px;background-color:#F00;background-image:url(picker_mask.png);}*html .yui-picker-bg{background-image:none;filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='../../build/colorpicker/assets/picker_mask.png',sizingMethod='scale');}.yui-picker-mask{position:absolute;z-index:1;top:0px;left:0px;}.yui-picker-thumb{cursor:default;width:11px;height:11px;z-index:9;position:absolute;top:-4px;left:-4px;}.yui-picker-swatch{position:absolute;left:240px;top:4px;height:60px;width:55px;border:1px solid #888;}.yui-picker-websafe-swatch{position:absolute;left:304px;top:4px;height:24px;width:24px;border:1px solid #888;}.yui-picker-controls{position:absolute;top:72px;left:226px;font:1em monospace;}.yui-picker-controls .hd{background:transparent;border-width:0px !important;}.yui-picker-controls .bd{height:100px;border-width:0px !important;}.yui-picker-controls ul{float:left;padding:0 2px 0 0;margin:0}.yui-picker-controls li{padding:2px;list-style:none;margin:0}.yui-picker-controls input{font-size:0.85em;width:2.4em;}.yui-picker-hex-controls{clear:both;padding:2px;}.yui-picker-hex-controls input{width:4.6em;}.yui-picker-controls a{font:1em arial,helvetica,clean,sans-serif;display:block;*display:inline-block;padding:0;color:#000;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/container.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/container.css new file mode 100644 index 0000000..b3e54fa --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/container.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-overlay,.yui-panel-container{visibility:hidden;position:absolute;z-index:2;}.yui-panel-container form{margin:0;}.mask{z-index:1;display:none;position:absolute;top:0;left:0;right:0;bottom:0;}.mask.block-scrollbars{overflow:auto;}.masked select,.drag select,.hide-select select{_visibility:hidden;}.yui-panel-container select{_visibility:inherit;}.hide-scrollbars,.hide-scrollbars *{overflow:hidden;}.hide-scrollbars select{display:none;}.show-scrollbars{overflow:auto;}.yui-panel-container.show-scrollbars,.yui-tt.show-scrollbars{overflow:visible;}.yui-panel-container.show-scrollbars .underlay,.yui-tt.show-scrollbars .yui-tt-shadow{overflow:auto;}.yui-panel-container.shadow .underlay.yui-force-redraw{padding-bottom:1px;}.yui-effect-fade .underlay{display:none;}.yui-tt-shadow{position:absolute;}.yui-skin-sam .mask{background-color:#000;opacity:.25;*filter:alpha(opacity=25);}.yui-skin-sam .yui-panel-container{padding:0 1px;*padding:2px 3px;}.yui-skin-sam .yui-panel{position:relative;*zoom:1;left:0;top:0;border-style:solid;border-width:1px 0;border-color:#808080;z-index:1;}.yui-skin-sam .yui-panel .hd,.yui-skin-sam .yui-panel .bd,.yui-skin-sam .yui-panel .ft{*zoom:1;*position:relative;border-style:solid;border-width:0 1px;border-color:#808080;margin:0 -1px; background:#fff;}.yui-skin-sam .yui-panel .hd{border-bottom:solid 1px #ccc;}.yui-skin-sam .yui-panel .bd,.yui-skin-sam .yui-panel .ft{background-color:#F2F2F2;}.yui-skin-sam .yui-panel .hd{padding:0 10px;font-size:93%;line-height:2;*line-height:1.9;font-weight:bold;color:#000;background:url(sprite.png) repeat-x 0 -200px;}.yui-skin-sam .yui-panel .bd{padding:10px;}.yui-skin-sam .yui-panel .ft{border-top:solid 1px #808080;padding:5px 10px;font-size:77%;}.yui-skin-sam .yui-panel-container.focused .yui-panel .hd{}.yui-skin-sam .container-close{position:absolute;top:5px;right:6px;width:25px;height:15px;background:url(sprite.png) no-repeat 0 -300px;cursor:pointer;}.yui-skin-sam .yui-panel-container .underlay{right:-1px;left:-1px;}.yui-skin-sam .yui-panel-container.matte{padding:9px 10px;background-color:#fff;}.yui-skin-sam .yui-panel-container.shadow{_padding:2px 5px 0 3px;}.yui-skin-sam .yui-panel-container.shadow .underlay{position:absolute;top:2px;right:-3px;bottom:-3px;left:-3px;*top:3px;*left:-1px;*right:-1px;*bottom:-1px;_top:0;_right:0;_bottom:0;_left:0;_margin-top:3px;_margin-left:-1px;background-color:#000;opacity:.12;*filter:alpha(opacity=12);}.yui-skin-sam .yui-dialog .ft{border-top:none;padding:0 10px 10px 10px;font-size:100%;}.yui-skin-sam .yui-dialog .ft .button-group{display:block;text-align:right;}.yui-skin-sam .yui-dialog .ft button.default{font-weight:bold;}.yui-skin-sam .yui-dialog .ft span.default{border-color:#304369;background-position:0 -1400px;}.yui-skin-sam .yui-dialog .ft span.default .first-child{border-color:#304369;}.yui-skin-sam .yui-dialog .ft span.default button{color:#fff;}.yui-skin-sam .yui-simple-dialog .bd .yui-icon{background:url(sprite.png) no-repeat 0 0;width:16px;height:16px;margin-right:10px;float:left;}.yui-skin-sam .yui-simple-dialog .bd span.blckicon{background-position:0 -1100px;}.yui-skin-sam .yui-simple-dialog .bd span.alrticon{background-position:0 -1050px;}.yui-skin-sam .yui-simple-dialog .bd span.hlpicon{background-position:0 -1150px;}.yui-skin-sam .yui-simple-dialog .bd span.infoicon{background-position:0 -1200px;}.yui-skin-sam .yui-simple-dialog .bd span.warnicon{background-position:0 -1900px;}.yui-skin-sam .yui-simple-dialog .bd span.tipicon{background-position:0 -1250px;}.yui-skin-sam .yui-tt .bd{position:relative;top:0;left:0;z-index:1;color:#000;padding:2px 5px;border-color:#D4C237 #A6982B #A6982B #A6982B;border-width:1px;border-style:solid;background-color:#FFEE69;}.yui-skin-sam .yui-tt.show-scrollbars .bd{overflow:auto;}.yui-skin-sam .yui-tt-shadow{top:2px;right:-3px;left:-3px;bottom:-3px;background-color:#000;}.yui-skin-sam .yui-tt-shadow-visible{opacity:.12;*filter:alpha(opacity=12);}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/datatable.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/datatable.css new file mode 100644 index 0000000..694960d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/datatable.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-dt{border-bottom:1px solid transparent;}.yui-dt-noop{border-bottom:none;}.yui-dt-hd{display:none;}.yui-dt-scrollable .yui-dt-hd{display:block;}.yui-dt-scrollable .yui-dt-bd thead tr,.yui-dt-scrollable .yui-dt-bd thead th{position:absolute;left:-1500px;}.yui-dt-scrollable tbody{-moz-outline:none;}.yui-dt-draggable{cursor:move;}.yui-dt-coltarget{position:absolute;z-index:999;}.yui-dt-hd{zoom:1;}th.yui-dt-resizeable .yui-dt-liner{position:relative;}.yui-dt-resizer{position:absolute;right:0;bottom:0;height:100%;cursor:e-resize;cursor:col-resize;background:url(transparent.gif);}.yui-dt-resizerproxy{visibility:hidden;position:absolute;z-index:9000;background:url(transparent.gif);}.yui-skin-sam th.yui-dt-hidden .yui-dt-liner,.yui-skin-sam td.yui-dt-hidden .yui-dt-liner{margin:0;padding:0;overflow:hidden;white-space:nowrap;}.yui-dt-scrollable .yui-dt-bd{overflow:auto;}.yui-dt-scrollable .yui-dt-hd{overflow:hidden;position:relative;}.yui-dt-editor{position:absolute;z-index:9000;}.yui-skin-sam .yui-dt table{margin:0;padding:0;font-family:arial;font-size:inherit;border-collapse:separate;*border-collapse:collapse;border-spacing:0;}.yui-skin-sam .yui-dt thead{border-spacing:0;}.yui-skin-sam .yui-dt caption{padding-bottom:1em;text-align:left;}.yui-skin-sam .yui-dt-hd table{border-left:1px solid #7F7F7F;border-top:1px solid #7F7F7F;border-right:1px solid #7F7F7F;}.yui-skin-sam .yui-dt-bd table{border:1px solid #7F7F7F;}.yui-skin-sam .yui-dt th{background:#D8D8DA url(sprite.png) repeat-x 0 0;}.yui-skin-sam .yui-dt th,.yui-skin-sam .yui-dt th a{font-weight:normal;text-decoration:none;color:#000;vertical-align:bottom;}.yui-skin-sam .yui-dt th{margin:0;padding:0;border:none;border-right:1px solid #CBCBCB;}.yui-skin-sam .yui-dt th .yui-dt-liner{white-space:nowrap;}.yui-skin-sam .yui-dt-liner{margin:0;padding:0;padding:4px 10px 4px 10px;}.yui-skin-sam .yui-dt-coltarget{width:5px;background-color:red;}.yui-skin-sam .yui-dt td{margin:0;padding:0;border:none;border-right:1px solid #CBCBCB;text-align:left;}.yui-skin-sam .yui-dt-list td{border-right:none;}.yui-skin-sam .yui-dt-resizer{width:6px;}.yui-skin-sam tbody.yui-dt-msg td{border:none;}.yui-skin-sam .yui-dt-loading{background-color:#FFF;}.yui-skin-sam .yui-dt-empty{background-color:#FFF;}.yui-skin-sam .yui-dt-error{background-color:#FFF;}.yui-skin-sam .yui-dt-scrollable .yui-dt-hd table{border:0px;}.yui-skin-sam .yui-dt-scrollable .yui-dt-bd table{border:0px;}.yui-skin-sam .yui-dt-scrollable .yui-dt-hd{border-left:1px solid #7F7F7F;border-top:1px solid #7F7F7F;border-right:1px solid #7F7F7F;}.yui-skin-sam .yui-dt-scrollable .yui-dt-bd{border-left:1px solid #7F7F7F;border-bottom:1px solid #7F7F7F;border-right:1px solid #7F7F7F;background-color:#FFF;}.yui-skin-sam thead .yui-dt-sortable{cursor:pointer;}.yui-skin-sam th.yui-dt-asc,.yui-skin-sam th.yui-dt-desc{background:url(sprite.png) repeat-x 0 -100px;}.yui-skin-sam th.yui-dt-sortable .yui-dt-label{margin-right:10px;}.yui-skin-sam th.yui-dt-asc .yui-dt-liner{background:url(dt-arrow-up.png) no-repeat right;}.yui-skin-sam th.yui-dt-desc .yui-dt-liner{background:url(dt-arrow-dn.png) no-repeat right;}.yui-dt-editable{cursor:pointer;}.yui-dt-editor{text-align:left;background-color:#F2F2F2;border:1px solid #808080;padding:6px;}.yui-dt-editor label{padding-left:4px;padding-right:6px;}.yui-dt-editor .yui-dt-button{padding-top:6px;text-align:right;}.yui-dt-editor .yui-dt-button button{background:url(sprite.png) repeat-x 0 0;border:1px solid #999;width:4em;height:1.8em;margin-left:6px;}.yui-dt-editor .yui-dt-button button.yui-dt-default{background:url(sprite.png) repeat-x 0 -1400px;background-color:#5584E0;border:1px solid #304369;color:#FFF}.yui-dt-editor .yui-dt-button button:hover{background:url(sprite.png) repeat-x 0 -1300px;color:#000;}.yui-dt-editor .yui-dt-button button:active{background:url(sprite.png) repeat-x 0 -1700px;color:#000;}.yui-skin-sam tr.yui-dt-even{background-color:#FFF;}.yui-skin-sam tr.yui-dt-odd{background-color:#EDF5FF;}.yui-skin-sam tr.yui-dt-even td.yui-dt-asc,.yui-skin-sam tr.yui-dt-even td.yui-dt-desc{background-color:#EDF5FF;}.yui-skin-sam tr.yui-dt-odd td.yui-dt-asc,.yui-skin-sam tr.yui-dt-odd td.yui-dt-desc{background-color:#DBEAFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-even{background-color:#FFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-odd{background-color:#FFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-desc{background-color:#EDF5FF;}.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-desc{background-color:#EDF5FF;}.yui-skin-sam th.yui-dt-highlighted,.yui-skin-sam th.yui-dt-highlighted a{background-color:#B2D2FF;}.yui-skin-sam tr.yui-dt-highlighted,.yui-skin-sam tr.yui-dt-highlighted td.yui-dt-asc,.yui-skin-sam tr.yui-dt-highlighted td.yui-dt-desc,.yui-skin-sam tr.yui-dt-even td.yui-dt-highlighted,.yui-skin-sam tr.yui-dt-odd td.yui-dt-highlighted{cursor:pointer;background-color:#B2D2FF;}.yui-skin-sam .yui-dt-list th.yui-dt-highlighted,.yui-skin-sam .yui-dt-list th.yui-dt-highlighted a{background-color:#B2D2FF;}.yui-skin-sam .yui-dt-list tr.yui-dt-highlighted,.yui-skin-sam .yui-dt-list tr.yui-dt-highlighted td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-highlighted td.yui-dt-desc,.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-highlighted,.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-highlighted{cursor:pointer;background-color:#B2D2FF;}.yui-skin-sam th.yui-dt-selected,.yui-skin-sam th.yui-dt-selected a{background-color:#446CD7;}.yui-skin-sam tr.yui-dt-selected td,.yui-skin-sam tr.yui-dt-selected td.yui-dt-asc,.yui-skin-sam tr.yui-dt-selected td.yui-dt-desc{background-color:#426FD9;color:#FFF;}.yui-skin-sam tr.yui-dt-even td.yui-dt-selected,.yui-skin-sam tr.yui-dt-odd td.yui-dt-selected{background-color:#446CD7;color:#FFF;}.yui-skin-sam .yui-dt-list th.yui-dt-selected,.yui-skin-sam .yui-dt-list th.yui-dt-selected a{background-color:#446CD7;}.yui-skin-sam .yui-dt-list tr.yui-dt-selected td,.yui-skin-sam .yui-dt-list tr.yui-dt-selected td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-selected td.yui-dt-desc{background-color:#426FD9;color:#FFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-selected,.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-selected{background-color:#446CD7;color:#FFF;}.yui-skin-sam .yui-pg-container,.yui-skin-sam .yui-dt-paginator{display:block;margin:6px 0;white-space:nowrap;}.yui-skin-sam .yui-pg-first,.yui-skin-sam .yui-pg-last,.yui-skin-sam .yui-pg-current-page,.yui-skin-sam .yui-dt-paginator .yui-dt-first,.yui-skin-sam .yui-dt-paginator .yui-dt-last,.yui-skin-sam .yui-dt-paginator .yui-dt-selected{padding:2px 6px;}.yui-skin-sam a.yui-pg-first,.yui-skin-sam a.yui-pg-previous,.yui-skin-sam a.yui-pg-next,.yui-skin-sam a.yui-pg-last,.yui-skin-sam a.yui-pg-page,.yui-skin-sam .yui-dt-paginator a.yui-dt-first,.yui-skin-sam .yui-dt-paginator a.yui-dt-last{text-decoration:none;}.yui-skin-sam .yui-dt-paginator .yui-dt-previous,.yui-skin-sam .yui-dt-paginator .yui-dt-next{display:none;}.yui-skin-sam a.yui-pg-page,.yui-skin-sam a.yui-dt-page{border:1px solid #CBCBCB;padding:2px 6px;text-decoration:none;background-color:#fff}.yui-skin-sam .yui-pg-current-page,.yui-skin-sam .yui-dt-paginator .yui-dt-selected{border:1px solid #fff;background-color:#fff;}.yui-skin-sam .yui-pg-pages{margin-left:1ex;margin-right:1ex;}.yui-skin-sam .yui-pg-page{margin-right:1px;margin-left:1px;}.yui-skin-sam .yui-pg-first,.yui-skin-sam .yui-pg-previous{margin-right:3px;}.yui-skin-sam .yui-pg-next,.yui-skin-sam .yui-pg-last{margin-left:3px;}.yui-skin-sam .yui-pg-current,.yui-skin-sam .yui-pg-rpp-options{margin-right:1em;margin-left:1em;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/desc.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/desc.gif new file mode 100644 index 0000000..c114f29 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/desc.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/dt-arrow-dn.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/dt-arrow-dn.png new file mode 100644 index 0000000..85fda0b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/dt-arrow-dn.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/dt-arrow-up.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/dt-arrow-up.png new file mode 100644 index 0000000..1c67431 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/dt-arrow-up.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-knob.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-knob.gif new file mode 100644 index 0000000..03feab3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-knob.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-sprite-active.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-sprite-active.gif new file mode 100644 index 0000000..04ac4e4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-sprite-active.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-sprite.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-sprite.gif new file mode 100644 index 0000000..dd36c3e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor-sprite.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor.css new file mode 100644 index 0000000..48f9c19 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/editor.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-busy{cursor:wait !important;}.yui-toolbar-container fieldset{padding:0;margin:0;border:0;}.yui-toolbar-container legend{display:none;}.yui-toolbar-container .yui-toolbar-subcont{padding:.25em 0;zoom:1;}.yui-toolbar-container-collapsed .yui-toolbar-subcont{display:none;}.yui-toolbar-container .yui-toolbar-subcont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container span.yui-toolbar-draghandle{cursor:move;border-left:1px solid #999;border-right:1px solid #999;overflow:hidden;text-indent:77777px;width:2px;height:20px;display:block;clear:none;float:left;margin:0 0 0 .2em;}.yui-toolbar-container .yui-toolbar-titlebar.draggable{cursor:move;}.yui-toolbar-container .yui-toolbar-titlebar{position:relative;}.yui-toolbar-container .yui-toolbar-titlebar h2{font-weight:bold;letter-spacing:0;border:none;color:#000;margin:0;padding:.2em;}.yui-toolbar-container .yui-toolbar-titlebar h2 a{text-decoration:none;color:#000;cursor:default;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-draghandle{height:40px;}.yui-toolbar-container .yui-toolbar-group{float:left;zoom:1;}.yui-toolbar-container .yui-toolbar-group:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container .yui-toolbar-group h3{font-size:75%;padding:0 0 0 .25em;margin:0;}.yui-toolbar-container span.yui-toolbar-separator{width:2px;height:18px;margin:.2em 0 .2em .1em;display:block;clear:none;float:left;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-separator{height:35px;}.yui-toolbar-container.yui-toolbar-grouped .yui-toolbar-group span.yui-toolbar-separator{height:18px;}.yui-toolbar-container ul li{margin:0;padding:0;list-style-type:none;}.yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-toolbar-container .yui-push-button,.yui-toolbar-container .yui-color-button,.yui-toolbar-container .yui-menu-button{position:relative;cursor:pointer;}.yui-toolbar-container .yui-button .first-child,.yui-toolbar-container .yui-button .first-child a{height:100%;width:100%;overflow:hidden;}.yui-toolbar-container .yui-button-disabled{cursor:default;}.yui-toolbar-container .yui-button-disabled .yui-toolbar-icon{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button-disabled .up,.yui-toolbar-container .yui-button-disabled .down{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button a{overflow:hidden;}.yui-toolbar-container .yui-toolbar-select .first-child a{cursor:pointer;}.yui-toolbar-fontname-arial{font-family:Arial;}.yui-toolbar-fontname-arial-black{font-family:Arial Black;}.yui-toolbar-fontname-comic-sans-ms{font-family:Comic Sans MS;}.yui-toolbar-fontname-courier-new{font-family:Courier New;}.yui-toolbar-fontname-times-new-roman{font-family:Times New Roman;}.yui-toolbar-fontname-verdana{font-family:Verdana;}.yui-toolbar-fontname-impact{font-family:Impact;}.yui-toolbar-fontname-lucida-console{font-family:Lucida Console;}.yui-toolbar-fontname-tahoma{font-family:Tahoma;}.yui-toolbar-fontname-trebuchet-ms{font-family:Trebuchet MS;}.yui-toolbar-container .yui-toolbar-spinbutton{position:relative;}.yui-toolbar-container .yui-toolbar-spinbutton .first-child a{z-index:0;opacity:1;}.yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-toolbar-container .yui-toolbar-spinbutton a.down{position:absolute;display:block right:0;cursor:pointer;z-index:1;padding:0;margin:0;}.yui-toolbar-container .yui-overlay{position:absolute;}.yui-toolbar-container .yui-overlay ul li{margin:0;list-style-type:none;}.yui-toolbar-container{z-index:1;}.yui-editor-container .yui-editor-editable-container{position:relative;z-index:0;width:100%;}.yui-editor-container .yui-editor-masked{background-color:#CCC;}.yui-editor-container iframe{border:0px;padding:0;margin:0;zoom:1;display:block;}.yui-editor-container .yui-editor-editable{padding:0;margin:0;}.yui-editor-container .dompath{font-size:85%;}.yui-editor-panel .hd{text-align:left;position:relative;}.yui-editor-panel .hd h3{font-weight:bold;padding:0.25em 0pt 0.25em 0.25em;margin:0;}.yui-editor-panel .bd{width:100%;zoom:1;position:relative;}.yui-editor-panel .bd div.yui-editor-body-cont{padding:.25em .1em;zoom:1;}.yui-editor-panel .bd .gecko form{overflow:auto;}.yui-editor-panel .bd div.yui-editor-body-cont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-editor-panel .ft{text-align:right;width:99%;float:left;clear:both;}.yui-editor-panel .ft span.tip{display:block;position:relative;padding:.5em .5em .5em 23px;text-align:left;zoom:1;}.yui-editor-panel label{clear:both;float:left;padding:0;width:100%;text-align:left;zoom:1;}.yui-editor-panel .gecko label{overflow:auto;}.yui-editor-panel label strong{float:left;width:6em;}.yui-editor-panel .removeLink{width:80%;text-align:right;}.yui-editor-panel label input{margin-left:.25em;float:left;}.yui-editor-panel .yui-toolbar-group-padding{}.yui-editor-panel .yui-toolbar-group-border{}.yui-editor-panel .yui-toolbar-group-textflow{}.yui-editor-panel .height-width{float:left;}.yui-editor-panel .height-width h3{}.yui-editor-panel .height-width span{font-style:italic;display:block;float:left;overflow:visible;}.yui-editor-panel .height-width span.info{font-size:70%;margin-top:3px;}.yui-editor-panel .yui-toolbar-bordersize,.yui-editor-panel .yui-toolbar-bordertype{font-size:75%;}.yui-editor-panel .yui-toolbar-container span.yui-toolbar-separator{border:none;}.yui-editor-panel .yui-toolbar-bordersize span a span,.yui-editor-panel .yui-toolbar-bordertype span a span{display:block;height:8px;left:4px;position:absolute;top:3px;*top:-5px;width:24px;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-solid{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dotted{border-bottom:1px dotted black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dashed{border-bottom:1px dashed black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-0{*top:0px;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-1{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-2{border-bottom:2px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-3{top:2px;*top:-5px;border-bottom:3px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-4{top:1px;*top:-5px;border-bottom:4px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-5{top:1px;*top:-5px;border-bottom:5px solid black;}.yui-toolbar-container .yui-toolbar-bordersize-menu,.yui-toolbar-container .yui-toolbar-bordertype-menu{width:95px !important;}.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel,.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel:hover{margin:0px 3px 7px 17px;}.yui-toolbar-bordersize-menu .yuimenuitemlabel .checkedindicator,.yui-toolbar-bordertype-menu .yuimenuitemlabel .checkedindicator{position:absolute;left:-12px;*top:14px;*left:0px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-1 a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-2 a{border-bottom:2px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-3 a{border-bottom:3px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-4 a{border-bottom:4px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-5 a{border-bottom:5px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-solid a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dashed a{border-bottom:1px dashed black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dotted a{border-bottom:1px dotted black;height:14px;}h2.yui-editor-skipheader,h3.yui-editor-skipheader{height:0;margin:0;padding:0;border:none;width:0;overflow:hidden;position:absolute;}.yui-toolbar-colors{width:133px;zoom:1;display:none;z-index:100;overflow:hidden;}.yui-toolbar-colors:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors a{height:9px;width:9px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0;cursor:pointer;border:1px solid #F6F7EE;}.yui-toolbar-colors a:hover{border:1px solid black;}.yui-color-button-menu{overflow:visible;background-color:transparent;}.yui-toolbar-colors span{position:relative;display:block;padding:3px;overflow:hidden;float:left;width:100%;zoom:1;}.yui-toolbar-colors span:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors span em{height:35px;width:30px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0.75px;border:1px solid black;}.yui-toolbar-colors span strong{font-weight:normal;padding-left:3px;display:block;font-size:85%;float:left;width:65%;}.yui-skin-sam .yui-editor-container{border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container{zoom:1;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar{background:url(sprite.png) repeat-x 0 -200px;position:relative;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar h2{color:#000000;font-weight:bold;margin:0;padding:0.3em 1em;font-size:100%;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-group h3{color:#808080;font-size:75%;margin:1em 0 0;padding-bottom:0;padding-left:0.25em;text-align:left;}.yui-toolbar-container span.yui-toolbar-separator{border:none;text-indent:33px;overflow:hidden;margin:0 .25em;}.yui-skin-sam .yui-toolbar-container{background-color:#F2F2F2;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subcont{padding:0 1em 0.35em;border-bottom:1px solid #808080;}.yui-skin-sam .yui-toolbar-container-collapsed .yui-toolbar-titlebar{border-bottom:1px solid #808080;}.yui-skin-sam .yui-editor-container .visible .yui-menu-shadow,.yui-skin-sam .yui-editor-panel .visible .yui-menu-shadow{display:none;}.yui-skin-sam .yui-editor-container ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-container ul li{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-toolbar-group ul li.yui-toolbar-groupitem{float:left;}.yui-skin-sam .yui-editor-container .dompath{background-color:#F2F2F2;border-top:1px solid #808080;color:#999;text-align:left;padding:0.25em;}.yui-skin-sam .yui-toolbar-container .collapse{background:url(sprite.png) no-repeat 0 -400px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar span.collapse{cursor:pointer;position:absolute;top:4px;right:2px;display:block;overflow:hidden;height:15px;width:15px;text-indent:9999px;}.yui-skin-sam .yui-toolbar-container .yui-push-button,.yui-skin-sam .yui-toolbar-container .yui-color-button,.yui-skin-sam .yui-toolbar-container .yui-menu-button{background:url(sprite.png) repeat-x 0 0;position:relative;display:block;height:22px;width:30px;margin:0;border-color:#808080;border-style:solid;border-width:1px 0;}.yui-skin-sam .yui-toolbar-container .yui-push-button a,.yui-skin-sam .yui-toolbar-container .yui-color-button a,.yui-skin-sam .yui-toolbar-container .yui-menu-button a{padding-left:35px;height:20px;text-decoration:none;font-size:93%;line-height:2;display:block;color:#000000;overflow:hidden;}.yui-skin-sam .yui-toolbar-container .yui-push-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button .first-child{border-color:#808080;border-style:solid;border-width:0 1px;margin:0 -1px;display:block;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled .first-child{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled a{color:#A6A6A6;cursor:default;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-button .first-child{*left:0px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-fontname{width:135px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-heading{width:92px;}.yui-skin-sam .yui-toolbar-container .yui-button-hover{background:url(sprite.png) repeat-x 0 -1300px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-button-selected{background:url(sprite.png) repeat-x 0 -1700px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels .yui-toolbar-group{margin-top:.75em;}.yui-skin-sam .yui-toolbar-container .yui-push-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-color-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-menu-button span.yui-toolbar-icon{display:block;position:absolute;top:2px;height:18px;width:18px;overflow:hidden;background:url(editor-sprite.gif) no-repeat 30px 30px;}.yui-skin-sam .yui-toolbar-container .yui-button-selected span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-button-hover span.yui-toolbar-icon{background-image:url(editor-sprite-active.gif);}.yui-skin-sam .yui-toolbar-container .visible .yuimenuitemlabel{cursor:pointer;color:#000;*position:relative;}.yui-skin-sam .yui-toolbar-container .yui-button-menu{background-color:#fff;}.yui-skin-sam div.yuimenu li.selected{background-color:#B3D4FF;}.yui-skin-sam div.yuimenu li.selected a.selected{color:#000;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bold span.yui-toolbar-icon{background-position:0 0;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-strikethrough span.yui-toolbar-icon{background-position:0 -108px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-italic span.yui-toolbar-icon{background-position:0 -36px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-underline span.yui-toolbar-icon{background-position:0 -72px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subscript span.yui-toolbar-icon{background-position:0 -180px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-superscript span.yui-toolbar-icon{background-position:0 -144px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-forecolor span.yui-toolbar-icon{background-position:0 -216px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-backcolor span.yui-toolbar-icon{background-position:0 -288px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyleft span.yui-toolbar-icon{background-position:0 -324px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifycenter span.yui-toolbar-icon{background-position:0 -360px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyright span.yui-toolbar-icon{background-position:0 -396px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyfull span.yui-toolbar-icon{background-position:0 -432px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-indent span.yui-toolbar-icon{background-position:0 -720px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-outdent span.yui-toolbar-icon{background-position:0 -684px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-createlink span.yui-toolbar-icon{background-position:0 -792px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertimage span.yui-toolbar-icon{background-position:1px -756px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-left span.yui-toolbar-icon{background-position:0 -972px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-right span.yui-toolbar-icon{background-position:0 -936px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-inline span.yui-toolbar-icon{background-position:0 -900px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-block span.yui-toolbar-icon{background-position:0 -864px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bordercolor span.yui-toolbar-icon{background-position:0 -252px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-removeformat span.yui-toolbar-icon{background-position:0 -1080px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-hiddenelements span.yui-toolbar-icon{background-position:0 -1044px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertunorderedlist span.yui-toolbar-icon{background-position:0 -468px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertorderedlist span.yui-toolbar-icon{background-position:0 -504px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child{width:35px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child a{padding-left:2px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton span.yui-toolbar-icon{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{right:2px;background:url(editor-sprite.gif) no-repeat 0 -1222px;overflow:hidden;height:6px;width:7px;min-height:0;padding:0;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up{top:2px;background-position:0 -1222px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{bottom:2px;background-position:0 -1187px;}.yui-skin-sam .yui-toolbar-container select{height:22px;border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select .first-child a{padding-left:5px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select span.yui-toolbar-icon{background:url( editor-sprite.gif ) no-repeat 0 -1144px;overflow:hidden;right:-2px;top:0px;height:20px;}.yui-skin-sam .yui-editor-panel .yui-color-button-menu .bd{background-color:transparent;border:none;width:135px;}.yui-skin-sam .yui-color-button-menu .yui-toolbar-colors{border:1px solid #808080;}.yui-skin-sam .yui-editor-panel{padding:0;margin:0;border:none;background-color:transparent;overflow:visible;}.yui-skin-sam .yui-editor-panel .hd{margin:10px 0 0;padding:0;border:none;}.yui-skin-sam .yui-editor-panel .hd h3{color:#000;border:1px solid #808080;background:url(sprite.png) repeat-x 0 -200px;width:99%;position:relative;margin:0;padding:3px 0 0 0;font-size:93%;text-indent:5px;height:20px;}.yui-skin-sam .yui-editor-panel .bd{background-color:#F2F2F2;border-left:1px solid #808080;border-right:1px solid #808080;width:99%;margin:0;padding:0;overflow:visible;}.yui-skin-sam .yui-editor-panel ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-panel ul li{margin:0;padding:0;}.yui-skin-sam .yui-editor-panel .yuimenu{}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .yui-toolbar-subcont{padding:0;border:none;margin-top:0.35em;}.yui-skin-sam .yui-editor-panel .yui-toolbar-bordersize,.yui-skin-sam .yui-editor-panel .yui-toolbar-bordertype{width:50px;}.yui-skin-sam .yui-editor-panel label{display:block;float:none;padding:4px 0;margin-bottom:7px;}.yui-skin-sam .yui-editor-panel label strong{font-weight:normal;font-size:93%;text-align:right;padding-top:2px;}.yui-skin-sam .yui-editor-panel label input{width:75%;}.yui-skin-sam .yui-editor-panel .createlink_target,.yui-skin-sam .yui-editor-panel .insertimage_target{width:auto;margin-right:5px;}.yui-skin-sam .yui-editor-panel .removeLink{width:98%;}.yui-skin-sam .yui-editor-panel label input.warning{background-color:#FFEE69;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group h3{color:#000;float:left;font-weight:normal;font-size:93%;margin:5px 0 0 0;padding:0 3px 0 0;text-align:right;}.yui-skin-sam .yui-editor-panel .height-width h3{margin:3px 0 0 10px;}.yui-skin-sam .yui-editor-panel .height-width{margin:3px 0 0 35px;*margin-left:14px;width:42%;*width:44%;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-border{width:190px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-border{width:210px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding{width:203px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-padding{width:172px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding h3{margin-left:25px;*margin-left:12px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-textflow{width:182px;}.yui-skin-sam .yui-editor-panel .hd{background:none;}.yui-skin-sam .yui-editor-panel .ft{background-color:#F2F2F2;border:1px solid #808080;border-top:none;padding:0;margin:0 0 2px 0;}.yui-skin-sam .yui-editor-panel .hd span.close{background:url(sprite.png) no-repeat 0 -300px;cursor:pointer;display:block;height:16px;overflow:hidden;position:absolute;right:5px;text-indent:500px;top:2px;width:26px;}.yui-skin-sam .yui-editor-panel .ft span.tip{background-color:#EDF5FF;border-top:1px solid #808080;font-size:85%;}.yui-skin-sam .yui-editor-panel .ft span.tip strong{display:block;float:left;margin:0 2px 8px 0;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon{background:url( editor-sprite.gif ) no-repeat 0 -1260px;display:block;height:20px;left:2px;position:absolute;top:8px;width:20px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-info{background-position:2px -1260px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-warn{background-position:2px -1296px;}.yui-skin-sam .yui-editor-panel .hd span.knob{position:absolute;height:10px;width:28px;top:-10px;left:25px;text-indent:9999px;overflow:hidden;background:url( editor-knob.gif ) no-repeat 0 0;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container{float:left;width:100%;background-image:none;border:none;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .bd{background-color:#ffffff;}.yui-editor-blankimage{background-image:url( blankimage.png );}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/fonts.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/fonts.css new file mode 100644 index 0000000..9d1bbd2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/fonts.css
@@ -0,0 +1,16 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/** + * Percents could work for IE, but for backCompat purposes, we are using keywords. + * x-small is for IE6/7 quirks mode. + */ +body {font:13px/1.231 arial,helvetica,clean,sans-serif;*font-size:small;*font:x-small;} +table {font-size:inherit;font:100%;} +/** + * Bump up IE to get to 13px equivalent + */ +pre,code,kbd,samp,tt {font-family:monospace;*font-size:108%;line-height:100%;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/header_background.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/header_background.png new file mode 100644 index 0000000..3ef7909 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/header_background.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/hue_bg.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/hue_bg.png new file mode 100644 index 0000000..d9bcdeb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/hue_bg.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/imagecropper.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/imagecropper.css new file mode 100644 index 0000000..508b085 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/imagecropper.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-crop{position:relative;}.yui-crop .yui-crop-mask{position:absolute;top:0;left:0;height:100%;width:100%;}.yui-crop .yui-resize{position:absolute;top:10px;left:10px;}.yui-crop .yui-crop-resize-mask{position:absolute;top:0;left:0;height:100%;width:100%;background-position:-10px -10px;overflow:hidden;}.yui-skin-sam .yui-crop .yui-crop-mask{background-color:#000;opacity:.5;filter:alpha(opacity=50);}.yui-skin-sam .yui-crop .yui-resize{border:1px dashed #fff;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/layout.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/layout.css new file mode 100644 index 0000000..c774f4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/layout.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-layout-loading{visibility:hidden;}body.yui-layout{overflow:hidden;position:relative;padding:0;margin:0;}.yui-layout-doc{position:relative;}.yui-layout-unit{height:50px;width:50px;padding:0;margin:0;float:none;z-index:0;overflow:hidden;}.yui-layout-unit-top{position:absolute;top:0;left:0;width:100%;}.yui-layout-unit-left{position:absolute;top:0;left:0;}.yui-layout-unit-right{position:absolute;top:0;right:0;}.yui-layout-unit-bottom{position:absolute;bottom:0;left:0;width:100%;}.yui-layout-unit-center{position:absolute;top:0;left:0;width:100%;}.yui-layout div.yui-layout-hd{position:absolute;top:0;left:0;zoom:1;width:100%;overflow:hidden;}.yui-layout div.yui-layout-bd{position:absolute;top:0;left:0;zoom:1;width:100%;overflow:hidden;}.yui-layout .yui-layout-scroll div.yui-layout-bd{overflow:auto;}.yui-layout div.yui-layout-ft{position:absolute;bottom:0;left:0;width:100%;zoom:1;overflow:hidden;}.yui-layout .yui-layout-unit div.yui-layout-hd h2{text-align:left;}.yui-layout .yui-layout-unit div.yui-layout-hd .collapse{cursor:pointer;height:13px;position:absolute;right:2px;top:2px;width:17px;font-size:0;}.yui-layout .yui-layout-unit div.yui-layout-hd .close{cursor:pointer;height:13px;position:absolute;right:2px;top:2px;width:17px;font-size:0;}.yui-layout .yui-layout-unit div.yui-layout-hd .collapse-close{right:25px;}.yui-layout .yui-layout-clip{position:absolute;height:20px;background-color:#c0c0c0;display:none;}.yui-layout .yui-layout-clip .collapse{cursor:pointer;height:13px;position:absolute;right:2px;top:2px;width:17px;font-size:0px;}.yui-layout .yui-layout-wrap{height:100%;width:100%;position:absolute;left:0;}.yui-layout .yui-layout-unit .yui-content{overflow:hidden;}.yui-layout .yui-layout-unit .yui-layout-scroll{overflow:visible;}.yui-skin-sam .yui-layout .yui-resize-proxy{border:none;font-size:0;margin:0;padding:0;}.yui-skin-sam .yui-layout .yui-resize-resizing .yui-resize-handle{opacity:0;filter:alpha(opacity=0);}.yui-skin-sam .yui-layout .yui-resize-proxy div{position:absolute;border:1px solid #808080;background-color:#EDF5FF;}.yui-skin-sam .yui-layout .yui-resize .yui-resize-handle-active{background-color:#EDF5FF;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-l{width:5px;height:100%;top:0;left:0;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-r{width:5px;top:0;right:0;height:100%;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-b{width:100%;bottom:0;left:0;height:5px;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-t{width:100%;top:0;left:0;height:5px;}.yui-skin-sam .yui-layout .yui-layout-unit-left div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -160px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-left .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -140px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit-right div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -200px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-right .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -120px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit-top div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -220px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-top .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -240px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit-bottom div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -260px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-bottom .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -180px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-hd .close{background:transparent url(layout_sprite.png) no-repeat -20px -100px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-hd{background:url(sprite.png) repeat-x 0 -1400px;border:1px solid #808080;}.yui-skin-sam .yui-layout{background-color:#EDF5FF;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-hd h2{font-weight:bold;color:#fff;padding:3px;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-bd{border:1px solid #808080;border-bottom:none;border-top:none;*border-bottom-width:0;*border-top-width:0;background-color:#f2f2f2;text-align:left;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-bd-noft{border-bottom:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-bd-nohd{border-top:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip{position:absolute;height:20px;background-color:#EDF5FF;display:none;border:1px solid #808080;}.yui-skin-sam .yui-layout div.yui-layout-ft{border:1px solid #808080;border-top:none;*border-top-width:0;background-color:#f2f2f2;}.yui-skin-sam .yui-layout-unit .yui-resize-handle{background-color:transparent;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-r{right:0;top:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-l{left:0;top:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-b{right:0;bottom:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-t{right:0;top:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-r .yui-layout-resize-knob,.yui-skin-sam .yui-layout-unit .yui-resize-handle-l .yui-layout-resize-knob{position:absolute;height:16px;width:6px;top:45%;left:0px;background:transparent url(layout_sprite.png) no-repeat 0 -5px;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-t .yui-layout-resize-knob,.yui-skin-sam .yui-layout-unit .yui-resize-handle-b .yui-layout-resize-knob{position:absolute;height:6px;width:16px;left:45%;background:transparent url(layout_sprite.png) no-repeat -20px 0;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/layout_sprite.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/layout_sprite.png new file mode 100644 index 0000000..d6fce3c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/layout_sprite.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/logger.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/logger.css new file mode 100644 index 0000000..f561f43 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/logger.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-skin-sam .yui-log{padding:1em;width:31em;background-color:#AAA;color:#000;border:1px solid black;font-family:monospace;font-size:77%;text-align:left;z-index:9000;}.yui-skin-sam .yui-log-container{position:absolute;top:1em;right:1em;}.yui-skin-sam .yui-log input{margin:0;padding:0;font-family:arial;font-size:100%;font-weight:normal;}.yui-skin-sam .yui-log .yui-log-btns{position:relative;float:right;bottom:.25em;}.yui-skin-sam .yui-log .yui-log-hd{margin-top:1em;padding:.5em;background-color:#575757;}.yui-skin-sam .yui-log .yui-log-hd h4{margin:0;padding:0;font-size:108%;font-weight:bold;color:#FFF;}.yui-skin-sam .yui-log .yui-log-bd{width:100%;height:20em;background-color:#FFF;border:1px solid gray;overflow:auto;}.yui-skin-sam .yui-log p{margin:1px;padding:.1em;}.yui-skin-sam .yui-log pre{margin:0;padding:0;}.yui-skin-sam .yui-log pre.yui-log-verbose{white-space:pre-wrap;white-space:-moz-pre-wrap !important;white-space:-pre-wrap;white-space:-o-pre-wrap;word-wrap:break-word;}.yui-skin-sam .yui-log .yui-log-ft{margin-top:.5em;}.yui-skin-sam .yui-log .yui-log-ft .yui-log-categoryfilters{}.yui-skin-sam .yui-log .yui-log-ft .yui-log-sourcefilters{width:100%;border-top:1px solid #575757;margin-top:.75em;padding-top:.75em;}.yui-skin-sam .yui-log .yui-log-filtergrp{margin-right:.5em;}.yui-skin-sam .yui-log .info{background-color:#A7CC25;}.yui-skin-sam .yui-log .warn{background-color:#F58516;}.yui-skin-sam .yui-log .error{background-color:#E32F0B;}.yui-skin-sam .yui-log .time{background-color:#A6C9D7;}.yui-skin-sam .yui-log .window{background-color:#F2E886;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu-button-arrow-disabled.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu-button-arrow-disabled.png new file mode 100644 index 0000000..8cef2ab --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu-button-arrow-disabled.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu-button-arrow.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu-button-arrow.png new file mode 100644 index 0000000..f03dfee --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu-button-arrow.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu.css new file mode 100644 index 0000000..3a3512d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menu.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yuimenubar{visibility:visible;position:static;}.yuimenu .yuimenu,.yuimenubar .yuimenu{visibility:hidden;position:absolute;top:-10000px;left:-10000px;}.yuimenubar li,.yuimenu li{list-style-type:none;}.yuimenubar ul,.yuimenu ul,.yuimenubar li,.yuimenu li,.yuimenu h6,.yuimenubar h6{margin:0;padding:0;}.yuimenuitemlabel,.yuimenubaritemlabel{text-align:left;white-space:nowrap;}.yuimenubar ul{*zoom:1;}.yuimenubar .yuimenu ul{*zoom:normal;}.yuimenubar>.bd>ul:after{content:".";display:block;clear:both;visibility:hidden;height:0;line-height:0;}.yuimenubaritem{float:left;}.yuimenubaritemlabel,.yuimenuitemlabel{display:block;}.yuimenuitemlabel .helptext{font-style:normal;display:block;margin:-1em 0 0 10em;}.yui-menu-shadow{position:absolute;visibility:hidden;z-index:-1;}.yui-menu-shadow-visible{top:2px;right:-3px;left:-3px;bottom:-3px;visibility:visible;}.hide-scrollbars *{overflow:hidden;}.hide-scrollbars select{display:none;}.yuimenu.show-scrollbars,.yuimenubar.show-scrollbars{overflow:visible;}.yuimenu.hide-scrollbars .yui-menu-shadow,.yuimenubar.hide-scrollbars .yui-menu-shadow{overflow:hidden;}.yuimenu.show-scrollbars .yui-menu-shadow,.yuimenubar.show-scrollbars .yui-menu-shadow{overflow:auto;}.yui-skin-sam .yuimenubar{font-size:93%;line-height:2;*line-height:1.9;border:solid 1px #808080;background:url(sprite.png) repeat-x 0 0;}.yui-skin-sam .yuimenubarnav .yuimenubaritem{border-right:solid 1px #ccc;}.yui-skin-sam .yuimenubaritemlabel{padding:0 10px;color:#000;text-decoration:none;cursor:default;border-style:solid;border-color:#808080;border-width:1px 0;*position:relative;margin:-1px 0;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel{padding-right:20px;*display:inline-block;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel-hassubmenu{background:url(menubaritem_submenuindicator.png) right center no-repeat;}.yui-skin-sam .yuimenubaritem-selected{background:url(sprite.png) repeat-x 0 -1700px;}.yui-skin-sam .yuimenubaritemlabel-selected{border-color:#7D98B8;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel-selected{border-left-width:1px;margin-left:-1px;*left:-1px;}.yui-skin-sam .yuimenubaritemlabel-disabled{cursor:default;color:#A6A6A6;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel-hassubmenu-disabled{background-image:url(menubaritem_submenuindicator_disabled.png);}.yui-skin-sam .yuimenu{font-size:93%;line-height:1.5;*line-height:1.45;}.yui-skin-sam .yuimenubar .yuimenu,.yui-skin-sam .yuimenu .yuimenu{font-size:100%;}.yui-skin-sam .yuimenu .bd{border:solid 1px #808080;background-color:#fff;}.yui-skin-sam .yuimenu ul{padding:3px 0;border-width:1px 0 0 0;border-color:#ccc;border-style:solid;}.yui-skin-sam .yuimenu ul.first-of-type{border-width:0;}.yui-skin-sam .yuimenu h6{font-weight:bold;border-style:solid;border-color:#ccc;border-width:1px 0 0 0;color:#a4a4a4;padding:3px 10px 0 10px;}.yui-skin-sam .yuimenu ul.hastitle,.yui-skin-sam .yuimenu h6.first-of-type{border-width:0;}.yui-skin-sam .yuimenu .yui-menu-body-scrolled{border-color:#ccc #808080;overflow:hidden;}.yui-skin-sam .yuimenu .topscrollbar,.yui-skin-sam .yuimenu .bottomscrollbar{height:16px;border:solid 1px #808080;background:#fff url(sprite.png) no-repeat 0 0;}.yui-skin-sam .yuimenu .topscrollbar{border-bottom-width:0;background-position:center -950px;}.yui-skin-sam .yuimenu .topscrollbar_disabled{background-position:center -975px;}.yui-skin-sam .yuimenu .bottomscrollbar{border-top-width:0;background-position:center -850px;}.yui-skin-sam .yuimenu .bottomscrollbar_disabled{background-position:center -875px;}.yui-skin-sam .yuimenuitem{_border-bottom:solid 1px #fff;}.yui-skin-sam .yuimenuitemlabel{padding:0 20px;color:#000;text-decoration:none;cursor:default;}.yui-skin-sam .yuimenuitemlabel .helptext{margin-top:-1.5em;*margin-top:-1.45em;}.yui-skin-sam .yuimenuitem-hassubmenu{background-image:url(menuitem_submenuindicator.png);background-position:right center;background-repeat:no-repeat;}.yui-skin-sam .yuimenuitem-checked{background-image:url(menuitem_checkbox.png);background-position:left center;background-repeat:no-repeat;}.yui-skin-sam .yui-menu-shadow-visible{background-color:#000;opacity:.12;*filter:alpha(opacity=12);}.yui-skin-sam .yuimenuitem-selected{background-color:#B3D4FF;}.yui-skin-sam .yuimenuitemlabel-disabled{cursor:default;color:#A6A6A6;}.yui-skin-sam .yuimenuitem-hassubmenu-disabled{background-image:url(menuitem_submenuindicator_disabled.png);}.yui-skin-sam .yuimenuitem-checked-disabled{background-image:url(menuitem_checkbox_disabled.png);}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menubaritem_submenuindicator.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menubaritem_submenuindicator.png new file mode 100644 index 0000000..030941c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menubaritem_submenuindicator.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menubaritem_submenuindicator_disabled.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menubaritem_submenuindicator_disabled.png new file mode 100644 index 0000000..6c16122 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menubaritem_submenuindicator_disabled.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_checkbox.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_checkbox.png new file mode 100644 index 0000000..1437a4f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_checkbox.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_checkbox_disabled.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_checkbox_disabled.png new file mode 100644 index 0000000..5d5b998 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_checkbox_disabled.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_submenuindicator.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_submenuindicator.png new file mode 100644 index 0000000..ea4f660 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_submenuindicator.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_submenuindicator_disabled.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_submenuindicator_disabled.png new file mode 100644 index 0000000..427d60a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/menuitem_submenuindicator_disabled.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/picker_mask.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/picker_mask.png new file mode 100644 index 0000000..f8d9193 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/picker_mask.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/profilerviewer.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/profilerviewer.css new file mode 100644 index 0000000..c2c9f35 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/profilerviewer.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-skin-sam .yui-pv{background-color:#4a4a4a;font:arial;position:relative;width:99%;z-index:1000;margin-bottom:1em;overflow:hidden;}.yui-skin-sam .yui-pv .hd{background:url(header_background.png) repeat-x;min-height:30px;overflow:hidden;zoom:1;padding:2px 0;}.yui-skin-sam .yui-pv .hd h4{padding:8px 10px;margin:0;font:bold 14px arial;color:#fff;}.yui-skin-sam .yui-pv .hd a{background:#3f6bc3;font:bold 11px arial;color:#fff;padding:4px;margin:3px 10px 0 0;border:1px solid #3f567d;cursor:pointer;display:block;float:right;}.yui-skin-sam .yui-pv .hd span{display:none;}.yui-skin-sam .yui-pv .hd span.yui-pv-busy{height:18px;width:18px;background:url(wait.gif) no-repeat;overflow:hidden;display:block;float:right;margin:4px 10px 0 0;}.yui-skin-sam .yui-pv .hd:after,.yui-pv .bd:after,.yui-skin-sam .yui-pv-chartlegend dl:after{content:'.';visibility:hidden;clear:left;height:0;display:block;}.yui-skin-sam .yui-pv .bd{position:relative;zoom:1;overflow-x:auto;overflow-y:hidden;}.yui-skin-sam .yui-pv .yui-pv-table{padding:0 10px;margin:5px 0 10px 0;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-bd td{color:#eeee5c;font:12px arial;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-odd{background:#929292;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-even{background:#58637a;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-even td.yui-dt-asc,.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-even td.yui-dt-desc{background:#384970;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-odd td.yui-dt-asc,.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-odd td.yui-dt-desc{background:#6F6E6E;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th{background-image:none;background:#2E2D2D;}.yui-skin-sam .yui-pv th.yui-dt-asc .yui-dt-liner{background:transparent url(asc.gif) no-repeat scroll right center;}.yui-skin-sam .yui-pv th.yui-dt-desc .yui-dt-liner{background:transparent url(desc.gif) no-repeat scroll right center;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th a{color:#fff;font:bold 12px arial;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th.yui-dt-asc,.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th.yui-dt-desc{background:#333;}.yui-skin-sam .yui-pv-chartcontainer{padding:0 10px;}.yui-skin-sam .yui-pv-chart{height:250px;clear:right;margin:5px 0 0 0;color:#fff;}.yui-skin-sam .yui-pv-chartlegend div{float:right;margin:0 0 0 10px;_width:250px;}.yui-skin-sam .yui-pv-chartlegend dl{border:1px solid #999;padding:.2em 0 .2em .5em;zoom:1;margin:5px 0;}.yui-skin-sam .yui-pv-chartlegend dt{float:left;display:block;height:.7em;width:.7em;padding:0;}.yui-skin-sam .yui-pv-chartlegend dd{float:left;display:block;color:#fff;margin:0 1em 0 .5em;padding:0;font:11px arial;}.yui-skin-sam .yui-pv-minimized{height:35px;}.yui-skin-sam .yui-pv-minimized .bd{top:-3000px;}.yui-skin-sam .yui-pv-minimized .hd a.yui-pv-refresh{display:none;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/resize.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/resize.css new file mode 100644 index 0000000..3541cb0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/resize.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-resize{position:relative;zoom:1;z-index:0;}.yui-resize-wrap{zoom:1;}.yui-draggable{cursor:move;}.yui-resize .yui-resize-handle{position:absolute;z-index:1;font-size:0;margin:0;padding:0;zoom:1;height:1px;width:1px;}.yui-resize .yui-resize-handle-br{height:5px;width:5px;bottom:0;right:0;cursor:se-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-bl{height:5px;width:5px;bottom:0;left:0;cursor:sw-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-tl{height:5px;width:5px;top:0;left:0;cursor:nw-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-tr{height:5px;width:5px;top:0;right:0;cursor:ne-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-r{width:5px;height:100%;top:0;right:0;cursor:e-resize;zoom:1;}.yui-resize .yui-resize-handle-l{height:100%;width:5px;top:0;left:0;cursor:w-resize;zoom:1;}.yui-resize .yui-resize-handle-b{width:100%;height:5px;bottom:0;right:0;cursor:s-resize;zoom:1;}.yui-resize .yui-resize-handle-t{width:100%;height:5px;top:0;right:0;cursor:n-resize;zoom:1;}.yui-resize-proxy{position:absolute;border:1px dashed #000;visibility:hidden;z-index:1000;}.yui-resize-hover .yui-resize-handle,.yui-resize-hidden .yui-resize-handle{opacity:0;filter:alpha(opacity=0);}.yui-resize-ghost{opacity:.5;filter:alpha(opacity=50);}.yui-resize-knob .yui-resize-handle{height:6px;width:6px;}.yui-resize-knob .yui-resize-handle-tr{right:-3px;top:-3px;}.yui-resize-knob .yui-resize-handle-tl{left:-3px;top:-3px;}.yui-resize-knob .yui-resize-handle-bl{left:-3px;bottom:-3px;}.yui-resize-knob .yui-resize-handle-br{right:-3px;bottom:-3px;}.yui-resize-knob .yui-resize-handle-t{left:45%;top:-3px;}.yui-resize-knob .yui-resize-handle-r{right:-3px;top:45%;}.yui-resize-knob .yui-resize-handle-l{left:-3px;top:45%;}.yui-resize-knob .yui-resize-handle-b{left:45%;bottom:-3px;}.yui-resize-status{position:absolute;top:-999px;left:-999px;padding:2px;font-size:80%;display:none;zoom:1;z-index:9999;}.yui-resize-status strong,.yui-resize-status em{font-weight:normal;font-style:normal;padding:1px;zoom:1;}.yui-skin-sam .yui-resize .yui-resize-handle{background-color:#F2F2F2;}.yui-skin-sam .yui-resize .yui-resize-handle-active{background-color:#7D98B8;zoom:1;}.yui-skin-sam .yui-resize .yui-resize-handle-l,.yui-skin-sam .yui-resize .yui-resize-handle-r,.yui-skin-sam .yui-resize .yui-resize-handle-l-active,.yui-skin-sam .yui-resize .yui-resize-handle-r-active{height:100%;}.yui-skin-sam .yui-resize-knob .yui-resize-handle{border:1px solid #808080;}.yui-skin-sam .yui-resize-hover .yui-resize-handle-active{opacity:1;filter:alpha(opacity=100);}.yui-skin-sam .yui-resize-proxy{border:1px dashed #426FD9;}.yui-skin-sam .yui-resize-status{border:1px solid #A6982B;border-top:1px solid #D4C237;background-color:#FFEE69}.yui-skin-sam .yui-resize-status strong,.yui-skin-sam .yui-resize-status em{float:left;display:block;clear:both;padding:1px;text-align:center;}.yui-skin-sam .yui-resize .yui-resize-handle-inner-r,.yui-skin-sam .yui-resize .yui-resize-handle-inner-l{background:transparent url( layout_sprite.png) no-repeat 0 -5px;height:16px;width:5px;position:absolute;top:45%;}.yui-skin-sam .yui-resize .yui-resize-handle-inner-t,.yui-skin-sam .yui-resize .yui-resize-handle-inner-b{background:transparent url(layout_sprite.png) no-repeat -20px 0;height:5px;width:16px;position:absolute;left:50%;}.yui-skin-sam .yui-resize .yui-resize-handle-br{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -62px;}.yui-skin-sam .yui-resize .yui-resize-handle-tr{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -42px;}.yui-skin-sam .yui-resize .yui-resize-handle-tl{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -82px;}.yui-skin-sam .yui-resize .yui-resize-handle-bl{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -23px;}.yui-skin-sam .yui-resize-knob .yui-resize-handle-t,.yui-skin-sam .yui-resize-knob .yui-resize-handle-r,.yui-skin-sam .yui-resize-knob .yui-resize-handle-b,.yui-skin-sam .yui-resize-knob .yui-resize-handle-l,.yui-skin-sam .yui-resize-knob .yui-resize-handle-tl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-tr,.yui-skin-sam .yui-resize-knob .yui-resize-handle-bl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-br,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-t,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-r,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-b,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-l,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-tl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-tr,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-bl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-br{background-image:none;}.yui-skin-sam .yui-resize-knob .yui-resize-handle-l,.yui-skin-sam .yui-resize-knob .yui-resize-handle-r,.yui-skin-sam .yui-resize-knob .yui-resize-handle-l-active,.yui-skin-sam .yui-resize-knob .yui-resize-handle-r-active{height:6px;width:6px;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/simpleeditor.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/simpleeditor.css new file mode 100644 index 0000000..48f9c19 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/simpleeditor.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-busy{cursor:wait !important;}.yui-toolbar-container fieldset{padding:0;margin:0;border:0;}.yui-toolbar-container legend{display:none;}.yui-toolbar-container .yui-toolbar-subcont{padding:.25em 0;zoom:1;}.yui-toolbar-container-collapsed .yui-toolbar-subcont{display:none;}.yui-toolbar-container .yui-toolbar-subcont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container span.yui-toolbar-draghandle{cursor:move;border-left:1px solid #999;border-right:1px solid #999;overflow:hidden;text-indent:77777px;width:2px;height:20px;display:block;clear:none;float:left;margin:0 0 0 .2em;}.yui-toolbar-container .yui-toolbar-titlebar.draggable{cursor:move;}.yui-toolbar-container .yui-toolbar-titlebar{position:relative;}.yui-toolbar-container .yui-toolbar-titlebar h2{font-weight:bold;letter-spacing:0;border:none;color:#000;margin:0;padding:.2em;}.yui-toolbar-container .yui-toolbar-titlebar h2 a{text-decoration:none;color:#000;cursor:default;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-draghandle{height:40px;}.yui-toolbar-container .yui-toolbar-group{float:left;zoom:1;}.yui-toolbar-container .yui-toolbar-group:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container .yui-toolbar-group h3{font-size:75%;padding:0 0 0 .25em;margin:0;}.yui-toolbar-container span.yui-toolbar-separator{width:2px;height:18px;margin:.2em 0 .2em .1em;display:block;clear:none;float:left;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-separator{height:35px;}.yui-toolbar-container.yui-toolbar-grouped .yui-toolbar-group span.yui-toolbar-separator{height:18px;}.yui-toolbar-container ul li{margin:0;padding:0;list-style-type:none;}.yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-toolbar-container .yui-push-button,.yui-toolbar-container .yui-color-button,.yui-toolbar-container .yui-menu-button{position:relative;cursor:pointer;}.yui-toolbar-container .yui-button .first-child,.yui-toolbar-container .yui-button .first-child a{height:100%;width:100%;overflow:hidden;}.yui-toolbar-container .yui-button-disabled{cursor:default;}.yui-toolbar-container .yui-button-disabled .yui-toolbar-icon{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button-disabled .up,.yui-toolbar-container .yui-button-disabled .down{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button a{overflow:hidden;}.yui-toolbar-container .yui-toolbar-select .first-child a{cursor:pointer;}.yui-toolbar-fontname-arial{font-family:Arial;}.yui-toolbar-fontname-arial-black{font-family:Arial Black;}.yui-toolbar-fontname-comic-sans-ms{font-family:Comic Sans MS;}.yui-toolbar-fontname-courier-new{font-family:Courier New;}.yui-toolbar-fontname-times-new-roman{font-family:Times New Roman;}.yui-toolbar-fontname-verdana{font-family:Verdana;}.yui-toolbar-fontname-impact{font-family:Impact;}.yui-toolbar-fontname-lucida-console{font-family:Lucida Console;}.yui-toolbar-fontname-tahoma{font-family:Tahoma;}.yui-toolbar-fontname-trebuchet-ms{font-family:Trebuchet MS;}.yui-toolbar-container .yui-toolbar-spinbutton{position:relative;}.yui-toolbar-container .yui-toolbar-spinbutton .first-child a{z-index:0;opacity:1;}.yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-toolbar-container .yui-toolbar-spinbutton a.down{position:absolute;display:block right:0;cursor:pointer;z-index:1;padding:0;margin:0;}.yui-toolbar-container .yui-overlay{position:absolute;}.yui-toolbar-container .yui-overlay ul li{margin:0;list-style-type:none;}.yui-toolbar-container{z-index:1;}.yui-editor-container .yui-editor-editable-container{position:relative;z-index:0;width:100%;}.yui-editor-container .yui-editor-masked{background-color:#CCC;}.yui-editor-container iframe{border:0px;padding:0;margin:0;zoom:1;display:block;}.yui-editor-container .yui-editor-editable{padding:0;margin:0;}.yui-editor-container .dompath{font-size:85%;}.yui-editor-panel .hd{text-align:left;position:relative;}.yui-editor-panel .hd h3{font-weight:bold;padding:0.25em 0pt 0.25em 0.25em;margin:0;}.yui-editor-panel .bd{width:100%;zoom:1;position:relative;}.yui-editor-panel .bd div.yui-editor-body-cont{padding:.25em .1em;zoom:1;}.yui-editor-panel .bd .gecko form{overflow:auto;}.yui-editor-panel .bd div.yui-editor-body-cont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-editor-panel .ft{text-align:right;width:99%;float:left;clear:both;}.yui-editor-panel .ft span.tip{display:block;position:relative;padding:.5em .5em .5em 23px;text-align:left;zoom:1;}.yui-editor-panel label{clear:both;float:left;padding:0;width:100%;text-align:left;zoom:1;}.yui-editor-panel .gecko label{overflow:auto;}.yui-editor-panel label strong{float:left;width:6em;}.yui-editor-panel .removeLink{width:80%;text-align:right;}.yui-editor-panel label input{margin-left:.25em;float:left;}.yui-editor-panel .yui-toolbar-group-padding{}.yui-editor-panel .yui-toolbar-group-border{}.yui-editor-panel .yui-toolbar-group-textflow{}.yui-editor-panel .height-width{float:left;}.yui-editor-panel .height-width h3{}.yui-editor-panel .height-width span{font-style:italic;display:block;float:left;overflow:visible;}.yui-editor-panel .height-width span.info{font-size:70%;margin-top:3px;}.yui-editor-panel .yui-toolbar-bordersize,.yui-editor-panel .yui-toolbar-bordertype{font-size:75%;}.yui-editor-panel .yui-toolbar-container span.yui-toolbar-separator{border:none;}.yui-editor-panel .yui-toolbar-bordersize span a span,.yui-editor-panel .yui-toolbar-bordertype span a span{display:block;height:8px;left:4px;position:absolute;top:3px;*top:-5px;width:24px;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-solid{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dotted{border-bottom:1px dotted black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dashed{border-bottom:1px dashed black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-0{*top:0px;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-1{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-2{border-bottom:2px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-3{top:2px;*top:-5px;border-bottom:3px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-4{top:1px;*top:-5px;border-bottom:4px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-5{top:1px;*top:-5px;border-bottom:5px solid black;}.yui-toolbar-container .yui-toolbar-bordersize-menu,.yui-toolbar-container .yui-toolbar-bordertype-menu{width:95px !important;}.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel,.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel:hover{margin:0px 3px 7px 17px;}.yui-toolbar-bordersize-menu .yuimenuitemlabel .checkedindicator,.yui-toolbar-bordertype-menu .yuimenuitemlabel .checkedindicator{position:absolute;left:-12px;*top:14px;*left:0px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-1 a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-2 a{border-bottom:2px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-3 a{border-bottom:3px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-4 a{border-bottom:4px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-5 a{border-bottom:5px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-solid a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dashed a{border-bottom:1px dashed black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dotted a{border-bottom:1px dotted black;height:14px;}h2.yui-editor-skipheader,h3.yui-editor-skipheader{height:0;margin:0;padding:0;border:none;width:0;overflow:hidden;position:absolute;}.yui-toolbar-colors{width:133px;zoom:1;display:none;z-index:100;overflow:hidden;}.yui-toolbar-colors:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors a{height:9px;width:9px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0;cursor:pointer;border:1px solid #F6F7EE;}.yui-toolbar-colors a:hover{border:1px solid black;}.yui-color-button-menu{overflow:visible;background-color:transparent;}.yui-toolbar-colors span{position:relative;display:block;padding:3px;overflow:hidden;float:left;width:100%;zoom:1;}.yui-toolbar-colors span:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors span em{height:35px;width:30px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0.75px;border:1px solid black;}.yui-toolbar-colors span strong{font-weight:normal;padding-left:3px;display:block;font-size:85%;float:left;width:65%;}.yui-skin-sam .yui-editor-container{border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container{zoom:1;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar{background:url(sprite.png) repeat-x 0 -200px;position:relative;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar h2{color:#000000;font-weight:bold;margin:0;padding:0.3em 1em;font-size:100%;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-group h3{color:#808080;font-size:75%;margin:1em 0 0;padding-bottom:0;padding-left:0.25em;text-align:left;}.yui-toolbar-container span.yui-toolbar-separator{border:none;text-indent:33px;overflow:hidden;margin:0 .25em;}.yui-skin-sam .yui-toolbar-container{background-color:#F2F2F2;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subcont{padding:0 1em 0.35em;border-bottom:1px solid #808080;}.yui-skin-sam .yui-toolbar-container-collapsed .yui-toolbar-titlebar{border-bottom:1px solid #808080;}.yui-skin-sam .yui-editor-container .visible .yui-menu-shadow,.yui-skin-sam .yui-editor-panel .visible .yui-menu-shadow{display:none;}.yui-skin-sam .yui-editor-container ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-container ul li{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-toolbar-group ul li.yui-toolbar-groupitem{float:left;}.yui-skin-sam .yui-editor-container .dompath{background-color:#F2F2F2;border-top:1px solid #808080;color:#999;text-align:left;padding:0.25em;}.yui-skin-sam .yui-toolbar-container .collapse{background:url(sprite.png) no-repeat 0 -400px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar span.collapse{cursor:pointer;position:absolute;top:4px;right:2px;display:block;overflow:hidden;height:15px;width:15px;text-indent:9999px;}.yui-skin-sam .yui-toolbar-container .yui-push-button,.yui-skin-sam .yui-toolbar-container .yui-color-button,.yui-skin-sam .yui-toolbar-container .yui-menu-button{background:url(sprite.png) repeat-x 0 0;position:relative;display:block;height:22px;width:30px;margin:0;border-color:#808080;border-style:solid;border-width:1px 0;}.yui-skin-sam .yui-toolbar-container .yui-push-button a,.yui-skin-sam .yui-toolbar-container .yui-color-button a,.yui-skin-sam .yui-toolbar-container .yui-menu-button a{padding-left:35px;height:20px;text-decoration:none;font-size:93%;line-height:2;display:block;color:#000000;overflow:hidden;}.yui-skin-sam .yui-toolbar-container .yui-push-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button .first-child{border-color:#808080;border-style:solid;border-width:0 1px;margin:0 -1px;display:block;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled .first-child{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled a{color:#A6A6A6;cursor:default;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-button .first-child{*left:0px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-fontname{width:135px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-heading{width:92px;}.yui-skin-sam .yui-toolbar-container .yui-button-hover{background:url(sprite.png) repeat-x 0 -1300px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-button-selected{background:url(sprite.png) repeat-x 0 -1700px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels .yui-toolbar-group{margin-top:.75em;}.yui-skin-sam .yui-toolbar-container .yui-push-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-color-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-menu-button span.yui-toolbar-icon{display:block;position:absolute;top:2px;height:18px;width:18px;overflow:hidden;background:url(editor-sprite.gif) no-repeat 30px 30px;}.yui-skin-sam .yui-toolbar-container .yui-button-selected span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-button-hover span.yui-toolbar-icon{background-image:url(editor-sprite-active.gif);}.yui-skin-sam .yui-toolbar-container .visible .yuimenuitemlabel{cursor:pointer;color:#000;*position:relative;}.yui-skin-sam .yui-toolbar-container .yui-button-menu{background-color:#fff;}.yui-skin-sam div.yuimenu li.selected{background-color:#B3D4FF;}.yui-skin-sam div.yuimenu li.selected a.selected{color:#000;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bold span.yui-toolbar-icon{background-position:0 0;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-strikethrough span.yui-toolbar-icon{background-position:0 -108px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-italic span.yui-toolbar-icon{background-position:0 -36px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-underline span.yui-toolbar-icon{background-position:0 -72px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subscript span.yui-toolbar-icon{background-position:0 -180px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-superscript span.yui-toolbar-icon{background-position:0 -144px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-forecolor span.yui-toolbar-icon{background-position:0 -216px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-backcolor span.yui-toolbar-icon{background-position:0 -288px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyleft span.yui-toolbar-icon{background-position:0 -324px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifycenter span.yui-toolbar-icon{background-position:0 -360px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyright span.yui-toolbar-icon{background-position:0 -396px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyfull span.yui-toolbar-icon{background-position:0 -432px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-indent span.yui-toolbar-icon{background-position:0 -720px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-outdent span.yui-toolbar-icon{background-position:0 -684px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-createlink span.yui-toolbar-icon{background-position:0 -792px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertimage span.yui-toolbar-icon{background-position:1px -756px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-left span.yui-toolbar-icon{background-position:0 -972px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-right span.yui-toolbar-icon{background-position:0 -936px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-inline span.yui-toolbar-icon{background-position:0 -900px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-block span.yui-toolbar-icon{background-position:0 -864px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bordercolor span.yui-toolbar-icon{background-position:0 -252px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-removeformat span.yui-toolbar-icon{background-position:0 -1080px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-hiddenelements span.yui-toolbar-icon{background-position:0 -1044px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertunorderedlist span.yui-toolbar-icon{background-position:0 -468px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertorderedlist span.yui-toolbar-icon{background-position:0 -504px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child{width:35px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child a{padding-left:2px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton span.yui-toolbar-icon{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{right:2px;background:url(editor-sprite.gif) no-repeat 0 -1222px;overflow:hidden;height:6px;width:7px;min-height:0;padding:0;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up{top:2px;background-position:0 -1222px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{bottom:2px;background-position:0 -1187px;}.yui-skin-sam .yui-toolbar-container select{height:22px;border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select .first-child a{padding-left:5px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select span.yui-toolbar-icon{background:url( editor-sprite.gif ) no-repeat 0 -1144px;overflow:hidden;right:-2px;top:0px;height:20px;}.yui-skin-sam .yui-editor-panel .yui-color-button-menu .bd{background-color:transparent;border:none;width:135px;}.yui-skin-sam .yui-color-button-menu .yui-toolbar-colors{border:1px solid #808080;}.yui-skin-sam .yui-editor-panel{padding:0;margin:0;border:none;background-color:transparent;overflow:visible;}.yui-skin-sam .yui-editor-panel .hd{margin:10px 0 0;padding:0;border:none;}.yui-skin-sam .yui-editor-panel .hd h3{color:#000;border:1px solid #808080;background:url(sprite.png) repeat-x 0 -200px;width:99%;position:relative;margin:0;padding:3px 0 0 0;font-size:93%;text-indent:5px;height:20px;}.yui-skin-sam .yui-editor-panel .bd{background-color:#F2F2F2;border-left:1px solid #808080;border-right:1px solid #808080;width:99%;margin:0;padding:0;overflow:visible;}.yui-skin-sam .yui-editor-panel ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-panel ul li{margin:0;padding:0;}.yui-skin-sam .yui-editor-panel .yuimenu{}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .yui-toolbar-subcont{padding:0;border:none;margin-top:0.35em;}.yui-skin-sam .yui-editor-panel .yui-toolbar-bordersize,.yui-skin-sam .yui-editor-panel .yui-toolbar-bordertype{width:50px;}.yui-skin-sam .yui-editor-panel label{display:block;float:none;padding:4px 0;margin-bottom:7px;}.yui-skin-sam .yui-editor-panel label strong{font-weight:normal;font-size:93%;text-align:right;padding-top:2px;}.yui-skin-sam .yui-editor-panel label input{width:75%;}.yui-skin-sam .yui-editor-panel .createlink_target,.yui-skin-sam .yui-editor-panel .insertimage_target{width:auto;margin-right:5px;}.yui-skin-sam .yui-editor-panel .removeLink{width:98%;}.yui-skin-sam .yui-editor-panel label input.warning{background-color:#FFEE69;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group h3{color:#000;float:left;font-weight:normal;font-size:93%;margin:5px 0 0 0;padding:0 3px 0 0;text-align:right;}.yui-skin-sam .yui-editor-panel .height-width h3{margin:3px 0 0 10px;}.yui-skin-sam .yui-editor-panel .height-width{margin:3px 0 0 35px;*margin-left:14px;width:42%;*width:44%;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-border{width:190px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-border{width:210px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding{width:203px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-padding{width:172px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding h3{margin-left:25px;*margin-left:12px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-textflow{width:182px;}.yui-skin-sam .yui-editor-panel .hd{background:none;}.yui-skin-sam .yui-editor-panel .ft{background-color:#F2F2F2;border:1px solid #808080;border-top:none;padding:0;margin:0 0 2px 0;}.yui-skin-sam .yui-editor-panel .hd span.close{background:url(sprite.png) no-repeat 0 -300px;cursor:pointer;display:block;height:16px;overflow:hidden;position:absolute;right:5px;text-indent:500px;top:2px;width:26px;}.yui-skin-sam .yui-editor-panel .ft span.tip{background-color:#EDF5FF;border-top:1px solid #808080;font-size:85%;}.yui-skin-sam .yui-editor-panel .ft span.tip strong{display:block;float:left;margin:0 2px 8px 0;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon{background:url( editor-sprite.gif ) no-repeat 0 -1260px;display:block;height:20px;left:2px;position:absolute;top:8px;width:20px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-info{background-position:2px -1260px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-warn{background-position:2px -1296px;}.yui-skin-sam .yui-editor-panel .hd span.knob{position:absolute;height:10px;width:28px;top:-10px;left:25px;text-indent:9999px;overflow:hidden;background:url( editor-knob.gif ) no-repeat 0 0;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container{float:left;width:100%;background-image:none;border:none;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .bd{background-color:#ffffff;}.yui-editor-blankimage{background-image:url( blankimage.png );}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/skin.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/skin.css new file mode 100644 index 0000000..c49588d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/skin.css
@@ -0,0 +1,23 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-skin-sam .yui-ac{position:relative;font-family:arial;font-size:100%;}.yui-skin-sam .yui-ac-input{position:absolute;width:100%;}.yui-skin-sam .yui-ac-container{position:absolute;top:1.6em;width:100%;}.yui-skin-sam .yui-ac-content{position:absolute;width:100%;border:1px solid #808080;background:#fff;overflow:hidden;z-index:9050;}.yui-skin-sam .yui-ac-shadow{position:absolute;margin:.3em;width:100%;background:#000;-moz-opacity:0.10;opacity:.10;filter:alpha(opacity=10);z-index:9049;}.yui-skin-sam .yui-ac-content ul{margin:0;padding:0;width:100%;}.yui-skin-sam .yui-ac-content li{margin:0;padding:2px 5px;cursor:default;white-space:nowrap;}.yui-skin-sam .yui-ac-content li.yui-ac-prehighlight{background:#B3D4FF;}.yui-skin-sam .yui-ac-content li.yui-ac-highlight{background:#426FD9;color:#FFF;} +.yui-button{display:-moz-inline-box;display:inline-block;vertical-align:text-bottom;}.yui-button .first-child{display:block;*display:inline-block;}.yui-button button,.yui-button a{display:block;*display:inline-block;border:none;margin:0;}.yui-button button{background-color:transparent;*overflow:visible;cursor:pointer;}.yui-button a{text-decoration:none;}.yui-skin-sam .yui-button{border-width:1px 0;border-style:solid;border-color:#808080;background:url(sprite.png) repeat-x 0 0;margin:auto .25em;}.yui-skin-sam .yui-button .first-child{border-width:0 1px;border-style:solid;border-color:#808080;margin:0 -1px;*position:relative;*left:-1px;}.yui-skin-sam .yui-button button,.yui-skin-sam .yui-button a{padding:0 10px;font-size:93%;line-height:2;*line-height:1.7;min-height:2em;*min-height:auto;color:#000;}.yui-skin-sam .yui-button a{*line-height:2;}.yui-skin-sam .yui-split-button button,.yui-skin-sam .yui-menu-button button{padding-right:20px;background-position:right center;background-repeat:no-repeat;}.yui-skin-sam .yui-menu-button button{background-image:url(menu-button-arrow.png);}.yui-skin-sam .yui-split-button button{background-image:url(split-button-arrow.png);}.yui-skin-sam .yui-button-focus{border-color:#7D98B8;background-position:0 -1300px;}.yui-skin-sam .yui-button-focus .first-child{border-color:#7D98B8;}.yui-skin-sam .yui-button-focus button,.yui-skin-sam .yui-button-focus a{color:#000;}.yui-skin-sam .yui-split-button-focus button{background-image:url(split-button-arrow-focus.png);}.yui-skin-sam .yui-button-hover{border-color:#7D98B8;background-position:0 -1300px;}.yui-skin-sam .yui-button-hover .first-child{border-color:#7D98B8;}.yui-skin-sam .yui-button-hover button,.yui-skin-sam .yui-button-hover a{color:#000;}.yui-skin-sam .yui-split-button-hover button{background-image:url(split-button-arrow-hover.png);}.yui-skin-sam .yui-button-active{border-color:#7D98B8;background-position:0 -1700px;}.yui-skin-sam .yui-button-active .first-child{border-color:#7D98B8;}.yui-skin-sam .yui-button-active button,.yui-skin-sam .yui-button-active a{color:#000;}.yui-skin-sam .yui-split-button-activeoption{border-color:#808080;background-position:0 0;}.yui-skin-sam .yui-split-button-activeoption .first-child{border-color:#808080;}.yui-skin-sam .yui-split-button-activeoption button{background-image:url(split-button-arrow-active.png);}.yui-skin-sam .yui-radio-button-checked,.yui-skin-sam .yui-checkbox-button-checked{border-color:#304369;background-position:0 -1400px;}.yui-skin-sam .yui-radio-button-checked .first-child,.yui-skin-sam .yui-checkbox-button-checked .first-child{border-color:#304369;}.yui-skin-sam .yui-radio-button-checked button,.yui-skin-sam .yui-checkbox-button-checked button{color:#fff;}.yui-skin-sam .yui-button-disabled{border-color:#ccc;background-position:0 -1500px;}.yui-skin-sam .yui-button-disabled .first-child{border-color:#ccc;}.yui-skin-sam .yui-button-disabled button,.yui-skin-sam .yui-button-disabled a{color:#A6A6A6;cursor:default;}.yui-skin-sam .yui-menu-button-disabled button{background-image:url(menu-button-arrow-disabled.png);}.yui-skin-sam .yui-split-button-disabled button{background-image:url(split-button-arrow-disabled.png);} +.yui-calcontainer{position:relative;float:left;_overflow:hidden;}.yui-calcontainer iframe{position:absolute;border:none;margin:0;padding:0;z-index:0;width:100%;height:100%;left:0px;top:0px;}.yui-calcontainer iframe.fixedsize{width:50em;height:50em;top:-1px;left:-1px;}.yui-calcontainer.multi .groupcal{z-index:1;float:left;position:relative;}.yui-calcontainer .title{position:relative;z-index:1;}.yui-calcontainer .close-icon{position:absolute;z-index:1;}.yui-calendar{position:relative;}.yui-calendar .calnavleft{position:absolute;z-index:1;}.yui-calendar .calnavright{position:absolute;z-index:1;}.yui-calendar .calheader{position:relative;width:100%;text-align:center;}.yui-calcontainer .yui-cal-nav-mask{position:absolute;z-index:2;margin:0;padding:0;width:100%;height:100%;_width:0;_height:0;left:0;top:0;display:none;}.yui-calcontainer .yui-cal-nav{position:absolute;z-index:3;top:0;display:none;}.yui-calcontainer .yui-cal-nav .yui-cal-nav-btn{display:-moz-inline-box;display:inline-block;}.yui-calcontainer .yui-cal-nav .yui-cal-nav-btn button{display:block;*display:inline-block;*overflow:visible;border:none;background-color:transparent;cursor:pointer;}.yui-calendar .calbody a:hover{background:inherit;}p#clear{clear:left;padding-top:10px;}.yui-skin-sam .yui-calcontainer{background-color:#f2f2f2;border:1px solid #808080;padding:10px;}.yui-skin-sam .yui-calcontainer.multi{padding:0 5px 0 5px;}.yui-skin-sam .yui-calcontainer.multi .groupcal{background-color:transparent;border:none;padding:10px 5px 10px 5px;margin:0;}.yui-skin-sam .yui-calcontainer .title{background:url(sprite.png) repeat-x 0 0;border-bottom:1px solid #cccccc;font:100% sans-serif;color:#000;font-weight:bold;height:auto;padding:.4em;margin:0 -10px 10px -10px;top:0;left:0;text-align:left;}.yui-skin-sam .yui-calcontainer.multi .title{margin:0 -5px 0 -5px;}.yui-skin-sam .yui-calcontainer.withtitle{padding-top:0;}.yui-skin-sam .yui-calcontainer .calclose{background:url(sprite.png) no-repeat 0 -300px;width:25px;height:15px;top:.4em;right:.4em;cursor:pointer;}.yui-skin-sam .yui-calendar{border-spacing:0;border-collapse:collapse;font:100% sans-serif;text-align:center;margin:0;}.yui-skin-sam .yui-calendar .calhead{background:transparent;border:none;vertical-align:middle;padding:0;}.yui-skin-sam .yui-calendar .calheader{background:transparent;font-weight:bold;padding:0 0 .6em 0;text-align:center;}.yui-skin-sam .yui-calendar .calheader img{border:none;}.yui-skin-sam .yui-calendar .calnavleft{background:url(sprite.png) no-repeat 0 -450px;width:25px;height:15px;top:0;bottom:0;left:-10px;margin-left:.4em;cursor:pointer;}.yui-skin-sam .yui-calendar .calnavright{background:url(sprite.png) no-repeat 0 -500px;width:25px;height:15px;top:0;bottom:0;right:-10px;margin-right:.4em;cursor:pointer;}.yui-skin-sam .yui-calendar .calweekdayrow{height:2em;}.yui-skin-sam .yui-calendar .calweekdayrow th{padding:0;border:none;}.yui-skin-sam .yui-calendar .calweekdaycell{color:#000;font-weight:bold;text-align:center;width:2em;}.yui-skin-sam .yui-calendar .calfoot{background-color:#f2f2f2;}.yui-skin-sam .yui-calendar .calrowhead,.yui-skin-sam .yui-calendar .calrowfoot{color:#a6a6a6;font-size:85%;font-style:normal;font-weight:normal;border:none;}.yui-skin-sam .yui-calendar .calrowhead{text-align:right;padding:0 2px 0 0;}.yui-skin-sam .yui-calendar .calrowfoot{text-align:left;padding:0 0 0 2px;}.yui-skin-sam .yui-calendar td.calcell{border:1px solid #cccccc;background:#fff;padding:1px;height:1.6em;line-height:1.6em;text-align:center;white-space:nowrap;}.yui-skin-sam .yui-calendar td.calcell a{color:#0066cc;display:block;height:100%;text-decoration:none;}.yui-skin-sam .yui-calendar td.calcell.today{background-color:#000;}.yui-skin-sam .yui-calendar td.calcell.today a{background-color:#fff;}.yui-skin-sam .yui-calendar td.calcell.oom{background-color:#cccccc;color:#a6a6a6;cursor:default;}.yui-skin-sam .yui-calendar td.calcell.selected{background-color:#fff;color:#000;}.yui-skin-sam .yui-calendar td.calcell.selected a{background-color:#b3d4ff;color:#000;}.yui-skin-sam .yui-calendar td.calcell.calcellhover{background-color:#426fd9;color:#fff;cursor:pointer;}.yui-skin-sam .yui-calendar td.calcell.calcellhover a{background-color:#426fd9;color:#fff;}.yui-skin-sam .yui-calendar td.calcell.previous{color:#e0e0e0;}.yui-skin-sam .yui-calendar td.calcell.restricted{text-decoration:line-through;}.yui-skin-sam .yui-calendar td.calcell.highlight1{background-color:#ccff99;}.yui-skin-sam .yui-calendar td.calcell.highlight2{background-color:#99ccff;}.yui-skin-sam .yui-calendar td.calcell.highlight3{background-color:#ffcccc;}.yui-skin-sam .yui-calendar td.calcell.highlight4{background-color:#ccff99;}.yui-skin-sam .yui-calendar a.calnav{border:1px solid #f2f2f2;padding:0 4px;text-decoration:none;color:#000;zoom:1;}.yui-skin-sam .yui-calendar a.calnav:hover{background:url(sprite.png) repeat-x 0 0;border-color:#A0A0A0;cursor:pointer;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-mask{background-color:#000;opacity:0.25;*filter:alpha(opacity=25);}.yui-skin-sam .yui-calcontainer .yui-cal-nav{font-family:arial,helvetica,clean,sans-serif;font-size:93%;border:1px solid #808080;left:50%;margin-left:-7em;width:14em;padding:0;top:2.5em;background-color:#f2f2f2;}.yui-skin-sam .yui-calcontainer.withtitle .yui-cal-nav{top:4.5em;}.yui-skin-sam .yui-calcontainer.multi .yui-cal-nav{width:16em;margin-left:-8em;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-y,.yui-skin-sam .yui-calcontainer .yui-cal-nav-m,.yui-skin-sam .yui-calcontainer .yui-cal-nav-b{padding:5px 10px 5px 10px;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-b{text-align:center;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-e{margin-top:5px;padding:5px;background-color:#EDF5FF;border-top:1px solid black;display:none;}.yui-skin-sam .yui-calcontainer .yui-cal-nav label{display:block;font-weight:bold;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-mc{width:100%;_width:auto;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-y input.yui-invalid{background-color:#FFEE69;border:1px solid #000;}.yui-skin-sam .yui-calcontainer .yui-cal-nav-yc{width:4em;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn{border:1px solid #808080;background:url(sprite.png) repeat-x 0 0;background-color:#ccc;margin:auto .15em;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn button{padding:0 8px;font-size:93%;line-height:2;*line-height:1.7;min-height:2em;*min-height:auto;color:#000;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn.yui-default{border:1px solid #304369;background-color:#426fd9;background:url(sprite.png) repeat-x 0 -1400px;}.yui-skin-sam .yui-calcontainer .yui-cal-nav .yui-cal-nav-btn.yui-default button{color:#fff;} +.yui-picker-panel{background:#e3e3e3;border-color:#888;}.yui-picker-panel .hd{background-color:#ccc;font-size:100%;line-height:100%;border:1px solid #e3e3e3;font-weight:bold;overflow:hidden;padding:6px;color:#000;}.yui-picker-panel .bd{background:#e8e8e8;margin:1px;height:200px;}.yui-picker-panel .ft{background:#e8e8e8;margin:1px;padding:1px;}.yui-picker{position:relative;}.yui-picker-hue-thumb{cursor:default;width:18px;height:18px;top:-8px;left:-2px;z-index:9;position:absolute;}.yui-picker-hue-bg{-moz-outline:none;outline:0px none;position:absolute;left:200px;height:183px;width:14px;background:url(hue_bg.png) no-repeat;top:4px;}.yui-picker-bg{-moz-outline:none;outline:0px none;position:absolute;top:4px;left:4px;height:182px;width:182px;background-color:#F00;background-image:url(picker_mask.png);}*html .yui-picker-bg{background-image:none;filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='../../build/colorpicker/assets/picker_mask.png',sizingMethod='scale');}.yui-picker-mask{position:absolute;z-index:1;top:0px;left:0px;}.yui-picker-thumb{cursor:default;width:11px;height:11px;z-index:9;position:absolute;top:-4px;left:-4px;}.yui-picker-swatch{position:absolute;left:240px;top:4px;height:60px;width:55px;border:1px solid #888;}.yui-picker-websafe-swatch{position:absolute;left:304px;top:4px;height:24px;width:24px;border:1px solid #888;}.yui-picker-controls{position:absolute;top:72px;left:226px;font:1em monospace;}.yui-picker-controls .hd{background:transparent;border-width:0px !important;}.yui-picker-controls .bd{height:100px;border-width:0px !important;}.yui-picker-controls ul{float:left;padding:0 2px 0 0;margin:0}.yui-picker-controls li{padding:2px;list-style:none;margin:0}.yui-picker-controls input{font-size:0.85em;width:2.4em;}.yui-picker-hex-controls{clear:both;padding:2px;}.yui-picker-hex-controls input{width:4.6em;}.yui-picker-controls a{font:1em arial,helvetica,clean,sans-serif;display:block;*display:inline-block;padding:0;color:#000;} +.yui-overlay,.yui-panel-container{visibility:hidden;position:absolute;z-index:2;}.yui-panel-container form{margin:0;}.mask{z-index:1;display:none;position:absolute;top:0;left:0;right:0;bottom:0;}.mask.block-scrollbars{overflow:auto;}.masked select,.drag select,.hide-select select{_visibility:hidden;}.yui-panel-container select{_visibility:inherit;}.hide-scrollbars,.hide-scrollbars *{overflow:hidden;}.hide-scrollbars select{display:none;}.show-scrollbars{overflow:auto;}.yui-panel-container.show-scrollbars,.yui-tt.show-scrollbars{overflow:visible;}.yui-panel-container.show-scrollbars .underlay,.yui-tt.show-scrollbars .yui-tt-shadow{overflow:auto;}.yui-panel-container.shadow .underlay.yui-force-redraw{padding-bottom:1px;}.yui-effect-fade .underlay{display:none;}.yui-tt-shadow{position:absolute;}.yui-skin-sam .mask{background-color:#000;opacity:.25;*filter:alpha(opacity=25);}.yui-skin-sam .yui-panel-container{padding:0 1px;*padding:2px 3px;}.yui-skin-sam .yui-panel{position:relative;*zoom:1;left:0;top:0;border-style:solid;border-width:1px 0;border-color:#808080;z-index:1;}.yui-skin-sam .yui-panel .hd,.yui-skin-sam .yui-panel .bd,.yui-skin-sam .yui-panel .ft{*zoom:1;*position:relative;border-style:solid;border-width:0 1px;border-color:#808080;margin:0 -1px;}.yui-skin-sam .yui-panel .hd{border-bottom:solid 1px #ccc;}.yui-skin-sam .yui-panel .bd,.yui-skin-sam .yui-panel .ft{background-color:#F2F2F2;}.yui-skin-sam .yui-panel .hd{padding:0 10px;font-size:93%;line-height:2;*line-height:1.9;font-weight:bold;color:#000;background:url(sprite.png) repeat-x 0 -200px;}.yui-skin-sam .yui-panel .bd{padding:10px;}.yui-skin-sam .yui-panel .ft{border-top:solid 1px #808080;padding:5px 10px;font-size:77%;}.yui-skin-sam .yui-panel-container.focused .yui-panel .hd{}.yui-skin-sam .container-close{position:absolute;top:5px;right:6px;width:25px;height:15px;background:url(sprite.png) no-repeat 0 -300px;cursor:pointer;}.yui-skin-sam .yui-panel-container .underlay{right:-1px;left:-1px;}.yui-skin-sam .yui-panel-container.matte{padding:9px 10px;background-color:#fff;}.yui-skin-sam .yui-panel-container.shadow{_padding:2px 5px 0 3px;}.yui-skin-sam .yui-panel-container.shadow .underlay{position:absolute;top:2px;right:-3px;bottom:-3px;left:-3px;*top:3px;*left:-1px;*right:-1px;*bottom:-1px;_top:0;_right:0;_bottom:0;_left:0;_margin-top:3px;_margin-left:-1px;background-color:#000;opacity:.12;*filter:alpha(opacity=12);}.yui-skin-sam .yui-dialog .ft{border-top:none;padding:0 10px 10px 10px;font-size:100%;}.yui-skin-sam .yui-dialog .ft .button-group{display:block;text-align:right;}.yui-skin-sam .yui-dialog .ft button.default{font-weight:bold;}.yui-skin-sam .yui-dialog .ft span.default{border-color:#304369;background-position:0 -1400px;}.yui-skin-sam .yui-dialog .ft span.default .first-child{border-color:#304369;}.yui-skin-sam .yui-dialog .ft span.default button{color:#fff;}.yui-skin-sam .yui-simple-dialog .bd .yui-icon{background:url(sprite.png) no-repeat 0 0;width:16px;height:16px;margin-right:10px;float:left;}.yui-skin-sam .yui-simple-dialog .bd span.blckicon{background-position:0 -1100px;}.yui-skin-sam .yui-simple-dialog .bd span.alrticon{background-position:0 -1050px;}.yui-skin-sam .yui-simple-dialog .bd span.hlpicon{background-position:0 -1150px;}.yui-skin-sam .yui-simple-dialog .bd span.infoicon{background-position:0 -1200px;}.yui-skin-sam .yui-simple-dialog .bd span.warnicon{background-position:0 -1900px;}.yui-skin-sam .yui-simple-dialog .bd span.tipicon{background-position:0 -1250px;}.yui-skin-sam .yui-tt .bd{position:relative;top:0;left:0;z-index:1;color:#000;padding:2px 5px;border-color:#D4C237 #A6982B #A6982B #A6982B;border-width:1px;border-style:solid;background-color:#FFEE69;}.yui-skin-sam .yui-tt.show-scrollbars .bd{overflow:auto;}.yui-skin-sam .yui-tt-shadow{top:2px;right:-3px;left:-3px;bottom:-3px;background-color:#000;}.yui-skin-sam .yui-tt-shadow-visible{opacity:.12;*filter:alpha(opacity=12);} +.yui-dt{border-bottom:1px solid transparent;}.yui-dt-noop{border-bottom:none;}.yui-dt-hd{display:none;}.yui-dt-scrollable .yui-dt-hd{display:block;}.yui-dt-scrollable .yui-dt-bd thead tr,.yui-dt-scrollable .yui-dt-bd thead th{position:absolute;left:-1500px;}.yui-dt-scrollable tbody{-moz-outline:none;}.yui-dt-draggable{cursor:move;}.yui-dt-coltarget{position:absolute;z-index:999;}.yui-dt-hd{zoom:1;}th.yui-dt-resizeable .yui-dt-liner{position:relative;}.yui-dt-resizer{position:absolute;right:0;bottom:0;height:100%;cursor:e-resize;cursor:col-resize;background:url(transparent.gif);}.yui-dt-resizerproxy{visibility:hidden;position:absolute;z-index:9000;background:url(transparent.gif);}.yui-skin-sam th.yui-dt-hidden .yui-dt-liner,.yui-skin-sam td.yui-dt-hidden .yui-dt-liner{margin:0;padding:0;overflow:hidden;white-space:nowrap;}.yui-dt-scrollable .yui-dt-bd{overflow:auto;}.yui-dt-scrollable .yui-dt-hd{overflow:hidden;position:relative;}.yui-dt-editor{position:absolute;z-index:9000;}.yui-skin-sam .yui-dt table{margin:0;padding:0;font-family:arial;font-size:inherit;border-collapse:separate;*border-collapse:collapse;border-spacing:0;}.yui-skin-sam .yui-dt thead{border-spacing:0;}.yui-skin-sam .yui-dt caption{padding-bottom:1em;text-align:left;}.yui-skin-sam .yui-dt-hd table{border-left:1px solid #7F7F7F;border-top:1px solid #7F7F7F;border-right:1px solid #7F7F7F;}.yui-skin-sam .yui-dt-bd table{border:1px solid #7F7F7F;}.yui-skin-sam .yui-dt th{background:#D8D8DA url(sprite.png) repeat-x 0 0;}.yui-skin-sam .yui-dt th,.yui-skin-sam .yui-dt th a{font-weight:normal;text-decoration:none;color:#000;vertical-align:bottom;}.yui-skin-sam .yui-dt th{margin:0;padding:0;border:none;border-right:1px solid #CBCBCB;}.yui-skin-sam .yui-dt th .yui-dt-liner{white-space:nowrap;}.yui-skin-sam .yui-dt-liner{margin:0;padding:0;padding:4px 10px 4px 10px;}.yui-skin-sam .yui-dt-coltarget{width:5px;background-color:red;}.yui-skin-sam .yui-dt td{margin:0;padding:0;border:none;border-right:1px solid #CBCBCB;text-align:left;}.yui-skin-sam .yui-dt-list td{border-right:none;}.yui-skin-sam .yui-dt-resizer{width:6px;}.yui-skin-sam tbody.yui-dt-msg td{border:none;}.yui-skin-sam .yui-dt-loading{background-color:#FFF;}.yui-skin-sam .yui-dt-empty{background-color:#FFF;}.yui-skin-sam .yui-dt-error{background-color:#FFF;}.yui-skin-sam .yui-dt-scrollable .yui-dt-hd table{border:0px;}.yui-skin-sam .yui-dt-scrollable .yui-dt-bd table{border:0px;}.yui-skin-sam .yui-dt-scrollable .yui-dt-hd{border-left:1px solid #7F7F7F;border-top:1px solid #7F7F7F;border-right:1px solid #7F7F7F;}.yui-skin-sam .yui-dt-scrollable .yui-dt-bd{border-left:1px solid #7F7F7F;border-bottom:1px solid #7F7F7F;border-right:1px solid #7F7F7F;background-color:#FFF;}.yui-skin-sam thead .yui-dt-sortable{cursor:pointer;}.yui-skin-sam th.yui-dt-asc,.yui-skin-sam th.yui-dt-desc{background:url(sprite.png) repeat-x 0 -100px;}.yui-skin-sam th.yui-dt-sortable .yui-dt-label{margin-right:10px;}.yui-skin-sam th.yui-dt-asc .yui-dt-liner{background:url(dt-arrow-up.png) no-repeat right;}.yui-skin-sam th.yui-dt-desc .yui-dt-liner{background:url(dt-arrow-dn.png) no-repeat right;}.yui-dt-editable{cursor:pointer;}.yui-dt-editor{text-align:left;background-color:#F2F2F2;border:1px solid #808080;padding:6px;}.yui-dt-editor label{padding-left:4px;padding-right:6px;}.yui-dt-editor .yui-dt-button{padding-top:6px;text-align:right;}.yui-dt-editor .yui-dt-button button{background:url(sprite.png) repeat-x 0 0;border:1px solid #999;width:4em;height:1.8em;margin-left:6px;}.yui-dt-editor .yui-dt-button button.yui-dt-default{background:url(sprite.png) repeat-x 0 -1400px;background-color:#5584E0;border:1px solid #304369;color:#FFF}.yui-dt-editor .yui-dt-button button:hover{background:url(sprite.png) repeat-x 0 -1300px;color:#000;}.yui-dt-editor .yui-dt-button button:active{background:url(sprite.png) repeat-x 0 -1700px;color:#000;}.yui-skin-sam tr.yui-dt-even{background-color:#FFF;}.yui-skin-sam tr.yui-dt-odd{background-color:#EDF5FF;}.yui-skin-sam tr.yui-dt-even td.yui-dt-asc,.yui-skin-sam tr.yui-dt-even td.yui-dt-desc{background-color:#EDF5FF;}.yui-skin-sam tr.yui-dt-odd td.yui-dt-asc,.yui-skin-sam tr.yui-dt-odd td.yui-dt-desc{background-color:#DBEAFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-even{background-color:#FFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-odd{background-color:#FFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-desc{background-color:#EDF5FF;}.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-desc{background-color:#EDF5FF;}.yui-skin-sam th.yui-dt-highlighted,.yui-skin-sam th.yui-dt-highlighted a{background-color:#B2D2FF;}.yui-skin-sam tr.yui-dt-highlighted,.yui-skin-sam tr.yui-dt-highlighted td.yui-dt-asc,.yui-skin-sam tr.yui-dt-highlighted td.yui-dt-desc,.yui-skin-sam tr.yui-dt-even td.yui-dt-highlighted,.yui-skin-sam tr.yui-dt-odd td.yui-dt-highlighted{cursor:pointer;background-color:#B2D2FF;}.yui-skin-sam .yui-dt-list th.yui-dt-highlighted,.yui-skin-sam .yui-dt-list th.yui-dt-highlighted a{background-color:#B2D2FF;}.yui-skin-sam .yui-dt-list tr.yui-dt-highlighted,.yui-skin-sam .yui-dt-list tr.yui-dt-highlighted td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-highlighted td.yui-dt-desc,.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-highlighted,.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-highlighted{cursor:pointer;background-color:#B2D2FF;}.yui-skin-sam th.yui-dt-selected,.yui-skin-sam th.yui-dt-selected a{background-color:#446CD7;}.yui-skin-sam tr.yui-dt-selected td,.yui-skin-sam tr.yui-dt-selected td.yui-dt-asc,.yui-skin-sam tr.yui-dt-selected td.yui-dt-desc{background-color:#426FD9;color:#FFF;}.yui-skin-sam tr.yui-dt-even td.yui-dt-selected,.yui-skin-sam tr.yui-dt-odd td.yui-dt-selected{background-color:#446CD7;color:#FFF;}.yui-skin-sam .yui-dt-list th.yui-dt-selected,.yui-skin-sam .yui-dt-list th.yui-dt-selected a{background-color:#446CD7;}.yui-skin-sam .yui-dt-list tr.yui-dt-selected td,.yui-skin-sam .yui-dt-list tr.yui-dt-selected td.yui-dt-asc,.yui-skin-sam .yui-dt-list tr.yui-dt-selected td.yui-dt-desc{background-color:#426FD9;color:#FFF;}.yui-skin-sam .yui-dt-list tr.yui-dt-even td.yui-dt-selected,.yui-skin-sam .yui-dt-list tr.yui-dt-odd td.yui-dt-selected{background-color:#446CD7;color:#FFF;}.yui-skin-sam .yui-pg-container,.yui-skin-sam .yui-dt-paginator{display:block;margin:6px 0;white-space:nowrap;}.yui-skin-sam .yui-pg-first,.yui-skin-sam .yui-pg-last,.yui-skin-sam .yui-pg-current-page,.yui-skin-sam .yui-dt-paginator .yui-dt-first,.yui-skin-sam .yui-dt-paginator .yui-dt-last,.yui-skin-sam .yui-dt-paginator .yui-dt-selected{padding:2px 6px;}.yui-skin-sam a.yui-pg-first,.yui-skin-sam a.yui-pg-previous,.yui-skin-sam a.yui-pg-next,.yui-skin-sam a.yui-pg-last,.yui-skin-sam a.yui-pg-page,.yui-skin-sam .yui-dt-paginator a.yui-dt-first,.yui-skin-sam .yui-dt-paginator a.yui-dt-last{text-decoration:none;}.yui-skin-sam .yui-dt-paginator .yui-dt-previous,.yui-skin-sam .yui-dt-paginator .yui-dt-next{display:none;}.yui-skin-sam a.yui-pg-page,.yui-skin-sam a.yui-dt-page{border:1px solid #CBCBCB;padding:2px 6px;text-decoration:none;background-color:#fff}.yui-skin-sam .yui-pg-current-page,.yui-skin-sam .yui-dt-paginator .yui-dt-selected{border:1px solid #fff;background-color:#fff;}.yui-skin-sam .yui-pg-pages{margin-left:1ex;margin-right:1ex;}.yui-skin-sam .yui-pg-page{margin-right:1px;margin-left:1px;}.yui-skin-sam .yui-pg-first,.yui-skin-sam .yui-pg-previous{margin-right:3px;}.yui-skin-sam .yui-pg-next,.yui-skin-sam .yui-pg-last{margin-left:3px;}.yui-skin-sam .yui-pg-current,.yui-skin-sam .yui-pg-rpp-options{margin-right:1em;margin-left:1em;} +.yui-busy{cursor:wait !important;}.yui-toolbar-container fieldset{padding:0;margin:0;border:0;}.yui-toolbar-container legend{display:none;}.yui-toolbar-container .yui-toolbar-subcont{padding:.25em 0;zoom:1;}.yui-toolbar-container-collapsed .yui-toolbar-subcont{display:none;}.yui-toolbar-container .yui-toolbar-subcont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container span.yui-toolbar-draghandle{cursor:move;border-left:1px solid #999;border-right:1px solid #999;overflow:hidden;text-indent:77777px;width:2px;height:20px;display:block;clear:none;float:left;margin:0 0 0 .2em;}.yui-toolbar-container .yui-toolbar-titlebar.draggable{cursor:move;}.yui-toolbar-container .yui-toolbar-titlebar{position:relative;}.yui-toolbar-container .yui-toolbar-titlebar h2{font-weight:bold;letter-spacing:0;border:none;color:#000;margin:0;padding:.2em;}.yui-toolbar-container .yui-toolbar-titlebar h2 a{text-decoration:none;color:#000;cursor:default;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-draghandle{height:40px;}.yui-toolbar-container .yui-toolbar-group{float:left;zoom:1;}.yui-toolbar-container .yui-toolbar-group:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container .yui-toolbar-group h3{font-size:75%;padding:0 0 0 .25em;margin:0;}.yui-toolbar-container span.yui-toolbar-separator{width:2px;height:18px;margin:.2em 0 .2em .1em;display:block;clear:none;float:left;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-separator{height:35px;}.yui-toolbar-container.yui-toolbar-grouped .yui-toolbar-group span.yui-toolbar-separator{height:18px;}.yui-toolbar-container ul li{margin:0;padding:0;list-style-type:none;}.yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-toolbar-container .yui-push-button,.yui-toolbar-container .yui-color-button,.yui-toolbar-container .yui-menu-button{position:relative;cursor:pointer;}.yui-toolbar-container .yui-button .first-child,.yui-toolbar-container .yui-button .first-child a{height:100%;width:100%;overflow:hidden;}.yui-toolbar-container .yui-button-disabled{cursor:default;}.yui-toolbar-container .yui-button-disabled .yui-toolbar-icon{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button-disabled .up,.yui-toolbar-container .yui-button-disabled .down{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button a{overflow:hidden;}.yui-toolbar-container .yui-toolbar-select .first-child a{cursor:pointer;}.yui-toolbar-fontname-arial{font-family:Arial;}.yui-toolbar-fontname-arial-black{font-family:Arial Black;}.yui-toolbar-fontname-comic-sans-ms{font-family:Comic Sans MS;}.yui-toolbar-fontname-courier-new{font-family:Courier New;}.yui-toolbar-fontname-times-new-roman{font-family:Times New Roman;}.yui-toolbar-fontname-verdana{font-family:Verdana;}.yui-toolbar-fontname-impact{font-family:Impact;}.yui-toolbar-fontname-lucida-console{font-family:Lucida Console;}.yui-toolbar-fontname-tahoma{font-family:Tahoma;}.yui-toolbar-fontname-trebuchet-ms{font-family:Trebuchet MS;}.yui-toolbar-container .yui-toolbar-spinbutton{position:relative;}.yui-toolbar-container .yui-toolbar-spinbutton .first-child a{z-index:0;opacity:1;}.yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-toolbar-container .yui-toolbar-spinbutton a.down{position:absolute;display:block right:0;cursor:pointer;z-index:1;padding:0;margin:0;}.yui-toolbar-container .yui-overlay{position:absolute;}.yui-toolbar-container .yui-overlay ul li{margin:0;list-style-type:none;}.yui-toolbar-container{z-index:1;}.yui-editor-container .yui-editor-editable-container{position:relative;z-index:0;width:100%;}.yui-editor-container .yui-editor-masked{background-color:#CCC;}.yui-editor-container iframe{border:0px;padding:0;margin:0;zoom:1;display:block;}.yui-editor-container .yui-editor-editable{padding:0;margin:0;}.yui-editor-container .dompath{font-size:85%;}.yui-editor-panel .hd{text-align:left;position:relative;}.yui-editor-panel .hd h3{font-weight:bold;padding:0.25em 0pt 0.25em 0.25em;margin:0;}.yui-editor-panel .bd{width:100%;zoom:1;position:relative;}.yui-editor-panel .bd div.yui-editor-body-cont{padding:.25em .1em;zoom:1;}.yui-editor-panel .bd .gecko form{overflow:auto;}.yui-editor-panel .bd div.yui-editor-body-cont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-editor-panel .ft{text-align:right;width:99%;float:left;clear:both;}.yui-editor-panel .ft span.tip{display:block;position:relative;padding:.5em .5em .5em 23px;text-align:left;zoom:1;}.yui-editor-panel label{clear:both;float:left;padding:0;width:100%;text-align:left;zoom:1;}.yui-editor-panel .gecko label{overflow:auto;}.yui-editor-panel label strong{float:left;width:6em;}.yui-editor-panel .removeLink{width:80%;text-align:right;}.yui-editor-panel label input{margin-left:.25em;float:left;}.yui-editor-panel .yui-toolbar-group-padding{}.yui-editor-panel .yui-toolbar-group-border{}.yui-editor-panel .yui-toolbar-group-textflow{}.yui-editor-panel .height-width{float:left;}.yui-editor-panel .height-width h3{}.yui-editor-panel .height-width span{font-style:italic;display:block;float:left;overflow:visible;}.yui-editor-panel .height-width span.info{font-size:70%;margin-top:3px;}.yui-editor-panel .yui-toolbar-bordersize,.yui-editor-panel .yui-toolbar-bordertype{font-size:75%;}.yui-editor-panel .yui-toolbar-container span.yui-toolbar-separator{border:none;}.yui-editor-panel .yui-toolbar-bordersize span a span,.yui-editor-panel .yui-toolbar-bordertype span a span{display:block;height:8px;left:4px;position:absolute;top:3px;*top:-5px;width:24px;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-solid{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dotted{border-bottom:1px dotted black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dashed{border-bottom:1px dashed black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-0{*top:0px;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-1{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-2{border-bottom:2px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-3{top:2px;*top:-5px;border-bottom:3px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-4{top:1px;*top:-5px;border-bottom:4px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-5{top:1px;*top:-5px;border-bottom:5px solid black;}.yui-toolbar-container .yui-toolbar-bordersize-menu,.yui-toolbar-container .yui-toolbar-bordertype-menu{width:95px !important;}.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel,.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel:hover{margin:0px 3px 7px 17px;}.yui-toolbar-bordersize-menu .yuimenuitemlabel .checkedindicator,.yui-toolbar-bordertype-menu .yuimenuitemlabel .checkedindicator{position:absolute;left:-12px;*top:14px;*left:0px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-1 a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-2 a{border-bottom:2px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-3 a{border-bottom:3px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-4 a{border-bottom:4px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-5 a{border-bottom:5px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-solid a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dashed a{border-bottom:1px dashed black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dotted a{border-bottom:1px dotted black;height:14px;}h2.yui-editor-skipheader,h3.yui-editor-skipheader{height:0;margin:0;padding:0;border:none;width:0;overflow:hidden;position:absolute;}.yui-toolbar-colors{width:133px;zoom:1;display:none;z-index:100;overflow:hidden;}.yui-toolbar-colors:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors a{height:9px;width:9px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0;cursor:pointer;border:1px solid #F6F7EE;}.yui-toolbar-colors a:hover{border:1px solid black;}.yui-color-button-menu{overflow:visible;background-color:transparent;}.yui-toolbar-colors span{position:relative;display:block;padding:3px;overflow:hidden;float:left;width:100%;zoom:1;}.yui-toolbar-colors span:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors span em{height:35px;width:30px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0.75px;border:1px solid black;}.yui-toolbar-colors span strong{font-weight:normal;padding-left:3px;display:block;font-size:85%;float:left;width:65%;}.yui-skin-sam .yui-editor-container{border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container{zoom:1;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar{background:url(sprite.png) repeat-x 0 -200px;position:relative;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar h2{color:#000000;font-weight:bold;margin:0;padding:0.3em 1em;font-size:100%;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-group h3{color:#808080;font-size:75%;margin:1em 0 0;padding-bottom:0;padding-left:0.25em;text-align:left;}.yui-toolbar-container span.yui-toolbar-separator{border:none;text-indent:33px;overflow:hidden;margin:0 .25em;}.yui-skin-sam .yui-toolbar-container{background-color:#F2F2F2;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subcont{padding:0 1em 0.35em;border-bottom:1px solid #808080;}.yui-skin-sam .yui-toolbar-container-collapsed .yui-toolbar-titlebar{border-bottom:1px solid #808080;}.yui-skin-sam .yui-editor-container .visible .yui-menu-shadow,.yui-skin-sam .yui-editor-panel .visible .yui-menu-shadow{display:none;}.yui-skin-sam .yui-editor-container ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-container ul li{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-toolbar-group ul li.yui-toolbar-groupitem{float:left;}.yui-skin-sam .yui-editor-container .dompath{background-color:#F2F2F2;border-top:1px solid #808080;color:#999;text-align:left;padding:0.25em;}.yui-skin-sam .yui-toolbar-container .collapse{background:url(sprite.png) no-repeat 0 -400px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar span.collapse{cursor:pointer;position:absolute;top:4px;right:2px;display:block;overflow:hidden;height:15px;width:15px;text-indent:9999px;}.yui-skin-sam .yui-toolbar-container .yui-push-button,.yui-skin-sam .yui-toolbar-container .yui-color-button,.yui-skin-sam .yui-toolbar-container .yui-menu-button{background:url(sprite.png) repeat-x 0 0;position:relative;display:block;height:22px;width:30px;margin:0;border-color:#808080;border-style:solid;border-width:1px 0;}.yui-skin-sam .yui-toolbar-container .yui-push-button a,.yui-skin-sam .yui-toolbar-container .yui-color-button a,.yui-skin-sam .yui-toolbar-container .yui-menu-button a{padding-left:35px;height:20px;text-decoration:none;font-size:93%;line-height:2;display:block;color:#000000;overflow:hidden;}.yui-skin-sam .yui-toolbar-container .yui-push-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button .first-child{border-color:#808080;border-style:solid;border-width:0 1px;margin:0 -1px;display:block;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled .first-child{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled a{color:#A6A6A6;cursor:default;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-button .first-child{*left:0px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-fontname{width:135px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-heading{width:92px;}.yui-skin-sam .yui-toolbar-container .yui-button-hover{background:url(sprite.png) repeat-x 0 -1300px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-button-selected{background:url(sprite.png) repeat-x 0 -1700px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels .yui-toolbar-group{margin-top:.75em;}.yui-skin-sam .yui-toolbar-container .yui-push-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-color-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-menu-button span.yui-toolbar-icon{display:block;position:absolute;top:2px;height:18px;width:18px;overflow:hidden;background:url(editor-sprite.gif) no-repeat 30px 30px;}.yui-skin-sam .yui-toolbar-container .yui-button-selected span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-button-hover span.yui-toolbar-icon{background-image:url(editor-sprite-active.gif);}.yui-skin-sam .yui-toolbar-container .visible .yuimenuitemlabel{cursor:pointer;color:#000;*position:relative;}.yui-skin-sam .yui-toolbar-container .yui-button-menu{background-color:#fff;}.yui-skin-sam div.yuimenu li.selected{background-color:#B3D4FF;}.yui-skin-sam div.yuimenu li.selected a.selected{color:#000;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bold span.yui-toolbar-icon{background-position:0 0;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-strikethrough span.yui-toolbar-icon{background-position:0 -108px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-italic span.yui-toolbar-icon{background-position:0 -36px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-underline span.yui-toolbar-icon{background-position:0 -72px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subscript span.yui-toolbar-icon{background-position:0 -180px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-superscript span.yui-toolbar-icon{background-position:0 -144px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-forecolor span.yui-toolbar-icon{background-position:0 -216px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-backcolor span.yui-toolbar-icon{background-position:0 -288px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyleft span.yui-toolbar-icon{background-position:0 -324px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifycenter span.yui-toolbar-icon{background-position:0 -360px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyright span.yui-toolbar-icon{background-position:0 -396px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyfull span.yui-toolbar-icon{background-position:0 -432px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-indent span.yui-toolbar-icon{background-position:0 -720px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-outdent span.yui-toolbar-icon{background-position:0 -684px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-createlink span.yui-toolbar-icon{background-position:0 -792px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertimage span.yui-toolbar-icon{background-position:1px -756px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-left span.yui-toolbar-icon{background-position:0 -972px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-right span.yui-toolbar-icon{background-position:0 -936px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-inline span.yui-toolbar-icon{background-position:0 -900px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-block span.yui-toolbar-icon{background-position:0 -864px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bordercolor span.yui-toolbar-icon{background-position:0 -252px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-removeformat span.yui-toolbar-icon{background-position:0 -1080px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-hiddenelements span.yui-toolbar-icon{background-position:0 -1044px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertunorderedlist span.yui-toolbar-icon{background-position:0 -468px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertorderedlist span.yui-toolbar-icon{background-position:0 -504px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child{width:35px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child a{padding-left:2px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton span.yui-toolbar-icon{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{right:2px;background:url(editor-sprite.gif) no-repeat 0 -1222px;overflow:hidden;height:6px;width:7px;min-height:0;padding:0;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up{top:2px;background-position:0 -1222px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{bottom:2px;background-position:0 -1187px;}.yui-skin-sam .yui-toolbar-container select{height:22px;border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select .first-child a{padding-left:5px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select span.yui-toolbar-icon{background:url( editor-sprite.gif ) no-repeat 0 -1144px;overflow:hidden;right:-2px;top:0px;height:20px;}.yui-skin-sam .yui-editor-panel .yui-color-button-menu .bd{background-color:transparent;border:none;width:135px;}.yui-skin-sam .yui-color-button-menu .yui-toolbar-colors{border:1px solid #808080;}.yui-skin-sam .yui-editor-panel{padding:0;margin:0;border:none;background-color:transparent;overflow:visible;}.yui-skin-sam .yui-editor-panel .hd{margin:10px 0 0;padding:0;border:none;}.yui-skin-sam .yui-editor-panel .hd h3{color:#000;border:1px solid #808080;background:url(sprite.png) repeat-x 0 -200px;width:99%;position:relative;margin:0;padding:3px 0 0 0;font-size:93%;text-indent:5px;height:20px;}.yui-skin-sam .yui-editor-panel .bd{background-color:#F2F2F2;border-left:1px solid #808080;border-right:1px solid #808080;width:99%;margin:0;padding:0;overflow:visible;}.yui-skin-sam .yui-editor-panel ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-panel ul li{margin:0;padding:0;}.yui-skin-sam .yui-editor-panel .yuimenu{}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .yui-toolbar-subcont{padding:0;border:none;margin-top:0.35em;}.yui-skin-sam .yui-editor-panel .yui-toolbar-bordersize,.yui-skin-sam .yui-editor-panel .yui-toolbar-bordertype{width:50px;}.yui-skin-sam .yui-editor-panel label{display:block;float:none;padding:4px 0;margin-bottom:7px;}.yui-skin-sam .yui-editor-panel label strong{font-weight:normal;font-size:93%;text-align:right;padding-top:2px;}.yui-skin-sam .yui-editor-panel label input{width:75%;}.yui-skin-sam .yui-editor-panel .createlink_target,.yui-skin-sam .yui-editor-panel .insertimage_target{width:auto;margin-right:5px;}.yui-skin-sam .yui-editor-panel .removeLink{width:98%;}.yui-skin-sam .yui-editor-panel label input.warning{background-color:#FFEE69;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group h3{color:#000;float:left;font-weight:normal;font-size:93%;margin:5px 0 0 0;padding:0 3px 0 0;text-align:right;}.yui-skin-sam .yui-editor-panel .height-width h3{margin:3px 0 0 10px;}.yui-skin-sam .yui-editor-panel .height-width{margin:3px 0 0 35px;*margin-left:14px;width:42%;*width:44%;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-border{width:190px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-border{width:210px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding{width:203px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-padding{width:172px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding h3{margin-left:25px;*margin-left:12px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-textflow{width:182px;}.yui-skin-sam .yui-editor-panel .hd{background:none;}.yui-skin-sam .yui-editor-panel .ft{background-color:#F2F2F2;border:1px solid #808080;border-top:none;padding:0;margin:0 0 2px 0;}.yui-skin-sam .yui-editor-panel .hd span.close{background:url(sprite.png) no-repeat 0 -300px;cursor:pointer;display:block;height:16px;overflow:hidden;position:absolute;right:5px;text-indent:500px;top:2px;width:26px;}.yui-skin-sam .yui-editor-panel .ft span.tip{background-color:#EDF5FF;border-top:1px solid #808080;font-size:85%;}.yui-skin-sam .yui-editor-panel .ft span.tip strong{display:block;float:left;margin:0 2px 8px 0;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon{background:url( editor-sprite.gif ) no-repeat 0 -1260px;display:block;height:20px;left:2px;position:absolute;top:8px;width:20px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-info{background-position:2px -1260px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-warn{background-position:2px -1296px;}.yui-skin-sam .yui-editor-panel .hd span.knob{position:absolute;height:10px;width:28px;top:-10px;left:25px;text-indent:9999px;overflow:hidden;background:url( editor-knob.gif ) no-repeat 0 0;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container{float:left;width:100%;background-image:none;border:none;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .bd{background-color:#ffffff;}.yui-editor-blankimage{background-image:url( blankimage.png );} +.yui-crop{position:relative;}.yui-crop .yui-crop-mask{position:absolute;top:0;left:0;height:100%;width:100%;}.yui-crop .yui-resize{position:absolute;top:10px;left:10px;}.yui-crop .yui-crop-resize-mask{position:absolute;top:0;left:0;height:100%;width:100%;background-position:-10px -10px;overflow:hidden;}.yui-skin-sam .yui-crop .yui-crop-mask{background-color:#000;opacity:.5;filter:alpha(opacity=50);}.yui-skin-sam .yui-crop .yui-resize{border:1px dashed #fff;} +.yui-layout-loading{visibility:hidden;}body.yui-layout{overflow:hidden;position:relative;padding:0;margin:0;}.yui-layout-doc{position:relative;}.yui-layout-unit{height:50px;width:50px;padding:0;margin:0;float:none;z-index:0;overflow:hidden;}.yui-layout-unit-top{position:absolute;top:0;left:0;width:100%;}.yui-layout-unit-left{position:absolute;top:0;left:0;}.yui-layout-unit-right{position:absolute;top:0;right:0;}.yui-layout-unit-bottom{position:absolute;bottom:0;left:0;width:100%;}.yui-layout-unit-center{position:absolute;top:0;left:0;width:100%;}.yui-layout div.yui-layout-hd{position:absolute;top:0;left:0;zoom:1;width:100%;overflow:hidden;}.yui-layout div.yui-layout-bd{position:absolute;top:0;left:0;zoom:1;width:100%;overflow:hidden;}.yui-layout .yui-layout-scroll div.yui-layout-bd{overflow:auto;}.yui-layout div.yui-layout-ft{position:absolute;bottom:0;left:0;width:100%;zoom:1;overflow:hidden;}.yui-layout .yui-layout-unit div.yui-layout-hd h2{text-align:left;}.yui-layout .yui-layout-unit div.yui-layout-hd .collapse{cursor:pointer;height:13px;position:absolute;right:2px;top:2px;width:17px;font-size:0;}.yui-layout .yui-layout-unit div.yui-layout-hd .close{cursor:pointer;height:13px;position:absolute;right:2px;top:2px;width:17px;font-size:0;}.yui-layout .yui-layout-unit div.yui-layout-hd .collapse-close{right:25px;}.yui-layout .yui-layout-clip{position:absolute;height:20px;background-color:#c0c0c0;display:none;}.yui-layout .yui-layout-clip .collapse{cursor:pointer;height:13px;position:absolute;right:2px;top:2px;width:17px;font-size:0px;}.yui-layout .yui-layout-wrap{height:100%;width:100%;position:absolute;left:0;}.yui-layout .yui-layout-unit .yui-content{overflow:hidden;}.yui-layout .yui-layout-unit .yui-layout-scroll{overflow:visible;}.yui-skin-sam .yui-layout .yui-resize-proxy{border:none;font-size:0;margin:0;padding:0;}.yui-skin-sam .yui-layout .yui-resize-resizing .yui-resize-handle{opacity:0;filter:alpha(opacity=0);}.yui-skin-sam .yui-layout .yui-resize-proxy div{position:absolute;border:1px solid #808080;background-color:#EDF5FF;}.yui-skin-sam .yui-layout .yui-resize .yui-resize-handle-active{background-color:#EDF5FF;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-l{width:5px;height:100%;top:0;left:0;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-r{width:5px;top:0;right:0;height:100%;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-b{width:100%;bottom:0;left:0;height:5px;}.yui-skin-sam .yui-layout .yui-resize-proxy .yui-layout-handle-t{width:100%;top:0;left:0;height:5px;}.yui-skin-sam .yui-layout .yui-layout-unit-left div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -160px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-left .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -140px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit-right div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -200px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-right .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -120px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit-top div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -220px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-top .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -240px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit-bottom div.yui-layout-hd .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -260px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip-bottom .collapse{background:transparent url(layout_sprite.png) no-repeat -20px -180px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-hd .close{background:transparent url(layout_sprite.png) no-repeat -20px -100px;border:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-hd{background:url(sprite.png) repeat-x 0 -1400px;border:1px solid #808080;}.yui-skin-sam .yui-layout{background-color:#EDF5FF;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-hd h2{font-weight:bold;color:#fff;padding:3px;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-bd{border:1px solid #808080;border-bottom:none;border-top:none;*border-bottom-width:0;*border-top-width:0;background-color:#f2f2f2;text-align:left;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-bd-noft{border-bottom:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-unit div.yui-layout-bd-nohd{border-top:1px solid #808080;}.yui-skin-sam .yui-layout .yui-layout-clip{position:absolute;height:20px;background-color:#EDF5FF;display:none;border:1px solid #808080;}.yui-skin-sam .yui-layout div.yui-layout-ft{border:1px solid #808080;border-top:none;*border-top-width:0;background-color:#f2f2f2;}.yui-skin-sam .yui-layout-unit .yui-resize-handle{background-color:transparent;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-r{right:0;top:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-l{left:0;top:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-b{right:0;bottom:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-t{right:0;top:0;background-image:none;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-r .yui-layout-resize-knob,.yui-skin-sam .yui-layout-unit .yui-resize-handle-l .yui-layout-resize-knob{position:absolute;height:16px;width:6px;top:45%;left:0px;background:transparent url(layout_sprite.png) no-repeat 0 -5px;}.yui-skin-sam .yui-layout-unit .yui-resize-handle-t .yui-layout-resize-knob,.yui-skin-sam .yui-layout-unit .yui-resize-handle-b .yui-layout-resize-knob{position:absolute;height:6px;width:16px;left:45%;background:transparent url(layout_sprite.png) no-repeat -20px 0;} +.yui-skin-sam .yui-log{padding:1em;width:31em;background-color:#AAA;color:#000;border:1px solid black;font-family:monospace;font-size:77%;text-align:left;z-index:9000;}.yui-skin-sam .yui-log-container{position:absolute;top:1em;right:1em;}.yui-skin-sam .yui-log input{margin:0;padding:0;font-family:arial;font-size:100%;font-weight:normal;}.yui-skin-sam .yui-log .yui-log-btns{position:relative;float:right;bottom:.25em;}.yui-skin-sam .yui-log .yui-log-hd{margin-top:1em;padding:.5em;background-color:#575757;}.yui-skin-sam .yui-log .yui-log-hd h4{margin:0;padding:0;font-size:108%;font-weight:bold;color:#FFF;}.yui-skin-sam .yui-log .yui-log-bd{width:100%;height:20em;background-color:#FFF;border:1px solid gray;overflow:auto;}.yui-skin-sam .yui-log p{margin:1px;padding:.1em;}.yui-skin-sam .yui-log pre{margin:0;padding:0;}.yui-skin-sam .yui-log pre.yui-log-verbose{white-space:pre-wrap;white-space:-moz-pre-wrap !important;white-space:-pre-wrap;white-space:-o-pre-wrap;word-wrap:break-word;}.yui-skin-sam .yui-log .yui-log-ft{margin-top:.5em;}.yui-skin-sam .yui-log .yui-log-ft .yui-log-categoryfilters{}.yui-skin-sam .yui-log .yui-log-ft .yui-log-sourcefilters{width:100%;border-top:1px solid #575757;margin-top:.75em;padding-top:.75em;}.yui-skin-sam .yui-log .yui-log-filtergrp{margin-right:.5em;}.yui-skin-sam .yui-log .info{background-color:#A7CC25;}.yui-skin-sam .yui-log .warn{background-color:#F58516;}.yui-skin-sam .yui-log .error{background-color:#E32F0B;}.yui-skin-sam .yui-log .time{background-color:#A6C9D7;}.yui-skin-sam .yui-log .window{background-color:#F2E886;} +.yuimenubar{visibility:visible;position:static;}.yuimenu .yuimenu,.yuimenubar .yuimenu{visibility:hidden;position:absolute;top:-10000px;left:-10000px;}.yuimenubar li,.yuimenu li{list-style-type:none;}.yuimenubar ul,.yuimenu ul,.yuimenubar li,.yuimenu li,.yuimenu h6,.yuimenubar h6{margin:0;padding:0;}.yuimenuitemlabel,.yuimenubaritemlabel{text-align:left;white-space:nowrap;}.yuimenubar ul{*zoom:1;}.yuimenubar .yuimenu ul{*zoom:normal;}.yuimenubar>.bd>ul:after{content:".";display:block;clear:both;visibility:hidden;height:0;line-height:0;}.yuimenubaritem{float:left;}.yuimenubaritemlabel,.yuimenuitemlabel{display:block;}.yuimenuitemlabel .helptext{font-style:normal;display:block;margin:-1em 0 0 10em;}.yui-menu-shadow{position:absolute;visibility:hidden;z-index:-1;}.yui-menu-shadow-visible{top:2px;right:-3px;left:-3px;bottom:-3px;visibility:visible;}.hide-scrollbars *{overflow:hidden;}.hide-scrollbars select{display:none;}.yuimenu.show-scrollbars,.yuimenubar.show-scrollbars{overflow:visible;}.yuimenu.hide-scrollbars .yui-menu-shadow,.yuimenubar.hide-scrollbars .yui-menu-shadow{overflow:hidden;}.yuimenu.show-scrollbars .yui-menu-shadow,.yuimenubar.show-scrollbars .yui-menu-shadow{overflow:auto;}.yui-skin-sam .yuimenubar{font-size:93%;line-height:2;*line-height:1.9;border:solid 1px #808080;background:url(sprite.png) repeat-x 0 0;}.yui-skin-sam .yuimenubarnav .yuimenubaritem{border-right:solid 1px #ccc;}.yui-skin-sam .yuimenubaritemlabel{padding:0 10px;color:#000;text-decoration:none;cursor:default;border-style:solid;border-color:#808080;border-width:1px 0;*position:relative;margin:-1px 0;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel{padding-right:20px;*display:inline-block;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel-hassubmenu{background:url(menubaritem_submenuindicator.png) right center no-repeat;}.yui-skin-sam .yuimenubaritem-selected{background:url(sprite.png) repeat-x 0 -1700px;}.yui-skin-sam .yuimenubaritemlabel-selected{border-color:#7D98B8;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel-selected{border-left-width:1px;margin-left:-1px;*left:-1px;}.yui-skin-sam .yuimenubaritemlabel-disabled{cursor:default;color:#A6A6A6;}.yui-skin-sam .yuimenubarnav .yuimenubaritemlabel-hassubmenu-disabled{background-image:url(menubaritem_submenuindicator_disabled.png);}.yui-skin-sam .yuimenu{font-size:93%;line-height:1.5;*line-height:1.45;}.yui-skin-sam .yuimenubar .yuimenu,.yui-skin-sam .yuimenu .yuimenu{font-size:100%;}.yui-skin-sam .yuimenu .bd{border:solid 1px #808080;background-color:#fff;}.yui-skin-sam .yuimenu ul{padding:3px 0;border-width:1px 0 0 0;border-color:#ccc;border-style:solid;}.yui-skin-sam .yuimenu ul.first-of-type{border-width:0;}.yui-skin-sam .yuimenu h6{font-weight:bold;border-style:solid;border-color:#ccc;border-width:1px 0 0 0;color:#a4a4a4;padding:3px 10px 0 10px;}.yui-skin-sam .yuimenu ul.hastitle,.yui-skin-sam .yuimenu h6.first-of-type{border-width:0;}.yui-skin-sam .yuimenu .yui-menu-body-scrolled{border-color:#ccc #808080;overflow:hidden;}.yui-skin-sam .yuimenu .topscrollbar,.yui-skin-sam .yuimenu .bottomscrollbar{height:16px;border:solid 1px #808080;background:#fff url(sprite.png) no-repeat 0 0;}.yui-skin-sam .yuimenu .topscrollbar{border-bottom-width:0;background-position:center -950px;}.yui-skin-sam .yuimenu .topscrollbar_disabled{background-position:center -975px;}.yui-skin-sam .yuimenu .bottomscrollbar{border-top-width:0;background-position:center -850px;}.yui-skin-sam .yuimenu .bottomscrollbar_disabled{background-position:center -875px;}.yui-skin-sam .yuimenuitem{_border-bottom:solid 1px #fff;}.yui-skin-sam .yuimenuitemlabel{padding:0 20px;color:#000;text-decoration:none;cursor:default;}.yui-skin-sam .yuimenuitemlabel .helptext{margin-top:-1.5em;*margin-top:-1.45em;}.yui-skin-sam .yuimenuitem-hassubmenu{background-image:url(menuitem_submenuindicator.png);background-position:right center;background-repeat:no-repeat;}.yui-skin-sam .yuimenuitem-checked{background-image:url(menuitem_checkbox.png);background-position:left center;background-repeat:no-repeat;}.yui-skin-sam .yui-menu-shadow-visible{background-color:#000;opacity:.12;*filter:alpha(opacity=12);}.yui-skin-sam .yuimenuitem-selected{background-color:#B3D4FF;}.yui-skin-sam .yuimenuitemlabel-disabled{cursor:default;color:#A6A6A6;}.yui-skin-sam .yuimenuitem-hassubmenu-disabled{background-image:url(menuitem_submenuindicator_disabled.png);}.yui-skin-sam .yuimenuitem-checked-disabled{background-image:url(menuitem_checkbox_disabled.png);} +.yui-skin-sam .yui-pv{background-color:#4a4a4a;font:arial;position:relative;width:99%;z-index:1000;margin-bottom:1em;overflow:hidden;}.yui-skin-sam .yui-pv .hd{background:url(header_background.png) repeat-x;min-height:30px;overflow:hidden;zoom:1;padding:2px 0;}.yui-skin-sam .yui-pv .hd h4{padding:8px 10px;margin:0;font:bold 14px arial;color:#fff;}.yui-skin-sam .yui-pv .hd a{background:#3f6bc3;font:bold 11px arial;color:#fff;padding:4px;margin:3px 10px 0 0;border:1px solid #3f567d;cursor:pointer;display:block;float:right;}.yui-skin-sam .yui-pv .hd span{display:none;}.yui-skin-sam .yui-pv .hd span.yui-pv-busy{height:18px;width:18px;background:url(wait.gif) no-repeat;overflow:hidden;display:block;float:right;margin:4px 10px 0 0;}.yui-skin-sam .yui-pv .hd:after,.yui-pv .bd:after,.yui-skin-sam .yui-pv-chartlegend dl:after{content:'.';visibility:hidden;clear:left;height:0;display:block;}.yui-skin-sam .yui-pv .bd{position:relative;zoom:1;overflow-x:auto;overflow-y:hidden;}.yui-skin-sam .yui-pv .yui-pv-table{padding:0 10px;margin:5px 0 10px 0;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-bd td{color:#eeee5c;font:12px arial;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-odd{background:#929292;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-even{background:#58637a;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-even td.yui-dt-asc,.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-even td.yui-dt-desc{background:#384970;}.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-odd td.yui-dt-asc,.yui-skin-sam .yui-pv .yui-pv-table tr.yui-dt-odd td.yui-dt-desc{background:#6F6E6E;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th{background-image:none;background:#2E2D2D;}.yui-skin-sam .yui-pv th.yui-dt-asc .yui-dt-liner{background:transparent url(asc.gif) no-repeat scroll right center;}.yui-skin-sam .yui-pv th.yui-dt-desc .yui-dt-liner{background:transparent url(desc.gif) no-repeat scroll right center;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th a{color:#fff;font:bold 12px arial;}.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th.yui-dt-asc,.yui-skin-sam .yui-pv .yui-pv-table .yui-dt-hd th.yui-dt-desc{background:#333;}.yui-skin-sam .yui-pv-chartcontainer{padding:0 10px;}.yui-skin-sam .yui-pv-chart{height:250px;clear:right;margin:5px 0 0 0;color:#fff;}.yui-skin-sam .yui-pv-chartlegend div{float:right;margin:0 0 0 10px;_width:250px;}.yui-skin-sam .yui-pv-chartlegend dl{border:1px solid #999;padding:.2em 0 .2em .5em;zoom:1;margin:5px 0;}.yui-skin-sam .yui-pv-chartlegend dt{float:left;display:block;height:.7em;width:.7em;padding:0;}.yui-skin-sam .yui-pv-chartlegend dd{float:left;display:block;color:#fff;margin:0 1em 0 .5em;padding:0;font:11px arial;}.yui-skin-sam .yui-pv-minimized{height:35px;}.yui-skin-sam .yui-pv-minimized .bd{top:-3000px;}.yui-skin-sam .yui-pv-minimized .hd a.yui-pv-refresh{display:none;} +.yui-resize{position:relative;zoom:1;z-index:0;}.yui-resize-wrap{zoom:1;}.yui-draggable{cursor:move;}.yui-resize .yui-resize-handle{position:absolute;z-index:1;font-size:0;margin:0;padding:0;zoom:1;height:1px;width:1px;}.yui-resize .yui-resize-handle-br{height:5px;width:5px;bottom:0;right:0;cursor:se-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-bl{height:5px;width:5px;bottom:0;left:0;cursor:sw-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-tl{height:5px;width:5px;top:0;left:0;cursor:nw-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-tr{height:5px;width:5px;top:0;right:0;cursor:ne-resize;z-index:2;zoom:1;}.yui-resize .yui-resize-handle-r{width:5px;height:100%;top:0;right:0;cursor:e-resize;zoom:1;}.yui-resize .yui-resize-handle-l{height:100%;width:5px;top:0;left:0;cursor:w-resize;zoom:1;}.yui-resize .yui-resize-handle-b{width:100%;height:5px;bottom:0;right:0;cursor:s-resize;zoom:1;}.yui-resize .yui-resize-handle-t{width:100%;height:5px;top:0;right:0;cursor:n-resize;zoom:1;}.yui-resize-proxy{position:absolute;border:1px dashed #000;visibility:hidden;z-index:1000;}.yui-resize-hover .yui-resize-handle,.yui-resize-hidden .yui-resize-handle{opacity:0;filter:alpha(opacity=0);}.yui-resize-ghost{opacity:.5;filter:alpha(opacity=50);}.yui-resize-knob .yui-resize-handle{height:6px;width:6px;}.yui-resize-knob .yui-resize-handle-tr{right:-3px;top:-3px;}.yui-resize-knob .yui-resize-handle-tl{left:-3px;top:-3px;}.yui-resize-knob .yui-resize-handle-bl{left:-3px;bottom:-3px;}.yui-resize-knob .yui-resize-handle-br{right:-3px;bottom:-3px;}.yui-resize-knob .yui-resize-handle-t{left:45%;top:-3px;}.yui-resize-knob .yui-resize-handle-r{right:-3px;top:45%;}.yui-resize-knob .yui-resize-handle-l{left:-3px;top:45%;}.yui-resize-knob .yui-resize-handle-b{left:45%;bottom:-3px;}.yui-resize-status{position:absolute;top:-999px;left:-999px;padding:2px;font-size:80%;display:none;zoom:1;z-index:9999;}.yui-resize-status strong,.yui-resize-status em{font-weight:normal;font-style:normal;padding:1px;zoom:1;}.yui-skin-sam .yui-resize .yui-resize-handle{background-color:#F2F2F2;}.yui-skin-sam .yui-resize .yui-resize-handle-active{background-color:#7D98B8;zoom:1;}.yui-skin-sam .yui-resize .yui-resize-handle-l,.yui-skin-sam .yui-resize .yui-resize-handle-r,.yui-skin-sam .yui-resize .yui-resize-handle-l-active,.yui-skin-sam .yui-resize .yui-resize-handle-r-active{height:100%;}.yui-skin-sam .yui-resize-knob .yui-resize-handle{border:1px solid #808080;}.yui-skin-sam .yui-resize-hover .yui-resize-handle-active{opacity:1;filter:alpha(opacity=100);}.yui-skin-sam .yui-resize-proxy{border:1px dashed #426FD9;}.yui-skin-sam .yui-resize-status{border:1px solid #A6982B;border-top:1px solid #D4C237;background-color:#FFEE69}.yui-skin-sam .yui-resize-status strong,.yui-skin-sam .yui-resize-status em{float:left;display:block;clear:both;padding:1px;text-align:center;}.yui-skin-sam .yui-resize .yui-resize-handle-inner-r,.yui-skin-sam .yui-resize .yui-resize-handle-inner-l{background:transparent url( layout_sprite.png) no-repeat 0 -5px;height:16px;width:5px;position:absolute;top:45%;}.yui-skin-sam .yui-resize .yui-resize-handle-inner-t,.yui-skin-sam .yui-resize .yui-resize-handle-inner-b{background:transparent url(layout_sprite.png) no-repeat -20px 0;height:5px;width:16px;position:absolute;left:50%;}.yui-skin-sam .yui-resize .yui-resize-handle-br{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -62px;}.yui-skin-sam .yui-resize .yui-resize-handle-tr{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -42px;}.yui-skin-sam .yui-resize .yui-resize-handle-tl{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -82px;}.yui-skin-sam .yui-resize .yui-resize-handle-bl{background-image:url( layout_sprite.png );background-repeat:no-repeat;background-position:-22px -23px;}.yui-skin-sam .yui-resize-knob .yui-resize-handle-t,.yui-skin-sam .yui-resize-knob .yui-resize-handle-r,.yui-skin-sam .yui-resize-knob .yui-resize-handle-b,.yui-skin-sam .yui-resize-knob .yui-resize-handle-l,.yui-skin-sam .yui-resize-knob .yui-resize-handle-tl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-tr,.yui-skin-sam .yui-resize-knob .yui-resize-handle-bl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-br,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-t,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-r,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-b,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-l,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-tl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-tr,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-bl,.yui-skin-sam .yui-resize-knob .yui-resize-handle-inner-br{background-image:none;}.yui-skin-sam .yui-resize-knob .yui-resize-handle-l,.yui-skin-sam .yui-resize-knob .yui-resize-handle-r,.yui-skin-sam .yui-resize-knob .yui-resize-handle-l-active,.yui-skin-sam .yui-resize-knob .yui-resize-handle-r-active{height:6px;width:6px;} +.yui-busy{cursor:wait !important;}.yui-toolbar-container fieldset{padding:0;margin:0;border:0;}.yui-toolbar-container legend{display:none;}.yui-toolbar-container .yui-toolbar-subcont{padding:.25em 0;zoom:1;}.yui-toolbar-container-collapsed .yui-toolbar-subcont{display:none;}.yui-toolbar-container .yui-toolbar-subcont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container span.yui-toolbar-draghandle{cursor:move;border-left:1px solid #999;border-right:1px solid #999;overflow:hidden;text-indent:77777px;width:2px;height:20px;display:block;clear:none;float:left;margin:0 0 0 .2em;}.yui-toolbar-container .yui-toolbar-titlebar.draggable{cursor:move;}.yui-toolbar-container .yui-toolbar-titlebar{position:relative;}.yui-toolbar-container .yui-toolbar-titlebar h2{font-weight:bold;letter-spacing:0;border:none;color:#000;margin:0;padding:.2em;}.yui-toolbar-container .yui-toolbar-titlebar h2 a{text-decoration:none;color:#000;cursor:default;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-draghandle{height:40px;}.yui-toolbar-container .yui-toolbar-group{float:left;zoom:1;}.yui-toolbar-container .yui-toolbar-group:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-container .yui-toolbar-group h3{font-size:75%;padding:0 0 0 .25em;margin:0;}.yui-toolbar-container span.yui-toolbar-separator{width:2px;height:18px;margin:.2em 0 .2em .1em;display:block;clear:none;float:left;}.yui-toolbar-container.yui-toolbar-grouped span.yui-toolbar-separator{height:35px;}.yui-toolbar-container.yui-toolbar-grouped .yui-toolbar-group span.yui-toolbar-separator{height:18px;}.yui-toolbar-container ul li{margin:0;padding:0;list-style-type:none;}.yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-toolbar-container .yui-push-button,.yui-toolbar-container .yui-color-button,.yui-toolbar-container .yui-menu-button{position:relative;cursor:pointer;}.yui-toolbar-container .yui-button .first-child,.yui-toolbar-container .yui-button .first-child a{height:100%;width:100%;overflow:hidden;}.yui-toolbar-container .yui-button-disabled{cursor:default;}.yui-toolbar-container .yui-button-disabled .yui-toolbar-icon{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button-disabled .up,.yui-toolbar-container .yui-button-disabled .down{opacity:.5;filter:alpha(opacity=50);}.yui-toolbar-container .yui-button a{overflow:hidden;}.yui-toolbar-container .yui-toolbar-select .first-child a{cursor:pointer;}.yui-toolbar-fontname-arial{font-family:Arial;}.yui-toolbar-fontname-arial-black{font-family:Arial Black;}.yui-toolbar-fontname-comic-sans-ms{font-family:Comic Sans MS;}.yui-toolbar-fontname-courier-new{font-family:Courier New;}.yui-toolbar-fontname-times-new-roman{font-family:Times New Roman;}.yui-toolbar-fontname-verdana{font-family:Verdana;}.yui-toolbar-fontname-impact{font-family:Impact;}.yui-toolbar-fontname-lucida-console{font-family:Lucida Console;}.yui-toolbar-fontname-tahoma{font-family:Tahoma;}.yui-toolbar-fontname-trebuchet-ms{font-family:Trebuchet MS;}.yui-toolbar-container .yui-toolbar-spinbutton{position:relative;}.yui-toolbar-container .yui-toolbar-spinbutton .first-child a{z-index:0;opacity:1;}.yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-toolbar-container .yui-toolbar-spinbutton a.down{position:absolute;display:block right:0;cursor:pointer;z-index:1;padding:0;margin:0;}.yui-toolbar-container .yui-overlay{position:absolute;}.yui-toolbar-container .yui-overlay ul li{margin:0;list-style-type:none;}.yui-toolbar-container{z-index:1;}.yui-editor-container .yui-editor-editable-container{position:relative;z-index:0;width:100%;}.yui-editor-container .yui-editor-masked{background-color:#CCC;}.yui-editor-container iframe{border:0px;padding:0;margin:0;zoom:1;display:block;}.yui-editor-container .yui-editor-editable{padding:0;margin:0;}.yui-editor-container .dompath{font-size:85%;}.yui-editor-panel .hd{text-align:left;position:relative;}.yui-editor-panel .hd h3{font-weight:bold;padding:0.25em 0pt 0.25em 0.25em;margin:0;}.yui-editor-panel .bd{width:100%;zoom:1;position:relative;}.yui-editor-panel .bd div.yui-editor-body-cont{padding:.25em .1em;zoom:1;}.yui-editor-panel .bd .gecko form{overflow:auto;}.yui-editor-panel .bd div.yui-editor-body-cont:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-editor-panel .ft{text-align:right;width:99%;float:left;clear:both;}.yui-editor-panel .ft span.tip{display:block;position:relative;padding:.5em .5em .5em 23px;text-align:left;zoom:1;}.yui-editor-panel label{clear:both;float:left;padding:0;width:100%;text-align:left;zoom:1;}.yui-editor-panel .gecko label{overflow:auto;}.yui-editor-panel label strong{float:left;width:6em;}.yui-editor-panel .removeLink{width:80%;text-align:right;}.yui-editor-panel label input{margin-left:.25em;float:left;}.yui-editor-panel .yui-toolbar-group-padding{}.yui-editor-panel .yui-toolbar-group-border{}.yui-editor-panel .yui-toolbar-group-textflow{}.yui-editor-panel .height-width{float:left;}.yui-editor-panel .height-width h3{}.yui-editor-panel .height-width span{font-style:italic;display:block;float:left;overflow:visible;}.yui-editor-panel .height-width span.info{font-size:70%;margin-top:3px;}.yui-editor-panel .yui-toolbar-bordersize,.yui-editor-panel .yui-toolbar-bordertype{font-size:75%;}.yui-editor-panel .yui-toolbar-container span.yui-toolbar-separator{border:none;}.yui-editor-panel .yui-toolbar-bordersize span a span,.yui-editor-panel .yui-toolbar-bordertype span a span{display:block;height:8px;left:4px;position:absolute;top:3px;*top:-5px;width:24px;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-solid{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dotted{border-bottom:1px dotted black;}.yui-editor-panel .yui-toolbar-bordertype span a span.yui-toolbar-bordertype-dashed{border-bottom:1px dashed black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-0{*top:0px;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-1{border-bottom:1px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-2{border-bottom:2px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-3{top:2px;*top:-5px;border-bottom:3px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-4{top:1px;*top:-5px;border-bottom:4px solid black;}.yui-editor-panel .yui-toolbar-bordersize span a span.yui-toolbar-bordersize-5{top:1px;*top:-5px;border-bottom:5px solid black;}.yui-toolbar-container .yui-toolbar-bordersize-menu,.yui-toolbar-container .yui-toolbar-bordertype-menu{width:95px !important;}.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel,.yui-toolbar-bordersize-menu .yuimenuitemlabel,.yui-toolbar-bordertype-menu .yuimenuitemlabel:hover{margin:0px 3px 7px 17px;}.yui-toolbar-bordersize-menu .yuimenuitemlabel .checkedindicator,.yui-toolbar-bordertype-menu .yuimenuitemlabel .checkedindicator{position:absolute;left:-12px;*top:14px;*left:0px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-1 a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-2 a{border-bottom:2px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-3 a{border-bottom:3px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-4 a{border-bottom:4px solid black;height:14px;}.yui-toolbar-bordersize-menu li.yui-toolbar-bordersize-5 a{border-bottom:5px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-solid a{border-bottom:1px solid black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dashed a{border-bottom:1px dashed black;height:14px;}.yui-toolbar-bordertype-menu li.yui-toolbar-bordertype-dotted a{border-bottom:1px dotted black;height:14px;}h2.yui-editor-skipheader,h3.yui-editor-skipheader{height:0;margin:0;padding:0;border:none;width:0;overflow:hidden;position:absolute;}.yui-toolbar-colors{width:133px;zoom:1;display:none;z-index:100;overflow:hidden;}.yui-toolbar-colors:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors a{height:9px;width:9px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0;cursor:pointer;border:1px solid #F6F7EE;}.yui-toolbar-colors a:hover{border:1px solid black;}.yui-color-button-menu{overflow:visible;background-color:transparent;}.yui-toolbar-colors span{position:relative;display:block;padding:3px;overflow:hidden;float:left;width:100%;zoom:1;}.yui-toolbar-colors span:after{display:block;clear:both;visibility:hidden;content:'.';height:0;}.yui-toolbar-colors span em{height:35px;width:30px;float:left;display:block;overflow:hidden;text-indent:999px;margin:0.75px;border:1px solid black;}.yui-toolbar-colors span strong{font-weight:normal;padding-left:3px;display:block;font-size:85%;float:left;width:65%;}.yui-skin-sam .yui-editor-container{border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container{zoom:1;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar{background:url(sprite.png) repeat-x 0 -200px;position:relative;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar h2{color:#000000;font-weight:bold;margin:0;padding:0.3em 1em;font-size:100%;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-group h3{color:#808080;font-size:75%;margin:1em 0 0;padding-bottom:0;padding-left:0.25em;text-align:left;}.yui-toolbar-container span.yui-toolbar-separator{border:none;text-indent:33px;overflow:hidden;margin:0 .25em;}.yui-skin-sam .yui-toolbar-container{background-color:#F2F2F2;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subcont{padding:0 1em 0.35em;border-bottom:1px solid #808080;}.yui-skin-sam .yui-toolbar-container-collapsed .yui-toolbar-titlebar{border-bottom:1px solid #808080;}.yui-skin-sam .yui-editor-container .visible .yui-menu-shadow,.yui-skin-sam .yui-editor-panel .visible .yui-menu-shadow{display:none;}.yui-skin-sam .yui-editor-container ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-container ul li{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-toolbar-group ul li.yui-toolbar-groupitem{float:left;}.yui-skin-sam .yui-editor-container .dompath{background-color:#F2F2F2;border-top:1px solid #808080;color:#999;text-align:left;padding:0.25em;}.yui-skin-sam .yui-toolbar-container .collapse{background:url(sprite.png) no-repeat 0 -400px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-titlebar span.collapse{cursor:pointer;position:absolute;top:4px;right:2px;display:block;overflow:hidden;height:15px;width:15px;text-indent:9999px;}.yui-skin-sam .yui-toolbar-container .yui-push-button,.yui-skin-sam .yui-toolbar-container .yui-color-button,.yui-skin-sam .yui-toolbar-container .yui-menu-button{background:url(sprite.png) repeat-x 0 0;position:relative;display:block;height:22px;width:30px;margin:0;border-color:#808080;border-style:solid;border-width:1px 0;}.yui-skin-sam .yui-toolbar-container .yui-push-button a,.yui-skin-sam .yui-toolbar-container .yui-color-button a,.yui-skin-sam .yui-toolbar-container .yui-menu-button a{padding-left:35px;height:20px;text-decoration:none;font-size:93%;line-height:2;display:block;color:#000000;overflow:hidden;}.yui-skin-sam .yui-toolbar-container .yui-push-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button .first-child{border-color:#808080;border-style:solid;border-width:0 1px;margin:0 -1px;display:block;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled .first-child,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled .first-child{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled a,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled a{color:#A6A6A6;cursor:default;}.yui-skin-sam .yui-toolbar-container .yui-push-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-color-button-disabled,.yui-skin-sam .yui-toolbar-container .yui-menu-button-disabled{border-color:#ccc;}.yui-skin-sam .yui-toolbar-container .yui-button .first-child{*left:0px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-fontname{width:135px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-heading{width:92px;}.yui-skin-sam .yui-toolbar-container .yui-button-hover{background:url(sprite.png) repeat-x 0 -1300px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-button-selected{background:url(sprite.png) repeat-x 0 -1700px;border-color:#808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels h3{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-nogrouplabels .yui-toolbar-group{margin-top:.75em;}.yui-skin-sam .yui-toolbar-container .yui-push-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-color-button span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-menu-button span.yui-toolbar-icon{display:block;position:absolute;top:2px;height:18px;width:18px;overflow:hidden;background:url(editor-sprite.gif) no-repeat 30px 30px;}.yui-skin-sam .yui-toolbar-container .yui-button-selected span.yui-toolbar-icon,.yui-skin-sam .yui-toolbar-container .yui-button-hover span.yui-toolbar-icon{background-image:url(editor-sprite-active.gif);}.yui-skin-sam .yui-toolbar-container .visible .yuimenuitemlabel{cursor:pointer;color:#000;*position:relative;}.yui-skin-sam .yui-toolbar-container .yui-button-menu{background-color:#fff;}.yui-skin-sam div.yuimenu li.selected{background-color:#B3D4FF;}.yui-skin-sam div.yuimenu li.selected a.selected{color:#000;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bold span.yui-toolbar-icon{background-position:0 0;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-strikethrough span.yui-toolbar-icon{background-position:0 -108px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-italic span.yui-toolbar-icon{background-position:0 -36px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-underline span.yui-toolbar-icon{background-position:0 -72px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-subscript span.yui-toolbar-icon{background-position:0 -180px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-superscript span.yui-toolbar-icon{background-position:0 -144px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-forecolor span.yui-toolbar-icon{background-position:0 -216px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-backcolor span.yui-toolbar-icon{background-position:0 -288px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyleft span.yui-toolbar-icon{background-position:0 -324px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifycenter span.yui-toolbar-icon{background-position:0 -360px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyright span.yui-toolbar-icon{background-position:0 -396px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-justifyfull span.yui-toolbar-icon{background-position:0 -432px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-indent span.yui-toolbar-icon{background-position:0 -720px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-outdent span.yui-toolbar-icon{background-position:0 -684px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-createlink span.yui-toolbar-icon{background-position:0 -792px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertimage span.yui-toolbar-icon{background-position:1px -756px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-left span.yui-toolbar-icon{background-position:0 -972px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-right span.yui-toolbar-icon{background-position:0 -936px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-inline span.yui-toolbar-icon{background-position:0 -900px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-block span.yui-toolbar-icon{background-position:0 -864px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-bordercolor span.yui-toolbar-icon{background-position:0 -252px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-removeformat span.yui-toolbar-icon{background-position:0 -1080px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-hiddenelements span.yui-toolbar-icon{background-position:0 -1044px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertunorderedlist span.yui-toolbar-icon{background-position:0 -468px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-insertorderedlist span.yui-toolbar-icon{background-position:0 -504px;left:5px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child{width:35px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton .first-child a{padding-left:2px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton span.yui-toolbar-icon{display:none;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up,.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{right:2px;background:url(editor-sprite.gif) no-repeat 0 -1222px;overflow:hidden;height:6px;width:7px;min-height:0;padding:0;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.up{top:2px;background-position:0 -1222px;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-spinbutton a.down{bottom:2px;background-position:0 -1187px;}.yui-skin-sam .yui-toolbar-container select{height:22px;border:1px solid #808080;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select .first-child a{padding-left:5px;text-align:left;}.yui-skin-sam .yui-toolbar-container .yui-toolbar-select span.yui-toolbar-icon{background:url( editor-sprite.gif ) no-repeat 0 -1144px;overflow:hidden;right:-2px;top:0px;height:20px;}.yui-skin-sam .yui-editor-panel .yui-color-button-menu .bd{background-color:transparent;border:none;width:135px;}.yui-skin-sam .yui-color-button-menu .yui-toolbar-colors{border:1px solid #808080;}.yui-skin-sam .yui-editor-panel{padding:0;margin:0;border:none;background-color:transparent;overflow:visible;}.yui-skin-sam .yui-editor-panel .hd{margin:10px 0 0;padding:0;border:none;}.yui-skin-sam .yui-editor-panel .hd h3{color:#000;border:1px solid #808080;background:url(sprite.png) repeat-x 0 -200px;width:99%;position:relative;margin:0;padding:3px 0 0 0;font-size:93%;text-indent:5px;height:20px;}.yui-skin-sam .yui-editor-panel .bd{background-color:#F2F2F2;border-left:1px solid #808080;border-right:1px solid #808080;width:99%;margin:0;padding:0;overflow:visible;}.yui-skin-sam .yui-editor-panel ul{list-style-type:none;margin:0;padding:0;}.yui-skin-sam .yui-editor-panel ul li{margin:0;padding:0;}.yui-skin-sam .yui-editor-panel .yuimenu{}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .yui-toolbar-subcont{padding:0;border:none;margin-top:0.35em;}.yui-skin-sam .yui-editor-panel .yui-toolbar-bordersize,.yui-skin-sam .yui-editor-panel .yui-toolbar-bordertype{width:50px;}.yui-skin-sam .yui-editor-panel label{display:block;float:none;padding:4px 0;margin-bottom:7px;}.yui-skin-sam .yui-editor-panel label strong{font-weight:normal;font-size:93%;text-align:right;padding-top:2px;}.yui-skin-sam .yui-editor-panel label input{width:75%;}.yui-skin-sam .yui-editor-panel .createlink_target,.yui-skin-sam .yui-editor-panel .insertimage_target{width:auto;margin-right:5px;}.yui-skin-sam .yui-editor-panel .removeLink{width:98%;}.yui-skin-sam .yui-editor-panel label input.warning{background-color:#FFEE69;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group h3{color:#000;float:left;font-weight:normal;font-size:93%;margin:5px 0 0 0;padding:0 3px 0 0;text-align:right;}.yui-skin-sam .yui-editor-panel .height-width h3{margin:3px 0 0 10px;}.yui-skin-sam .yui-editor-panel .height-width{margin:3px 0 0 35px;*margin-left:14px;width:42%;*width:44%;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-border{width:190px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-border{width:210px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding{width:203px;}.yui-skin-sam .yui-editor-panel .no-button .yui-toolbar-group-padding{width:172px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-padding h3{margin-left:25px;*margin-left:12px;}.yui-skin-sam .yui-editor-panel .yui-toolbar-group-textflow{width:182px;}.yui-skin-sam .yui-editor-panel .hd{background:none;}.yui-skin-sam .yui-editor-panel .ft{background-color:#F2F2F2;border:1px solid #808080;border-top:none;padding:0;margin:0 0 2px 0;}.yui-skin-sam .yui-editor-panel .hd span.close{background:url(sprite.png) no-repeat 0 -300px;cursor:pointer;display:block;height:16px;overflow:hidden;position:absolute;right:5px;text-indent:500px;top:2px;width:26px;}.yui-skin-sam .yui-editor-panel .ft span.tip{background-color:#EDF5FF;border-top:1px solid #808080;font-size:85%;}.yui-skin-sam .yui-editor-panel .ft span.tip strong{display:block;float:left;margin:0 2px 8px 0;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon{background:url( editor-sprite.gif ) no-repeat 0 -1260px;display:block;height:20px;left:2px;position:absolute;top:8px;width:20px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-info{background-position:2px -1260px;}.yui-skin-sam .yui-editor-panel .ft span.tip span.icon-warn{background-position:2px -1296px;}.yui-skin-sam .yui-editor-panel .hd span.knob{position:absolute;height:10px;width:28px;top:-10px;left:25px;text-indent:9999px;overflow:hidden;background:url( editor-knob.gif ) no-repeat 0 0;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container{float:left;width:100%;background-image:none;border:none;}.yui-skin-sam .yui-editor-panel .yui-toolbar-container .bd{background-color:#ffffff;}.yui-editor-blankimage{background-image:url( blankimage.png );} +.yui-navset .yui-nav li,.yui-navset .yui-navset-top .yui-nav li,.yui-navset .yui-navset-bottom .yui-nav li{margin:0 0.5em 0 0;}.yui-navset-left .yui-nav li,.yui-navset-right .yui-nav li{margin:0 0 0.5em;}.yui-navset .yui-navset-left .yui-nav,.yui-navset .yui-navset-right .yui-nav,.yui-navset-left .yui-nav,.yui-navset-right .yui-nav{width:6em;}.yui-navset-top .yui-nav,.yui-navset-bottom .yui-nav{width:auto;}.yui-navset .yui-navset-left,.yui-navset-left{padding:0 0 0 6em;}.yui-navset-right{padding:0 6em 0 0;}.yui-navset-top,.yui-navset-bottom{padding:auto;}.yui-nav,.yui-nav li{margin:0;padding:0;list-style:none;}.yui-navset li em{font-style:normal;}.yui-navset{position:relative;zoom:1;}.yui-navset .yui-content{zoom:1;}.yui-navset .yui-nav li,.yui-navset .yui-navset-top .yui-nav li,.yui-navset .yui-navset-bottom .yui-nav li{display:inline-block;display:-moz-inline-stack;*display:inline;vertical-align:bottom;cursor:pointer;zoom:1;}.yui-navset-left .yui-nav li,.yui-navset-right .yui-nav li{display:block;}.yui-navset .yui-nav a{position:relative;}.yui-navset .yui-nav li a,.yui-navset-top .yui-nav li a,.yui-navset-bottom .yui-nav li a{display:block;display:inline-block;vertical-align:bottom;zoom:1;}.yui-navset-left .yui-nav li a,.yui-navset-right .yui-nav li a{display:block;}.yui-navset-bottom .yui-nav li a{vertical-align:text-top;}.yui-navset .yui-nav li a em,.yui-navset-top .yui-nav li a em,.yui-navset-bottom .yui-nav li a em{display:block;}.yui-navset .yui-navset-left .yui-nav,.yui-navset .yui-navset-right .yui-nav,.yui-navset-left .yui-nav,.yui-navset-right .yui-nav{position:absolute;z-index:1;}.yui-navset-top .yui-nav,.yui-navset-bottom .yui-nav{position:static;}.yui-navset .yui-navset-left .yui-nav,.yui-navset-left .yui-nav{left:0;right:auto;}.yui-navset .yui-navset-right .yui-nav,.yui-navset-right .yui-nav{right:0;left:auto;}.yui-skin-sam .yui-navset .yui-nav,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav{border:solid #2647a0;border-width:0 0 5px;Xposition:relative;zoom:1;}.yui-skin-sam .yui-navset .yui-nav li,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav li{margin:0 0.16em 0 0;padding:1px 0 0;zoom:1;}.yui-skin-sam .yui-navset .yui-nav .selected,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav .selected{margin:0 0.16em -1px 0;}.yui-skin-sam .yui-navset .yui-nav a,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav a{background:#d8d8d8 url(sprite.png) repeat-x;border:solid #a3a3a3;border-width:0 1px;color:#000;position:relative;text-decoration:none;}.yui-skin-sam .yui-navset .yui-nav a em,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav a em{border:solid #a3a3a3;border-width:1px 0 0;cursor:hand;padding:0.25em .75em;left:0;right:0;bottom:0;top:-1px;position:relative;}.yui-skin-sam .yui-navset .yui-nav .selected a,.yui-skin-sam .yui-navset .yui-nav .selected a:focus,.yui-skin-sam .yui-navset .yui-nav .selected a:hover{background:#2647a0 url(sprite.png) repeat-x left -1400px;color:#fff;}.yui-skin-sam .yui-navset .yui-nav a:hover,.yui-skin-sam .yui-navset .yui-nav a:focus{background:#bfdaff url(sprite.png) repeat-x left -1300px;outline:0;}.yui-skin-sam .yui-navset .yui-nav .selected a em{padding:0.35em 0.75em;}.yui-skin-sam .yui-navset .yui-nav .selected a,.yui-skin-sam .yui-navset .yui-nav .selected a em{border-color:#243356;}.yui-skin-sam .yui-navset .yui-content{background:#edf5ff;}.yui-skin-sam .yui-navset .yui-content,.yui-skin-sam .yui-navset .yui-navset-top .yui-content{border:1px solid #808080;border-top-color:#243356;padding:0.25em 0.5em;}.yui-skin-sam .yui-navset-left .yui-nav,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav,.yui-skin-sam .yui-navset .yui-navset-right .yui-nav,.yui-skin-sam .yui-navset-right .yui-nav{border-width:0 5px 0 0;Xposition:absolute;top:0;bottom:0;}.yui-skin-sam .yui-navset .yui-navset-right .yui-nav,.yui-skin-sam .yui-navset-right .yui-nav{border-width:0 0 0 5px;}.yui-skin-sam .yui-navset-left .yui-nav li,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav li,.yui-skin-sam .yui-navset-right .yui-nav li{margin:0 0 0.16em;padding:0 0 0 1px;}.yui-skin-sam .yui-navset-right .yui-nav li{padding:0 1px 0 0;}.yui-skin-sam .yui-navset-left .yui-nav .selected,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav .selected{margin:0 -1px 0.16em 0;}.yui-skin-sam .yui-navset-right .yui-nav .selected{margin:0 0 0.16em -1px;}.yui-skin-sam .yui-navset-left .yui-nav a,.yui-skin-sam .yui-navset-right .yui-nav a{border-width:1px 0;}.yui-skin-sam .yui-navset-left .yui-nav a em,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav a em,.yui-skin-sam .yui-navset-right .yui-nav a em{border-width:0 0 0 1px;padding:0.2em .75em;top:auto;left:-1px;}.yui-skin-sam .yui-navset-right .yui-nav a em{border-width:0 1px 0 0;left:auto;right:-1px;}.yui-skin-sam .yui-navset-left .yui-nav a,.yui-skin-sam .yui-navset-left .yui-nav .selected a,.yui-skin-sam .yui-navset-left .yui-nav a:hover,.yui-skin-sam .yui-navset-right .yui-nav a,.yui-skin-sam .yui-navset-right .yui-nav .selected a,.yui-skin-sam .yui-navset-right .yui-nav a:hover,.yui-skin-sam .yui-navset-bottom .yui-nav a,.yui-skin-sam .yui-navset-bottom .yui-nav .selected a,.yui-skin-sam .yui-navset-bottom .yui-nav a:hover{background-image:none;}.yui-skin-sam .yui-navset-left .yui-content{border:1px solid #808080;border-left-color:#243356;}.yui-skin-sam .yui-navset-bottom .yui-nav,.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav{border-width:5px 0 0;}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav .selected,.yui-skin-sam .yui-navset-bottom .yui-nav .selected{margin:-1px 0.16em 0 0;}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li,.yui-skin-sam .yui-navset-bottom .yui-nav li{padding:0 0 1px 0;vertical-align:top;}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li a,.yui-skin-sam .yui-navset-bottom .yui-nav li a{}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav a em,.yui-skin-sam .yui-navset-bottom .yui-nav a em{border-width:0 0 1px;top:auto;bottom:-1px;}.yui-skin-sam .yui-navset-bottom .yui-content,.yui-skin-sam .yui-navset .yui-navset-bottom .yui-content{border:1px solid #808080;border-bottom-color:#243356;} +.ygtvitem{}.ygtvitem table{margin-bottom:0;border:none;}.ygtvitem td{border:none;padding:0;}.ygtvtn{width:18px;height:22px;background:url(treeview-sprite.gif) 0 -5600px no-repeat;}.ygtvtm{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -4000px no-repeat;}.ygtvtmh{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -4800px no-repeat;}.ygtvtp{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -6400px no-repeat;}.ygtvtph{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -7200px no-repeat;}.ygtvln{width:18px;height:22px;background:url(treeview-sprite.gif) 0 -1600px no-repeat;}.ygtvlm{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 0px no-repeat;}.ygtvlmh{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -800px no-repeat;}.ygtvlp{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -2400px no-repeat;}.ygtvlph{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -3200px no-repeat;}.ygtvloading{width:18px;height:22px;background:url(treeview-loading.gif) 0 0 no-repeat;}.ygtvdepthcell{width:18px;height:22px;background:url(treeview-sprite.gif) 0 -8000px no-repeat;}.ygtvblankdepthcell{width:18px;height:22px;}.ygtvchildren{}* html .ygtvchildren{height:2%;}.ygtvlabel,.ygtvlabel:link,.ygtvlabel:visited,.ygtvlabel:hover{margin-left:2px;text-decoration:none;background-color:white;}.ygtvspacer{height:22px;width:12px;} +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-active.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-active.png new file mode 100644 index 0000000..fa58c50 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-active.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-disabled.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-disabled.png new file mode 100644 index 0000000..0a6a82c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-disabled.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-focus.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-focus.png new file mode 100644 index 0000000..167d71e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-focus.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-hover.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-hover.png new file mode 100644 index 0000000..167d71e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow-hover.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow.png new file mode 100644 index 0000000..b33a93f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/split-button-arrow.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/sprite.png b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/sprite.png new file mode 100644 index 0000000..afd65e0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/sprite.png Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/tabview.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/tabview.css new file mode 100644 index 0000000..f0f8b42 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/tabview.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-navset .yui-nav li,.yui-navset .yui-navset-top .yui-nav li,.yui-navset .yui-navset-bottom .yui-nav li{margin:0 0.5em 0 0;}.yui-navset-left .yui-nav li,.yui-navset-right .yui-nav li{margin:0 0 0.5em;}.yui-navset .yui-navset-left .yui-nav,.yui-navset .yui-navset-right .yui-nav,.yui-navset-left .yui-nav,.yui-navset-right .yui-nav{width:6em;}.yui-navset-top .yui-nav,.yui-navset-bottom .yui-nav{width:auto;}.yui-navset .yui-navset-left,.yui-navset-left{padding:0 0 0 6em;}.yui-navset-right{padding:0 6em 0 0;}.yui-navset-top,.yui-navset-bottom{padding:auto;}.yui-nav,.yui-nav li{margin:0;padding:0;list-style:none;}.yui-navset li em{font-style:normal;}.yui-navset{position:relative;zoom:1;}.yui-navset .yui-content{zoom:1;}.yui-navset .yui-nav li,.yui-navset .yui-navset-top .yui-nav li,.yui-navset .yui-navset-bottom .yui-nav li{display:inline-block;display:-moz-inline-stack;*display:inline;vertical-align:bottom;cursor:pointer;zoom:1;}.yui-navset-left .yui-nav li,.yui-navset-right .yui-nav li{display:block;}.yui-navset .yui-nav a{position:relative;}.yui-navset .yui-nav li a,.yui-navset-top .yui-nav li a,.yui-navset-bottom .yui-nav li a{display:block;display:inline-block;vertical-align:bottom;zoom:1;}.yui-navset-left .yui-nav li a,.yui-navset-right .yui-nav li a{display:block;}.yui-navset-bottom .yui-nav li a{vertical-align:text-top;}.yui-navset .yui-nav li a em,.yui-navset-top .yui-nav li a em,.yui-navset-bottom .yui-nav li a em{display:block;}.yui-navset .yui-navset-left .yui-nav,.yui-navset .yui-navset-right .yui-nav,.yui-navset-left .yui-nav,.yui-navset-right .yui-nav{position:absolute;z-index:1;}.yui-navset-top .yui-nav,.yui-navset-bottom .yui-nav{position:static;}.yui-navset .yui-navset-left .yui-nav,.yui-navset-left .yui-nav{left:0;right:auto;}.yui-navset .yui-navset-right .yui-nav,.yui-navset-right .yui-nav{right:0;left:auto;}.yui-skin-sam .yui-navset .yui-nav,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav{border:solid #2647a0;border-width:0 0 5px;Xposition:relative;zoom:1;}.yui-skin-sam .yui-navset .yui-nav li,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav li{margin:0 0.16em 0 0;padding:1px 0 0;zoom:1;}.yui-skin-sam .yui-navset .yui-nav .selected,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav .selected{margin:0 0.16em -1px 0;}.yui-skin-sam .yui-navset .yui-nav a,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav a{background:#d8d8d8 url(sprite.png) repeat-x;border:solid #a3a3a3;border-width:0 1px;color:#000;position:relative;text-decoration:none;}.yui-skin-sam .yui-navset .yui-nav a em,.yui-skin-sam .yui-navset .yui-navset-top .yui-nav a em{border:solid #a3a3a3;border-width:1px 0 0;cursor:hand;padding:0.25em .75em;left:0;right:0;bottom:0;top:-1px;position:relative;}.yui-skin-sam .yui-navset .yui-nav .selected a,.yui-skin-sam .yui-navset .yui-nav .selected a:focus,.yui-skin-sam .yui-navset .yui-nav .selected a:hover{background:#2647a0 url(sprite.png) repeat-x left -1400px;color:#fff;}.yui-skin-sam .yui-navset .yui-nav a:hover,.yui-skin-sam .yui-navset .yui-nav a:focus{background:#bfdaff url(sprite.png) repeat-x left -1300px;outline:0;}.yui-skin-sam .yui-navset .yui-nav .selected a em{padding:0.35em 0.75em;}.yui-skin-sam .yui-navset .yui-nav .selected a,.yui-skin-sam .yui-navset .yui-nav .selected a em{border-color:#243356;}.yui-skin-sam .yui-navset .yui-content{background:#edf5ff;}.yui-skin-sam .yui-navset .yui-content,.yui-skin-sam .yui-navset .yui-navset-top .yui-content{border:1px solid #808080;border-top-color:#243356;padding:0.25em 0.5em;}.yui-skin-sam .yui-navset-left .yui-nav,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav,.yui-skin-sam .yui-navset .yui-navset-right .yui-nav,.yui-skin-sam .yui-navset-right .yui-nav{border-width:0 5px 0 0;Xposition:absolute;top:0;bottom:0;}.yui-skin-sam .yui-navset .yui-navset-right .yui-nav,.yui-skin-sam .yui-navset-right .yui-nav{border-width:0 0 0 5px;}.yui-skin-sam .yui-navset-left .yui-nav li,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav li,.yui-skin-sam .yui-navset-right .yui-nav li{margin:0 0 0.16em;padding:0 0 0 1px;}.yui-skin-sam .yui-navset-right .yui-nav li{padding:0 1px 0 0;}.yui-skin-sam .yui-navset-left .yui-nav .selected,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav .selected{margin:0 -1px 0.16em 0;}.yui-skin-sam .yui-navset-right .yui-nav .selected{margin:0 0 0.16em -1px;}.yui-skin-sam .yui-navset-left .yui-nav a,.yui-skin-sam .yui-navset-right .yui-nav a{border-width:1px 0;}.yui-skin-sam .yui-navset-left .yui-nav a em,.yui-skin-sam .yui-navset .yui-navset-left .yui-nav a em,.yui-skin-sam .yui-navset-right .yui-nav a em{border-width:0 0 0 1px;padding:0.2em .75em;top:auto;left:-1px;}.yui-skin-sam .yui-navset-right .yui-nav a em{border-width:0 1px 0 0;left:auto;right:-1px;}.yui-skin-sam .yui-navset-left .yui-nav a,.yui-skin-sam .yui-navset-left .yui-nav .selected a,.yui-skin-sam .yui-navset-left .yui-nav a:hover,.yui-skin-sam .yui-navset-right .yui-nav a,.yui-skin-sam .yui-navset-right .yui-nav .selected a,.yui-skin-sam .yui-navset-right .yui-nav a:hover,.yui-skin-sam .yui-navset-bottom .yui-nav a,.yui-skin-sam .yui-navset-bottom .yui-nav .selected a,.yui-skin-sam .yui-navset-bottom .yui-nav a:hover{background-image:none;}.yui-skin-sam .yui-navset-left .yui-content{border:1px solid #808080;border-left-color:#243356;}.yui-skin-sam .yui-navset-bottom .yui-nav,.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav{border-width:5px 0 0;}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav .selected,.yui-skin-sam .yui-navset-bottom .yui-nav .selected{margin:-1px 0.16em 0 0;}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li,.yui-skin-sam .yui-navset-bottom .yui-nav li{padding:0 0 1px 0;vertical-align:top;}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li a,.yui-skin-sam .yui-navset-bottom .yui-nav li a{}.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav a em,.yui-skin-sam .yui-navset-bottom .yui-nav a em{border-width:0 0 1px;top:auto;bottom:-1px;}.yui-skin-sam .yui-navset-bottom .yui-content,.yui-skin-sam .yui-navset .yui-navset-bottom .yui-content{border:1px solid #808080;border-bottom-color:#243356;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/transparent.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/transparent.gif new file mode 100644 index 0000000..099c95f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/transparent.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview-loading.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview-loading.gif new file mode 100644 index 0000000..0bbf3bc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview-loading.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview-sprite.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview-sprite.gif new file mode 100644 index 0000000..a04eff6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview-sprite.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview.css new file mode 100644 index 0000000..b00a13a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/treeview.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.ygtvitem{}.ygtvitem table{margin-bottom:0;border:none;}.ygtvitem td{border:none;padding:0;}.ygtvtn{width:18px;height:22px;background:url(treeview-sprite.gif) 0 -5600px no-repeat;}.ygtvtm{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -4000px no-repeat;}.ygtvtmh{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -4800px no-repeat;}.ygtvtp{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -6400px no-repeat;}.ygtvtph{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -7200px no-repeat;}.ygtvln{width:18px;height:22px;background:url(treeview-sprite.gif) 0 -1600px no-repeat;}.ygtvlm{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 0px no-repeat;}.ygtvlmh{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -800px no-repeat;}.ygtvlp{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -2400px no-repeat;}.ygtvlph{width:18px;height:22px;cursor:pointer;background:url(treeview-sprite.gif) 0 -3200px no-repeat;}.ygtvloading{width:18px;height:22px;background:url(treeview-loading.gif) 0 0 no-repeat;}.ygtvdepthcell{width:18px;height:22px;background:url(treeview-sprite.gif) 0 -8000px no-repeat;}.ygtvblankdepthcell{width:18px;height:22px;}.ygtvchildren{}* html .ygtvchildren{height:2%;}.ygtvlabel,.ygtvlabel:link,.ygtvlabel:visited,.ygtvlabel:hover{margin-left:2px;text-decoration:none;background-color:white;}.ygtvspacer{height:22px;width:12px;}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/wait.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/wait.gif new file mode 100644 index 0000000..471c1a4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/wait.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/yuitest.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/yuitest.css new file mode 100644 index 0000000..1c34e96 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/css/yuitest.css
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/datasource-beta-min.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/datasource-beta-min.js new file mode 100644 index 0000000..8916e9d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/datasource-beta-min.js
@@ -0,0 +1,9 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +YAHOO.util.DataSource=function(B,D){if(!B){return ;}this.liveData=B;this._oQueue={interval:null,conn:null,requests:[]};if(B.nodeType&&B.nodeType==9){this.dataType=YAHOO.util.DataSource.TYPE_XML;}else{if(YAHOO.lang.isArray(B)){this.dataType=YAHOO.util.DataSource.TYPE_JSARRAY;}else{if(YAHOO.lang.isString(B)){this.dataType=YAHOO.util.DataSource.TYPE_XHR;}else{if(YAHOO.lang.isFunction(B)){this.dataType=YAHOO.util.DataSource.TYPE_JSFUNCTION;}else{if(B.nodeName&&(B.nodeName.toLowerCase()=="table")){this.dataType=YAHOO.util.DataSource.TYPE_HTMLTABLE;this.liveData=B.cloneNode(true);}else{if(YAHOO.lang.isObject(B)){this.dataType=YAHOO.util.DataSource.TYPE_JSON;}else{this.dataType=YAHOO.util.DataSource.TYPE_UNKNOWN;}}}}}}if(D&&(D.constructor==Object)){for(var C in D){if(C){this[C]=D[C];}}}var A=this.maxCacheEntries;if(!YAHOO.lang.isNumber(A)||(A<0)){A=0;}this._aIntervals=[];this._sName="DataSource instance"+YAHOO.util.DataSource._nIndex;YAHOO.util.DataSource._nIndex++;this.createEvent("cacheRequestEvent");this.createEvent("cacheResponseEvent");this.createEvent("requestEvent");this.createEvent("responseEvent");this.createEvent("responseParseEvent");this.createEvent("responseCacheEvent");this.createEvent("dataErrorEvent");this.createEvent("cacheFlushEvent");};YAHOO.augment(YAHOO.util.DataSource,YAHOO.util.EventProvider);YAHOO.util.DataSource.TYPE_UNKNOWN=-1;YAHOO.util.DataSource.TYPE_JSARRAY=0;YAHOO.util.DataSource.TYPE_JSFUNCTION=1;YAHOO.util.DataSource.TYPE_XHR=2;YAHOO.util.DataSource.TYPE_JSON=3;YAHOO.util.DataSource.TYPE_XML=4;YAHOO.util.DataSource.TYPE_TEXT=5;YAHOO.util.DataSource.TYPE_HTMLTABLE=6;YAHOO.util.DataSource.ERROR_DATAINVALID="Invalid data";YAHOO.util.DataSource.ERROR_DATANULL="Null data";YAHOO.util.DataSource._nIndex=0;YAHOO.util.DataSource._nTransactionId=0;YAHOO.util.DataSource.prototype._sName=null;YAHOO.util.DataSource.prototype._aCache=null;YAHOO.util.DataSource.prototype._oQueue=null;YAHOO.util.DataSource.prototype._aIntervals=null;YAHOO.util.DataSource.prototype.maxCacheEntries=0;YAHOO.util.DataSource.prototype.liveData=null;YAHOO.util.DataSource.prototype.dataType=YAHOO.util.DataSource.TYPE_UNKNOWN;YAHOO.util.DataSource.prototype.responseType=YAHOO.util.DataSource.TYPE_UNKNOWN;YAHOO.util.DataSource.prototype.responseSchema=null;YAHOO.util.DataSource.prototype.connMgr=null;YAHOO.util.DataSource.prototype.connXhrMode="allowAll";YAHOO.util.DataSource.prototype.connMethodPost=false;YAHOO.util.DataSource.prototype.connTimeout=0;YAHOO.util.DataSource.parseString=function(B){if(!YAHOO.lang.isValue(B)){return null;}var A=B+"";if(YAHOO.lang.isString(A)){return A;}else{return null;}};YAHOO.util.DataSource.parseNumber=function(B){var A=B*1;if(YAHOO.lang.isNumber(A)){return A;}else{return null;}};YAHOO.util.DataSource.convertNumber=function(A){return YAHOO.util.DataSource.parseNumber(A);};YAHOO.util.DataSource.parseDate=function(B){var A=null;if(!(B instanceof Date)){A=new Date(B);}else{return B;}if(A instanceof Date){return A;}else{return null;}};YAHOO.util.DataSource.convertDate=function(A){return YAHOO.util.DataSource.parseDate(A);};YAHOO.util.DataSource.prototype.toString=function(){return this._sName;};YAHOO.util.DataSource.prototype.getCachedResponse=function(H,B,G){var A=this._aCache;if(this.maxCacheEntries>0){if(!A){this._aCache=[];}else{var D=A.length;if(D>0){var F=null;this.fireEvent("cacheRequestEvent",{request:H,callback:B,caller:G});for(var E=D-1;E>=0;E--){var C=A[E];if(this.isCacheHit(H,C.request)){F=C.response;this.fireEvent("cacheResponseEvent",{request:H,response:F,callback:B,caller:G});if(E<D-1){A.splice(E,1);this.addToCache(H,F);}break;}}return F;}}}else{if(A){this._aCache=null;}}return null;};YAHOO.util.DataSource.prototype.isCacheHit=function(A,B){return(A===B);};YAHOO.util.DataSource.prototype.addToCache=function(D,C){var A=this._aCache;if(!A){return ;}while(A.length>=this.maxCacheEntries){A.shift();}var B={request:D,response:C};A[A.length]=B;this.fireEvent("responseCacheEvent",{request:D,response:C});};YAHOO.util.DataSource.prototype.flushCache=function(){if(this._aCache){this._aCache=[];this.fireEvent("cacheFlushEvent");}};YAHOO.util.DataSource.prototype.setInterval=function(D,F,B,E){if(YAHOO.lang.isNumber(D)&&(D>=0)){var C=this;var A=setInterval(function(){C.makeConnection(F,B,E);},D);this._aIntervals.push(A);return A;}else{}};YAHOO.util.DataSource.prototype.clearInterval=function(A){var C=this._aIntervals||[];for(var B=C.length-1;B>-1;B--){if(C[B]===A){C.splice(B,1);clearInterval(A);}}};YAHOO.util.DataSource.prototype.clearAllIntervals=function(A){var C=this._aIntervals||[];for(var B=C.length-1;B>-1;B--){C.splice(B,1);clearInterval(A);}};YAHOO.util.DataSource.issueCallback=function(E,D,B,C){if(YAHOO.lang.isFunction(E)){E.apply(C,D);}else{if(YAHOO.lang.isObject(E)){C=E.scope||C||window;var A=E.success;if(B){A=E.failure;}if(A){A.apply(C,D.concat([E.argument]));}}}};YAHOO.util.DataSource.prototype.sendRequest=function(D,A,C){var B=this.getCachedResponse(D,A,C);if(B){YAHOO.util.DataSource.issueCallback(A,[D,B],false,C);return null;}return this.makeConnection(D,A,C);};YAHOO.util.DataSource.prototype.makeConnection=function(A,P,K){this.fireEvent("requestEvent",{request:A,callback:P,caller:K});var D=null;var L=YAHOO.util.DataSource._nTransactionId++;switch(this.dataType){case YAHOO.util.DataSource.TYPE_JSFUNCTION:D=this.liveData(A);this.handleResponse(A,D,P,K,L);break;case YAHOO.util.DataSource.TYPE_XHR:var N=this;var C=this.connMgr||YAHOO.util.Connect;var G=this._oQueue;var J=function(Q){if(Q&&(this.connXhrMode=="ignoreStaleResponses")&&(Q.tId!=G.conn.tId)){return null;}else{if(!Q){this.fireEvent("dataErrorEvent",{request:A,callback:P,caller:K,message:YAHOO.util.DataSource.ERROR_DATANULL});YAHOO.util.DataSource.issueCallback(P,[A,{error:true}],true,K);return null;}else{this.handleResponse(A,Q,P,K,L);}}};var O=function(Q){this.fireEvent("dataErrorEvent",{request:A,callback:P,caller:K,message:YAHOO.util.DataSource.ERROR_DATAINVALID});if((this.liveData.lastIndexOf("?")!==this.liveData.length-1)&&(A.indexOf("?")!==0)){}Q=Q||{}; +Q.error=true;YAHOO.util.DataSource.issueCallback(P,[A,Q],true,K);return null;};var I={success:J,failure:O,scope:this};if(YAHOO.lang.isNumber(this.connTimeout)){I.timeout=this.connTimeout;}if(this.connXhrMode=="cancelStaleRequests"){if(G.conn){if(C.abort){C.abort(G.conn);G.conn=null;}else{}}}if(C&&C.asyncRequest){var B=this.liveData;var H=this.connMethodPost;var M=(H)?"POST":"GET";var E=(H)?B:B+A;var F=(H)?A:null;if(this.connXhrMode!="queueRequests"){G.conn=C.asyncRequest(M,E,I,F);}else{if(G.conn){G.requests.push({request:A,callback:I});if(!G.interval){G.interval=setInterval(function(){if(C.isCallInProgress(G.conn)){return ;}else{if(G.requests.length>0){E=(H)?B:B+G.requests[0].request;F=(H)?G.requests[0].request:null;G.conn=C.asyncRequest(M,E,G.requests[0].callback,F);G.requests.shift();}else{clearInterval(G.interval);G.interval=null;}}},50);}}else{G.conn=C.asyncRequest(M,E,I,F);}}}else{YAHOO.util.DataSource.issueCallback(P,[A,{error:true}],true,K);}break;default:D=this.liveData;this.handleResponse(A,D,P,K,L);break;}return L;};YAHOO.util.DataSource.prototype.handleResponse=function(oRequest,oRawResponse,oCallback,oCaller,tId){this.fireEvent("responseEvent",{request:oRequest,response:oRawResponse,callback:oCallback,caller:oCaller,tId:tId});var xhr=(this.dataType==YAHOO.util.DataSource.TYPE_XHR)?true:false;var oParsedResponse=null;var oFullResponse=oRawResponse;switch(this.responseType){case YAHOO.util.DataSource.TYPE_JSARRAY:if(xhr&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse);oParsedResponse=this.parseArrayData(oRequest,oFullResponse);break;case YAHOO.util.DataSource.TYPE_JSON:if(xhr&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}try{if(YAHOO.lang.isString(oFullResponse)){if(YAHOO.lang.JSON){oFullResponse=YAHOO.lang.JSON.parse(oFullResponse);}else{if(window.JSON&&JSON.parse){oFullResponse=JSON.parse(oFullResponse);}else{if(oFullResponse.parseJSON){oFullResponse=oFullResponse.parseJSON();}else{while(oFullResponse.length>0&&(oFullResponse.charAt(0)!="{")&&(oFullResponse.charAt(0)!="[")){oFullResponse=oFullResponse.substring(1,oFullResponse.length);}if(oFullResponse.length>0){var objEnd=Math.max(oFullResponse.lastIndexOf("]"),oFullResponse.lastIndexOf("}"));oFullResponse=oFullResponse.substring(0,objEnd+1);oFullResponse=eval("("+oFullResponse+")");}}}}}}catch(e){}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse);oParsedResponse=this.parseJSONData(oRequest,oFullResponse);break;case YAHOO.util.DataSource.TYPE_HTMLTABLE:if(xhr&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse);oParsedResponse=this.parseHTMLTableData(oRequest,oFullResponse);break;case YAHOO.util.DataSource.TYPE_XML:if(xhr&&oRawResponse.responseXML){oFullResponse=oRawResponse.responseXML;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse);oParsedResponse=this.parseXMLData(oRequest,oFullResponse);break;case YAHOO.util.DataSource.TYPE_TEXT:if(xhr&&oRawResponse.responseText){oFullResponse=oRawResponse.responseText;}oFullResponse=this.doBeforeParseData(oRequest,oFullResponse);oParsedResponse=this.parseTextData(oRequest,oFullResponse);break;default:oFullResponse=this.doBeforeParseData(oRequest,oFullResponse);oParsedResponse=this.doBeforeParseData(oRequest,oFullResponse);break;}if(oParsedResponse&&!oParsedResponse.error){oParsedResponse=this.doBeforeCallback(oRequest,oFullResponse,oParsedResponse);this.fireEvent("responseParseEvent",{request:oRequest,response:oParsedResponse,callback:oCallback,caller:oCaller});this.addToCache(oRequest,oParsedResponse);}else{this.fireEvent("dataErrorEvent",{request:oRequest,response:oRawResponse,callback:oCallback,caller:oCaller,message:YAHOO.util.DataSource.ERROR_DATANULL});oParsedResponse=oParsedResponse||{};oParsedResponse.error=true;}oParsedResponse.tId=tId;YAHOO.util.DataSource.issueCallback(oCallback,[oRequest,oParsedResponse],oParsedResponse.error,oCaller);};YAHOO.util.DataSource.prototype.doBeforeParseData=function(B,A){return A;};YAHOO.util.DataSource.prototype.doBeforeCallback=function(B,A,C){return C;};YAHOO.util.DataSource.prototype.parseArrayData=function(B,L){if(YAHOO.lang.isArray(L)){if(YAHOO.lang.isArray(this.responseSchema.fields)){var F=[],I=this.responseSchema.fields,G;for(G=I.length-1;G>=0;--G){if(typeof I[G]!=="object"){I[G]={key:I[G]};}}var M={};for(G=I.length-1;G>=0;--G){var A=I[G].parser||I[G].converter;if(A){M[I[G].key]=A;}}var J=YAHOO.lang.isArray(L[0]);for(G=L.length-1;G>-1;G--){var H={};var C=L[G];if(typeof C==="object"){for(var D=I.length-1;D>-1;D--){var K=I[D];var E=J?C[D]:C[K.key];if(M[K.key]){E=M[K.key].call(this,E);}if(E===undefined){E=null;}H[K.key]=E;}}F[G]=H;}var N={results:F};return N;}}return null;};YAHOO.util.DataSource.prototype.parseTextData=function(I,O){if(YAHOO.lang.isString(O)){if(YAHOO.lang.isArray(this.responseSchema.fields)&&YAHOO.lang.isString(this.responseSchema.recordDelim)&&YAHOO.lang.isString(this.responseSchema.fieldDelim)){var N={results:[]};var H=this.responseSchema.recordDelim;var F=this.responseSchema.fieldDelim;var G=this.responseSchema.fields;if(O.length>0){var C=O.length-H.length;if(O.substr(C)==H){O=O.substr(0,C);}var D=O.split(H);for(var K=0,L=D.length,Q=0;K<L;++K){var B={};var P=false;if(YAHOO.lang.isString(D[K])){var E=D[K].split(F);for(var J=G.length-1;J>-1;J--){try{var R=E[J];if(YAHOO.lang.isString(R)){if(R.charAt(0)=='"'){R=R.substr(1);}if(R.charAt(R.length-1)=='"'){R=R.substr(0,R.length-1);}var A=G[J];var S=(YAHOO.lang.isValue(A.key))?A.key:A;if(!A.parser&&A.converter){A.parser=A.converter;}if(A.parser){R=A.parser.call(this,R);}if(R===undefined){R=null;}B[S]=R;}else{P=true;}}catch(M){P=true;}}if(!P){N.results[Q++]=B;}}}}return N;}}return null;};YAHOO.util.DataSource.prototype.parseXMLData=function(N,S){var T=false,L=this.responseSchema,R={meta:{}},G=null,I=L.metaNode,A=L.metaFields||{},E=L.totalRecords,P,O,H,K;if(E&&!A.totalRecords){A.totalRecords=E; +}try{G=(L.resultNode)?S.getElementsByTagName(L.resultNode):null;I=I?S.getElementsByTagName(I)[0]:S;if(I){for(O in A){if(YAHOO.lang.hasOwnProperty(A,O)){H=A[O];K=I.getElementsByTagName(H)[0];if(K){K=K.firstChild.nodeValue;}else{K=I.attributes.getNamedItem(H);if(K){K=K.value;}}if(YAHOO.lang.isValue(K)){R.meta[O]=K;}}}}}catch(Q){}if(!G||!YAHOO.lang.isArray(L.fields)){T=true;}else{R.results=[];for(P=G.length-1;P>=0;--P){var J=G.item(P);var F={};for(var M=L.fields.length-1;M>=0;M--){var B=L.fields[M];var V=(YAHOO.lang.isValue(B.key))?B.key:B;var U=null;var D=J.attributes.getNamedItem(V);if(D){U=D.value;}else{var C=J.getElementsByTagName(V);if(C&&C.item(0)&&C.item(0).firstChild){U=C.item(0).firstChild.nodeValue;}else{U="";}}if(!B.parser&&B.converter){B.parser=B.converter;}if(B.parser){U=B.parser.call(this,U);}if(U===undefined){U=null;}F[V]=U;}R.results[P]=F;}}if(T){R.error=true;}else{}return R;};YAHOO.util.DataSource.prototype.parseJSONData=function(Q,V){var U={results:[],meta:{}},N=this.responseSchema;if(YAHOO.lang.isObject(V)){if(YAHOO.lang.isArray(N.fields)){var O=N.fields,C=V,P=[],I=N.metaFields||{},E=[],H=[],G=[],W=false,S,T,R,J,X,B,M;var A=function(b){var a=null,Z=[],Y=0;if(b){b=b.replace(/\[(['"])(.*?)\1\]/g,function(d,c,e){Z[Y]=e;return".@"+(Y++);}).replace(/\[(\d+)\]/g,function(d,c){Z[Y]=parseInt(c,10)|0;return".@"+(Y++);}).replace(/^\./,"");if(!/[^\w\.\$@]/.test(b)){a=b.split(".");for(Y=a.length-1;Y>=0;--Y){if(a[Y].charAt(0)==="@"){a[Y]=Z[parseInt(a[Y].substr(1),10)];}}}}return a;};var D=function(c,a){var Z=a,b=0,Y=c.length;for(;b<Y&&Z;++b){Z=Z[c[b]];}return Z;};for(S=O.length-1;S>=0;--S){X=O[S].key||O[S];B=O[S].parser||O[S].converter;M=A(X);if(B){E[E.length]={key:X,parser:B};}if(M){if(M.length>1){H[H.length]={key:X,path:M};}else{G[G.length]=X;}}else{}}if(N.resultsList){M=A(N.resultsList);if(M){C=D(M,V);if(C===undefined){W=true;}}else{W=true;}}if(!C){C=[];}if(!YAHOO.lang.isArray(C)){C=[C];}if(!W){for(S=C.length-1;S>=0;--S){var K=C[S],F={};for(R=G.length-1;R>=0;--R){F[G[R]]=K[G[R]];}for(R=H.length-1;R>=0;--R){F[H[R].key]=D(H[R].path,K);}for(R=E.length-1;R>=0;--R){var L=E[R].key;F[L]=E[R].parser(F[L]);if(F[L]===undefined){F[L]=null;}}P[S]=F;}if(N.totalRecords&&!I.totalRecords){I.totalRecords=N.totalRecords;}for(X in I){if(YAHOO.lang.hasOwnProperty(I,X)){M=A(I[X]);if(M){J=D(M,V);U.meta[X]=J;}}}}else{U.error=true;}U.results=P;}}else{U.error=true;}return U;};YAHOO.util.DataSource.prototype.parseHTMLTableData=function(B,M){var J=false;var K=M;var I=this.responseSchema.fields;var O={results:[]};for(var G=0;G<K.tBodies.length;G++){var C=K.tBodies[G];for(var E=C.rows.length-1;E>-1;E--){var A=C.rows[E];var H={};for(var D=I.length-1;D>-1;D--){var L=I[D];var N=(YAHOO.lang.isValue(L.key))?L.key:L;var F=A.cells[D].innerHTML;if(!L.parser&&L.converter){L.parser=L.converter;}if(L.parser){F=L.parser.call(this,F);}if(F===undefined){F=null;}H[N]=F;}O.results[E]=H;}}if(J){O.error=true;}else{}return O;};YAHOO.util.Number={format:function(B,E){E=E||{};if(!YAHOO.lang.isNumber(B)){B*=1;}if(YAHOO.lang.isNumber(B)){var I=B+"";var F=(E.decimalSeparator)?E.decimalSeparator:".";var G;if(YAHOO.lang.isNumber(E.decimalPlaces)){var H=E.decimalPlaces;var C=Math.pow(10,H);I=Math.round(B*C)/C+"";G=I.lastIndexOf(".");if(H>0){if(G<0){I+=F;G=I.length-1;}else{if(F!=="."){I=I.replace(".",F);}}while((I.length-1-G)<H){I+="0";}}}if(E.thousandsSeparator){var K=E.thousandsSeparator;G=I.lastIndexOf(F);G=(G>-1)?G:I.length;var J=I.substring(G);var A=-1;for(var D=G;D>0;D--){A++;if((A%3===0)&&(D!==G)){J=K+J;}J=I.charAt(D-1)+J;}I=J;}I=(E.prefix)?E.prefix+I:I;I=(E.suffix)?I+E.suffix:I;return I;}else{return B;}}};YAHOO.util.Date={format:function(C,B){B=B||{};if(C instanceof Date){var D=B.format||"MM/DD/YYYY";var E=C.getMonth()+1;var A=C.getDate();var F=C.getFullYear();switch(D){case"YYYY/MM/DD":return F+"/"+E+"/"+A;case"DD/MM/YYYY":return A+"/"+E+"/"+F;default:return E+"/"+A+"/"+F;}}else{return YAHOO.lang.isValue(C)?C:"";}}};YAHOO.register("datasource",YAHOO.util.DataSource,{version:"2.5.2",build:"1076"}); \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/element-beta.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/element-beta.js new file mode 100644 index 0000000..fc8ab7b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/element-beta.js
@@ -0,0 +1,992 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/** + * Provides Attribute configurations. + * @namespace YAHOO.util + * @class Attribute + * @constructor + * @param hash {Object} The intial Attribute. + * @param {YAHOO.util.AttributeProvider} The owner of the Attribute instance. + */ + +YAHOO.util.Attribute = function(hash, owner) { + if (owner) { + this.owner = owner; + this.configure(hash, true); + } +}; + +YAHOO.util.Attribute.prototype = { + /** + * The name of the attribute. + * @property name + * @type String + */ + name: undefined, + + /** + * The value of the attribute. + * @property value + * @type String + */ + value: null, + + /** + * The owner of the attribute. + * @property owner + * @type YAHOO.util.AttributeProvider + */ + owner: null, + + /** + * Whether or not the attribute is read only. + * @property readOnly + * @type Boolean + */ + readOnly: false, + + /** + * Whether or not the attribute can only be written once. + * @property writeOnce + * @type Boolean + */ + writeOnce: false, + + /** + * The attribute's initial configuration. + * @private + * @property _initialConfig + * @type Object + */ + _initialConfig: null, + + /** + * Whether or not the attribute's value has been set. + * @private + * @property _written + * @type Boolean + */ + _written: false, + + /** + * The method to use when setting the attribute's value. + * The method recieves the new value as the only argument. + * @property method + * @type Function + */ + method: null, + + /** + * The validator to use when setting the attribute's value. + * @property validator + * @type Function + * @return Boolean + */ + validator: null, + + /** + * Retrieves the current value of the attribute. + * @method getValue + * @return {any} The current value of the attribute. + */ + getValue: function() { + return this.value; + }, + + /** + * Sets the value of the attribute and fires beforeChange and change events. + * @method setValue + * @param {Any} value The value to apply to the attribute. + * @param {Boolean} silent If true the change events will not be fired. + * @return {Boolean} Whether or not the value was set. + */ + setValue: function(value, silent) { + var beforeRetVal; + var owner = this.owner; + var name = this.name; + + var event = { + type: name, + prevValue: this.getValue(), + newValue: value + }; + + if (this.readOnly || ( this.writeOnce && this._written) ) { + return false; // write not allowed + } + + if (this.validator && !this.validator.call(owner, value) ) { + return false; // invalid value + } + + if (!silent) { + beforeRetVal = owner.fireBeforeChangeEvent(event); + if (beforeRetVal === false) { + return false; + } + } + + if (this.method) { + this.method.call(owner, value); + } + + this.value = value; + this._written = true; + + event.type = name; + + if (!silent) { + this.owner.fireChangeEvent(event); + } + + return true; + }, + + /** + * Allows for configuring the Attribute's properties. + * @method configure + * @param {Object} map A key-value map of Attribute properties. + * @param {Boolean} init Whether or not this should become the initial config. + */ + configure: function(map, init) { + map = map || {}; + this._written = false; // reset writeOnce + this._initialConfig = this._initialConfig || {}; + + for (var key in map) { + if ( key && YAHOO.lang.hasOwnProperty(map, key) ) { + this[key] = map[key]; + if (init) { + this._initialConfig[key] = map[key]; + } + } + } + }, + + /** + * Resets the value to the initial config value. + * @method resetValue + * @return {Boolean} Whether or not the value was set. + */ + resetValue: function() { + return this.setValue(this._initialConfig.value); + }, + + /** + * Resets the attribute config to the initial config state. + * @method resetConfig + */ + resetConfig: function() { + this.configure(this._initialConfig); + }, + + /** + * Resets the value to the current value. + * Useful when values may have gotten out of sync with actual properties. + * @method refresh + * @return {Boolean} Whether or not the value was set. + */ + refresh: function(silent) { + this.setValue(this.value, silent); + } +}; + +(function() { + var Lang = YAHOO.util.Lang; + + /* + Copyright (c) 2006, Yahoo! Inc. All rights reserved. + Code licensed under the BSD License: + http://developer.yahoo.net/yui/license.txt + */ + + /** + * Provides and manages YAHOO.util.Attribute instances + * @namespace YAHOO.util + * @class AttributeProvider + * @uses YAHOO.util.EventProvider + */ + YAHOO.util.AttributeProvider = function() {}; + + YAHOO.util.AttributeProvider.prototype = { + + /** + * A key-value map of Attribute configurations + * @property _configs + * @protected (may be used by subclasses and augmentors) + * @private + * @type {Object} + */ + _configs: null, + /** + * Returns the current value of the attribute. + * @method get + * @param {String} key The attribute whose value will be returned. + */ + get: function(key){ + this._configs = this._configs || {}; + var config = this._configs[key]; + + if (!config) { + return undefined; + } + + return config.value; + }, + + /** + * Sets the value of a config. + * @method set + * @param {String} key The name of the attribute + * @param {Any} value The value to apply to the attribute + * @param {Boolean} silent Whether or not to suppress change events + * @return {Boolean} Whether or not the value was set. + */ + set: function(key, value, silent){ + this._configs = this._configs || {}; + var config = this._configs[key]; + + if (!config) { + return false; + } + + return config.setValue(value, silent); + }, + + /** + * Returns an array of attribute names. + * @method getAttributeKeys + * @return {Array} An array of attribute names. + */ + getAttributeKeys: function(){ + this._configs = this._configs; + var keys = []; + var config; + for (var key in this._configs) { + config = this._configs[key]; + if ( Lang.hasOwnProperty(this._configs, key) && + !Lang.isUndefined(config) ) { + keys[keys.length] = key; + } + } + + return keys; + }, + + /** + * Sets multiple attribute values. + * @method setAttributes + * @param {Object} map A key-value map of attributes + * @param {Boolean} silent Whether or not to suppress change events + */ + setAttributes: function(map, silent){ + for (var key in map) { + if ( Lang.hasOwnProperty(map, key) ) { + this.set(key, map[key], silent); + } + } + }, + + /** + * Resets the specified attribute's value to its initial value. + * @method resetValue + * @param {String} key The name of the attribute + * @param {Boolean} silent Whether or not to suppress change events + * @return {Boolean} Whether or not the value was set + */ + resetValue: function(key, silent){ + this._configs = this._configs || {}; + if (this._configs[key]) { + this.set(key, this._configs[key]._initialConfig.value, silent); + return true; + } + return false; + }, + + /** + * Sets the attribute's value to its current value. + * @method refresh + * @param {String | Array} key The attribute(s) to refresh + * @param {Boolean} silent Whether or not to suppress change events + */ + refresh: function(key, silent){ + this._configs = this._configs; + + key = ( ( Lang.isString(key) ) ? [key] : key ) || + this.getAttributeKeys(); + + for (var i = 0, len = key.length; i < len; ++i) { + if ( // only set if there is a value and not null + this._configs[key[i]] && + ! Lang.isUndefined(this._configs[key[i]].value) && + ! Lang.isNull(this._configs[key[i]].value) ) { + this._configs[key[i]].refresh(silent); + } + } + }, + + /** + * Adds an Attribute to the AttributeProvider instance. + * @method register + * @param {String} key The attribute's name + * @param {Object} map A key-value map containing the + * attribute's properties. + * @deprecated Use setAttributeConfig + */ + register: function(key, map) { + this.setAttributeConfig(key, map); + }, + + + /** + * Returns the attribute's properties. + * @method getAttributeConfig + * @param {String} key The attribute's name + * @private + * @return {object} A key-value map containing all of the + * attribute's properties. + */ + getAttributeConfig: function(key) { + this._configs = this._configs || {}; + var config = this._configs[key] || {}; + var map = {}; // returning a copy to prevent overrides + + for (key in config) { + if ( Lang.hasOwnProperty(config, key) ) { + map[key] = config[key]; + } + } + + return map; + }, + + /** + * Sets or updates an Attribute instance's properties. + * @method setAttributeConfig + * @param {String} key The attribute's name. + * @param {Object} map A key-value map of attribute properties + * @param {Boolean} init Whether or not this should become the intial config. + */ + setAttributeConfig: function(key, map, init) { + this._configs = this._configs || {}; + map = map || {}; + if (!this._configs[key]) { + map.name = key; + this._configs[key] = this.createAttribute(map); + } else { + this._configs[key].configure(map, init); + } + }, + + /** + * Sets or updates an Attribute instance's properties. + * @method configureAttribute + * @param {String} key The attribute's name. + * @param {Object} map A key-value map of attribute properties + * @param {Boolean} init Whether or not this should become the intial config. + * @deprecated Use setAttributeConfig + */ + configureAttribute: function(key, map, init) { + this.setAttributeConfig(key, map, init); + }, + + /** + * Resets an attribute to its intial configuration. + * @method resetAttributeConfig + * @param {String} key The attribute's name. + * @private + */ + resetAttributeConfig: function(key){ + this._configs = this._configs || {}; + this._configs[key].resetConfig(); + }, + + // wrapper for EventProvider.subscribe + // to create events on the fly + subscribe: function(type, callback) { + this._events = this._events || {}; + + if ( !(type in this._events) ) { + this._events[type] = this.createEvent(type); + } + + YAHOO.util.EventProvider.prototype.subscribe.apply(this, arguments); + }, + + on: function() { + this.subscribe.apply(this, arguments); + }, + + addListener: function() { + this.subscribe.apply(this, arguments); + }, + + /** + * Fires the attribute's beforeChange event. + * @method fireBeforeChangeEvent + * @param {String} key The attribute's name. + * @param {Obj} e The event object to pass to handlers. + */ + fireBeforeChangeEvent: function(e) { + var type = 'before'; + type += e.type.charAt(0).toUpperCase() + e.type.substr(1) + 'Change'; + e.type = type; + return this.fireEvent(e.type, e); + }, + + /** + * Fires the attribute's change event. + * @method fireChangeEvent + * @param {String} key The attribute's name. + * @param {Obj} e The event object to pass to the handlers. + */ + fireChangeEvent: function(e) { + e.type += 'Change'; + return this.fireEvent(e.type, e); + }, + + createAttribute: function(map) { + return new YAHOO.util.Attribute(map, this); + } + }; + + YAHOO.augment(YAHOO.util.AttributeProvider, YAHOO.util.EventProvider); +})(); + +(function() { +// internal shorthand +var Dom = YAHOO.util.Dom, + AttributeProvider = YAHOO.util.AttributeProvider; + +/** + * Element provides an wrapper object to simplify adding + * event listeners, using dom methods, and managing attributes. + * @module element + * @namespace YAHOO.util + * @requires yahoo, dom, event + * @beta + */ + +/** + * Element provides an wrapper object to simplify adding + * event listeners, using dom methods, and managing attributes. + * @class Element + * @uses YAHOO.util.AttributeProvider + * @constructor + * @param el {HTMLElement | String} The html element that + * represents the Element. + * @param {Object} map A key-value map of initial config names and values + */ +YAHOO.util.Element = function(el, map) { + if (arguments.length) { + this.init(el, map); + } +}; + +YAHOO.util.Element.prototype = { + /** + * Dom events supported by the Element instance. + * @property DOM_EVENTS + * @type Object + */ + DOM_EVENTS: null, + + /** + * Wrapper for HTMLElement method. + * @method appendChild + * @param {YAHOO.util.Element || HTMLElement} child The element to append. + */ + appendChild: function(child) { + child = child.get ? child.get('element') : child; + this.get('element').appendChild(child); + }, + + /** + * Wrapper for HTMLElement method. + * @method getElementsByTagName + * @param {String} tag The tagName to collect + */ + getElementsByTagName: function(tag) { + return this.get('element').getElementsByTagName(tag); + }, + + /** + * Wrapper for HTMLElement method. + * @method hasChildNodes + * @return {Boolean} Whether or not the element has childNodes + */ + hasChildNodes: function() { + return this.get('element').hasChildNodes(); + }, + + /** + * Wrapper for HTMLElement method. + * @method insertBefore + * @param {HTMLElement} element The HTMLElement to insert + * @param {HTMLElement} before The HTMLElement to insert + * the element before. + */ + insertBefore: function(element, before) { + element = element.get ? element.get('element') : element; + before = (before && before.get) ? before.get('element') : before; + + this.get('element').insertBefore(element, before); + }, + + /** + * Wrapper for HTMLElement method. + * @method removeChild + * @param {HTMLElement} child The HTMLElement to remove + */ + removeChild: function(child) { + child = child.get ? child.get('element') : child; + this.get('element').removeChild(child); + return true; + }, + + /** + * Wrapper for HTMLElement method. + * @method replaceChild + * @param {HTMLElement} newNode The HTMLElement to insert + * @param {HTMLElement} oldNode The HTMLElement to replace + */ + replaceChild: function(newNode, oldNode) { + newNode = newNode.get ? newNode.get('element') : newNode; + oldNode = oldNode.get ? oldNode.get('element') : oldNode; + return this.get('element').replaceChild(newNode, oldNode); + }, + + + /** + * Registers Element specific attributes. + * @method initAttributes + * @param {Object} map A key-value map of initial attribute configs + */ + initAttributes: function(map) { + }, + + /** + * Adds a listener for the given event. These may be DOM or + * customEvent listeners. Any event that is fired via fireEvent + * can be listened for. All handlers receive an event object. + * @method addListener + * @param {String} type The name of the event to listen for + * @param {Function} fn The handler to call when the event fires + * @param {Any} obj A variable to pass to the handler + * @param {Object} scope The object to use for the scope of the handler + */ + addListener: function(type, fn, obj, scope) { + var el = this.get('element'); + scope = scope || this; + + el = this.get('id') || el; + var self = this; + if (!this._events[type]) { // create on the fly + if ( this.DOM_EVENTS[type] ) { + YAHOO.util.Event.addListener(el, type, function(e) { + if (e.srcElement && !e.target) { // supplement IE with target + e.target = e.srcElement; + } + self.fireEvent(type, e); + }, obj, scope); + } + + this.createEvent(type, this); + } + + YAHOO.util.EventProvider.prototype.subscribe.apply(this, arguments); // notify via customEvent + }, + + + /** + * Alias for addListener + * @method on + * @param {String} type The name of the event to listen for + * @param {Function} fn The function call when the event fires + * @param {Any} obj A variable to pass to the handler + * @param {Object} scope The object to use for the scope of the handler + */ + on: function() { this.addListener.apply(this, arguments); }, + + /** + * Alias for addListener + * @method subscribe + * @param {String} type The name of the event to listen for + * @param {Function} fn The function call when the event fires + * @param {Any} obj A variable to pass to the handler + * @param {Object} scope The object to use for the scope of the handler + */ + subscribe: function() { this.addListener.apply(this, arguments); }, + + /** + * Remove an event listener + * @method removeListener + * @param {String} type The name of the event to listen for + * @param {Function} fn The function call when the event fires + */ + removeListener: function(type, fn) { + this.unsubscribe.apply(this, arguments); + }, + + /** + * Wrapper for Dom method. + * @method addClass + * @param {String} className The className to add + */ + addClass: function(className) { + Dom.addClass(this.get('element'), className); + }, + + /** + * Wrapper for Dom method. + * @method getElementsByClassName + * @param {String} className The className to collect + * @param {String} tag (optional) The tag to use in + * conjunction with class name + * @return {Array} Array of HTMLElements + */ + getElementsByClassName: function(className, tag) { + return Dom.getElementsByClassName(className, tag, + this.get('element') ); + }, + + /** + * Wrapper for Dom method. + * @method hasClass + * @param {String} className The className to add + * @return {Boolean} Whether or not the element has the class name + */ + hasClass: function(className) { + return Dom.hasClass(this.get('element'), className); + }, + + /** + * Wrapper for Dom method. + * @method removeClass + * @param {String} className The className to remove + */ + removeClass: function(className) { + return Dom.removeClass(this.get('element'), className); + }, + + /** + * Wrapper for Dom method. + * @method replaceClass + * @param {String} oldClassName The className to replace + * @param {String} newClassName The className to add + */ + replaceClass: function(oldClassName, newClassName) { + return Dom.replaceClass(this.get('element'), + oldClassName, newClassName); + }, + + /** + * Wrapper for Dom method. + * @method setStyle + * @param {String} property The style property to set + * @param {String} value The value to apply to the style property + */ + setStyle: function(property, value) { + var el = this.get('element'); + if (!el) { + return this._queue[this._queue.length] = ['setStyle', arguments]; + } + + return Dom.setStyle(el, property, value); // TODO: always queuing? + }, + + /** + * Wrapper for Dom method. + * @method getStyle + * @param {String} property The style property to retrieve + * @return {String} The current value of the property + */ + getStyle: function(property) { + return Dom.getStyle(this.get('element'), property); + }, + + /** + * Apply any queued set calls. + * @method fireQueue + */ + fireQueue: function() { + var queue = this._queue; + for (var i = 0, len = queue.length; i < len; ++i) { + this[queue[i][0]].apply(this, queue[i][1]); + } + }, + + /** + * Appends the HTMLElement into either the supplied parentNode. + * @method appendTo + * @param {HTMLElement | Element} parentNode The node to append to + * @param {HTMLElement | Element} before An optional node to insert before + */ + appendTo: function(parent, before) { + parent = (parent.get) ? parent.get('element') : Dom.get(parent); + + this.fireEvent('beforeAppendTo', { + type: 'beforeAppendTo', + target: parent + }); + + + before = (before && before.get) ? + before.get('element') : Dom.get(before); + var element = this.get('element'); + + if (!element) { + return false; + } + + if (!parent) { + return false; + } + + if (element.parent != parent) { + if (before) { + parent.insertBefore(element, before); + } else { + parent.appendChild(element); + } + } + + + this.fireEvent('appendTo', { + type: 'appendTo', + target: parent + }); + }, + + get: function(key) { + var configs = this._configs || {}; + var el = configs.element; // avoid loop due to 'element' + if (el && !configs[key] && !YAHOO.lang.isUndefined(el.value[key]) ) { + return el.value[key]; + } + + return AttributeProvider.prototype.get.call(this, key); + }, + + setAttributes: function(map, silent){ + var el = this.get('element'); + for (var key in map) { + // need to configure if setting unconfigured HTMLElement attribute + if ( !this._configs[key] && !YAHOO.lang.isUndefined(el[key]) ) { + this.setAttributeConfig(key); + } + } + + // set based on configOrder + for (var i = 0, len = this._configOrder.length; i < len; ++i) { + if (map[this._configOrder[i]] !== undefined) { + this.set(this._configOrder[i], map[this._configOrder[i]], silent); + } + } + }, + + set: function(key, value, silent) { + var el = this.get('element'); + if (!el) { + this._queue[this._queue.length] = ['set', arguments]; + if (this._configs[key]) { + this._configs[key].value = value; // so "get" works while queueing + + } + return; + } + + // set it on the element if not configured and is an HTML attribute + if ( !this._configs[key] && !YAHOO.lang.isUndefined(el[key]) ) { + _registerHTMLAttr.call(this, key); + } + + return AttributeProvider.prototype.set.apply(this, arguments); + }, + + setAttributeConfig: function(key, map, init) { + var el = this.get('element'); + + if (el && !this._configs[key] && !YAHOO.lang.isUndefined(el[key]) ) { + _registerHTMLAttr.call(this, key, map); + } else { + AttributeProvider.prototype.setAttributeConfig.apply(this, arguments); + } + this._configOrder.push(key); + }, + + getAttributeKeys: function() { + var el = this.get('element'); + var keys = AttributeProvider.prototype.getAttributeKeys.call(this); + + //add any unconfigured element keys + for (var key in el) { + if (!this._configs[key]) { + keys[key] = keys[key] || el[key]; + } + } + + return keys; + }, + + createEvent: function(type, scope) { + this._events[type] = true; + AttributeProvider.prototype.createEvent.apply(this, arguments); + }, + + init: function(el, attr) { + _initElement.apply(this, arguments); + } +}; + +var _initElement = function(el, attr) { + this._queue = this._queue || []; + this._events = this._events || {}; + this._configs = this._configs || {}; + this._configOrder = []; + attr = attr || {}; + attr.element = attr.element || el || null; + + this.DOM_EVENTS = { + 'click': true, + 'dblclick': true, + 'keydown': true, + 'keypress': true, + 'keyup': true, + 'mousedown': true, + 'mousemove': true, + 'mouseout': true, + 'mouseover': true, + 'mouseup': true, + 'focus': true, + 'blur': true, + 'submit': true + }; + + var isReady = false; // to determine when to init HTMLElement and content + + if (YAHOO.lang.isString(el) ) { // defer until available/ready + _registerHTMLAttr.call(this, 'id', { value: attr.element }); + } + + if (Dom.get(el)) { + isReady = true; + _initHTMLElement.call(this, attr); + _initContent.call(this, attr); + } + + YAHOO.util.Event.onAvailable(attr.element, function() { + if (!isReady) { // otherwise already done + _initHTMLElement.call(this, attr); + } + + this.fireEvent('available', { type: 'available', target: attr.element }); + }, this, true); + + YAHOO.util.Event.onContentReady(attr.element, function() { + if (!isReady) { // otherwise already done + _initContent.call(this, attr); + } + this.fireEvent('contentReady', { type: 'contentReady', target: attr.element }); + }, this, true); +}; + +var _initHTMLElement = function(attr) { + /** + * The HTMLElement the Element instance refers to. + * @attribute element + * @type HTMLElement + */ + this.setAttributeConfig('element', { + value: Dom.get(attr.element), + readOnly: true + }); +}; + +var _initContent = function(attr) { + this.initAttributes(attr); + this.setAttributes(attr, true); + this.fireQueue(); + +}; + +/** + * Sets the value of the property and fires beforeChange and change events. + * @private + * @method _registerHTMLAttr + * @param {YAHOO.util.Element} element The Element instance to + * register the config to. + * @param {String} key The name of the config to register + * @param {Object} map A key-value map of the config's params + */ +var _registerHTMLAttr = function(key, map) { + var el = this.get('element'); + map = map || {}; + map.name = key; + map.method = map.method || function(value) { + el[key] = value; + }; + map.value = map.value || el[key]; + this._configs[key] = new YAHOO.util.Attribute(map, this); +}; + +/** + * Fires when the Element's HTMLElement can be retrieved by Id. + * <p>See: <a href="#addListener">Element.addListener</a></p> + * <p><strong>Event fields:</strong><br> + * <code><String> type</code> available<br> + * <code><HTMLElement> + * target</code> the HTMLElement bound to this Element instance<br> + * <p><strong>Usage:</strong><br> + * <code>var handler = function(e) {var target = e.target};<br> + * myTabs.addListener('available', handler);</code></p> + * @event available + */ + +/** + * Fires when the Element's HTMLElement subtree is rendered. + * <p>See: <a href="#addListener">Element.addListener</a></p> + * <p><strong>Event fields:</strong><br> + * <code><String> type</code> contentReady<br> + * <code><HTMLElement> + * target</code> the HTMLElement bound to this Element instance<br> + * <p><strong>Usage:</strong><br> + * <code>var handler = function(e) {var target = e.target};<br> + * myTabs.addListener('contentReady', handler);</code></p> + * @event contentReady + */ + +/** + * Fires before the Element is appended to another Element. + * <p>See: <a href="#addListener">Element.addListener</a></p> + * <p><strong>Event fields:</strong><br> + * <code><String> type</code> beforeAppendTo<br> + * <code><HTMLElement/Element> + * target</code> the HTMLElement/Element being appended to + * <p><strong>Usage:</strong><br> + * <code>var handler = function(e) {var target = e.target};<br> + * myTabs.addListener('beforeAppendTo', handler);</code></p> + * @event beforeAppendTo + */ + +/** + * Fires after the Element is appended to another Element. + * <p>See: <a href="#addListener">Element.addListener</a></p> + * <p><strong>Event fields:</strong><br> + * <code><String> type</code> appendTo<br> + * <code><HTMLElement/Element> + * target</code> the HTMLElement/Element being appended to + * <p><strong>Usage:</strong><br> + * <code>var handler = function(e) {var target = e.target};<br> + * myTabs.addListener('appendTo', handler);</code></p> + * @event appendTo + */ + +YAHOO.augment(YAHOO.util.Element, AttributeProvider); +})(); + +YAHOO.register("element", YAHOO.util.Element, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/json-min.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/json-min.js new file mode 100644 index 0000000..6acce5a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/json-min.js
@@ -0,0 +1,7 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +YAHOO.namespace("lang");YAHOO.lang.JSON={_ESCAPES:/\\["\\\/bfnrtu]/g,_VALUES:/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,_BRACKETS:/(?:^|:|,)(?:\s*\[)+/g,_INVALID:/^[\],:{}\s]*$/,_SPECIAL_CHARS:/["\\\x00-\x1f\x7f-\x9f]/g,_PARSE_DATE:/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})Z$/,_CHARS:{"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},_applyFilter:function(C,B){var A=function(E,D){var F,G;if(D&&typeof D==="object"){for(F in D){if(YAHOO.lang.hasOwnProperty(D,F)){G=A(F,D[F]);if(G===undefined){delete D[F];}else{D[F]=G;}}}}return B(E,D);};if(YAHOO.lang.isFunction(B)){A("",C);}return C;},isValid:function(A){if(!YAHOO.lang.isString(A)){return false;}return this._INVALID.test(A.replace(this._ESCAPES,"@").replace(this._VALUES,"]").replace(this._BRACKETS,""));},dateToString:function(B){function A(C){return C<10?"0"+C:C;}return'"'+B.getUTCFullYear()+"-"+A(B.getUTCMonth()+1)+"-"+A(B.getUTCDate())+"T"+A(B.getUTCHours())+":"+A(B.getUTCMinutes())+":"+A(B.getUTCSeconds())+'Z"';},stringToDate:function(B){if(this._PARSE_DATE.test(B)){var A=new Date();A.setUTCFullYear(RegExp.$1,(RegExp.$2|0)-1,RegExp.$3);A.setUTCHours(RegExp.$4,RegExp.$5,RegExp.$6);return A;}},parse:function(s,filter){if(this.isValid(s)){return this._applyFilter(eval("("+s+")"),filter);}throw new SyntaxError("parseJSON");},stringify:function(C,K,F){var E=YAHOO.lang,H=E.JSON,D=H._CHARS,A=this._SPECIAL_CHARS,B=[];var I=function(N){if(!D[N]){var J=N.charCodeAt();D[N]="\\u00"+Math.floor(J/16).toString(16)+(J%16).toString(16);}return D[N];};var M=function(J){return'"'+J.replace(A,I)+'"';};var L=H.dateToString;var G=function(J,T,R){var W=typeof J,P,Q,O,N,U,V,S;if(W==="string"){return M(J);}if(W==="boolean"||J instanceof Boolean){return String(J);}if(W==="number"||J instanceof Number){return isFinite(J)?String(J):"null";}if(J instanceof Date){return L(J);}if(E.isArray(J)){for(P=B.length-1;P>=0;--P){if(B[P]===J){return"null";}}B[B.length]=J;S=[];if(R>0){for(P=J.length-1;P>=0;--P){S[P]=G(J[P],T,R-1)||"null";}}B.pop();return"["+S.join(",")+"]";}if(W==="object"){if(!J){return"null";}for(P=B.length-1;P>=0;--P){if(B[P]===J){return"null";}}B[B.length]=J;S=[];if(R>0){if(T){for(P=0,O=0,Q=T.length;P<Q;++P){if(typeof T[P]==="string"){U=G(J[T[P]],T,R-1);if(U){S[O++]=M(T[P])+":"+U;}}}}else{O=0;for(N in J){if(typeof N==="string"&&E.hasOwnProperty(J,N)){U=G(J[N],T,R-1);if(U){S[O++]=M(N)+":"+U;}}}}}B.pop();return"{"+S.join(",")+"}";}return undefined;};F=F>=0?F:1/0;return G(C,K,F);}};YAHOO.register("json",YAHOO.lang.JSON,{version:"2.5.2",build:"1076"}); \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/border_tabs.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/border_tabs.css new file mode 100644 index 0000000..c16cc61 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/border_tabs.css
@@ -0,0 +1,54 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-navset .yui-nav li a, .yui-navset .yui-content { + border:1px solid #000; /* label and content borders */ +} + +.yui-navset .yui-nav .selected a, .yui-navset .yui-nav a:hover, .yui-navset .yui-content { + background-color:#f6f7ee; /* active tab, tab hover, and content bgcolor */ +} + +.yui-navset .yui-nav li em { padding:.5em; } /* tab padding */ + +/* defaults to orientation "top" */ +.yui-navset .yui-nav .selected a { + border-bottom-width:0; /* no bottom border for active tab */ + padding-bottom:1px; /* to match height of other tabs */ +} + +.yui-navset .yui-content { + margin-top:-1px; /* for active tab overlap */ +} + +/* overrides for other orientations */ + +.yui-navset-bottom .yui-nav .selected a { + border-width:0 1px 1px; /* no top border for active tab */ + padding:1px 0 0; /* to match height of other tabs */ +} + +.yui-navset-bottom .yui-content { + margin:0 0 -1px; /* for active tab overlap */ +} + +.yui-navset-left .yui-nav li.selected a { + border-width:1px 0 1px 1px; /* no right border for active tab */ + padding:0 1px 0 0; /* to match width of other tabs */ +} + +.yui-navset-left .yui-content { + margin:0 0 0 -1px; /* for active tab overlap */ +} + +.yui-navset-right .yui-nav li.selected a { + border-width:1px 1px 1px 0; /* no left border for active tab */ + padding:0 0 0 1px; /* to match width of other tabs */ +} + +.yui-navset-right .yui-content { + margin:0 -1px 0 0; /* for active tab overlap */ +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/loading.gif b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/loading.gif new file mode 100644 index 0000000..6a56815 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/loading.gif Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skin-sam.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skin-sam.css new file mode 100644 index 0000000..135eba8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skin-sam.css
@@ -0,0 +1,77 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +.yui-navset .yui-nav li { + margin-right:0.16em; /* space between tabs */ + padding-top:1px; /* gecko: make room for overflow */ + zoom:1; +} + +.yui-navset .yui-nav .selected { + margin-bottom:-1px; /* for overlap */ +} + +.yui-navset .yui-nav a { + background:#dadbdb url(../../assets/skins/sam/sprite.png) repeat-x; /* sprite position for normal gradient */ + border:solid #a3a3a3; + border-width:0 1px; + color:#000; + text-decoration:none; +} + +.yui-navset .yui-nav li a em { + border-top:solid 1px #a3a3a3; + border-bottom:0; + cursor:hand; + padding:0.2em 0.5em; + top:-1px; /* for 1px rounded corners */ + position:relative; +} + +.yui-navset .yui-nav .selected a, +.yui-navset .yui-nav a:focus, +.yui-navset .yui-nav a:hover { + background:#214197 url(../../assets/skins/sam/sprite.png) repeat-x left -1400px; + color:#fff; +} + +.yui-navset .yui-nav .selected a em { + padding:0.3em 0.5em; /* raise selected tab */ +} + +.yui-navset .yui-nav .selected a, +.yui-navset .yui-nav a:hover, +.yui-navset .yui-nav a:focus { + border-color:#243356; +} + +.yui-navset .yui-nav a:hover em, +.yui-navset .yui-nav a:focus em, +.yui-navset .yui-nav .selected a em { + border-color:#233356 #406ed9; +} + +.yui-navset .yui-nav { + border-bottom:1px solid #243356; + position:relative; + zoom:1; +} + +.yui-navset .yui-content { + background:#abceff; + border-top:5px solid #214095; +} + +.yui-navset .yui-content div { + border:1px solid #808080; + border-top-color:#243356; + padding:0.25em 0.5em; +} + +.yui-navset .yui-content div div { /* kill inheritance */ + border:0; + padding:0; +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skins/sam/tabview-skin.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skins/sam/tabview-skin.css new file mode 100644 index 0000000..b39d2f6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skins/sam/tabview-skin.css
@@ -0,0 +1,187 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/* .yui-navset defaults to .yui-navset-top */ +.yui-skin-sam .yui-navset .yui-nav, +.yui-skin-sam .yui-navset .yui-navset-top .yui-nav { /* protect nested tabviews from other orientations */ + border:solid #2647a0; /* color between tab list and content */ + border-width:0 0 5px; + Xposition:relative; + zoom:1; +} + +.yui-skin-sam .yui-navset .yui-nav li, +.yui-skin-sam .yui-navset .yui-navset-top .yui-nav li { + margin:0 0.16em 0 0; /* space between tabs */ + padding:1px 0 0; /* gecko: make room for overflow */ + zoom:1; +} + +.yui-skin-sam .yui-navset .yui-nav .selected, +.yui-skin-sam .yui-navset .yui-navset-top .yui-nav .selected { + margin:0 0.16em -1px 0; /* for overlap */ +} + +.yui-skin-sam .yui-navset .yui-nav a, +.yui-skin-sam .yui-navset .yui-navset-top .yui-nav a { + background:#d8d8d8 url(../../../../assets/skins/sam/sprite.png) repeat-x; /* tab background */ + border:solid #a3a3a3; + border-width:0 1px; + color:#000; + position:relative; + text-decoration:none; +} + +.yui-skin-sam .yui-navset .yui-nav a em, +.yui-skin-sam .yui-navset .yui-navset-top .yui-nav a em { + border:solid #a3a3a3; + border-width:1px 0 0; + cursor:hand; + padding:0.25em .75em; + left:0; right: 0; bottom: 0; /* protect from other orientations */ + top:-1px; /* for 1px rounded corners */ + position:relative; +} + +.yui-skin-sam .yui-navset .yui-nav .selected a, +.yui-skin-sam .yui-navset .yui-nav .selected a:focus, /* no focus effect for selected */ +.yui-skin-sam .yui-navset .yui-nav .selected a:hover { /* no hover effect for selected */ + background:#2647a0 url(../../../../assets/skins/sam/sprite.png) repeat-x left -1400px; /* selected tab background */ + color:#fff; +} + +.yui-skin-sam .yui-navset .yui-nav a:hover, +.yui-skin-sam .yui-navset .yui-nav a:focus { + background:#bfdaff url(../../../../assets/skins/sam/sprite.png) repeat-x left -1300px; /* selected tab background */ + outline:0; +} + +.yui-skin-sam .yui-navset .yui-nav .selected a em { + padding:0.35em 0.75em; /* raise selected tab */ +} + +.yui-skin-sam .yui-navset .yui-nav .selected a, +.yui-skin-sam .yui-navset .yui-nav .selected a em { + border-color:#243356; /* selected tab border color */ +} + +.yui-skin-sam .yui-navset .yui-content { + background:#edf5ff; /* content background color */ +} + +.yui-skin-sam .yui-navset .yui-content, +.yui-skin-sam .yui-navset .yui-navset-top .yui-content { + border:1px solid #808080; /* content border */ + border-top-color:#243356; /* different border color */ + padding:0.25em 0.5em; /* content padding */ +} + +/* left and right orientations */ +.yui-skin-sam .yui-navset-left .yui-nav, +.yui-skin-sam .yui-navset .yui-navset-left .yui-nav, +.yui-skin-sam .yui-navset .yui-navset-right .yui-nav, +.yui-skin-sam .yui-navset-right .yui-nav { + border-width:0 5px 0 0; + Xposition:absolute; /* from tabview-core; have to reiterate for skin-sam due to pos:rel on skin-sam yui-nav */ + top:0; bottom:0; /* stretch to fill content height */ +} + +.yui-skin-sam .yui-navset .yui-navset-right .yui-nav, +.yui-skin-sam .yui-navset-right .yui-nav { + border-width:0 0 0 5px; +} + +.yui-skin-sam .yui-navset-left .yui-nav li, +.yui-skin-sam .yui-navset .yui-navset-left .yui-nav li, +.yui-skin-sam .yui-navset-right .yui-nav li { + margin:0 0 0.16em; /* space between tabs */ + padding:0 0 0 1px; /* gecko: make room for overflow */ +} + +.yui-skin-sam .yui-navset-right .yui-nav li { + padding:0 1px 0 0; /* gecko: make room for overflow */ +} + +.yui-skin-sam .yui-navset-left .yui-nav .selected, +.yui-skin-sam .yui-navset .yui-navset-left .yui-nav .selected { + margin:0 -1px 0.16em 0; +} + +.yui-skin-sam .yui-navset-right .yui-nav .selected { + margin:0 0 0.16em -1px; +} + +.yui-skin-sam .yui-navset-left .yui-nav a, +.yui-skin-sam .yui-navset-right .yui-nav a { + border-width:1px 0; +} + +.yui-skin-sam .yui-navset-left .yui-nav a em, +.yui-skin-sam .yui-navset .yui-navset-left .yui-nav a em, +.yui-skin-sam .yui-navset-right .yui-nav a em { + border-width:0 0 0 1px; + padding:0.2em .75em; + top:auto; + left:-1px; /* for 1px rounded corners */ +} + +.yui-skin-sam .yui-navset-right .yui-nav a em { + border-width:0 1px 0 0; + left:auto; + right:-1px; /* for 1px rounded corners */ +} + +.yui-skin-sam .yui-navset-left .yui-nav a, +.yui-skin-sam .yui-navset-left .yui-nav .selected a, +.yui-skin-sam .yui-navset-left .yui-nav a:hover, +.yui-skin-sam .yui-navset-right .yui-nav a, +.yui-skin-sam .yui-navset-right .yui-nav .selected a, +.yui-skin-sam .yui-navset-right .yui-nav a:hover, +.yui-skin-sam .yui-navset-bottom .yui-nav a, +.yui-skin-sam .yui-navset-bottom .yui-nav .selected a, +.yui-skin-sam .yui-navset-bottom .yui-nav a:hover { + background-image:none; /* no left-right or bottom-top gradient */ +} + +.yui-skin-sam .yui-navset-left .yui-content { + border:1px solid #808080; /* content border */ + border-left-color:#243356; /* different border color */ +} + +/* bottom orientation */ +.yui-skin-sam .yui-navset-bottom .yui-nav, +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav { + border-width:5px 0 0; /* color between tab list and content */ +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav .selected, +.yui-skin-sam .yui-navset-bottom .yui-nav .selected { + margin:-1px 0.16em 0 0; /* for overlap */ +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li, +.yui-skin-sam .yui-navset-bottom .yui-nav li { + padding:0 0 1px 0; /* gecko: make room for overflow */ + vertical-align:top; +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li a, +.yui-skin-sam .yui-navset-bottom .yui-nav li a { +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav a em, +.yui-skin-sam .yui-navset-bottom .yui-nav a em { + border-width:0 0 1px; + top:auto; + bottom:-1px; /* for 1px rounded corners */ +} + +.yui-skin-sam .yui-navset-bottom .yui-content, +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-content { + border:1px solid #808080; /* content border */ + border-bottom-color:#243356; /* different border color */ +} +
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skins/sam/tabview.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skins/sam/tabview.css new file mode 100644 index 0000000..1896999 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/skins/sam/tabview.css
@@ -0,0 +1,259 @@ +/* + Copyright (c) 2008, Yahoo! Inc. All rights reserved. + Code licensed under the BSD License: + http://developer.yahoo.net/yui/license.txt + version: 2.5.2 + */ +.yui-navset .yui-nav li, .yui-navset .yui-navset-top .yui-nav li, .yui-navset .yui-navset-bottom .yui-nav li { + margin: 0 0.5em 0 0; +} + +.yui-navset-left .yui-nav li, .yui-navset-right .yui-nav li { + margin: 0 0 0.5em; +} + +.yui-navset .yui-navset-left .yui-nav, .yui-navset .yui-navset-right .yui-nav, .yui-navset-left .yui-nav, .yui-navset-right .yui-nav { + width: 6em; +} + +.yui-navset-top .yui-nav, .yui-navset-bottom .yui-nav { + width: auto; +} + +.yui-navset .yui-navset-left, .yui-navset-left { + padding: 0 0 0 6em; +} + +.yui-navset-right { + padding: 0 6em 0 0; +} + +.yui-navset-top, .yui-navset-bottom { + padding: auto; +} + +.yui-nav, .yui-nav li { + margin: 0; + padding: 0; + list-style: none; +} + +.yui-navset li em { + font-style: normal; +} + +.yui-navset { + position: relative; + zoom: 1; +} + +.yui-navset .yui-content { + zoom: 1; +} + +.yui-navset .yui-nav li, .yui-navset .yui-navset-top .yui-nav li, .yui-navset .yui-navset-bottom .yui-nav li { + display: inline-block; + display: -moz-inline-stack; + +* display:inline; + +vertical-align:bottom; + +cursor:pointer; + +zoom: + 1; +} + +.yui-navset-left .yui-nav li, .yui-navset-right .yui-nav li { + display: block; +} + +.yui-navset .yui-nav a { + position: relative; +} + +.yui-navset .yui-nav li a, .yui-navset-top .yui-nav li a, .yui-navset-bottom .yui-nav li a { + display: block; + display: inline-block; + vertical-align: bottom; + zoom: 1; +} + +.yui-navset-left .yui-nav li a, .yui-navset-right .yui-nav li a { + display: block; +} + +.yui-navset-bottom .yui-nav li a { + vertical-align: text-top; +} + +.yui-navset .yui-nav li a em, .yui-navset-top .yui-nav li a em, .yui-navset-bottom .yui-nav li a em { + display: block; +} + +.yui-navset .yui-navset-left .yui-nav, .yui-navset .yui-navset-right .yui-nav, .yui-navset-left .yui-nav, .yui-navset-right .yui-nav { + position: absolute; + z-index: 1; +} + +.yui-navset-top .yui-nav, .yui-navset-bottom .yui-nav { + position: static; +} + +.yui-navset .yui-navset-left .yui-nav, .yui-navset-left .yui-nav { + left: 0; + right: auto; +} + +.yui-navset .yui-navset-right .yui-nav, .yui-navset-right .yui-nav { + right: 0; + left: auto; +} + +.yui-skin-sam .yui-navset .yui-nav, .yui-skin-sam .yui-navset .yui-navset-top .yui-nav { + border: solid #2647a0; + border-width: 0 0 5px; + Xposition: relative; + zoom: 1; +} + +.yui-skin-sam .yui-navset .yui-nav li, .yui-skin-sam .yui-navset .yui-navset-top .yui-nav li { + margin: 0 0.16em 0 0; + padding: 1px 0 0; + zoom: 1; +} + +.yui-skin-sam .yui-navset .yui-nav .selected, .yui-skin-sam .yui-navset .yui-navset-top .yui-nav .selected { + margin: 0 0.16em -1px 0; +} + +.yui-skin-sam .yui-navset .yui-nav a, .yui-skin-sam .yui-navset .yui-navset-top .yui-nav a { + background: #d8d8d8 url(../../../../assets/skins/sam/sprite.png) repeat-x; + border: solid #a3a3a3; + border-width: 0 1px; + color: #000; + position: relative; + text-decoration: none; +} + +.yui-skin-sam .yui-navset .yui-nav a em, .yui-skin-sam .yui-navset .yui-navset-top .yui-nav a em { + border: solid #a3a3a3; + border-width: 1px 0 0; + cursor: hand; + padding: 0.25em .75em; + left: 0; + right: 0; + bottom: 0; + top: -1px; + position: relative; +} + +.yui-skin-sam .yui-navset .yui-nav .selected a, .yui-skin-sam .yui-navset .yui-nav .selected a:focus, .yui-skin-sam .yui-navset .yui-nav .selected a:hover { + background: #2647a0 url(../../../../assets/skins/sam/sprite.png) repeat-x left -1400px; + color: #fff; +} + +.yui-skin-sam .yui-navset .yui-nav a:hover, .yui-skin-sam .yui-navset .yui-nav a:focus { + background: #bfdaff url(../../../../assets/skins/sam/sprite.png) repeat-x left -1300px; + outline: 0; +} + +.yui-skin-sam .yui-navset .yui-nav .selected a em { + padding: 0.35em 0.75em; +} + +.yui-skin-sam .yui-navset .yui-nav .selected a, .yui-skin-sam .yui-navset .yui-nav .selected a em { + border-color: #243356; +} + +.yui-skin-sam .yui-navset .yui-content { + background: #fff; +} + +.yui-skin-sam .yui-navset .yui-content, .yui-skin-sam .yui-navset .yui-navset-top .yui-content { + border: 1px solid #fff; + border-top-color: #fff; + padding: 0.25em 0.5em; +} + +.yui-skin-sam .yui-navset-left .yui-nav, .yui-skin-sam .yui-navset .yui-navset-left .yui-nav, .yui-skin-sam .yui-navset .yui-navset-right .yui-nav, .yui-skin-sam .yui-navset-right .yui-nav { + border-width: 0 5px 0 0; + Xposition: absolute; + top: 0; + bottom: 0; +} + +.yui-skin-sam .yui-navset .yui-navset-right .yui-nav, .yui-skin-sam .yui-navset-right .yui-nav { + border-width: 0 0 0 5px; +} + +.yui-skin-sam .yui-navset-left .yui-nav li, .yui-skin-sam .yui-navset .yui-navset-left .yui-nav li, .yui-skin-sam .yui-navset-right .yui-nav li { + margin: 0 0 0.16em; + padding: 0 0 0 1px; +} + +.yui-skin-sam .yui-navset-right .yui-nav li { + padding: 0 1px 0 0; +} + +.yui-skin-sam .yui-navset-left .yui-nav .selected, .yui-skin-sam .yui-navset .yui-navset-left .yui-nav .selected { + margin: 0 -1px 0.16em 0; +} + +.yui-skin-sam .yui-navset-right .yui-nav .selected { + margin: 0 0 0.16em -1px; +} + +.yui-skin-sam .yui-navset-left .yui-nav a, .yui-skin-sam .yui-navset-right .yui-nav a { + border-width: 1px 0; +} + +.yui-skin-sam .yui-navset-left .yui-nav a em, .yui-skin-sam .yui-navset .yui-navset-left .yui-nav a em, .yui-skin-sam .yui-navset-right .yui-nav a em { + border-width: 0 0 0 1px; + padding: 0.2em .75em; + top: auto; + left: -1px; +} + +.yui-skin-sam .yui-navset-right .yui-nav a em { + border-width: 0 1px 0 0; + left: auto; + right: -1px; +} + +.yui-skin-sam .yui-navset-left .yui-nav a, .yui-skin-sam .yui-navset-left .yui-nav .selected a, .yui-skin-sam .yui-navset-left .yui-nav a:hover, .yui-skin-sam .yui-navset-right .yui-nav a, .yui-skin-sam .yui-navset-right .yui-nav .selected a, .yui-skin-sam .yui-navset-right .yui-nav a:hover, .yui-skin-sam .yui-navset-bottom .yui-nav a, .yui-skin-sam .yui-navset-bottom .yui-nav .selected a, .yui-skin-sam .yui-navset-bottom .yui-nav a:hover { + background-image: none; +} + +.yui-skin-sam .yui-navset-left .yui-content { + border: 1px solid #fff; + border-left-color: #fff; +} + +.yui-skin-sam .yui-navset-bottom .yui-nav, .yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav { + border-width: 5px 0 0; +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav .selected, .yui-skin-sam .yui-navset-bottom .yui-nav .selected { + margin: -1px 0.16em 0 0; +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li, .yui-skin-sam .yui-navset-bottom .yui-nav li { + padding: 0 0 1px 0; + vertical-align: top; +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav li a, .yui-skin-sam .yui-navset-bottom .yui-nav li a { +} + +.yui-skin-sam .yui-navset .yui-navset-bottom .yui-nav a em, .yui-skin-sam .yui-navset-bottom .yui-nav a em { + border-width: 0 0 1px; + top: auto; + bottom: -1px; +} + +.yui-skin-sam .yui-navset-bottom .yui-content, .yui-skin-sam .yui-navset .yui-navset-bottom .yui-content { + border: 1px solid #fff; + border-bottom-color: #fff; +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/tabview-core.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/tabview-core.css new file mode 100644 index 0000000..3a94ab4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/tabview-core.css
@@ -0,0 +1,110 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/* default space between tabs */ +.yui-navset .yui-nav li, +.yui-navset .yui-navset-top .yui-nav li, +.yui-navset .yui-navset-bottom .yui-nav li { + margin:0 0.5em 0 0; /* horizontal tabs */ +} +.yui-navset-left .yui-nav li, +.yui-navset-right .yui-nav li { + margin:0 0 0.5em; /* vertical tabs */ +} + +/* default width for side tabs */ +.yui-navset .yui-navset-left .yui-nav, +.yui-navset .yui-navset-right .yui-nav, +.yui-navset-left .yui-nav, +.yui-navset-right .yui-nav { width:6em; } + +.yui-navset-top .yui-nav, +.yui-navset-bottom .yui-nav { + width:auto; +} +.yui-navset .yui-navset-left, +.yui-navset-left { padding:0 0 0 6em; } /* map to nav width */ +.yui-navset-right { padding:0 6em 0 0; } /* ditto */ + +.yui-navset-top, +.yui-navset-bottom { + padding:auto; +} +/* core */ + +.yui-nav, +.yui-nav li { + margin:0; + padding:0; + list-style:none; +} +.yui-navset li em { font-style:normal; } + +.yui-navset { + position:relative; /* contain absolute positioned tabs (left/right) */ + zoom:1; +} + +.yui-navset .yui-content { zoom:1; } + +.yui-navset .yui-nav li, +.yui-navset .yui-navset-top .yui-nav li, /* in case nested */ +.yui-navset .yui-navset-bottom .yui-nav li { + display:inline-block; + display:-moz-inline-stack; + *display:inline; /* IE */ + vertical-align:bottom; /* safari: for overlap */ + cursor:pointer; /* gecko: due to -moz-inline-stack on anchor */ + zoom:1; /* IE: kill space between horizontal tabs */ +} + +.yui-navset-left .yui-nav li, +.yui-navset-right .yui-nav li { + display:block; +} + +.yui-navset .yui-nav a { position:relative; } /* IE: to allow overlap */ + +.yui-navset .yui-nav li a, +.yui-navset-top .yui-nav li a, +.yui-navset-bottom .yui-nav li a { + display:block; + display:inline-block; + vertical-align:bottom; /* safari: for overlap */ + zoom:1; +} + +.yui-navset-left .yui-nav li a, +.yui-navset-right .yui-nav li a { + display:block; +} + +.yui-navset-bottom .yui-nav li a { + vertical-align:text-top; /* for inline overlap (reverse for Opera border bug) */ +} + +.yui-navset .yui-nav li a em, +.yui-navset-top .yui-nav li a em, +.yui-navset-bottom .yui-nav li a em { display:block; } + +/* position left and right oriented tabs */ +.yui-navset .yui-navset-left .yui-nav, +.yui-navset .yui-navset-right .yui-nav, +.yui-navset-left .yui-nav, +.yui-navset-right .yui-nav { + position:absolute; + z-index:1; +} + +.yui-navset-top .yui-nav, +.yui-navset-bottom .yui-nav { + position:static; +} +.yui-navset .yui-navset-left .yui-nav, +.yui-navset-left .yui-nav { left:0; right:auto; } + +.yui-navset .yui-navset-right .yui-nav, +.yui-navset-right .yui-nav { right:0; left:auto; }
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/tabview.css b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/tabview.css new file mode 100644 index 0000000..689508f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tab/tabview.css
@@ -0,0 +1,75 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +/* default space between tabs */ +.yui-navset .yui-nav li { + margin-right:0.5em; /* horizontal tabs */ +} +.yui-navset-left .yui-nav li, .yui-navset-right .yui-nav li { + margin:0 0 0.5em; /* vertical tabs */ +} + +/* default width for side tabs */ +.yui-navset-left .yui-nav, .yui-navset-right .yui-nav { width:6em; } +.yui-navset-left { padding-left:6em; } /* map to nav width */ +.yui-navset-right { padding-right:6em; } /* ditto */ + +/* core */ + +.yui-nav, .yui-nav li { + margin:0; + padding:0; + list-style:none; +} +.yui-navset li em { font-style:normal; } + +.yui-navset { + position:relative; /* contain absolute positioned tabs (left/right) */ + zoom:1; +} + +.yui-navset .yui-content { zoom:1; } + +.yui-navset .yui-nav li { + display:inline-block; + display:-moz-inline-stack; + *display:inline; /* IE */ + vertical-align:bottom; /* safari: for overlap */ + cursor:pointer; /* gecko: due to -moz-inline-stack on anchor */ + zoom:1; /* IE: kill space between horizontal tabs */ +} + +.yui-navset-left .yui-nav li, .yui-navset-right .yui-nav li { + display:block; +} + +.yui-navset .yui-nav a { + outline:0; /* gecko: keep from shifting */ +} + +.yui-navset .yui-nav a { position:relative; } /* IE: to allow overlap */ + +.yui-navset .yui-nav li a { + display:block; + display:inline-block; + vertical-align:bottom; /* safari: for overlap */ + zoom:1; +} + +.yui-navset-left .yui-nav li a, .yui-navset-right .yui-nav li a { + display:block; +} + +.yui-navset-bottom .yui-nav li a { + vertical-align:text-top; /* for inline overlap (reverse for Op border bug) */ +} + +.yui-navset .yui-nav li a em { display:block; } + +/* position left and right oriented tabs */ +.yui-navset-left .yui-nav, .yui-navset-right .yui-nav { position:absolute; z-index:1; } +.yui-navset-left .yui-nav { left:0; } +.yui-navset-right .yui-nav { right:0; }
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tabview.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tabview.js new file mode 100644 index 0000000..2ff0f74 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/tabview.js
@@ -0,0 +1,890 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +(function() { + + /** + * The tabview module provides a widget for managing content bound to tabs. + * @module tabview + * @requires yahoo, dom, event, element + * + */ + /** + * A widget to control tabbed views. + * @namespace YAHOO.widget + * @class TabView + * @extends YAHOO.util.Element + * @constructor + * @param {HTMLElement | String | Object} el(optional) The html + * element that represents the TabView, or the attribute object to use. + * An element will be created if none provided. + * @param {Object} attr (optional) A key map of the tabView's + * initial attributes. Ignored if first arg is attributes object. + */ + YAHOO.widget.TabView = function(el, attr) { + attr = attr || {}; + if (arguments.length == 1 && !YAHOO.lang.isString(el) && !el.nodeName) { + attr = el; // treat first arg as attr object + el = attr.element || null; + } + + if (!el && !attr.element) { // create if we dont have one + el = _createTabViewElement.call(this, attr); + } + YAHOO.widget.TabView.superclass.constructor.call(this, el, attr); + }; + + YAHOO.extend(YAHOO.widget.TabView, YAHOO.util.Element); + + var proto = YAHOO.widget.TabView.prototype; + var Dom = YAHOO.util.Dom; + var Event = YAHOO.util.Event; + var Tab = YAHOO.widget.Tab; + + + /** + * The className to add when building from scratch. + * @property CLASSNAME + * @default "navset" + */ + proto.CLASSNAME = 'yui-navset'; + + /** + * The className of the HTMLElement containing the TabView's tab elements + * to look for when building from existing markup, or to add when building + * from scratch. + * All childNodes of the tab container are treated as Tabs when building + * from existing markup. + * @property TAB_PARENT_CLASSNAME + * @default "nav" + */ + proto.TAB_PARENT_CLASSNAME = 'yui-nav'; + + /** + * The className of the HTMLElement containing the TabView's label elements + * to look for when building from existing markup, or to add when building + * from scratch. + * All childNodes of the content container are treated as content elements when + * building from existing markup. + * @property CONTENT_PARENT_CLASSNAME + * @default "nav-content" + */ + proto.CONTENT_PARENT_CLASSNAME = 'yui-content'; + + proto._tabParent = null; + proto._contentParent = null; + + /** + * Adds a Tab to the TabView instance. + * If no index is specified, the tab is added to the end of the tab list. + * @method addTab + * @param {YAHOO.widget.Tab} tab A Tab instance to add. + * @param {Integer} index The position to add the tab. + * @return void + */ + proto.addTab = function(tab, index) { + var tabs = this.get('tabs'); + if (!tabs) { // not ready yet + this._queue[this._queue.length] = ['addTab', arguments]; + return false; + } + + index = (index === undefined) ? tabs.length : index; + + var before = this.getTab(index); + + var self = this; + var el = this.get('element'); + var tabParent = this._tabParent; + var contentParent = this._contentParent; + + var tabElement = tab.get('element'); + var contentEl = tab.get('contentEl'); + + if ( before ) { + tabParent.insertBefore(tabElement, before.get('element')); + } else { + tabParent.appendChild(tabElement); + } + + if ( contentEl && !Dom.isAncestor(contentParent, contentEl) ) { + contentParent.appendChild(contentEl); + } + + if ( !tab.get('active') ) { + tab.set('contentVisible', false, true); /* hide if not active */ + } else { + this.set('activeTab', tab, true); + + } + + var activate = function(e) { + YAHOO.util.Event.preventDefault(e); + var silent = false; + + if (this == self.get('activeTab')) { + silent = true; // dont fire activeTabChange if already active + } + self.set('activeTab', this, silent); + }; + + tab.addListener( tab.get('activationEvent'), activate); + + tab.addListener('activationEventChange', function(e) { + if (e.prevValue != e.newValue) { + tab.removeListener(e.prevValue, activate); + tab.addListener(e.newValue, activate); + } + }); + + tabs.splice(index, 0, tab); + }; + + /** + * Routes childNode events. + * @method DOMEventHandler + * @param {event} e The Dom event that is being handled. + * @return void + */ + proto.DOMEventHandler = function(e) { + var el = this.get('element'); + var target = YAHOO.util.Event.getTarget(e); + var tabParent = this._tabParent; + + if (Dom.isAncestor(tabParent, target) ) { + var tabEl; + var tab = null; + var contentEl; + var tabs = this.get('tabs'); + + for (var i = 0, len = tabs.length; i < len; i++) { + tabEl = tabs[i].get('element'); + contentEl = tabs[i].get('contentEl'); + + if ( target == tabEl || Dom.isAncestor(tabEl, target) ) { + tab = tabs[i]; + break; // note break + } + } + + if (tab) { + tab.fireEvent(e.type, e); + } + } + }; + + /** + * Returns the Tab instance at the specified index. + * @method getTab + * @param {Integer} index The position of the Tab. + * @return YAHOO.widget.Tab + */ + proto.getTab = function(index) { + return this.get('tabs')[index]; + }; + + /** + * Returns the index of given tab. + * @method getTabIndex + * @param {YAHOO.widget.Tab} tab The tab whose index will be returned. + * @return int + */ + proto.getTabIndex = function(tab) { + var index = null; + var tabs = this.get('tabs'); + for (var i = 0, len = tabs.length; i < len; ++i) { + if (tab == tabs[i]) { + index = i; + break; + } + } + + return index; + }; + + /** + * Removes the specified Tab from the TabView. + * @method removeTab + * @param {YAHOO.widget.Tab} item The Tab instance to be removed. + * @return void + */ + proto.removeTab = function(tab) { + var tabCount = this.get('tabs').length; + + var index = this.getTabIndex(tab); + var nextIndex = index + 1; + if ( tab == this.get('activeTab') ) { // select next tab + if (tabCount > 1) { + if (index + 1 == tabCount) { + this.set('activeIndex', index - 1); + } else { + this.set('activeIndex', index + 1); + } + } + } + + this._tabParent.removeChild( tab.get('element') ); + this._contentParent.removeChild( tab.get('contentEl') ); + this._configs.tabs.value.splice(index, 1); + + }; + + /** + * Provides a readable name for the TabView instance. + * @method toString + * @return String + */ + proto.toString = function() { + var name = this.get('id') || this.get('tagName'); + return "TabView " + name; + }; + + /** + * The transiton to use when switching between tabs. + * @method contentTransition + */ + proto.contentTransition = function(newTab, oldTab) { + newTab.set('contentVisible', true); + oldTab.set('contentVisible', false); + }; + + /** + * setAttributeConfigs TabView specific properties. + * @method initAttributes + * @param {Object} attr Hash of initial attributes + */ + proto.initAttributes = function(attr) { + YAHOO.widget.TabView.superclass.initAttributes.call(this, attr); + + if (!attr.orientation) { + attr.orientation = 'top'; + } + + var el = this.get('element'); + + if (!YAHOO.util.Dom.hasClass(el, this.CLASSNAME)) { + YAHOO.util.Dom.addClass(el, this.CLASSNAME); + } + + /** + * The Tabs belonging to the TabView instance. + * @attribute tabs + * @type Array + */ + this.setAttributeConfig('tabs', { + value: [], + readOnly: true + }); + + /** + * The container of the tabView's label elements. + * @property _tabParent + * @private + * @type HTMLElement + */ + this._tabParent = + this.getElementsByClassName(this.TAB_PARENT_CLASSNAME, + 'ul' )[0] || _createTabParent.call(this); + + /** + * The container of the tabView's content elements. + * @property _contentParent + * @type HTMLElement + * @private + */ + this._contentParent = + this.getElementsByClassName(this.CONTENT_PARENT_CLASSNAME, + 'div')[0] || _createContentParent.call(this); + + /** + * How the Tabs should be oriented relative to the TabView. + * @attribute orientation + * @type String + * @default "top" + */ + this.setAttributeConfig('orientation', { + value: attr.orientation, + method: function(value) { + var current = this.get('orientation'); + this.addClass('yui-navset-' + value); + + if (current != value) { + this.removeClass('yui-navset-' + current); + } + + switch(value) { + case 'bottom': + this.appendChild(this._tabParent); + break; + } + } + }); + + /** + * The index of the tab currently active. + * @attribute activeIndex + * @type Int + */ + this.setAttributeConfig('activeIndex', { + value: attr.activeIndex, + method: function(value) { + this.set('activeTab', this.getTab(value)); + }, + validator: function(value) { + return !this.getTab(value).get('disabled'); // cannot activate if disabled + } + }); + + /** + * The tab currently active. + * @attribute activeTab + * @type YAHOO.widget.Tab + */ + this.setAttributeConfig('activeTab', { + value: attr.activeTab, + method: function(tab) { + var activeTab = this.get('activeTab'); + + if (tab) { + tab.set('active', true); + this._configs['activeIndex'].value = this.getTabIndex(tab); // keep in sync + } + + if (activeTab && activeTab != tab) { + activeTab.set('active', false); + } + + if (activeTab && tab != activeTab) { // no transition if only 1 + this.contentTransition(tab, activeTab); + } else if (tab) { + tab.set('contentVisible', true); + } + }, + validator: function(value) { + return !value.get('disabled'); // cannot activate if disabled + } + }); + + if ( this._tabParent ) { + _initTabs.call(this); + } + + // Due to delegation we add all DOM_EVENTS to the TabView container + // but IE will leak when unsupported events are added, so remove these + this.DOM_EVENTS.submit = false; + this.DOM_EVENTS.focus = false; + this.DOM_EVENTS.blur = false; + + for (var type in this.DOM_EVENTS) { + if ( YAHOO.lang.hasOwnProperty(this.DOM_EVENTS, type) ) { + this.addListener.call(this, type, this.DOMEventHandler); + } + } + }; + + /** + * Creates Tab instances from a collection of HTMLElements. + * @method initTabs + * @private + * @return void + */ + var _initTabs = function() { + var tab, + attr, + contentEl; + + var el = this.get('element'); + var tabs = _getChildNodes(this._tabParent); + var contentElements = _getChildNodes(this._contentParent); + + for (var i = 0, len = tabs.length; i < len; ++i) { + attr = {}; + + if (contentElements[i]) { + attr.contentEl = contentElements[i]; + } + + tab = new YAHOO.widget.Tab(tabs[i], attr); + this.addTab(tab); + + if (tab.hasClass(tab.ACTIVE_CLASSNAME) ) { + this._configs.activeTab.value = tab; // dont invoke method + this._configs.activeIndex.value = this.getTabIndex(tab); + } + } + }; + + var _createTabViewElement = function(attr) { + var el = document.createElement('div'); + + if ( this.CLASSNAME ) { + el.className = this.CLASSNAME; + } + + return el; + }; + + var _createTabParent = function(attr) { + var el = document.createElement('ul'); + + if ( this.TAB_PARENT_CLASSNAME ) { + el.className = this.TAB_PARENT_CLASSNAME; + } + + this.get('element').appendChild(el); + + return el; + }; + + var _createContentParent = function(attr) { + var el = document.createElement('div'); + + if ( this.CONTENT_PARENT_CLASSNAME ) { + el.className = this.CONTENT_PARENT_CLASSNAME; + } + + this.get('element').appendChild(el); + + return el; + }; + + var _getChildNodes = function(el) { + var nodes = []; + var childNodes = el.childNodes; + + for (var i = 0, len = childNodes.length; i < len; ++i) { + if (childNodes[i].nodeType == 1) { + nodes[nodes.length] = childNodes[i]; + } + } + + return nodes; + }; +})(); + +(function() { + var Dom = YAHOO.util.Dom, + Event = YAHOO.util.Event; + + /** + * A representation of a Tab's label and content. + * @namespace YAHOO.widget + * @class Tab + * @extends YAHOO.util.Element + * @constructor + * @param element {HTMLElement | String} (optional) The html element that + * represents the TabView. An element will be created if none provided. + * @param {Object} properties A key map of initial properties + */ + var Tab = function(el, attr) { + attr = attr || {}; + if (arguments.length == 1 && !YAHOO.lang.isString(el) && !el.nodeName) { + attr = el; + el = attr.element; + } + + if (!el && !attr.element) { + el = _createTabElement.call(this, attr); + } + + this.loadHandler = { + success: function(o) { + this.set('content', o.responseText); + }, + failure: function(o) { + } + }; + + Tab.superclass.constructor.call(this, el, attr); + + this.DOM_EVENTS = {}; // delegating to tabView + }; + + YAHOO.extend(Tab, YAHOO.util.Element); + var proto = Tab.prototype; + + /** + * The default tag name for a Tab's inner element. + * @property LABEL_INNER_TAGNAME + * @type String + * @default "em" + */ + proto.LABEL_TAGNAME = 'em'; + + /** + * The class name applied to active tabs. + * @property ACTIVE_CLASSNAME + * @type String + * @default "selected" + */ + proto.ACTIVE_CLASSNAME = 'selected'; + + /** + * The title applied to active tabs. + * @property ACTIVE_TITLE + * @type String + * @default "active" + */ + proto.ACTIVE_TITLE = 'active'; + + /** + * The class name applied to disabled tabs. + * @property DISABLED_CLASSNAME + * @type String + * @default "disabled" + */ + proto.DISABLED_CLASSNAME = 'disabled'; + + /** + * The class name applied to dynamic tabs while loading. + * @property LOADING_CLASSNAME + * @type String + * @default "disabled" + */ + proto.LOADING_CLASSNAME = 'loading'; + + /** + * Provides a reference to the connection request object when data is + * loaded dynamically. + * @property dataConnection + * @type Object + */ + proto.dataConnection = null; + + /** + * Object containing success and failure callbacks for loading data. + * @property loadHandler + * @type object + */ + proto.loadHandler = null; + + proto._loading = false; + + /** + * Provides a readable name for the tab. + * @method toString + * @return String + */ + proto.toString = function() { + var el = this.get('element'); + var id = el.id || el.tagName; + return "Tab " + id; + }; + + /** + * setAttributeConfigs TabView specific properties. + * @method initAttributes + * @param {Object} attr Hash of initial attributes + */ + proto.initAttributes = function(attr) { + attr = attr || {}; + Tab.superclass.initAttributes.call(this, attr); + + var el = this.get('element'); + + /** + * The event that triggers the tab's activation. + * @attribute activationEvent + * @type String + */ + this.setAttributeConfig('activationEvent', { + value: attr.activationEvent || 'click' + }); + + /** + * The element that contains the tab's label. + * @attribute labelEl + * @type HTMLElement + */ + this.setAttributeConfig('labelEl', { + value: attr.labelEl || _getlabelEl.call(this), + method: function(value) { + var current = this.get('labelEl'); + + if (current) { + if (current == value) { + return false; // already set + } + + this.replaceChild(value, current); + } else if (el.firstChild) { // ensure label is firstChild by default + this.insertBefore(value, el.firstChild); + } else { + this.appendChild(value); + } + } + }); + + /** + * The tab's label text (or innerHTML). + * @attribute label + * @type String + */ + this.setAttributeConfig('label', { + value: attr.label || _getLabel.call(this), + method: function(value) { + var labelEl = this.get('labelEl'); + if (!labelEl) { // create if needed + this.set('labelEl', _createlabelEl.call(this)); + } + + _setLabel.call(this, value); + } + }); + + /** + * The HTMLElement that contains the tab's content. + * @attribute contentEl + * @type HTMLElement + */ + this.setAttributeConfig('contentEl', { + value: attr.contentEl || document.createElement('div'), + method: function(value) { + var current = this.get('contentEl'); + + if (current) { + if (current == value) { + return false; // already set + } + this.replaceChild(value, current); + } + } + }); + + /** + * The tab's content. + * @attribute content + * @type String + */ + this.setAttributeConfig('content', { + value: attr.content, + method: function(value) { + this.get('contentEl').innerHTML = value; + } + }); + + var _dataLoaded = false; + + /** + * The tab's data source, used for loading content dynamically. + * @attribute dataSrc + * @type String + */ + this.setAttributeConfig('dataSrc', { + value: attr.dataSrc + }); + + /** + * Whether or not content should be reloaded for every view. + * @attribute cacheData + * @type Boolean + * @default false + */ + this.setAttributeConfig('cacheData', { + value: attr.cacheData || false, + validator: YAHOO.lang.isBoolean + }); + + /** + * The method to use for the data request. + * @attribute loadMethod + * @type String + * @default "GET" + */ + this.setAttributeConfig('loadMethod', { + value: attr.loadMethod || 'GET', + validator: YAHOO.lang.isString + }); + + /** + * Whether or not any data has been loaded from the server. + * @attribute dataLoaded + * @type Boolean + */ + this.setAttributeConfig('dataLoaded', { + value: false, + validator: YAHOO.lang.isBoolean, + writeOnce: true + }); + + /** + * Number if milliseconds before aborting and calling failure handler. + * @attribute dataTimeout + * @type Number + * @default null + */ + this.setAttributeConfig('dataTimeout', { + value: attr.dataTimeout || null, + validator: YAHOO.lang.isNumber + }); + + /** + * Whether or not the tab is currently active. + * If a dataSrc is set for the tab, the content will be loaded from + * the given source. + * @attribute active + * @type Boolean + */ + this.setAttributeConfig('active', { + value: attr.active || this.hasClass(this.ACTIVE_CLASSNAME), + method: function(value) { + if (value === true) { + this.addClass(this.ACTIVE_CLASSNAME); + this.set('title', this.ACTIVE_TITLE); + } else { + this.removeClass(this.ACTIVE_CLASSNAME); + this.set('title', ''); + } + }, + validator: function(value) { + return YAHOO.lang.isBoolean(value) && !this.get('disabled') ; + } + }); + + /** + * Whether or not the tab is disabled. + * @attribute disabled + * @type Boolean + */ + this.setAttributeConfig('disabled', { + value: attr.disabled || this.hasClass(this.DISABLED_CLASSNAME), + method: function(value) { + if (value === true) { + Dom.addClass(this.get('element'), this.DISABLED_CLASSNAME); + } else { + Dom.removeClass(this.get('element'), this.DISABLED_CLASSNAME); + } + }, + validator: YAHOO.lang.isBoolean + }); + + /** + * The href of the tab's anchor element. + * @attribute href + * @type String + * @default '#' + */ + this.setAttributeConfig('href', { + value: attr.href || + this.getElementsByTagName('a')[0].getAttribute('href', 2) || '#', + method: function(value) { + this.getElementsByTagName('a')[0].href = value; + }, + validator: YAHOO.lang.isString + }); + + /** + * The Whether or not the tab's content is visible. + * @attribute contentVisible + * @type Boolean + * @default false + */ + this.setAttributeConfig('contentVisible', { + value: attr.contentVisible, + method: function(value) { + if (value) { + this.get('contentEl').style.display = 'block'; + + if ( this.get('dataSrc') ) { + // load dynamic content unless already loading or loaded and caching + if ( !this._loading && !(this.get('dataLoaded') && this.get('cacheData')) ) { + _dataConnect.call(this); + } + } + } else { + this.get('contentEl').style.display = 'none'; + } + + }, + validator: YAHOO.lang.isBoolean + }); + }; + + var _createTabElement = function(attr) { + var el = document.createElement('li'); + var a = document.createElement('a'); + + a.href = attr.href || '#'; + + el.appendChild(a); + + var label = attr.label || null; + var labelEl = attr.labelEl || null; + + if (labelEl) { // user supplied labelEl + if (!label) { // user supplied label + label = _getLabel.call(this, labelEl); + } + } else { + labelEl = _createlabelEl.call(this); + } + + a.appendChild(labelEl); + + return el; + }; + + var _getlabelEl = function() { + return this.getElementsByTagName(this.LABEL_TAGNAME)[0]; + }; + + var _createlabelEl = function() { + var el = document.createElement(this.LABEL_TAGNAME); + return el; + }; + + var _setLabel = function(label) { + var el = this.get('labelEl'); + el.innerHTML = label; + }; + + var _getLabel = function() { + var label, + el = this.get('labelEl'); + + if (!el) { + return undefined; + } + + return el.innerHTML; + }; + + var _dataConnect = function() { + if (!YAHOO.util.Connect) { + return false; + } + + Dom.addClass(this.get('contentEl').parentNode, this.LOADING_CLASSNAME); + this._loading = true; + this.dataConnection = YAHOO.util.Connect.asyncRequest( + this.get('loadMethod'), + this.get('dataSrc'), + { + success: function(o) { + this.loadHandler.success.call(this, o); + this.set('dataLoaded', true); + this.dataConnection = null; + Dom.removeClass(this.get('contentEl').parentNode, + this.LOADING_CLASSNAME); + this._loading = false; + }, + failure: function(o) { + this.loadHandler.failure.call(this, o); + this.dataConnection = null; + Dom.removeClass(this.get('contentEl').parentNode, + this.LOADING_CLASSNAME); + this._loading = false; + }, + scope: this, + timeout: this.get('dataTimeout') + } + ); + }; + + YAHOO.widget.Tab = Tab; +})(); + +YAHOO.register("tabview", YAHOO.widget.TabView, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/utilities.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/utilities.js new file mode 100644 index 0000000..3f56c71 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/utilities.js
@@ -0,0 +1,37 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +if(typeof YAHOO=="undefined"||!YAHOO){var YAHOO={};}YAHOO.namespace=function(){var A=arguments,E=null,C,B,D;for(C=0;C<A.length;C=C+1){D=A[C].split(".");E=YAHOO;for(B=(D[0]=="YAHOO")?1:0;B<D.length;B=B+1){E[D[B]]=E[D[B]]||{};E=E[D[B]];}}return E;};YAHOO.log=function(D,A,C){var B=YAHOO.widget.Logger;if(B&&B.log){return B.log(D,A,C);}else{return false;}};YAHOO.register=function(A,E,D){var I=YAHOO.env.modules;if(!I[A]){I[A]={versions:[],builds:[]};}var B=I[A],H=D.version,G=D.build,F=YAHOO.env.listeners;B.name=A;B.version=H;B.build=G;B.versions.push(H);B.builds.push(G);B.mainClass=E;for(var C=0;C<F.length;C=C+1){F[C](B);}if(E){E.VERSION=H;E.BUILD=G;}else{YAHOO.log("mainClass is undefined for module "+A,"warn");}};YAHOO.env=YAHOO.env||{modules:[],listeners:[]};YAHOO.env.getVersion=function(A){return YAHOO.env.modules[A]||null;};YAHOO.env.ua=function(){var C={ie:0,opera:0,gecko:0,webkit:0,mobile:null,air:0};var B=navigator.userAgent,A;if((/KHTML/).test(B)){C.webkit=1;}A=B.match(/AppleWebKit\/([^\s]*)/);if(A&&A[1]){C.webkit=parseFloat(A[1]);if(/ Mobile\//.test(B)){C.mobile="Apple";}else{A=B.match(/NokiaN[^\/]*/);if(A){C.mobile=A[0];}}A=B.match(/AdobeAIR\/([^\s]*)/);if(A){C.air=A[0];}}if(!C.webkit){A=B.match(/Opera[\s\/]([^\s]*)/);if(A&&A[1]){C.opera=parseFloat(A[1]);A=B.match(/Opera Mini[^;]*/);if(A){C.mobile=A[0];}}else{A=B.match(/MSIE\s([^;]*)/);if(A&&A[1]){C.ie=parseFloat(A[1]);}else{A=B.match(/Gecko\/([^\s]*)/);if(A){C.gecko=1;A=B.match(/rv:([^\s\)]*)/);if(A&&A[1]){C.gecko=parseFloat(A[1]);}}}}}return C;}();(function(){YAHOO.namespace("util","widget","example");if("undefined"!==typeof YAHOO_config){var B=YAHOO_config.listener,A=YAHOO.env.listeners,D=true,C;if(B){for(C=0;C<A.length;C=C+1){if(A[C]==B){D=false;break;}}if(D){A.push(B);}}}})();YAHOO.lang=YAHOO.lang||{};(function(){var A=YAHOO.lang,C=["toString","valueOf"],B={isArray:function(D){if(D){return A.isNumber(D.length)&&A.isFunction(D.splice);}return false;},isBoolean:function(D){return typeof D==="boolean";},isFunction:function(D){return typeof D==="function";},isNull:function(D){return D===null;},isNumber:function(D){return typeof D==="number"&&isFinite(D);},isObject:function(D){return(D&&(typeof D==="object"||A.isFunction(D)))||false;},isString:function(D){return typeof D==="string";},isUndefined:function(D){return typeof D==="undefined";},_IEEnumFix:(YAHOO.env.ua.ie)?function(F,E){for(var D=0;D<C.length;D=D+1){var H=C[D],G=E[H];if(A.isFunction(G)&&G!=Object.prototype[H]){F[H]=G;}}}:function(){},extend:function(H,I,G){if(!I||!H){throw new Error("extend failed, please check that "+"all dependencies are included.");}var E=function(){};E.prototype=I.prototype;H.prototype=new E();H.prototype.constructor=H;H.superclass=I.prototype;if(I.prototype.constructor==Object.prototype.constructor){I.prototype.constructor=I;}if(G){for(var D in G){if(A.hasOwnProperty(G,D)){H.prototype[D]=G[D];}}A._IEEnumFix(H.prototype,G);}},augmentObject:function(H,G){if(!G||!H){throw new Error("Absorb failed, verify dependencies.");}var D=arguments,F,I,E=D[2];if(E&&E!==true){for(F=2;F<D.length;F=F+1){H[D[F]]=G[D[F]];}}else{for(I in G){if(E||!(I in H)){H[I]=G[I];}}A._IEEnumFix(H,G);}},augmentProto:function(G,F){if(!F||!G){throw new Error("Augment failed, verify dependencies.");}var D=[G.prototype,F.prototype];for(var E=2;E<arguments.length;E=E+1){D.push(arguments[E]);}A.augmentObject.apply(this,D);},dump:function(D,I){var F,H,K=[],L="{...}",E="f(){...}",J=", ",G=" => ";if(!A.isObject(D)){return D+"";}else{if(D instanceof Date||("nodeType" in D&&"tagName" in D)){return D;}else{if(A.isFunction(D)){return E;}}}I=(A.isNumber(I))?I:3;if(A.isArray(D)){K.push("[");for(F=0,H=D.length;F<H;F=F+1){if(A.isObject(D[F])){K.push((I>0)?A.dump(D[F],I-1):L);}else{K.push(D[F]);}K.push(J);}if(K.length>1){K.pop();}K.push("]");}else{K.push("{");for(F in D){if(A.hasOwnProperty(D,F)){K.push(F+G);if(A.isObject(D[F])){K.push((I>0)?A.dump(D[F],I-1):L);}else{K.push(D[F]);}K.push(J);}}if(K.length>1){K.pop();}K.push("}");}return K.join("");},substitute:function(S,E,L){var I,H,G,O,P,R,N=[],F,J="dump",M=" ",D="{",Q="}";for(;;){I=S.lastIndexOf(D);if(I<0){break;}H=S.indexOf(Q,I);if(I+1>=H){break;}F=S.substring(I+1,H);O=F;R=null;G=O.indexOf(M);if(G>-1){R=O.substring(G+1);O=O.substring(0,G);}P=E[O];if(L){P=L(O,P,R);}if(A.isObject(P)){if(A.isArray(P)){P=A.dump(P,parseInt(R,10));}else{R=R||"";var K=R.indexOf(J);if(K>-1){R=R.substring(4);}if(P.toString===Object.prototype.toString||K>-1){P=A.dump(P,parseInt(R,10));}else{P=P.toString();}}}else{if(!A.isString(P)&&!A.isNumber(P)){P="~-"+N.length+"-~";N[N.length]=F;}}S=S.substring(0,I)+P+S.substring(H+1);}for(I=N.length-1;I>=0;I=I-1){S=S.replace(new RegExp("~-"+I+"-~"),"{"+N[I]+"}","g");}return S;},trim:function(D){try{return D.replace(/^\s+|\s+$/g,"");}catch(E){return D;}},merge:function(){var G={},E=arguments;for(var F=0,D=E.length;F<D;F=F+1){A.augmentObject(G,E[F],true);}return G;},later:function(K,E,L,G,H){K=K||0;E=E||{};var F=L,J=G,I,D;if(A.isString(L)){F=E[L];}if(!F){throw new TypeError("method undefined");}if(!A.isArray(J)){J=[G];}I=function(){F.apply(E,J);};D=(H)?setInterval(I,K):setTimeout(I,K);return{interval:H,cancel:function(){if(this.interval){clearInterval(D);}else{clearTimeout(D);}}};},isValue:function(D){return(A.isObject(D)||A.isString(D)||A.isNumber(D)||A.isBoolean(D));}};A.hasOwnProperty=(Object.prototype.hasOwnProperty)?function(D,E){return D&&D.hasOwnProperty(E);}:function(D,E){return !A.isUndefined(D[E])&&D.constructor.prototype[E]!==D[E];};B.augmentObject(A,B,true);YAHOO.util.Lang=A;A.augment=A.augmentProto;YAHOO.augment=A.augmentProto;YAHOO.extend=A.extend;})();YAHOO.register("yahoo",YAHOO,{version:"2.5.2",build:"1076"});YAHOO.util.Get=function(){var M={},L=0,Q=0,E=false,N=YAHOO.env.ua,R=YAHOO.lang;var J=function(V,S,W){var T=W||window,X=T.document,Y=X.createElement(V);for(var U in S){if(S[U]&&YAHOO.lang.hasOwnProperty(S,U)){Y.setAttribute(U,S[U]);}}return Y;};var H=function(S,T,V){var U=V||"utf-8";return J("link",{"id":"yui__dyn_"+(Q++),"type":"text/css","charset":U,"rel":"stylesheet","href":S},T); +};var O=function(S,T,V){var U=V||"utf-8";return J("script",{"id":"yui__dyn_"+(Q++),"type":"text/javascript","charset":U,"src":S},T);};var A=function(S,T){return{tId:S.tId,win:S.win,data:S.data,nodes:S.nodes,msg:T,purge:function(){D(this.tId);}};};var B=function(S,V){var T=M[V],U=(R.isString(S))?T.win.document.getElementById(S):S;if(!U){P(V,"target node not found: "+S);}return U;};var P=function(V,U){var S=M[V];if(S.onFailure){var T=S.scope||S.win;S.onFailure.call(T,A(S,U));}};var C=function(V){var S=M[V];S.finished=true;if(S.aborted){var U="transaction "+V+" was aborted";P(V,U);return ;}if(S.onSuccess){var T=S.scope||S.win;S.onSuccess.call(T,A(S));}};var G=function(U,Y){var T=M[U];if(T.aborted){var W="transaction "+U+" was aborted";P(U,W);return ;}if(Y){T.url.shift();if(T.varName){T.varName.shift();}}else{T.url=(R.isString(T.url))?[T.url]:T.url;if(T.varName){T.varName=(R.isString(T.varName))?[T.varName]:T.varName;}}var b=T.win,a=b.document,Z=a.getElementsByTagName("head")[0],V;if(T.url.length===0){if(T.type==="script"&&N.webkit&&N.webkit<420&&!T.finalpass&&!T.varName){var X=O(null,T.win,T.charset);X.innerHTML='YAHOO.util.Get._finalize("'+U+'");';T.nodes.push(X);Z.appendChild(X);}else{C(U);}return ;}var S=T.url[0];if(T.type==="script"){V=O(S,b,T.charset);}else{V=H(S,b,T.charset);}F(T.type,V,U,S,b,T.url.length);T.nodes.push(V);if(T.insertBefore){var c=B(T.insertBefore,U);if(c){c.parentNode.insertBefore(V,c);}}else{Z.appendChild(V);}if((N.webkit||N.gecko)&&T.type==="css"){G(U,S);}};var K=function(){if(E){return ;}E=true;for(var S in M){var T=M[S];if(T.autopurge&&T.finished){D(T.tId);delete M[S];}}E=false;};var D=function(Z){var W=M[Z];if(W){var Y=W.nodes,S=Y.length,X=W.win.document,V=X.getElementsByTagName("head")[0];if(W.insertBefore){var U=B(W.insertBefore,Z);if(U){V=U.parentNode;}}for(var T=0;T<S;T=T+1){V.removeChild(Y[T]);}}W.nodes=[];};var I=function(T,S,U){var W="q"+(L++);U=U||{};if(L%YAHOO.util.Get.PURGE_THRESH===0){K();}M[W]=R.merge(U,{tId:W,type:T,url:S,finished:false,nodes:[]});var V=M[W];V.win=V.win||window;V.scope=V.scope||V.win;V.autopurge=("autopurge" in V)?V.autopurge:(T==="script")?true:false;R.later(0,V,G,W);return{tId:W};};var F=function(b,W,V,T,X,Y,a){var Z=a||G;if(N.ie){W.onreadystatechange=function(){var c=this.readyState;if("loaded"===c||"complete"===c){Z(V,T);}};}else{if(N.webkit){if(b==="script"){if(N.webkit>=420){W.addEventListener("load",function(){Z(V,T);});}else{var S=M[V];if(S.varName){var U=YAHOO.util.Get.POLL_FREQ;S.maxattempts=YAHOO.util.Get.TIMEOUT/U;S.attempts=0;S._cache=S.varName[0].split(".");S.timer=R.later(U,S,function(h){var e=this._cache,d=e.length,c=this.win,f;for(f=0;f<d;f=f+1){c=c[e[f]];if(!c){this.attempts++;if(this.attempts++>this.maxattempts){var g="Over retry limit, giving up";S.timer.cancel();P(V,g);}else{}return ;}}S.timer.cancel();Z(V,T);},null,true);}else{R.later(YAHOO.util.Get.POLL_FREQ,null,Z,[V,T]);}}}}else{W.onload=function(){Z(V,T);};}}};return{POLL_FREQ:10,PURGE_THRESH:20,TIMEOUT:2000,_finalize:function(S){R.later(0,null,C,S);},abort:function(T){var U=(R.isString(T))?T:T.tId;var S=M[U];if(S){S.aborted=true;}},script:function(S,T){return I("script",S,T);},css:function(S,T){return I("css",S,T);}};}();YAHOO.register("get",YAHOO.util.Get,{version:"2.5.2",build:"1076"});(function(){var Y=YAHOO,util=Y.util,lang=Y.lang,env=Y.env,PROV="_provides",SUPER="_supersedes",REQ="expanded",AFTER="_after";var YUI={dupsAllowed:{"yahoo":true,"get":true},info:{"base":"http://yui.yahooapis.com/2.5.2/build/","skin":{"defaultSkin":"sam","base":"assets/skins/","path":"skin.css","after":["reset","fonts","grids","base"],"rollup":3},dupsAllowed:["yahoo","get"],"moduleInfo":{"animation":{"type":"js","path":"animation/animation-min.js","requires":["dom","event"]},"autocomplete":{"type":"js","path":"autocomplete/autocomplete-min.js","requires":["dom","event"],"optional":["connection","animation"],"skinnable":true},"base":{"type":"css","path":"base/base-min.css","after":["reset","fonts","grids"]},"button":{"type":"js","path":"button/button-min.js","requires":["element"],"optional":["menu"],"skinnable":true},"calendar":{"type":"js","path":"calendar/calendar-min.js","requires":["event","dom"],"skinnable":true},"charts":{"type":"js","path":"charts/charts-experimental-min.js","requires":["element","json","datasource"]},"colorpicker":{"type":"js","path":"colorpicker/colorpicker-min.js","requires":["slider","element"],"optional":["animation"],"skinnable":true},"connection":{"type":"js","path":"connection/connection-min.js","requires":["event"]},"container":{"type":"js","path":"container/container-min.js","requires":["dom","event"],"optional":["dragdrop","animation","connection"],"supersedes":["containercore"],"skinnable":true},"containercore":{"type":"js","path":"container/container_core-min.js","requires":["dom","event"],"pkg":"container"},"cookie":{"type":"js","path":"cookie/cookie-beta-min.js","requires":["yahoo"]},"datasource":{"type":"js","path":"datasource/datasource-beta-min.js","requires":["event"],"optional":["connection"]},"datatable":{"type":"js","path":"datatable/datatable-beta-min.js","requires":["element","datasource"],"optional":["calendar","dragdrop"],"skinnable":true},"dom":{"type":"js","path":"dom/dom-min.js","requires":["yahoo"]},"dragdrop":{"type":"js","path":"dragdrop/dragdrop-min.js","requires":["dom","event"]},"editor":{"type":"js","path":"editor/editor-beta-min.js","requires":["menu","element","button"],"optional":["animation","dragdrop"],"supersedes":["simpleeditor"],"skinnable":true},"element":{"type":"js","path":"element/element-beta-min.js","requires":["dom","event"]},"event":{"type":"js","path":"event/event-min.js","requires":["yahoo"]},"fonts":{"type":"css","path":"fonts/fonts-min.css"},"get":{"type":"js","path":"get/get-min.js","requires":["yahoo"]},"grids":{"type":"css","path":"grids/grids-min.css","requires":["fonts"],"optional":["reset"]},"history":{"type":"js","path":"history/history-min.js","requires":["event"]},"imagecropper":{"type":"js","path":"imagecropper/imagecropper-beta-min.js","requires":["dom","event","dragdrop","element","resize"],"skinnable":true},"imageloader":{"type":"js","path":"imageloader/imageloader-min.js","requires":["event","dom"]},"json":{"type":"js","path":"json/json-min.js","requires":["yahoo"]},"layout":{"type":"js","path":"layout/layout-beta-min.js","requires":["dom","event","element"],"optional":["animation","dragdrop","resize","selector"],"skinnable":true},"logger":{"type":"js","path":"logger/logger-min.js","requires":["event","dom"],"optional":["dragdrop"],"skinnable":true},"menu":{"type":"js","path":"menu/menu-min.js","requires":["containercore"],"skinnable":true},"profiler":{"type":"js","path":"profiler/profiler-beta-min.js","requires":["yahoo"]},"profilerviewer":{"type":"js","path":"profilerviewer/profilerviewer-beta-min.js","requires":["profiler","yuiloader","element"],"skinnable":true},"reset":{"type":"css","path":"reset/reset-min.css"},"reset-fonts-grids":{"type":"css","path":"reset-fonts-grids/reset-fonts-grids.css","supersedes":["reset","fonts","grids","reset-fonts"],"rollup":4},"reset-fonts":{"type":"css","path":"reset-fonts/reset-fonts.css","supersedes":["reset","fonts"],"rollup":2},"resize":{"type":"js","path":"resize/resize-beta-min.js","requires":["dom","event","dragdrop","element"],"optional":["animation"],"skinnable":true},"selector":{"type":"js","path":"selector/selector-beta-min.js","requires":["yahoo","dom"]},"simpleeditor":{"type":"js","path":"editor/simpleeditor-beta-min.js","requires":["element"],"optional":["containercore","menu","button","animation","dragdrop"],"skinnable":true,"pkg":"editor"},"slider":{"type":"js","path":"slider/slider-min.js","requires":["dragdrop"],"optional":["animation"]},"tabview":{"type":"js","path":"tabview/tabview-min.js","requires":["element"],"optional":["connection"],"skinnable":true},"treeview":{"type":"js","path":"treeview/treeview-min.js","requires":["event"],"skinnable":true},"uploader":{"type":"js","path":"uploader/uploader-experimental.js","requires":["element"]},"utilities":{"type":"js","path":"utilities/utilities.js","supersedes":["yahoo","event","dragdrop","animation","dom","connection","element","yahoo-dom-event","get","yuiloader","yuiloader-dom-event"],"rollup":8},"yahoo":{"type":"js","path":"yahoo/yahoo-min.js"},"yahoo-dom-event":{"type":"js","path":"yahoo-dom-event/yahoo-dom-event.js","supersedes":["yahoo","event","dom"],"rollup":3},"yuiloader":{"type":"js","path":"yuiloader/yuiloader-beta-min.js","supersedes":["yahoo","get"]},"yuiloader-dom-event":{"type":"js","path":"yuiloader-dom-event/yuiloader-dom-event.js","supersedes":["yahoo","dom","event","get","yuiloader","yahoo-dom-event"],"rollup":5},"yuitest":{"type":"js","path":"yuitest/yuitest-min.js","requires":["logger"],"skinnable":true}}},ObjectUtil:{appendArray:function(o,a){if(a){for(var i=0; +i<a.length;i=i+1){o[a[i]]=true;}}},keys:function(o,ordered){var a=[],i;for(i in o){if(lang.hasOwnProperty(o,i)){a.push(i);}}return a;}},ArrayUtil:{appendArray:function(a1,a2){Array.prototype.push.apply(a1,a2);},indexOf:function(a,val){for(var i=0;i<a.length;i=i+1){if(a[i]===val){return i;}}return -1;},toObject:function(a){var o={};for(var i=0;i<a.length;i=i+1){o[a[i]]=true;}return o;},uniq:function(a){return YUI.ObjectUtil.keys(YUI.ArrayUtil.toObject(a));}}};YAHOO.util.YUILoader=function(o){this._internalCallback=null;this._useYahooListener=false;this.onSuccess=null;this.onFailure=Y.log;this.onProgress=null;this.scope=this;this.data=null;this.insertBefore=null;this.charset=null;this.varName=null;this.base=YUI.info.base;this.ignore=null;this.force=null;this.allowRollup=true;this.filter=null;this.required={};this.moduleInfo=lang.merge(YUI.info.moduleInfo);this.rollups=null;this.loadOptional=false;this.sorted=[];this.loaded={};this.dirty=true;this.inserted={};var self=this;env.listeners.push(function(m){if(self._useYahooListener){self.loadNext(m.name);}});this.skin=lang.merge(YUI.info.skin);this._config(o);};Y.util.YUILoader.prototype={FILTERS:{RAW:{"searchExp":"-min\\.js","replaceStr":".js"},DEBUG:{"searchExp":"-min\\.js","replaceStr":"-debug.js"}},SKIN_PREFIX:"skin-",_config:function(o){if(o){for(var i in o){if(lang.hasOwnProperty(o,i)){if(i=="require"){this.require(o[i]);}else{this[i]=o[i];}}}}var f=this.filter;if(lang.isString(f)){f=f.toUpperCase();if(f==="DEBUG"){this.require("logger");}if(!Y.widget.LogWriter){Y.widget.LogWriter=function(){return Y;};}this.filter=this.FILTERS[f];}},addModule:function(o){if(!o||!o.name||!o.type||(!o.path&&!o.fullpath)){return false;}o.ext=("ext" in o)?o.ext:true;o.requires=o.requires||[];this.moduleInfo[o.name]=o;this.dirty=true;return true;},require:function(what){var a=(typeof what==="string")?arguments:what;this.dirty=true;YUI.ObjectUtil.appendArray(this.required,a);},_addSkin:function(skin,mod){var name=this.formatSkin(skin),info=this.moduleInfo,sinf=this.skin,ext=info[mod]&&info[mod].ext;if(!info[name]){this.addModule({"name":name,"type":"css","path":sinf.base+skin+"/"+sinf.path,"after":sinf.after,"rollup":sinf.rollup,"ext":ext});}if(mod){name=this.formatSkin(skin,mod);if(!info[name]){var mdef=info[mod],pkg=mdef.pkg||mod;this.addModule({"name":name,"type":"css","after":sinf.after,"path":pkg+"/"+sinf.base+skin+"/"+mod+".css","ext":ext});}}return name;},getRequires:function(mod){if(!mod){return[];}if(!this.dirty&&mod.expanded){return mod.expanded;}mod.requires=mod.requires||[];var i,d=[],r=mod.requires,o=mod.optional,info=this.moduleInfo,m;for(i=0;i<r.length;i=i+1){d.push(r[i]);m=info[r[i]];YUI.ArrayUtil.appendArray(d,this.getRequires(m));}if(o&&this.loadOptional){for(i=0;i<o.length;i=i+1){d.push(o[i]);YUI.ArrayUtil.appendArray(d,this.getRequires(info[o[i]]));}}mod.expanded=YUI.ArrayUtil.uniq(d);return mod.expanded;},getProvides:function(name,notMe){var addMe=!(notMe),ckey=(addMe)?PROV:SUPER,m=this.moduleInfo[name],o={};if(!m){return o;}if(m[ckey]){return m[ckey];}var s=m.supersedes,done={},me=this;var add=function(mm){if(!done[mm]){done[mm]=true;lang.augmentObject(o,me.getProvides(mm));}};if(s){for(var i=0;i<s.length;i=i+1){add(s[i]);}}m[SUPER]=o;m[PROV]=lang.merge(o);m[PROV][name]=true;return m[ckey];},calculate:function(o){if(this.dirty){this._config(o);this._setup();this._explode();if(this.allowRollup){this._rollup();}this._reduce();this._sort();this.dirty=false;}},_setup:function(){var info=this.moduleInfo,name,i,j;for(name in info){var m=info[name];if(m&&m.skinnable){var o=this.skin.overrides,smod;if(o&&o[name]){for(i=0;i<o[name].length;i=i+1){smod=this._addSkin(o[name][i],name);}}else{smod=this._addSkin(this.skin.defaultSkin,name);}m.requires.push(smod);}}var l=lang.merge(this.inserted);if(!this._sandbox){l=lang.merge(l,env.modules);}if(this.ignore){YUI.ObjectUtil.appendArray(l,this.ignore);}if(this.force){for(i=0;i<this.force.length;i=i+1){if(this.force[i] in l){delete l[this.force[i]];}}}for(j in l){if(lang.hasOwnProperty(l,j)){lang.augmentObject(l,this.getProvides(j));}}this.loaded=l;},_explode:function(){var r=this.required,i,mod;for(i in r){mod=this.moduleInfo[i];if(mod){var req=this.getRequires(mod);if(req){YUI.ObjectUtil.appendArray(r,req);}}}},_skin:function(){},formatSkin:function(skin,mod){var s=this.SKIN_PREFIX+skin;if(mod){s=s+"-"+mod;}return s;},parseSkin:function(mod){if(mod.indexOf(this.SKIN_PREFIX)===0){var a=mod.split("-");return{skin:a[1],module:a[2]};}return null;},_rollup:function(){var i,j,m,s,rollups={},r=this.required,roll;if(this.dirty||!this.rollups){for(i in this.moduleInfo){m=this.moduleInfo[i];if(m&&m.rollup){rollups[i]=m;}}this.rollups=rollups;}for(;;){var rolled=false;for(i in rollups){if(!r[i]&&!this.loaded[i]){m=this.moduleInfo[i];s=m.supersedes;roll=false;if(!m.rollup){continue;}var skin=(m.ext)?false:this.parseSkin(i),c=0;if(skin){for(j in r){if(i!==j&&this.parseSkin(j)){c++;roll=(c>=m.rollup);if(roll){break;}}}}else{for(j=0;j<s.length;j=j+1){if(this.loaded[s[j]]&&(!YUI.dupsAllowed[s[j]])){roll=false;break;}else{if(r[s[j]]){c++;roll=(c>=m.rollup);if(roll){break;}}}}}if(roll){r[i]=true;rolled=true;this.getRequires(m);}}}if(!rolled){break;}}},_reduce:function(){var i,j,s,m,r=this.required;for(i in r){if(i in this.loaded){delete r[i];}else{var skinDef=this.parseSkin(i);if(skinDef){if(!skinDef.module){var skin_pre=this.SKIN_PREFIX+skinDef.skin;for(j in r){m=this.moduleInfo[j];var ext=m&&m.ext;if(!ext&&j!==i&&j.indexOf(skin_pre)>-1){delete r[j];}}}}else{m=this.moduleInfo[i];s=m&&m.supersedes;if(s){for(j=0;j<s.length;j=j+1){if(s[j] in r){delete r[s[j]];}}}}}}},_sort:function(){var s=[],info=this.moduleInfo,loaded=this.loaded,checkOptional=!this.loadOptional,me=this;var requires=function(aa,bb){if(loaded[bb]){return false;}var ii,mm=info[aa],rr=mm&&mm.expanded,after=mm&&mm.after,other=info[bb],optional=mm&&mm.optional;if(rr&&YUI.ArrayUtil.indexOf(rr,bb)>-1){return true;}if(after&&YUI.ArrayUtil.indexOf(after,bb)>-1){return true; +}if(checkOptional&&optional&&YUI.ArrayUtil.indexOf(optional,bb)>-1){return true;}var ss=info[bb]&&info[bb].supersedes;if(ss){for(ii=0;ii<ss.length;ii=ii+1){if(requires(aa,ss[ii])){return true;}}}if(mm.ext&&mm.type=="css"&&(!other.ext)){return true;}return false;};for(var i in this.required){s.push(i);}var p=0;for(;;){var l=s.length,a,b,j,k,moved=false;for(j=p;j<l;j=j+1){a=s[j];for(k=j+1;k<l;k=k+1){if(requires(a,s[k])){b=s.splice(k,1);s.splice(j,0,b[0]);moved=true;break;}}if(moved){break;}else{p=p+1;}}if(!moved){break;}}this.sorted=s;},toString:function(){var o={type:"YUILoader",base:this.base,filter:this.filter,required:this.required,loaded:this.loaded,inserted:this.inserted};lang.dump(o,1);},insert:function(o,type){this.calculate(o);if(!type){var self=this;this._internalCallback=function(){self._internalCallback=null;self.insert(null,"js");};this.insert(null,"css");return ;}this._loading=true;this.loadType=type;this.loadNext();},sandbox:function(o,type){if(o){}else{}this._config(o);if(!this.onSuccess){throw new Error("You must supply an onSuccess handler for your sandbox");}this._sandbox=true;var self=this;if(!type||type!=="js"){this._internalCallback=function(){self._internalCallback=null;self.sandbox(null,"js");};this.insert(null,"css");return ;}if(!util.Connect){var ld=new YAHOO.util.YUILoader();ld.insert({base:this.base,filter:this.filter,require:"connection",insertBefore:this.insertBefore,charset:this.charset,onSuccess:function(){this.sandbox(null,"js");},scope:this},"js");return ;}this._scriptText=[];this._loadCount=0;this._stopCount=this.sorted.length;this._xhr=[];this.calculate();var s=this.sorted,l=s.length,i,m,url;for(i=0;i<l;i=i+1){m=this.moduleInfo[s[i]];if(!m){this.onFailure.call(this.scope,{msg:"undefined module "+m,data:this.data});for(var j=0;j<this._xhr.length;j=j+1){this._xhr[j].abort();}return ;}if(m.type!=="js"){this._loadCount++;continue;}url=m.fullpath||this._url(m.path);var xhrData={success:function(o){var idx=o.argument[0],name=o.argument[2];this._scriptText[idx]=o.responseText;if(this.onProgress){this.onProgress.call(this.scope,{name:name,scriptText:o.responseText,xhrResponse:o,data:this.data});}this._loadCount++;if(this._loadCount>=this._stopCount){var v=this.varName||"YAHOO";var t="(function() {\n";var b="\nreturn "+v+";\n})();";var ref=eval(t+this._scriptText.join("\n")+b);this._pushEvents(ref);if(ref){this.onSuccess.call(this.scope,{reference:ref,data:this.data});}else{this.onFailure.call(this.scope,{msg:this.varName+" reference failure",data:this.data});}}},failure:function(o){this.onFailure.call(this.scope,{msg:"XHR failure",xhrResponse:o,data:this.data});},scope:this,argument:[i,url,s[i]]};this._xhr.push(util.Connect.asyncRequest("GET",url,xhrData));}},loadNext:function(mname){if(!this._loading){return ;}if(mname){if(mname!==this._loading){return ;}this.inserted[mname]=true;if(this.onProgress){this.onProgress.call(this.scope,{name:mname,data:this.data});}}var s=this.sorted,len=s.length,i,m;for(i=0;i<len;i=i+1){if(s[i] in this.inserted){continue;}if(s[i]===this._loading){return ;}m=this.moduleInfo[s[i]];if(!m){this.onFailure.call(this.scope,{msg:"undefined module "+m,data:this.data});return ;}if(!this.loadType||this.loadType===m.type){this._loading=s[i];var fn=(m.type==="css")?util.Get.css:util.Get.script,url=m.fullpath||this._url(m.path),self=this,c=function(o){self.loadNext(o.data);};if(env.ua.webkit&&env.ua.webkit<420&&m.type==="js"&&!m.varName){c=null;this._useYahooListener=true;}fn(url,{data:s[i],onSuccess:c,insertBefore:this.insertBefore,charset:this.charset,varName:m.varName,scope:self});return ;}}this._loading=null;if(this._internalCallback){var f=this._internalCallback;this._internalCallback=null;f.call(this);}else{if(this.onSuccess){this._pushEvents();this.onSuccess.call(this.scope,{data:this.data});}}},_pushEvents:function(ref){var r=ref||YAHOO;if(r.util&&r.util.Event){r.util.Event._load();}},_url:function(path){var u=this.base||"",f=this.filter;u=u+path;if(f){u=u.replace(new RegExp(f.searchExp),f.replaceStr);}return u;}};})();(function(){var B=YAHOO.util,K,I,J={},F={},M=window.document;YAHOO.env._id_counter=YAHOO.env._id_counter||0;var C=YAHOO.env.ua.opera,L=YAHOO.env.ua.webkit,A=YAHOO.env.ua.gecko,G=YAHOO.env.ua.ie;var E={HYPHEN:/(-[a-z])/i,ROOT_TAG:/^body|html$/i,OP_SCROLL:/^(?:inline|table-row)$/i};var N=function(P){if(!E.HYPHEN.test(P)){return P;}if(J[P]){return J[P];}var Q=P;while(E.HYPHEN.exec(Q)){Q=Q.replace(RegExp.$1,RegExp.$1.substr(1).toUpperCase());}J[P]=Q;return Q;};var O=function(Q){var P=F[Q];if(!P){P=new RegExp("(?:^|\\s+)"+Q+"(?:\\s+|$)");F[Q]=P;}return P;};if(M.defaultView&&M.defaultView.getComputedStyle){K=function(P,S){var R=null;if(S=="float"){S="cssFloat";}var Q=P.ownerDocument.defaultView.getComputedStyle(P,"");if(Q){R=Q[N(S)];}return P.style[S]||R;};}else{if(M.documentElement.currentStyle&&G){K=function(P,R){switch(N(R)){case"opacity":var T=100;try{T=P.filters["DXImageTransform.Microsoft.Alpha"].opacity;}catch(S){try{T=P.filters("alpha").opacity;}catch(S){}}return T/100;case"float":R="styleFloat";default:var Q=P.currentStyle?P.currentStyle[R]:null;return(P.style[R]||Q);}};}else{K=function(P,Q){return P.style[Q];};}}if(G){I=function(P,Q,R){switch(Q){case"opacity":if(YAHOO.lang.isString(P.style.filter)){P.style.filter="alpha(opacity="+R*100+")";if(!P.currentStyle||!P.currentStyle.hasLayout){P.style.zoom=1;}}break;case"float":Q="styleFloat";default:P.style[Q]=R;}};}else{I=function(P,Q,R){if(Q=="float"){Q="cssFloat";}P.style[Q]=R;};}var D=function(P,Q){return P&&P.nodeType==1&&(!Q||Q(P));};YAHOO.util.Dom={get:function(R){if(R&&(R.nodeType||R.item)){return R;}if(YAHOO.lang.isString(R)||!R){return M.getElementById(R);}if(R.length!==undefined){var S=[];for(var Q=0,P=R.length;Q<P;++Q){S[S.length]=B.Dom.get(R[Q]);}return S;}return R;},getStyle:function(P,R){R=N(R);var Q=function(S){return K(S,R);};return B.Dom.batch(P,Q,B.Dom,true);},setStyle:function(P,R,S){R=N(R);var Q=function(T){I(T,R,S);};B.Dom.batch(P,Q,B.Dom,true);},getXY:function(P){var Q=function(R){if((R.parentNode===null||R.offsetParent===null||this.getStyle(R,"display")=="none")&&R!=R.ownerDocument.body){return false;}return H(R);};return B.Dom.batch(P,Q,B.Dom,true);},getX:function(P){var Q=function(R){return B.Dom.getXY(R)[0];};return B.Dom.batch(P,Q,B.Dom,true);},getY:function(P){var Q=function(R){return B.Dom.getXY(R)[1];};return B.Dom.batch(P,Q,B.Dom,true);},setXY:function(P,S,R){var Q=function(V){var U=this.getStyle(V,"position");if(U=="static"){this.setStyle(V,"position","relative");U="relative";}var X=this.getXY(V);if(X===false){return false;}var W=[parseInt(this.getStyle(V,"left"),10),parseInt(this.getStyle(V,"top"),10)];if(isNaN(W[0])){W[0]=(U=="relative")?0:V.offsetLeft;}if(isNaN(W[1])){W[1]=(U=="relative")?0:V.offsetTop;}if(S[0]!==null){V.style.left=S[0]-X[0]+W[0]+"px";}if(S[1]!==null){V.style.top=S[1]-X[1]+W[1]+"px";}if(!R){var T=this.getXY(V);if((S[0]!==null&&T[0]!=S[0])||(S[1]!==null&&T[1]!=S[1])){this.setXY(V,S,true);}}};B.Dom.batch(P,Q,B.Dom,true);},setX:function(Q,P){B.Dom.setXY(Q,[P,null]);},setY:function(P,Q){B.Dom.setXY(P,[null,Q]);},getRegion:function(P){var Q=function(R){if((R.parentNode===null||R.offsetParent===null||this.getStyle(R,"display")=="none")&&R!=R.ownerDocument.body){return false;}var S=B.Region.getRegion(R);return S;};return B.Dom.batch(P,Q,B.Dom,true);},getClientWidth:function(){return B.Dom.getViewportWidth();},getClientHeight:function(){return B.Dom.getViewportHeight();},getElementsByClassName:function(T,X,U,V){X=X||"*";U=(U)?B.Dom.get(U):null||M;if(!U){return[];}var Q=[],P=U.getElementsByTagName(X),W=O(T);for(var R=0,S=P.length;R<S;++R){if(W.test(P[R].className)){Q[Q.length]=P[R];if(V){V.call(P[R],P[R]);}}}return Q;},hasClass:function(R,Q){var P=O(Q);var S=function(T){return P.test(T.className);};return B.Dom.batch(R,S,B.Dom,true);},addClass:function(Q,P){var R=function(S){if(this.hasClass(S,P)){return false;}S.className=YAHOO.lang.trim([S.className,P].join(" "));return true;};return B.Dom.batch(Q,R,B.Dom,true);},removeClass:function(R,Q){var P=O(Q);var S=function(T){if(!Q||!this.hasClass(T,Q)){return false;}var U=T.className;T.className=U.replace(P," ");if(this.hasClass(T,Q)){this.removeClass(T,Q);}T.className=YAHOO.lang.trim(T.className);return true;};return B.Dom.batch(R,S,B.Dom,true);},replaceClass:function(S,Q,P){if(!P||Q===P){return false;}var R=O(Q);var T=function(U){if(!this.hasClass(U,Q)){this.addClass(U,P);return true;}U.className=U.className.replace(R," "+P+" ");if(this.hasClass(U,Q)){this.replaceClass(U,Q,P);}U.className=YAHOO.lang.trim(U.className);return true;};return B.Dom.batch(S,T,B.Dom,true);},generateId:function(P,R){R=R||"yui-gen";var Q=function(S){if(S&&S.id){return S.id;}var T=R+YAHOO.env._id_counter++;if(S){S.id=T;}return T;};return B.Dom.batch(P,Q,B.Dom,true)||Q.apply(B.Dom,arguments);},isAncestor:function(P,Q){P=B.Dom.get(P);Q=B.Dom.get(Q);if(!P||!Q){return false;}if(P.contains&&Q.nodeType&&!L){return P.contains(Q);}else{if(P.compareDocumentPosition&&Q.nodeType){return !!(P.compareDocumentPosition(Q)&16);}else{if(Q.nodeType){return !!this.getAncestorBy(Q,function(R){return R==P;});}}}return false;},inDocument:function(P){return this.isAncestor(M.documentElement,P);},getElementsBy:function(W,Q,R,T){Q=Q||"*";R=(R)?B.Dom.get(R):null||M;if(!R){return[];}var S=[],V=R.getElementsByTagName(Q);for(var U=0,P=V.length;U<P;++U){if(W(V[U])){S[S.length]=V[U];if(T){T(V[U]);}}}return S;},batch:function(T,W,V,R){T=(T&&(T.tagName||T.item))?T:B.Dom.get(T);if(!T||!W){return false;}var S=(R)?V:window;if(T.tagName||T.length===undefined){return W.call(S,T,V);}var U=[];for(var Q=0,P=T.length;Q<P;++Q){U[U.length]=W.call(S,T[Q],V);}return U;},getDocumentHeight:function(){var Q=(M.compatMode!="CSS1Compat")?M.body.scrollHeight:M.documentElement.scrollHeight;var P=Math.max(Q,B.Dom.getViewportHeight());return P;},getDocumentWidth:function(){var Q=(M.compatMode!="CSS1Compat")?M.body.scrollWidth:M.documentElement.scrollWidth;var P=Math.max(Q,B.Dom.getViewportWidth());return P;},getViewportHeight:function(){var P=self.innerHeight; +var Q=M.compatMode;if((Q||G)&&!C){P=(Q=="CSS1Compat")?M.documentElement.clientHeight:M.body.clientHeight;}return P;},getViewportWidth:function(){var P=self.innerWidth;var Q=M.compatMode;if(Q||G){P=(Q=="CSS1Compat")?M.documentElement.clientWidth:M.body.clientWidth;}return P;},getAncestorBy:function(P,Q){while(P=P.parentNode){if(D(P,Q)){return P;}}return null;},getAncestorByClassName:function(Q,P){Q=B.Dom.get(Q);if(!Q){return null;}var R=function(S){return B.Dom.hasClass(S,P);};return B.Dom.getAncestorBy(Q,R);},getAncestorByTagName:function(Q,P){Q=B.Dom.get(Q);if(!Q){return null;}var R=function(S){return S.tagName&&S.tagName.toUpperCase()==P.toUpperCase();};return B.Dom.getAncestorBy(Q,R);},getPreviousSiblingBy:function(P,Q){while(P){P=P.previousSibling;if(D(P,Q)){return P;}}return null;},getPreviousSibling:function(P){P=B.Dom.get(P);if(!P){return null;}return B.Dom.getPreviousSiblingBy(P);},getNextSiblingBy:function(P,Q){while(P){P=P.nextSibling;if(D(P,Q)){return P;}}return null;},getNextSibling:function(P){P=B.Dom.get(P);if(!P){return null;}return B.Dom.getNextSiblingBy(P);},getFirstChildBy:function(P,R){var Q=(D(P.firstChild,R))?P.firstChild:null;return Q||B.Dom.getNextSiblingBy(P.firstChild,R);},getFirstChild:function(P,Q){P=B.Dom.get(P);if(!P){return null;}return B.Dom.getFirstChildBy(P);},getLastChildBy:function(P,R){if(!P){return null;}var Q=(D(P.lastChild,R))?P.lastChild:null;return Q||B.Dom.getPreviousSiblingBy(P.lastChild,R);},getLastChild:function(P){P=B.Dom.get(P);return B.Dom.getLastChildBy(P);},getChildrenBy:function(Q,S){var R=B.Dom.getFirstChildBy(Q,S);var P=R?[R]:[];B.Dom.getNextSiblingBy(R,function(T){if(!S||S(T)){P[P.length]=T;}return false;});return P;},getChildren:function(P){P=B.Dom.get(P);if(!P){}return B.Dom.getChildrenBy(P);},getDocumentScrollLeft:function(P){P=P||M;return Math.max(P.documentElement.scrollLeft,P.body.scrollLeft);},getDocumentScrollTop:function(P){P=P||M;return Math.max(P.documentElement.scrollTop,P.body.scrollTop);},insertBefore:function(Q,P){Q=B.Dom.get(Q);P=B.Dom.get(P);if(!Q||!P||!P.parentNode){return null;}return P.parentNode.insertBefore(Q,P);},insertAfter:function(Q,P){Q=B.Dom.get(Q);P=B.Dom.get(P);if(!Q||!P||!P.parentNode){return null;}if(P.nextSibling){return P.parentNode.insertBefore(Q,P.nextSibling);}else{return P.parentNode.appendChild(Q);}},getClientRegion:function(){var R=B.Dom.getDocumentScrollTop(),Q=B.Dom.getDocumentScrollLeft(),S=B.Dom.getViewportWidth()+Q,P=B.Dom.getViewportHeight()+R;return new B.Region(R,S,P,Q);}};var H=function(){if(M.documentElement.getBoundingClientRect){return function(Q){var R=Q.getBoundingClientRect();var P=Q.ownerDocument;return[R.left+B.Dom.getDocumentScrollLeft(P),R.top+B.Dom.getDocumentScrollTop(P)];};}else{return function(R){var S=[R.offsetLeft,R.offsetTop];var Q=R.offsetParent;var P=(L&&B.Dom.getStyle(R,"position")=="absolute"&&R.offsetParent==R.ownerDocument.body);if(Q!=R){while(Q){S[0]+=Q.offsetLeft;S[1]+=Q.offsetTop;if(!P&&L&&B.Dom.getStyle(Q,"position")=="absolute"){P=true;}Q=Q.offsetParent;}}if(P){S[0]-=R.ownerDocument.body.offsetLeft;S[1]-=R.ownerDocument.body.offsetTop;}Q=R.parentNode;while(Q.tagName&&!E.ROOT_TAG.test(Q.tagName)){if(Q.scrollTop||Q.scrollLeft){if(!E.OP_SCROLL.test(B.Dom.getStyle(Q,"display"))){if(!C||B.Dom.getStyle(Q,"overflow")!=="visible"){S[0]-=Q.scrollLeft;S[1]-=Q.scrollTop;}}}Q=Q.parentNode;}return S;};}}();})();YAHOO.util.Region=function(C,D,A,B){this.top=C;this[1]=C;this.right=D;this.bottom=A;this.left=B;this[0]=B;};YAHOO.util.Region.prototype.contains=function(A){return(A.left>=this.left&&A.right<=this.right&&A.top>=this.top&&A.bottom<=this.bottom);};YAHOO.util.Region.prototype.getArea=function(){return((this.bottom-this.top)*(this.right-this.left));};YAHOO.util.Region.prototype.intersect=function(E){var C=Math.max(this.top,E.top);var D=Math.min(this.right,E.right);var A=Math.min(this.bottom,E.bottom);var B=Math.max(this.left,E.left);if(A>=C&&D>=B){return new YAHOO.util.Region(C,D,A,B);}else{return null;}};YAHOO.util.Region.prototype.union=function(E){var C=Math.min(this.top,E.top);var D=Math.max(this.right,E.right);var A=Math.max(this.bottom,E.bottom);var B=Math.min(this.left,E.left);return new YAHOO.util.Region(C,D,A,B);};YAHOO.util.Region.prototype.toString=function(){return("Region {"+"top: "+this.top+", right: "+this.right+", bottom: "+this.bottom+", left: "+this.left+"}");};YAHOO.util.Region.getRegion=function(D){var F=YAHOO.util.Dom.getXY(D);var C=F[1];var E=F[0]+D.offsetWidth;var A=F[1]+D.offsetHeight;var B=F[0];return new YAHOO.util.Region(C,E,A,B);};YAHOO.util.Point=function(A,B){if(YAHOO.lang.isArray(A)){B=A[1];A=A[0];}this.x=this.right=this.left=this[0]=A;this.y=this.top=this.bottom=this[1]=B;};YAHOO.util.Point.prototype=new YAHOO.util.Region();YAHOO.register("dom",YAHOO.util.Dom,{version:"2.5.2",build:"1076"});YAHOO.util.CustomEvent=function(D,B,C,A){this.type=D;this.scope=B||window;this.silent=C;this.signature=A||YAHOO.util.CustomEvent.LIST;this.subscribers=[];if(!this.silent){}var E="_YUICEOnSubscribe";if(D!==E){this.subscribeEvent=new YAHOO.util.CustomEvent(E,this,true);}this.lastError=null;};YAHOO.util.CustomEvent.LIST=0;YAHOO.util.CustomEvent.FLAT=1;YAHOO.util.CustomEvent.prototype={subscribe:function(B,C,A){if(!B){throw new Error("Invalid callback for subscriber to '"+this.type+"'");}if(this.subscribeEvent){this.subscribeEvent.fire(B,C,A);}this.subscribers.push(new YAHOO.util.Subscriber(B,C,A));},unsubscribe:function(D,F){if(!D){return this.unsubscribeAll();}var E=false;for(var B=0,A=this.subscribers.length;B<A;++B){var C=this.subscribers[B];if(C&&C.contains(D,F)){this._delete(B);E=true;}}return E;},fire:function(){this.lastError=null;var K=[],E=this.subscribers.length;if(!E&&this.silent){return true;}var I=[].slice.call(arguments,0),G=true,D,J=false;if(!this.silent){}var C=this.subscribers.slice(),A=YAHOO.util.Event.throwErrors;for(D=0;D<E;++D){var M=C[D];if(!M){J=true;}else{if(!this.silent){}var L=M.getScope(this.scope);if(this.signature==YAHOO.util.CustomEvent.FLAT){var B=null;if(I.length>0){B=I[0];}try{G=M.fn.call(L,B,M.obj);}catch(F){this.lastError=F;if(A){throw F;}}}else{try{G=M.fn.call(L,this.type,I,M.obj);}catch(H){this.lastError=H;if(A){throw H;}}}if(false===G){if(!this.silent){}break;}}}return(G!==false);},unsubscribeAll:function(){for(var A=this.subscribers.length-1;A>-1;A--){this._delete(A);}this.subscribers=[];return A;},_delete:function(A){var B=this.subscribers[A];if(B){delete B.fn;delete B.obj;}this.subscribers.splice(A,1);},toString:function(){return"CustomEvent: "+"'"+this.type+"', "+"scope: "+this.scope;}};YAHOO.util.Subscriber=function(B,C,A){this.fn=B;this.obj=YAHOO.lang.isUndefined(C)?null:C;this.override=A;};YAHOO.util.Subscriber.prototype.getScope=function(A){if(this.override){if(this.override===true){return this.obj;}else{return this.override;}}return A;};YAHOO.util.Subscriber.prototype.contains=function(A,B){if(B){return(this.fn==A&&this.obj==B);}else{return(this.fn==A);}};YAHOO.util.Subscriber.prototype.toString=function(){return"Subscriber { obj: "+this.obj+", override: "+(this.override||"no")+" }";};if(!YAHOO.util.Event){YAHOO.util.Event=function(){var H=false;var I=[];var J=[];var G=[];var E=[];var C=0;var F=[];var B=[];var A=0;var D={63232:38,63233:40,63234:37,63235:39,63276:33,63277:34,25:9};return{POLL_RETRYS:2000,POLL_INTERVAL:20,EL:0,TYPE:1,FN:2,WFN:3,UNLOAD_OBJ:3,ADJ_SCOPE:4,OBJ:5,OVERRIDE:6,lastError:null,isSafari:YAHOO.env.ua.webkit,webkit:YAHOO.env.ua.webkit,isIE:YAHOO.env.ua.ie,_interval:null,_dri:null,DOMReady:false,throwErrors:false,startInterval:function(){if(!this._interval){var K=this;var L=function(){K._tryPreloadAttach();};this._interval=setInterval(L,this.POLL_INTERVAL);}},onAvailable:function(P,M,Q,O,N){var K=(YAHOO.lang.isString(P))?[P]:P;for(var L=0;L<K.length;L=L+1){F.push({id:K[L],fn:M,obj:Q,override:O,checkReady:N});}C=this.POLL_RETRYS;this.startInterval();},onContentReady:function(M,K,N,L){this.onAvailable(M,K,N,L,true);},onDOMReady:function(K,M,L){if(this.DOMReady){setTimeout(function(){var N=window;if(L){if(L===true){N=M;}else{N=L;}}K.call(N,"DOMReady",[],M);},0);}else{this.DOMReadyEvent.subscribe(K,M,L);}},addListener:function(M,K,V,Q,L){if(!V||!V.call){return false;}if(this._isValidCollection(M)){var W=true;for(var R=0,T=M.length;R<T;++R){W=this.on(M[R],K,V,Q,L)&&W;}return W;}else{if(YAHOO.lang.isString(M)){var P=this.getEl(M);if(P){M=P;}else{this.onAvailable(M,function(){YAHOO.util.Event.on(M,K,V,Q,L);});return true;}}}if(!M){return false;}if("unload"==K&&Q!==this){J[J.length]=[M,K,V,Q,L];return true;}var Y=M;if(L){if(L===true){Y=Q;}else{Y=L;}}var N=function(Z){return V.call(Y,YAHOO.util.Event.getEvent(Z,M),Q);};var X=[M,K,V,N,Y,Q,L];var S=I.length;I[S]=X;if(this.useLegacyEvent(M,K)){var O=this.getLegacyIndex(M,K);if(O==-1||M!=G[O][0]){O=G.length;B[M.id+K]=O;G[O]=[M,K,M["on"+K]];E[O]=[];M["on"+K]=function(Z){YAHOO.util.Event.fireLegacyEvent(YAHOO.util.Event.getEvent(Z),O);};}E[O].push(X);}else{try{this._simpleAdd(M,K,N,false);}catch(U){this.lastError=U;this.removeListener(M,K,V);return false;}}return true;},fireLegacyEvent:function(O,M){var Q=true,K,S,R,T,P;S=E[M].slice();for(var L=0,N=S.length;L<N;++L){R=S[L];if(R&&R[this.WFN]){T=R[this.ADJ_SCOPE];P=R[this.WFN].call(T,O);Q=(Q&&P);}}K=G[M];if(K&&K[2]){K[2](O);}return Q;},getLegacyIndex:function(L,M){var K=this.generateId(L)+M;if(typeof B[K]=="undefined"){return -1;}else{return B[K];}},useLegacyEvent:function(L,M){if(this.webkit&&("click"==M||"dblclick"==M)){var K=parseInt(this.webkit,10);if(!isNaN(K)&&K<418){return true;}}return false;},removeListener:function(L,K,T){var O,R,V;if(typeof L=="string"){L=this.getEl(L);}else{if(this._isValidCollection(L)){var U=true;for(O=L.length-1;O>-1;O--){U=(this.removeListener(L[O],K,T)&&U);}return U;}}if(!T||!T.call){return this.purgeElement(L,false,K);}if("unload"==K){for(O=J.length-1;O>-1;O--){V=J[O];if(V&&V[0]==L&&V[1]==K&&V[2]==T){J.splice(O,1);return true;}}return false;}var P=null;var Q=arguments[3];if("undefined"===typeof Q){Q=this._getCacheIndex(L,K,T);}if(Q>=0){P=I[Q];}if(!L||!P){return false;}if(this.useLegacyEvent(L,K)){var N=this.getLegacyIndex(L,K);var M=E[N];if(M){for(O=0,R=M.length;O<R;++O){V=M[O];if(V&&V[this.EL]==L&&V[this.TYPE]==K&&V[this.FN]==T){M.splice(O,1);break;}}}}else{try{this._simpleRemove(L,K,P[this.WFN],false);}catch(S){this.lastError=S;return false;}}delete I[Q][this.WFN];delete I[Q][this.FN];I.splice(Q,1);return true;},getTarget:function(M,L){var K=M.target||M.srcElement;return this.resolveTextNode(K);},resolveTextNode:function(L){try{if(L&&3==L.nodeType){return L.parentNode;}}catch(K){}return L;},getPageX:function(L){var K=L.pageX;if(!K&&0!==K){K=L.clientX||0;if(this.isIE){K+=this._getScrollLeft();}}return K;},getPageY:function(K){var L=K.pageY;if(!L&&0!==L){L=K.clientY||0;if(this.isIE){L+=this._getScrollTop();}}return L; +},getXY:function(K){return[this.getPageX(K),this.getPageY(K)];},getRelatedTarget:function(L){var K=L.relatedTarget;if(!K){if(L.type=="mouseout"){K=L.toElement;}else{if(L.type=="mouseover"){K=L.fromElement;}}}return this.resolveTextNode(K);},getTime:function(M){if(!M.time){var L=new Date().getTime();try{M.time=L;}catch(K){this.lastError=K;return L;}}return M.time;},stopEvent:function(K){this.stopPropagation(K);this.preventDefault(K);},stopPropagation:function(K){if(K.stopPropagation){K.stopPropagation();}else{K.cancelBubble=true;}},preventDefault:function(K){if(K.preventDefault){K.preventDefault();}else{K.returnValue=false;}},getEvent:function(M,K){var L=M||window.event;if(!L){var N=this.getEvent.caller;while(N){L=N.arguments[0];if(L&&Event==L.constructor){break;}N=N.caller;}}return L;},getCharCode:function(L){var K=L.keyCode||L.charCode||0;if(YAHOO.env.ua.webkit&&(K in D)){K=D[K];}return K;},_getCacheIndex:function(O,P,N){for(var M=0,L=I.length;M<L;M=M+1){var K=I[M];if(K&&K[this.FN]==N&&K[this.EL]==O&&K[this.TYPE]==P){return M;}}return -1;},generateId:function(K){var L=K.id;if(!L){L="yuievtautoid-"+A;++A;K.id=L;}return L;},_isValidCollection:function(L){try{return(L&&typeof L!=="string"&&L.length&&!L.tagName&&!L.alert&&typeof L[0]!=="undefined");}catch(K){return false;}},elCache:{},getEl:function(K){return(typeof K==="string")?document.getElementById(K):K;},clearCache:function(){},DOMReadyEvent:new YAHOO.util.CustomEvent("DOMReady",this),_load:function(L){if(!H){H=true;var K=YAHOO.util.Event;K._ready();K._tryPreloadAttach();}},_ready:function(L){var K=YAHOO.util.Event;if(!K.DOMReady){K.DOMReady=true;K.DOMReadyEvent.fire();K._simpleRemove(document,"DOMContentLoaded",K._ready);}},_tryPreloadAttach:function(){if(F.length===0){C=0;clearInterval(this._interval);this._interval=null;return ;}if(this.locked){return ;}if(this.isIE){if(!this.DOMReady){this.startInterval();return ;}}this.locked=true;var Q=!H;if(!Q){Q=(C>0&&F.length>0);}var P=[];var R=function(T,U){var S=T;if(U.override){if(U.override===true){S=U.obj;}else{S=U.override;}}U.fn.call(S,U.obj);};var L,K,O,N,M=[];for(L=0,K=F.length;L<K;L=L+1){O=F[L];if(O){N=this.getEl(O.id);if(N){if(O.checkReady){if(H||N.nextSibling||!Q){M.push(O);F[L]=null;}}else{R(N,O);F[L]=null;}}else{P.push(O);}}}for(L=0,K=M.length;L<K;L=L+1){O=M[L];R(this.getEl(O.id),O);}C--;if(Q){for(L=F.length-1;L>-1;L--){O=F[L];if(!O||!O.id){F.splice(L,1);}}this.startInterval();}else{clearInterval(this._interval);this._interval=null;}this.locked=false;},purgeElement:function(O,P,R){var M=(YAHOO.lang.isString(O))?this.getEl(O):O;var Q=this.getListeners(M,R),N,K;if(Q){for(N=Q.length-1;N>-1;N--){var L=Q[N];this.removeListener(M,L.type,L.fn);}}if(P&&M&&M.childNodes){for(N=0,K=M.childNodes.length;N<K;++N){this.purgeElement(M.childNodes[N],P,R);}}},getListeners:function(M,K){var P=[],L;if(!K){L=[I,J];}else{if(K==="unload"){L=[J];}else{L=[I];}}var R=(YAHOO.lang.isString(M))?this.getEl(M):M;for(var O=0;O<L.length;O=O+1){var T=L[O];if(T){for(var Q=0,S=T.length;Q<S;++Q){var N=T[Q];if(N&&N[this.EL]===R&&(!K||K===N[this.TYPE])){P.push({type:N[this.TYPE],fn:N[this.FN],obj:N[this.OBJ],adjust:N[this.OVERRIDE],scope:N[this.ADJ_SCOPE],index:Q});}}}}return(P.length)?P:null;},_unload:function(Q){var K=YAHOO.util.Event,N,M,L,P,O,R=J.slice();for(N=0,P=J.length;N<P;++N){L=R[N];if(L){var S=window;if(L[K.ADJ_SCOPE]){if(L[K.ADJ_SCOPE]===true){S=L[K.UNLOAD_OBJ];}else{S=L[K.ADJ_SCOPE];}}L[K.FN].call(S,K.getEvent(Q,L[K.EL]),L[K.UNLOAD_OBJ]);R[N]=null;L=null;S=null;}}J=null;if(I){for(M=I.length-1;M>-1;M--){L=I[M];if(L){K.removeListener(L[K.EL],L[K.TYPE],L[K.FN],M);}}L=null;}G=null;K._simpleRemove(window,"unload",K._unload);},_getScrollLeft:function(){return this._getScroll()[1];},_getScrollTop:function(){return this._getScroll()[0];},_getScroll:function(){var K=document.documentElement,L=document.body;if(K&&(K.scrollTop||K.scrollLeft)){return[K.scrollTop,K.scrollLeft];}else{if(L){return[L.scrollTop,L.scrollLeft];}else{return[0,0];}}},regCE:function(){},_simpleAdd:function(){if(window.addEventListener){return function(M,N,L,K){M.addEventListener(N,L,(K));};}else{if(window.attachEvent){return function(M,N,L,K){M.attachEvent("on"+N,L);};}else{return function(){};}}}(),_simpleRemove:function(){if(window.removeEventListener){return function(M,N,L,K){M.removeEventListener(N,L,(K));};}else{if(window.detachEvent){return function(L,M,K){L.detachEvent("on"+M,K);};}else{return function(){};}}}()};}();(function(){var EU=YAHOO.util.Event;EU.on=EU.addListener; +/* DOMReady: based on work by: Dean Edwards/John Resig/Matthias Miller */ +if(EU.isIE){YAHOO.util.Event.onDOMReady(YAHOO.util.Event._tryPreloadAttach,YAHOO.util.Event,true);var n=document.createElement("p");EU._dri=setInterval(function(){try{n.doScroll("left");clearInterval(EU._dri);EU._dri=null;EU._ready();n=null;}catch(ex){}},EU.POLL_INTERVAL);}else{if(EU.webkit&&EU.webkit<525){EU._dri=setInterval(function(){var rs=document.readyState;if("loaded"==rs||"complete"==rs){clearInterval(EU._dri);EU._dri=null;EU._ready();}},EU.POLL_INTERVAL);}else{EU._simpleAdd(document,"DOMContentLoaded",EU._ready);}}EU._simpleAdd(window,"load",EU._load);EU._simpleAdd(window,"unload",EU._unload);EU._tryPreloadAttach();})();}YAHOO.util.EventProvider=function(){};YAHOO.util.EventProvider.prototype={__yui_events:null,__yui_subscribers:null,subscribe:function(A,C,F,E){this.__yui_events=this.__yui_events||{};var D=this.__yui_events[A];if(D){D.subscribe(C,F,E);}else{this.__yui_subscribers=this.__yui_subscribers||{};var B=this.__yui_subscribers;if(!B[A]){B[A]=[];}B[A].push({fn:C,obj:F,override:E});}},unsubscribe:function(C,E,G){this.__yui_events=this.__yui_events||{};var A=this.__yui_events;if(C){var F=A[C];if(F){return F.unsubscribe(E,G);}}else{var B=true;for(var D in A){if(YAHOO.lang.hasOwnProperty(A,D)){B=B&&A[D].unsubscribe(E,G);}}return B;}return false;},unsubscribeAll:function(A){return this.unsubscribe(A);},createEvent:function(G,D){this.__yui_events=this.__yui_events||{};var A=D||{};var I=this.__yui_events; +if(I[G]){}else{var H=A.scope||this;var E=(A.silent);var B=new YAHOO.util.CustomEvent(G,H,E,YAHOO.util.CustomEvent.FLAT);I[G]=B;if(A.onSubscribeCallback){B.subscribeEvent.subscribe(A.onSubscribeCallback);}this.__yui_subscribers=this.__yui_subscribers||{};var F=this.__yui_subscribers[G];if(F){for(var C=0;C<F.length;++C){B.subscribe(F[C].fn,F[C].obj,F[C].override);}}}return I[G];},fireEvent:function(E,D,A,C){this.__yui_events=this.__yui_events||{};var G=this.__yui_events[E];if(!G){return null;}var B=[];for(var F=1;F<arguments.length;++F){B.push(arguments[F]);}return G.fire.apply(G,B);},hasEvent:function(A){if(this.__yui_events){if(this.__yui_events[A]){return true;}}return false;}};YAHOO.util.KeyListener=function(A,F,B,C){if(!A){}else{if(!F){}else{if(!B){}}}if(!C){C=YAHOO.util.KeyListener.KEYDOWN;}var D=new YAHOO.util.CustomEvent("keyPressed");this.enabledEvent=new YAHOO.util.CustomEvent("enabled");this.disabledEvent=new YAHOO.util.CustomEvent("disabled");if(typeof A=="string"){A=document.getElementById(A);}if(typeof B=="function"){D.subscribe(B);}else{D.subscribe(B.fn,B.scope,B.correctScope);}function E(J,I){if(!F.shift){F.shift=false;}if(!F.alt){F.alt=false;}if(!F.ctrl){F.ctrl=false;}if(J.shiftKey==F.shift&&J.altKey==F.alt&&J.ctrlKey==F.ctrl){var G;if(F.keys instanceof Array){for(var H=0;H<F.keys.length;H++){G=F.keys[H];if(G==J.charCode){D.fire(J.charCode,J);break;}else{if(G==J.keyCode){D.fire(J.keyCode,J);break;}}}}else{G=F.keys;if(G==J.charCode){D.fire(J.charCode,J);}else{if(G==J.keyCode){D.fire(J.keyCode,J);}}}}}this.enable=function(){if(!this.enabled){YAHOO.util.Event.addListener(A,C,E);this.enabledEvent.fire(F);}this.enabled=true;};this.disable=function(){if(this.enabled){YAHOO.util.Event.removeListener(A,C,E);this.disabledEvent.fire(F);}this.enabled=false;};this.toString=function(){return"KeyListener ["+F.keys+"] "+A.tagName+(A.id?"["+A.id+"]":"");};};YAHOO.util.KeyListener.KEYDOWN="keydown";YAHOO.util.KeyListener.KEYUP="keyup";YAHOO.util.KeyListener.KEY={ALT:18,BACK_SPACE:8,CAPS_LOCK:20,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,META:224,NUM_LOCK:144,PAGE_DOWN:34,PAGE_UP:33,PAUSE:19,PRINTSCREEN:44,RIGHT:39,SCROLL_LOCK:145,SHIFT:16,SPACE:32,TAB:9,UP:38};YAHOO.register("event",YAHOO.util.Event,{version:"2.5.2",build:"1076"});YAHOO.util.Connect={_msxml_progid:["Microsoft.XMLHTTP","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP"],_http_headers:{},_has_http_headers:false,_use_default_post_header:true,_default_post_header:"application/x-www-form-urlencoded; charset=UTF-8",_default_form_header:"application/x-www-form-urlencoded",_use_default_xhr_header:true,_default_xhr_header:"XMLHttpRequest",_has_default_headers:true,_default_headers:{},_isFormSubmit:false,_isFileUpload:false,_formNode:null,_sFormData:null,_poll:{},_timeOut:{},_polling_interval:50,_transaction_id:0,_submitElementValue:null,_hasSubmitListener:(function(){if(YAHOO.util.Event){YAHOO.util.Event.addListener(document,"click",function(B){var A=YAHOO.util.Event.getTarget(B);if(A.nodeName.toLowerCase()=="input"&&(A.type&&A.type.toLowerCase()=="submit")){YAHOO.util.Connect._submitElementValue=encodeURIComponent(A.name)+"="+encodeURIComponent(A.value);}});return true;}return false;})(),startEvent:new YAHOO.util.CustomEvent("start"),completeEvent:new YAHOO.util.CustomEvent("complete"),successEvent:new YAHOO.util.CustomEvent("success"),failureEvent:new YAHOO.util.CustomEvent("failure"),uploadEvent:new YAHOO.util.CustomEvent("upload"),abortEvent:new YAHOO.util.CustomEvent("abort"),_customEvents:{onStart:["startEvent","start"],onComplete:["completeEvent","complete"],onSuccess:["successEvent","success"],onFailure:["failureEvent","failure"],onUpload:["uploadEvent","upload"],onAbort:["abortEvent","abort"]},setProgId:function(A){this._msxml_progid.unshift(A);YAHOO.log("ActiveX Program Id "+A+" added to _msxml_progid.","info","Connection");},setDefaultPostHeader:function(A){if(typeof A=="string"){this._default_post_header=A;YAHOO.log("Default POST header set to "+A,"info","Connection");}else{if(typeof A=="boolean"){this._use_default_post_header=A;}}},setDefaultXhrHeader:function(A){if(typeof A=="string"){this._default_xhr_header=A;YAHOO.log("Default XHR header set to "+A,"info","Connection");}else{this._use_default_xhr_header=A;}},setPollingInterval:function(A){if(typeof A=="number"&&isFinite(A)){this._polling_interval=A;YAHOO.log("Default polling interval set to "+A+"ms","info","Connection");}},createXhrObject:function(E){var D,A;try{A=new XMLHttpRequest();D={conn:A,tId:E};YAHOO.log("XHR object created for transaction "+E,"info","Connection");}catch(C){for(var B=0;B<this._msxml_progid.length;++B){try{A=new ActiveXObject(this._msxml_progid[B]);D={conn:A,tId:E};YAHOO.log("ActiveX XHR object created for transaction "+E,"info","Connection");break;}catch(C){}}}finally{return D;}},getConnectionObject:function(A){var C;var D=this._transaction_id;try{if(!A){C=this.createXhrObject(D);}else{C={};C.tId=D;C.isUpload=true;}if(C){this._transaction_id++;}}catch(B){}finally{return C;}},asyncRequest:function(F,C,E,A){var D=(this._isFileUpload)?this.getConnectionObject(true):this.getConnectionObject();var B=(E&&E.argument)?E.argument:null;if(!D){YAHOO.log("Unable to create connection object.","error","Connection");return null;}else{if(E&&E.customevents){this.initCustomEvents(D,E);}if(this._isFormSubmit){if(this._isFileUpload){this.uploadFile(D,E,C,A);return D;}if(F.toUpperCase()=="GET"){if(this._sFormData.length!==0){C+=((C.indexOf("?")==-1)?"?":"&")+this._sFormData;}}else{if(F.toUpperCase()=="POST"){A=A?this._sFormData+"&"+A:this._sFormData;}}}if(F.toUpperCase()=="GET"&&(E&&E.cache===false)){C+=((C.indexOf("?")==-1)?"?":"&")+"rnd="+new Date().valueOf().toString();}D.conn.open(F,C,true);if(this._use_default_xhr_header){if(!this._default_headers["X-Requested-With"]){this.initHeader("X-Requested-With",this._default_xhr_header,true);YAHOO.log("Initialize transaction header X-Request-Header to XMLHttpRequest.","info","Connection");}}if((F.toUpperCase()=="POST"&&this._use_default_post_header)&&this._isFormSubmit===false){this.initHeader("Content-Type",this._default_post_header);YAHOO.log("Initialize header Content-Type to application/x-www-form-urlencoded; UTF-8 for POST transaction.","info","Connection");}if(this._has_default_headers||this._has_http_headers){this.setHeader(D);}this.handleReadyState(D,E);D.conn.send(A||"");YAHOO.log("Transaction "+D.tId+" sent.","info","Connection");if(this._isFormSubmit===true){this.resetFormState();}this.startEvent.fire(D,B);if(D.startEvent){D.startEvent.fire(D,B);}return D;}},initCustomEvents:function(A,C){for(var B in C.customevents){if(this._customEvents[B][0]){A[this._customEvents[B][0]]=new YAHOO.util.CustomEvent(this._customEvents[B][1],(C.scope)?C.scope:null);YAHOO.log("Transaction-specific Custom Event "+A[this._customEvents[B][1]]+" created.","info","Connection");A[this._customEvents[B][0]].subscribe(C.customevents[B]);YAHOO.log("Transaction-specific Custom Event "+A[this._customEvents[B][1]]+" subscribed.","info","Connection");}}},handleReadyState:function(C,D){var B=this;var A=(D&&D.argument)?D.argument:null;if(D&&D.timeout){this._timeOut[C.tId]=window.setTimeout(function(){B.abort(C,D,true);},D.timeout);}this._poll[C.tId]=window.setInterval(function(){if(C.conn&&C.conn.readyState===4){window.clearInterval(B._poll[C.tId]);delete B._poll[C.tId];if(D&&D.timeout){window.clearTimeout(B._timeOut[C.tId]);delete B._timeOut[C.tId];}B.completeEvent.fire(C,A);if(C.completeEvent){C.completeEvent.fire(C,A);}B.handleTransactionResponse(C,D);}},this._polling_interval);},handleTransactionResponse:function(F,G,A){var D,C;var B=(G&&G.argument)?G.argument:null;try{if(F.conn.status!==undefined&&F.conn.status!==0){D=F.conn.status;}else{D=13030;}}catch(E){D=13030;}if(D>=200&&D<300||D===1223){C=this.createResponseObject(F,B);if(G&&G.success){if(!G.scope){G.success(C);YAHOO.log("Success callback. HTTP code is "+D,"info","Connection");}else{G.success.apply(G.scope,[C]);YAHOO.log("Success callback with scope. HTTP code is "+D,"info","Connection");}}this.successEvent.fire(C);if(F.successEvent){F.successEvent.fire(C);}}else{switch(D){case 12002:case 12029:case 12030:case 12031:case 12152:case 13030:C=this.createExceptionObject(F.tId,B,(A?A:false));if(G&&G.failure){if(!G.scope){G.failure(C); +YAHOO.log("Failure callback. Exception detected. Status code is "+D,"warn","Connection");}else{G.failure.apply(G.scope,[C]);YAHOO.log("Failure callback with scope. Exception detected. Status code is "+D,"warn","Connection");}}break;default:C=this.createResponseObject(F,B);if(G&&G.failure){if(!G.scope){G.failure(C);YAHOO.log("Failure callback. HTTP status code is "+D,"warn","Connection");}else{G.failure.apply(G.scope,[C]);YAHOO.log("Failure callback with scope. HTTP status code is "+D,"warn","Connection");}}}this.failureEvent.fire(C);if(F.failureEvent){F.failureEvent.fire(C);}}this.releaseObject(F);C=null;},createResponseObject:function(A,G){var D={};var I={};try{var C=A.conn.getAllResponseHeaders();var F=C.split("\n");for(var E=0;E<F.length;E++){var B=F[E].indexOf(":");if(B!=-1){I[F[E].substring(0,B)]=F[E].substring(B+2);}}}catch(H){}D.tId=A.tId;D.status=(A.conn.status==1223)?204:A.conn.status;D.statusText=(A.conn.status==1223)?"No Content":A.conn.statusText;D.getResponseHeader=I;D.getAllResponseHeaders=C;D.responseText=A.conn.responseText;D.responseXML=A.conn.responseXML;if(G){D.argument=G;}return D;},createExceptionObject:function(H,D,A){var F=0;var G="communication failure";var C=-1;var B="transaction aborted";var E={};E.tId=H;if(A){E.status=C;E.statusText=B;}else{E.status=F;E.statusText=G;}if(D){E.argument=D;}return E;},initHeader:function(A,D,C){var B=(C)?this._default_headers:this._http_headers;B[A]=D;if(C){this._has_default_headers=true;}else{this._has_http_headers=true;}},setHeader:function(A){if(this._has_default_headers){for(var B in this._default_headers){if(YAHOO.lang.hasOwnProperty(this._default_headers,B)){A.conn.setRequestHeader(B,this._default_headers[B]);YAHOO.log("Default HTTP header "+B+" set with value of "+this._default_headers[B],"info","Connection");}}}if(this._has_http_headers){for(var B in this._http_headers){if(YAHOO.lang.hasOwnProperty(this._http_headers,B)){A.conn.setRequestHeader(B,this._http_headers[B]);YAHOO.log("HTTP header "+B+" set with value of "+this._http_headers[B],"info","Connection");}}delete this._http_headers;this._http_headers={};this._has_http_headers=false;}},resetDefaultHeaders:function(){delete this._default_headers;this._default_headers={};this._has_default_headers=false;},setForm:function(K,E,B){this.resetFormState();var J;if(typeof K=="string"){J=(document.getElementById(K)||document.forms[K]);}else{if(typeof K=="object"){J=K;}else{YAHOO.log("Unable to create form object "+K,"warn","Connection");return ;}}if(E){var F=this.createFrame((window.location.href.toLowerCase().indexOf("https")===0||B)?true:false);this._isFormSubmit=true;this._isFileUpload=true;this._formNode=J;return ;}var A,I,G,L;var H=false;for(var D=0;D<J.elements.length;D++){A=J.elements[D];L=A.disabled;I=A.name;G=A.value;if(!L&&I){switch(A.type){case"select-one":case"select-multiple":for(var C=0;C<A.options.length;C++){if(A.options[C].selected){if(window.ActiveXObject){this._sFormData+=encodeURIComponent(I)+"="+encodeURIComponent(A.options[C].attributes["value"].specified?A.options[C].value:A.options[C].text)+"&";}else{this._sFormData+=encodeURIComponent(I)+"="+encodeURIComponent(A.options[C].hasAttribute("value")?A.options[C].value:A.options[C].text)+"&";}}}break;case"radio":case"checkbox":if(A.checked){this._sFormData+=encodeURIComponent(I)+"="+encodeURIComponent(G)+"&";}break;case"file":case undefined:case"reset":case"button":break;case"submit":if(H===false){if(this._hasSubmitListener&&this._submitElementValue){this._sFormData+=this._submitElementValue+"&";}else{this._sFormData+=encodeURIComponent(I)+"="+encodeURIComponent(G)+"&";}H=true;}break;default:this._sFormData+=encodeURIComponent(I)+"="+encodeURIComponent(G)+"&";}}}this._isFormSubmit=true;this._sFormData=this._sFormData.substr(0,this._sFormData.length-1);YAHOO.log("Form initialized for transaction. HTML form POST message is: "+this._sFormData,"info","Connection");this.initHeader("Content-Type",this._default_form_header);YAHOO.log("Initialize header Content-Type to application/x-www-form-urlencoded for setForm() transaction.","info","Connection");return this._sFormData;},resetFormState:function(){this._isFormSubmit=false;this._isFileUpload=false;this._formNode=null;this._sFormData="";},createFrame:function(A){var B="yuiIO"+this._transaction_id;var C;if(window.ActiveXObject){C=document.createElement('<iframe id="'+B+'" name="'+B+'" />');if(typeof A=="boolean"){C.src="javascript:false";}}else{C=document.createElement("iframe");C.id=B;C.name=B;}C.style.position="absolute";C.style.top="-1000px";C.style.left="-1000px";document.body.appendChild(C);YAHOO.log("File upload iframe created. Id is:"+B,"info","Connection");},appendPostData:function(A){var D=[];var B=A.split("&");for(var C=0;C<B.length;C++){var E=B[C].indexOf("=");if(E!=-1){D[C]=document.createElement("input");D[C].type="hidden";D[C].name=B[C].substring(0,E);D[C].value=B[C].substring(E+1);this._formNode.appendChild(D[C]);}}return D;},uploadFile:function(D,M,E,C){var N=this;var H="yuiIO"+D.tId;var I="multipart/form-data";var K=document.getElementById(H);var J=(M&&M.argument)?M.argument:null;var B={action:this._formNode.getAttribute("action"),method:this._formNode.getAttribute("method"),target:this._formNode.getAttribute("target")};this._formNode.setAttribute("action",E);this._formNode.setAttribute("method","POST");this._formNode.setAttribute("target",H);if(YAHOO.env.ua.ie){this._formNode.setAttribute("encoding",I);}else{this._formNode.setAttribute("enctype",I);}if(C){var L=this.appendPostData(C);}this._formNode.submit();this.startEvent.fire(D,J);if(D.startEvent){D.startEvent.fire(D,J);}if(M&&M.timeout){this._timeOut[D.tId]=window.setTimeout(function(){N.abort(D,M,true);},M.timeout);}if(L&&L.length>0){for(var G=0;G<L.length;G++){this._formNode.removeChild(L[G]);}}for(var A in B){if(YAHOO.lang.hasOwnProperty(B,A)){if(B[A]){this._formNode.setAttribute(A,B[A]);}else{this._formNode.removeAttribute(A);}}}this.resetFormState();var F=function(){if(M&&M.timeout){window.clearTimeout(N._timeOut[D.tId]); +delete N._timeOut[D.tId];}N.completeEvent.fire(D,J);if(D.completeEvent){D.completeEvent.fire(D,J);}var P={};P.tId=D.tId;P.argument=M.argument;try{P.responseText=K.contentWindow.document.body?K.contentWindow.document.body.innerHTML:K.contentWindow.document.documentElement.textContent;P.responseXML=K.contentWindow.document.XMLDocument?K.contentWindow.document.XMLDocument:K.contentWindow.document;}catch(O){}if(M&&M.upload){if(!M.scope){M.upload(P);YAHOO.log("Upload callback.","info","Connection");}else{M.upload.apply(M.scope,[P]);YAHOO.log("Upload callback with scope.","info","Connection");}}N.uploadEvent.fire(P);if(D.uploadEvent){D.uploadEvent.fire(P);}YAHOO.util.Event.removeListener(K,"load",F);setTimeout(function(){document.body.removeChild(K);N.releaseObject(D);YAHOO.log("File upload iframe destroyed. Id is:"+H,"info","Connection");},100);};YAHOO.util.Event.addListener(K,"load",F);},abort:function(E,G,A){var D;var B=(G&&G.argument)?G.argument:null;if(E&&E.conn){if(this.isCallInProgress(E)){E.conn.abort();window.clearInterval(this._poll[E.tId]);delete this._poll[E.tId];if(A){window.clearTimeout(this._timeOut[E.tId]);delete this._timeOut[E.tId];}D=true;}}else{if(E&&E.isUpload===true){var C="yuiIO"+E.tId;var F=document.getElementById(C);if(F){YAHOO.util.Event.removeListener(F,"load");document.body.removeChild(F);YAHOO.log("File upload iframe destroyed. Id is:"+C,"info","Connection");if(A){window.clearTimeout(this._timeOut[E.tId]);delete this._timeOut[E.tId];}D=true;}}else{D=false;}}if(D===true){this.abortEvent.fire(E,B);if(E.abortEvent){E.abortEvent.fire(E,B);}this.handleTransactionResponse(E,G,true);YAHOO.log("Transaction "+E.tId+" aborted.","info","Connection");}return D;},isCallInProgress:function(B){if(B&&B.conn){return B.conn.readyState!==4&&B.conn.readyState!==0;}else{if(B&&B.isUpload===true){var A="yuiIO"+B.tId;return document.getElementById(A)?true:false;}else{return false;}}},releaseObject:function(A){if(A&&A.conn){A.conn=null;YAHOO.log("Connection object for transaction "+A.tId+" destroyed.","info","Connection");A=null;}}};YAHOO.register("connection",YAHOO.util.Connect,{version:"2.5.2",build:"1076"});(function(){var B=YAHOO.util;var A=function(D,C,E,F){if(!D){}this.init(D,C,E,F);};A.NAME="Anim";A.prototype={toString:function(){var C=this.getEl()||{};var D=C.id||C.tagName;return(this.constructor.NAME+": "+D);},patterns:{noNegatives:/width|height|opacity|padding/i,offsetAttribute:/^((width|height)|(top|left))$/,defaultUnit:/width|height|top$|bottom$|left$|right$/i,offsetUnit:/\d+(em|%|en|ex|pt|in|cm|mm|pc)$/i},doMethod:function(C,E,D){return this.method(this.currentFrame,E,D-E,this.totalFrames);},setAttribute:function(C,E,D){if(this.patterns.noNegatives.test(C)){E=(E>0)?E:0;}B.Dom.setStyle(this.getEl(),C,E+D);},getAttribute:function(C){var E=this.getEl();var G=B.Dom.getStyle(E,C);if(G!=="auto"&&!this.patterns.offsetUnit.test(G)){return parseFloat(G);}var D=this.patterns.offsetAttribute.exec(C)||[];var H=!!(D[3]);var F=!!(D[2]);if(F||(B.Dom.getStyle(E,"position")=="absolute"&&H)){G=E["offset"+D[0].charAt(0).toUpperCase()+D[0].substr(1)];}else{G=0;}return G;},getDefaultUnit:function(C){if(this.patterns.defaultUnit.test(C)){return"px";}return"";},setRuntimeAttribute:function(D){var I;var E;var F=this.attributes;this.runtimeAttributes[D]={};var H=function(J){return(typeof J!=="undefined");};if(!H(F[D]["to"])&&!H(F[D]["by"])){return false;}I=(H(F[D]["from"]))?F[D]["from"]:this.getAttribute(D);if(H(F[D]["to"])){E=F[D]["to"];}else{if(H(F[D]["by"])){if(I.constructor==Array){E=[];for(var G=0,C=I.length;G<C;++G){E[G]=I[G]+F[D]["by"][G]*1;}}else{E=I+F[D]["by"]*1;}}}this.runtimeAttributes[D].start=I;this.runtimeAttributes[D].end=E;this.runtimeAttributes[D].unit=(H(F[D].unit))?F[D]["unit"]:this.getDefaultUnit(D);return true;},init:function(E,J,I,C){var D=false;var F=null;var H=0;E=B.Dom.get(E);this.attributes=J||{};this.duration=!YAHOO.lang.isUndefined(I)?I:1;this.method=C||B.Easing.easeNone;this.useSeconds=true;this.currentFrame=0;this.totalFrames=B.AnimMgr.fps;this.setEl=function(M){E=B.Dom.get(M);};this.getEl=function(){return E;};this.isAnimated=function(){return D;};this.getStartTime=function(){return F;};this.runtimeAttributes={};this.animate=function(){if(this.isAnimated()){return false;}this.currentFrame=0;this.totalFrames=(this.useSeconds)?Math.ceil(B.AnimMgr.fps*this.duration):this.duration;if(this.duration===0&&this.useSeconds){this.totalFrames=1;}B.AnimMgr.registerElement(this);return true;};this.stop=function(M){if(!this.isAnimated()){return false;}if(M){this.currentFrame=this.totalFrames;this._onTween.fire();}B.AnimMgr.stop(this);};var L=function(){this.onStart.fire();this.runtimeAttributes={};for(var M in this.attributes){this.setRuntimeAttribute(M);}D=true;H=0;F=new Date();};var K=function(){var O={duration:new Date()-this.getStartTime(),currentFrame:this.currentFrame};O.toString=function(){return("duration: "+O.duration+", currentFrame: "+O.currentFrame);};this.onTween.fire(O);var N=this.runtimeAttributes;for(var M in N){this.setAttribute(M,this.doMethod(M,N[M].start,N[M].end),N[M].unit);}H+=1;};var G=function(){var M=(new Date()-F)/1000;var N={duration:M,frames:H,fps:H/M};N.toString=function(){return("duration: "+N.duration+", frames: "+N.frames+", fps: "+N.fps);};D=false;H=0;this.onComplete.fire(N);};this._onStart=new B.CustomEvent("_start",this,true);this.onStart=new B.CustomEvent("start",this);this.onTween=new B.CustomEvent("tween",this);this._onTween=new B.CustomEvent("_tween",this,true);this.onComplete=new B.CustomEvent("complete",this);this._onComplete=new B.CustomEvent("_complete",this,true);this._onStart.subscribe(L);this._onTween.subscribe(K);this._onComplete.subscribe(G);}};B.Anim=A;})();YAHOO.util.AnimMgr=new function(){var C=null;var B=[];var A=0;this.fps=1000;this.delay=1;this.registerElement=function(F){B[B.length]=F;A+=1;F._onStart.fire();this.start();};this.unRegister=function(G,F){F=F||E(G);if(!G.isAnimated()||F==-1){return false;}G._onComplete.fire();B.splice(F,1);A-=1;if(A<=0){this.stop();}return true;};this.start=function(){if(C===null){C=setInterval(this.run,this.delay);}};this.stop=function(H){if(!H){clearInterval(C);for(var G=0,F=B.length;G<F;++G){this.unRegister(B[0],0);}B=[];C=null;A=0;}else{this.unRegister(H);}};this.run=function(){for(var H=0,F=B.length;H<F;++H){var G=B[H];if(!G||!G.isAnimated()){continue;}if(G.currentFrame<G.totalFrames||G.totalFrames===null){G.currentFrame+=1;if(G.useSeconds){D(G);}G._onTween.fire();}else{YAHOO.util.AnimMgr.stop(G,H);}}};var E=function(H){for(var G=0,F=B.length;G<F;++G){if(B[G]==H){return G;}}return -1;};var D=function(G){var J=G.totalFrames;var I=G.currentFrame;var H=(G.currentFrame*G.duration*1000/G.totalFrames);var F=(new Date()-G.getStartTime());var K=0;if(F<G.duration*1000){K=Math.round((F/H-1)*G.currentFrame);}else{K=J-(I+1);}if(K>0&&isFinite(K)){if(G.currentFrame+K>=J){K=J-(I+1);}G.currentFrame+=K;}};};YAHOO.util.Bezier=new function(){this.getPosition=function(E,D){var F=E.length;var C=[];for(var B=0;B<F;++B){C[B]=[E[B][0],E[B][1]];}for(var A=1;A<F;++A){for(B=0;B<F-A;++B){C[B][0]=(1-D)*C[B][0]+D*C[parseInt(B+1,10)][0];C[B][1]=(1-D)*C[B][1]+D*C[parseInt(B+1,10)][1];}}return[C[0][0],C[0][1]];};};(function(){var A=function(F,E,G,H){A.superclass.constructor.call(this,F,E,G,H);};A.NAME="ColorAnim";var C=YAHOO.util;YAHOO.extend(A,C.Anim);var D=A.superclass;var B=A.prototype;B.patterns.color=/color$/i;B.patterns.rgb=/^rgb\(([0-9]+)\s*,\s*([0-9]+)\s*,\s*([0-9]+)\)$/i;B.patterns.hex=/^#?([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})$/i;B.patterns.hex3=/^#?([0-9A-F]{1})([0-9A-F]{1})([0-9A-F]{1})$/i;B.patterns.transparent=/^transparent|rgba\(0, 0, 0, 0\)$/;B.parseColor=function(E){if(E.length==3){return E;}var F=this.patterns.hex.exec(E);if(F&&F.length==4){return[parseInt(F[1],16),parseInt(F[2],16),parseInt(F[3],16)];}F=this.patterns.rgb.exec(E);if(F&&F.length==4){return[parseInt(F[1],10),parseInt(F[2],10),parseInt(F[3],10)];}F=this.patterns.hex3.exec(E);if(F&&F.length==4){return[parseInt(F[1]+F[1],16),parseInt(F[2]+F[2],16),parseInt(F[3]+F[3],16)];}return null;};B.getAttribute=function(E){var G=this.getEl();if(this.patterns.color.test(E)){var H=YAHOO.util.Dom.getStyle(G,E); +if(this.patterns.transparent.test(H)){var F=G.parentNode;H=C.Dom.getStyle(F,E);while(F&&this.patterns.transparent.test(H)){F=F.parentNode;H=C.Dom.getStyle(F,E);if(F.tagName.toUpperCase()=="HTML"){H="#fff";}}}}else{H=D.getAttribute.call(this,E);}return H;};B.doMethod=function(F,J,G){var I;if(this.patterns.color.test(F)){I=[];for(var H=0,E=J.length;H<E;++H){I[H]=D.doMethod.call(this,F,J[H],G[H]);}I="rgb("+Math.floor(I[0])+","+Math.floor(I[1])+","+Math.floor(I[2])+")";}else{I=D.doMethod.call(this,F,J,G);}return I;};B.setRuntimeAttribute=function(F){D.setRuntimeAttribute.call(this,F);if(this.patterns.color.test(F)){var H=this.attributes;var J=this.parseColor(this.runtimeAttributes[F].start);var G=this.parseColor(this.runtimeAttributes[F].end);if(typeof H[F]["to"]==="undefined"&&typeof H[F]["by"]!=="undefined"){G=this.parseColor(H[F].by);for(var I=0,E=J.length;I<E;++I){G[I]=J[I]+G[I];}}this.runtimeAttributes[F].start=J;this.runtimeAttributes[F].end=G;}};C.ColorAnim=A;})(); +/* +TERMS OF USE - EASING EQUATIONS +Open source under the BSD License. +Copyright 2001 Robert Penner All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + * Neither the name of the author nor the names of contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +*/ +YAHOO.util.Easing={easeNone:function(B,A,D,C){return D*B/C+A;},easeIn:function(B,A,D,C){return D*(B/=C)*B+A;},easeOut:function(B,A,D,C){return -D*(B/=C)*(B-2)+A;},easeBoth:function(B,A,D,C){if((B/=C/2)<1){return D/2*B*B+A;}return -D/2*((--B)*(B-2)-1)+A;},easeInStrong:function(B,A,D,C){return D*(B/=C)*B*B*B+A;},easeOutStrong:function(B,A,D,C){return -D*((B=B/C-1)*B*B*B-1)+A;},easeBothStrong:function(B,A,D,C){if((B/=C/2)<1){return D/2*B*B*B*B+A;}return -D/2*((B-=2)*B*B*B-2)+A;},elasticIn:function(C,A,G,F,B,E){if(C==0){return A;}if((C/=F)==1){return A+G;}if(!E){E=F*0.3;}if(!B||B<Math.abs(G)){B=G;var D=E/4;}else{var D=E/(2*Math.PI)*Math.asin(G/B);}return -(B*Math.pow(2,10*(C-=1))*Math.sin((C*F-D)*(2*Math.PI)/E))+A;},elasticOut:function(C,A,G,F,B,E){if(C==0){return A;}if((C/=F)==1){return A+G;}if(!E){E=F*0.3;}if(!B||B<Math.abs(G)){B=G;var D=E/4;}else{var D=E/(2*Math.PI)*Math.asin(G/B);}return B*Math.pow(2,-10*C)*Math.sin((C*F-D)*(2*Math.PI)/E)+G+A;},elasticBoth:function(C,A,G,F,B,E){if(C==0){return A;}if((C/=F/2)==2){return A+G;}if(!E){E=F*(0.3*1.5);}if(!B||B<Math.abs(G)){B=G;var D=E/4;}else{var D=E/(2*Math.PI)*Math.asin(G/B);}if(C<1){return -0.5*(B*Math.pow(2,10*(C-=1))*Math.sin((C*F-D)*(2*Math.PI)/E))+A;}return B*Math.pow(2,-10*(C-=1))*Math.sin((C*F-D)*(2*Math.PI)/E)*0.5+G+A;},backIn:function(B,A,E,D,C){if(typeof C=="undefined"){C=1.70158;}return E*(B/=D)*B*((C+1)*B-C)+A;},backOut:function(B,A,E,D,C){if(typeof C=="undefined"){C=1.70158;}return E*((B=B/D-1)*B*((C+1)*B+C)+1)+A;},backBoth:function(B,A,E,D,C){if(typeof C=="undefined"){C=1.70158;}if((B/=D/2)<1){return E/2*(B*B*(((C*=(1.525))+1)*B-C))+A;}return E/2*((B-=2)*B*(((C*=(1.525))+1)*B+C)+2)+A;},bounceIn:function(B,A,D,C){return D-YAHOO.util.Easing.bounceOut(C-B,0,D,C)+A;},bounceOut:function(B,A,D,C){if((B/=C)<(1/2.75)){return D*(7.5625*B*B)+A;}else{if(B<(2/2.75)){return D*(7.5625*(B-=(1.5/2.75))*B+0.75)+A;}else{if(B<(2.5/2.75)){return D*(7.5625*(B-=(2.25/2.75))*B+0.9375)+A;}}}return D*(7.5625*(B-=(2.625/2.75))*B+0.984375)+A;},bounceBoth:function(B,A,D,C){if(B<C/2){return YAHOO.util.Easing.bounceIn(B*2,0,D,C)*0.5+A;}return YAHOO.util.Easing.bounceOut(B*2-C,0,D,C)*0.5+D*0.5+A;}};(function(){var A=function(H,G,I,J){if(H){A.superclass.constructor.call(this,H,G,I,J);}};A.NAME="Motion";var E=YAHOO.util;YAHOO.extend(A,E.ColorAnim);var F=A.superclass;var C=A.prototype;C.patterns.points=/^points$/i;C.setAttribute=function(G,I,H){if(this.patterns.points.test(G)){H=H||"px";F.setAttribute.call(this,"left",I[0],H);F.setAttribute.call(this,"top",I[1],H);}else{F.setAttribute.call(this,G,I,H);}};C.getAttribute=function(G){if(this.patterns.points.test(G)){var H=[F.getAttribute.call(this,"left"),F.getAttribute.call(this,"top")];}else{H=F.getAttribute.call(this,G);}return H;};C.doMethod=function(G,K,H){var J=null;if(this.patterns.points.test(G)){var I=this.method(this.currentFrame,0,100,this.totalFrames)/100;J=E.Bezier.getPosition(this.runtimeAttributes[G],I);}else{J=F.doMethod.call(this,G,K,H);}return J;};C.setRuntimeAttribute=function(P){if(this.patterns.points.test(P)){var H=this.getEl();var J=this.attributes;var G;var L=J["points"]["control"]||[];var I;var M,O;if(L.length>0&&!(L[0] instanceof Array)){L=[L];}else{var K=[];for(M=0,O=L.length;M<O;++M){K[M]=L[M];}L=K;}if(E.Dom.getStyle(H,"position")=="static"){E.Dom.setStyle(H,"position","relative");}if(D(J["points"]["from"])){E.Dom.setXY(H,J["points"]["from"]);}else{E.Dom.setXY(H,E.Dom.getXY(H));}G=this.getAttribute("points");if(D(J["points"]["to"])){I=B.call(this,J["points"]["to"],G); +var N=E.Dom.getXY(this.getEl());for(M=0,O=L.length;M<O;++M){L[M]=B.call(this,L[M],G);}}else{if(D(J["points"]["by"])){I=[G[0]+J["points"]["by"][0],G[1]+J["points"]["by"][1]];for(M=0,O=L.length;M<O;++M){L[M]=[G[0]+L[M][0],G[1]+L[M][1]];}}}this.runtimeAttributes[P]=[G];if(L.length>0){this.runtimeAttributes[P]=this.runtimeAttributes[P].concat(L);}this.runtimeAttributes[P][this.runtimeAttributes[P].length]=I;}else{F.setRuntimeAttribute.call(this,P);}};var B=function(G,I){var H=E.Dom.getXY(this.getEl());G=[G[0]-H[0]+I[0],G[1]-H[1]+I[1]];return G;};var D=function(G){return(typeof G!=="undefined");};E.Motion=A;})();(function(){var D=function(F,E,G,H){if(F){D.superclass.constructor.call(this,F,E,G,H);}};D.NAME="Scroll";var B=YAHOO.util;YAHOO.extend(D,B.ColorAnim);var C=D.superclass;var A=D.prototype;A.doMethod=function(E,H,F){var G=null;if(E=="scroll"){G=[this.method(this.currentFrame,H[0],F[0]-H[0],this.totalFrames),this.method(this.currentFrame,H[1],F[1]-H[1],this.totalFrames)];}else{G=C.doMethod.call(this,E,H,F);}return G;};A.getAttribute=function(E){var G=null;var F=this.getEl();if(E=="scroll"){G=[F.scrollLeft,F.scrollTop];}else{G=C.getAttribute.call(this,E);}return G;};A.setAttribute=function(E,H,G){var F=this.getEl();if(E=="scroll"){F.scrollLeft=H[0];F.scrollTop=H[1];}else{C.setAttribute.call(this,E,H,G);}};B.Scroll=D;})();YAHOO.register("animation",YAHOO.util.Anim,{version:"2.5.2",build:"1076"});if(!YAHOO.util.DragDropMgr){YAHOO.util.DragDropMgr=function(){var A=YAHOO.util.Event;return{ids:{},handleIds:{},dragCurrent:null,dragOvers:{},deltaX:0,deltaY:0,preventDefault:true,stopPropagation:true,initialized:false,locked:false,interactionInfo:null,init:function(){this.initialized=true;},POINT:0,INTERSECT:1,STRICT_INTERSECT:2,mode:0,_execOnAll:function(D,C){for(var E in this.ids){for(var B in this.ids[E]){var F=this.ids[E][B];if(!this.isTypeOfDD(F)){continue;}F[D].apply(F,C);}}},_onLoad:function(){this.init();A.on(document,"mouseup",this.handleMouseUp,this,true);A.on(document,"mousemove",this.handleMouseMove,this,true);A.on(window,"unload",this._onUnload,this,true);A.on(window,"resize",this._onResize,this,true);},_onResize:function(B){this._execOnAll("resetConstraints",[]);},lock:function(){this.locked=true;},unlock:function(){this.locked=false;},isLocked:function(){return this.locked;},locationCache:{},useCache:true,clickPixelThresh:3,clickTimeThresh:1000,dragThreshMet:false,clickTimeout:null,startX:0,startY:0,fromTimeout:false,regDragDrop:function(C,B){if(!this.initialized){this.init();}if(!this.ids[B]){this.ids[B]={};}this.ids[B][C.id]=C;},removeDDFromGroup:function(D,B){if(!this.ids[B]){this.ids[B]={};}var C=this.ids[B];if(C&&C[D.id]){delete C[D.id];}},_remove:function(C){for(var B in C.groups){if(B&&this.ids[B][C.id]){delete this.ids[B][C.id];}}delete this.handleIds[C.id];},regHandle:function(C,B){if(!this.handleIds[C]){this.handleIds[C]={};}this.handleIds[C][B]=B;},isDragDrop:function(B){return(this.getDDById(B))?true:false;},getRelated:function(G,C){var F=[];for(var E in G.groups){for(var D in this.ids[E]){var B=this.ids[E][D];if(!this.isTypeOfDD(B)){continue;}if(!C||B.isTarget){F[F.length]=B;}}}return F;},isLegalTarget:function(F,E){var C=this.getRelated(F,true);for(var D=0,B=C.length;D<B;++D){if(C[D].id==E.id){return true;}}return false;},isTypeOfDD:function(B){return(B&&B.__ygDragDrop);},isHandle:function(C,B){return(this.handleIds[C]&&this.handleIds[C][B]);},getDDById:function(C){for(var B in this.ids){if(this.ids[B][C]){return this.ids[B][C];}}return null;},handleMouseDown:function(D,C){this.currentTarget=YAHOO.util.Event.getTarget(D);this.dragCurrent=C;var B=C.getEl();this.startX=YAHOO.util.Event.getPageX(D);this.startY=YAHOO.util.Event.getPageY(D);this.deltaX=this.startX-B.offsetLeft;this.deltaY=this.startY-B.offsetTop;this.dragThreshMet=false;this.clickTimeout=setTimeout(function(){var E=YAHOO.util.DDM;E.startDrag(E.startX,E.startY);E.fromTimeout=true;},this.clickTimeThresh);},startDrag:function(B,D){clearTimeout(this.clickTimeout);var C=this.dragCurrent;if(C&&C.events.b4StartDrag){C.b4StartDrag(B,D);C.fireEvent("b4StartDragEvent",{x:B,y:D});}if(C&&C.events.startDrag){C.startDrag(B,D);C.fireEvent("startDragEvent",{x:B,y:D});}this.dragThreshMet=true;},handleMouseUp:function(B){if(this.dragCurrent){clearTimeout(this.clickTimeout);if(this.dragThreshMet){if(this.fromTimeout){this.fromTimeout=false;this.handleMouseMove(B);}this.fromTimeout=false;this.fireEvents(B,true);}else{}this.stopDrag(B);this.stopEvent(B);}},stopEvent:function(B){if(this.stopPropagation){YAHOO.util.Event.stopPropagation(B);}if(this.preventDefault){YAHOO.util.Event.preventDefault(B);}},stopDrag:function(D,C){var B=this.dragCurrent;if(B&&!C){if(this.dragThreshMet){if(B.events.b4EndDrag){B.b4EndDrag(D);B.fireEvent("b4EndDragEvent",{e:D});}if(B.events.endDrag){B.endDrag(D);B.fireEvent("endDragEvent",{e:D});}}if(B.events.mouseUp){B.onMouseUp(D);B.fireEvent("mouseUpEvent",{e:D});}}this.dragCurrent=null;this.dragOvers={};},handleMouseMove:function(E){var B=this.dragCurrent;if(B){if(YAHOO.util.Event.isIE&&!E.button){this.stopEvent(E);return this.handleMouseUp(E);}else{if(E.clientX<0||E.clientY<0){}}if(!this.dragThreshMet){var D=Math.abs(this.startX-YAHOO.util.Event.getPageX(E));var C=Math.abs(this.startY-YAHOO.util.Event.getPageY(E));if(D>this.clickPixelThresh||C>this.clickPixelThresh){this.startDrag(this.startX,this.startY);}}if(this.dragThreshMet){if(B&&B.events.b4Drag){B.b4Drag(E);B.fireEvent("b4DragEvent",{e:E});}if(B&&B.events.drag){B.onDrag(E);B.fireEvent("dragEvent",{e:E});}if(B){this.fireEvents(E,false);}}this.stopEvent(E);}},fireEvents:function(U,K){var Z=this.dragCurrent;if(!Z||Z.isLocked()||Z.dragOnly){return ;}var M=YAHOO.util.Event.getPageX(U),L=YAHOO.util.Event.getPageY(U),O=new YAHOO.util.Point(M,L),J=Z.getTargetCoord(O.x,O.y),E=Z.getDragEl(),D=["out","over","drop","enter"],T=new YAHOO.util.Region(J.y,J.x+E.offsetWidth,J.y+E.offsetHeight,J.x),H=[],C={},P=[],a={outEvts:[],overEvts:[],dropEvts:[],enterEvts:[]};for(var R in this.dragOvers){var c=this.dragOvers[R];if(!this.isTypeOfDD(c)){continue;}if(!this.isOverTarget(O,c,this.mode,T)){a.outEvts.push(c);}H[R]=true;delete this.dragOvers[R];}for(var Q in Z.groups){if("string"!=typeof Q){continue;}for(R in this.ids[Q]){var F=this.ids[Q][R];if(!this.isTypeOfDD(F)){continue;}if(F.isTarget&&!F.isLocked()&&F!=Z){if(this.isOverTarget(O,F,this.mode,T)){C[Q]=true;if(K){a.dropEvts.push(F);}else{if(!H[F.id]){a.enterEvts.push(F);}else{a.overEvts.push(F);}this.dragOvers[F.id]=F;}}}}}this.interactionInfo={out:a.outEvts,enter:a.enterEvts,over:a.overEvts,drop:a.dropEvts,point:O,draggedRegion:T,sourceRegion:this.locationCache[Z.id],validDrop:K};for(var B in C){P.push(B);}if(K&&!a.dropEvts.length){this.interactionInfo.validDrop=false;if(Z.events.invalidDrop){Z.onInvalidDrop(U);Z.fireEvent("invalidDropEvent",{e:U});}}for(R=0;R<D.length;R++){var X=null;if(a[D[R]+"Evts"]){X=a[D[R]+"Evts"];}if(X&&X.length){var G=D[R].charAt(0).toUpperCase()+D[R].substr(1),W="onDrag"+G,I="b4Drag"+G,N="drag"+G+"Event",V="drag"+G;if(this.mode){if(Z.events[I]){Z[I](U,X,P);Z.fireEvent(I+"Event",{event:U,info:X,group:P});}if(Z.events[V]){Z[W](U,X,P);Z.fireEvent(N,{event:U,info:X,group:P});}}else{for(var Y=0,S=X.length;Y<S;++Y){if(Z.events[I]){Z[I](U,X[Y].id,P[0]);Z.fireEvent(I+"Event",{event:U,info:X[Y].id,group:P[0]});}if(Z.events[V]){Z[W](U,X[Y].id,P[0]);Z.fireEvent(N,{event:U,info:X[Y].id,group:P[0]}); +}}}}}},getBestMatch:function(D){var F=null;var C=D.length;if(C==1){F=D[0];}else{for(var E=0;E<C;++E){var B=D[E];if(this.mode==this.INTERSECT&&B.cursorIsOver){F=B;break;}else{if(!F||!F.overlap||(B.overlap&&F.overlap.getArea()<B.overlap.getArea())){F=B;}}}}return F;},refreshCache:function(C){var E=C||this.ids;for(var B in E){if("string"!=typeof B){continue;}for(var D in this.ids[B]){var F=this.ids[B][D];if(this.isTypeOfDD(F)){var G=this.getLocation(F);if(G){this.locationCache[F.id]=G;}else{delete this.locationCache[F.id];}}}}},verifyEl:function(C){try{if(C){var B=C.offsetParent;if(B){return true;}}}catch(D){}return false;},getLocation:function(G){if(!this.isTypeOfDD(G)){return null;}var E=G.getEl(),J,D,C,L,K,M,B,I,F;try{J=YAHOO.util.Dom.getXY(E);}catch(H){}if(!J){return null;}D=J[0];C=D+E.offsetWidth;L=J[1];K=L+E.offsetHeight;M=L-G.padding[0];B=C+G.padding[1];I=K+G.padding[2];F=D-G.padding[3];return new YAHOO.util.Region(M,B,I,F);},isOverTarget:function(J,B,D,E){var F=this.locationCache[B.id];if(!F||!this.useCache){F=this.getLocation(B);this.locationCache[B.id]=F;}if(!F){return false;}B.cursorIsOver=F.contains(J);var I=this.dragCurrent;if(!I||(!D&&!I.constrainX&&!I.constrainY)){return B.cursorIsOver;}B.overlap=null;if(!E){var G=I.getTargetCoord(J.x,J.y);var C=I.getDragEl();E=new YAHOO.util.Region(G.y,G.x+C.offsetWidth,G.y+C.offsetHeight,G.x);}var H=E.intersect(F);if(H){B.overlap=H;return(D)?true:B.cursorIsOver;}else{return false;}},_onUnload:function(C,B){this.unregAll();},unregAll:function(){if(this.dragCurrent){this.stopDrag();this.dragCurrent=null;}this._execOnAll("unreg",[]);this.ids={};},elementCache:{},getElWrapper:function(C){var B=this.elementCache[C];if(!B||!B.el){B=this.elementCache[C]=new this.ElementWrapper(YAHOO.util.Dom.get(C));}return B;},getElement:function(B){return YAHOO.util.Dom.get(B);},getCss:function(C){var B=YAHOO.util.Dom.get(C);return(B)?B.style:null;},ElementWrapper:function(B){this.el=B||null;this.id=this.el&&B.id;this.css=this.el&&B.style;},getPosX:function(B){return YAHOO.util.Dom.getX(B);},getPosY:function(B){return YAHOO.util.Dom.getY(B);},swapNode:function(D,B){if(D.swapNode){D.swapNode(B);}else{var E=B.parentNode;var C=B.nextSibling;if(C==D){E.insertBefore(D,B);}else{if(B==D.nextSibling){E.insertBefore(B,D);}else{D.parentNode.replaceChild(B,D);E.insertBefore(D,C);}}}},getScroll:function(){var D,B,E=document.documentElement,C=document.body;if(E&&(E.scrollTop||E.scrollLeft)){D=E.scrollTop;B=E.scrollLeft;}else{if(C){D=C.scrollTop;B=C.scrollLeft;}else{}}return{top:D,left:B};},getStyle:function(C,B){return YAHOO.util.Dom.getStyle(C,B);},getScrollTop:function(){return this.getScroll().top;},getScrollLeft:function(){return this.getScroll().left;},moveToEl:function(B,D){var C=YAHOO.util.Dom.getXY(D);YAHOO.util.Dom.setXY(B,C);},getClientHeight:function(){return YAHOO.util.Dom.getViewportHeight();},getClientWidth:function(){return YAHOO.util.Dom.getViewportWidth();},numericSort:function(C,B){return(C-B);},_timeoutCount:0,_addListeners:function(){var B=YAHOO.util.DDM;if(YAHOO.util.Event&&document){B._onLoad();}else{if(B._timeoutCount>2000){}else{setTimeout(B._addListeners,10);if(document&&document.body){B._timeoutCount+=1;}}}},handleWasClicked:function(B,D){if(this.isHandle(D,B.id)){return true;}else{var C=B.parentNode;while(C){if(this.isHandle(D,C.id)){return true;}else{C=C.parentNode;}}}return false;}};}();YAHOO.util.DDM=YAHOO.util.DragDropMgr;YAHOO.util.DDM._addListeners();}(function(){var A=YAHOO.util.Event;var B=YAHOO.util.Dom;YAHOO.util.DragDrop=function(E,C,D){if(E){this.init(E,C,D);}};YAHOO.util.DragDrop.prototype={events:null,on:function(){this.subscribe.apply(this,arguments);},id:null,config:null,dragElId:null,handleElId:null,invalidHandleTypes:null,invalidHandleIds:null,invalidHandleClasses:null,startPageX:0,startPageY:0,groups:null,locked:false,lock:function(){this.locked=true;},unlock:function(){this.locked=false;},isTarget:true,padding:null,dragOnly:false,_domRef:null,__ygDragDrop:true,constrainX:false,constrainY:false,minX:0,maxX:0,minY:0,maxY:0,deltaX:0,deltaY:0,maintainOffset:false,xTicks:null,yTicks:null,primaryButtonOnly:true,available:false,hasOuterHandles:false,cursorIsOver:false,overlap:null,b4StartDrag:function(C,D){},startDrag:function(C,D){},b4Drag:function(C){},onDrag:function(C){},onDragEnter:function(C,D){},b4DragOver:function(C){},onDragOver:function(C,D){},b4DragOut:function(C){},onDragOut:function(C,D){},b4DragDrop:function(C){},onDragDrop:function(C,D){},onInvalidDrop:function(C){},b4EndDrag:function(C){},endDrag:function(C){},b4MouseDown:function(C){},onMouseDown:function(C){},onMouseUp:function(C){},onAvailable:function(){},getEl:function(){if(!this._domRef){this._domRef=B.get(this.id);}return this._domRef;},getDragEl:function(){return B.get(this.dragElId);},init:function(F,C,D){this.initTarget(F,C,D);A.on(this._domRef||this.id,"mousedown",this.handleMouseDown,this,true);for(var E in this.events){this.createEvent(E+"Event");}},initTarget:function(E,C,D){this.config=D||{};this.events={};this.DDM=YAHOO.util.DDM;this.groups={};if(typeof E!=="string"){this._domRef=E;E=B.generateId(E);}this.id=E;this.addToGroup((C)?C:"default");this.handleElId=E;A.onAvailable(E,this.handleOnAvailable,this,true);this.setDragElId(E);this.invalidHandleTypes={A:"A"};this.invalidHandleIds={};this.invalidHandleClasses=[];this.applyConfig();},applyConfig:function(){this.events={mouseDown:true,b4MouseDown:true,mouseUp:true,b4StartDrag:true,startDrag:true,b4EndDrag:true,endDrag:true,drag:true,b4Drag:true,invalidDrop:true,b4DragOut:true,dragOut:true,dragEnter:true,b4DragOver:true,dragOver:true,b4DragDrop:true,dragDrop:true};if(this.config.events){for(var C in this.config.events){if(this.config.events[C]===false){this.events[C]=false;}}}this.padding=this.config.padding||[0,0,0,0];this.isTarget=(this.config.isTarget!==false);this.maintainOffset=(this.config.maintainOffset);this.primaryButtonOnly=(this.config.primaryButtonOnly!==false);this.dragOnly=((this.config.dragOnly===true)?true:false); +},handleOnAvailable:function(){this.available=true;this.resetConstraints();this.onAvailable();},setPadding:function(E,C,F,D){if(!C&&0!==C){this.padding=[E,E,E,E];}else{if(!F&&0!==F){this.padding=[E,C,E,C];}else{this.padding=[E,C,F,D];}}},setInitPosition:function(F,E){var G=this.getEl();if(!this.DDM.verifyEl(G)){if(G&&G.style&&(G.style.display=="none")){}else{}return ;}var D=F||0;var C=E||0;var H=B.getXY(G);this.initPageX=H[0]-D;this.initPageY=H[1]-C;this.lastPageX=H[0];this.lastPageY=H[1];this.setStartPosition(H);},setStartPosition:function(D){var C=D||B.getXY(this.getEl());this.deltaSetXY=null;this.startPageX=C[0];this.startPageY=C[1];},addToGroup:function(C){this.groups[C]=true;this.DDM.regDragDrop(this,C);},removeFromGroup:function(C){if(this.groups[C]){delete this.groups[C];}this.DDM.removeDDFromGroup(this,C);},setDragElId:function(C){this.dragElId=C;},setHandleElId:function(C){if(typeof C!=="string"){C=B.generateId(C);}this.handleElId=C;this.DDM.regHandle(this.id,C);},setOuterHandleElId:function(C){if(typeof C!=="string"){C=B.generateId(C);}A.on(C,"mousedown",this.handleMouseDown,this,true);this.setHandleElId(C);this.hasOuterHandles=true;},unreg:function(){A.removeListener(this.id,"mousedown",this.handleMouseDown);this._domRef=null;this.DDM._remove(this);},isLocked:function(){return(this.DDM.isLocked()||this.locked);},handleMouseDown:function(H,G){var D=H.which||H.button;if(this.primaryButtonOnly&&D>1){return ;}if(this.isLocked()){return ;}var C=this.b4MouseDown(H);if(this.events.b4MouseDown){C=this.fireEvent("b4MouseDownEvent",H);}var E=this.onMouseDown(H);if(this.events.mouseDown){E=this.fireEvent("mouseDownEvent",H);}if((C===false)||(E===false)){return ;}this.DDM.refreshCache(this.groups);var F=new YAHOO.util.Point(A.getPageX(H),A.getPageY(H));if(!this.hasOuterHandles&&!this.DDM.isOverTarget(F,this)){}else{if(this.clickValidator(H)){this.setStartPosition();this.DDM.handleMouseDown(H,this);this.DDM.stopEvent(H);}else{}}},clickValidator:function(D){var C=YAHOO.util.Event.getTarget(D);return(this.isValidHandleChild(C)&&(this.id==this.handleElId||this.DDM.handleWasClicked(C,this.id)));},getTargetCoord:function(E,D){var C=E-this.deltaX;var F=D-this.deltaY;if(this.constrainX){if(C<this.minX){C=this.minX;}if(C>this.maxX){C=this.maxX;}}if(this.constrainY){if(F<this.minY){F=this.minY;}if(F>this.maxY){F=this.maxY;}}C=this.getTick(C,this.xTicks);F=this.getTick(F,this.yTicks);return{x:C,y:F};},addInvalidHandleType:function(C){var D=C.toUpperCase();this.invalidHandleTypes[D]=D;},addInvalidHandleId:function(C){if(typeof C!=="string"){C=B.generateId(C);}this.invalidHandleIds[C]=C;},addInvalidHandleClass:function(C){this.invalidHandleClasses.push(C);},removeInvalidHandleType:function(C){var D=C.toUpperCase();delete this.invalidHandleTypes[D];},removeInvalidHandleId:function(C){if(typeof C!=="string"){C=B.generateId(C);}delete this.invalidHandleIds[C];},removeInvalidHandleClass:function(D){for(var E=0,C=this.invalidHandleClasses.length;E<C;++E){if(this.invalidHandleClasses[E]==D){delete this.invalidHandleClasses[E];}}},isValidHandleChild:function(F){var E=true;var H;try{H=F.nodeName.toUpperCase();}catch(G){H=F.nodeName;}E=E&&!this.invalidHandleTypes[H];E=E&&!this.invalidHandleIds[F.id];for(var D=0,C=this.invalidHandleClasses.length;E&&D<C;++D){E=!B.hasClass(F,this.invalidHandleClasses[D]);}return E;},setXTicks:function(F,C){this.xTicks=[];this.xTickSize=C;var E={};for(var D=this.initPageX;D>=this.minX;D=D-C){if(!E[D]){this.xTicks[this.xTicks.length]=D;E[D]=true;}}for(D=this.initPageX;D<=this.maxX;D=D+C){if(!E[D]){this.xTicks[this.xTicks.length]=D;E[D]=true;}}this.xTicks.sort(this.DDM.numericSort);},setYTicks:function(F,C){this.yTicks=[];this.yTickSize=C;var E={};for(var D=this.initPageY;D>=this.minY;D=D-C){if(!E[D]){this.yTicks[this.yTicks.length]=D;E[D]=true;}}for(D=this.initPageY;D<=this.maxY;D=D+C){if(!E[D]){this.yTicks[this.yTicks.length]=D;E[D]=true;}}this.yTicks.sort(this.DDM.numericSort);},setXConstraint:function(E,D,C){this.leftConstraint=parseInt(E,10);this.rightConstraint=parseInt(D,10);this.minX=this.initPageX-this.leftConstraint;this.maxX=this.initPageX+this.rightConstraint;if(C){this.setXTicks(this.initPageX,C);}this.constrainX=true;},clearConstraints:function(){this.constrainX=false;this.constrainY=false;this.clearTicks();},clearTicks:function(){this.xTicks=null;this.yTicks=null;this.xTickSize=0;this.yTickSize=0;},setYConstraint:function(C,E,D){this.topConstraint=parseInt(C,10);this.bottomConstraint=parseInt(E,10);this.minY=this.initPageY-this.topConstraint;this.maxY=this.initPageY+this.bottomConstraint;if(D){this.setYTicks(this.initPageY,D);}this.constrainY=true;},resetConstraints:function(){if(this.initPageX||this.initPageX===0){var D=(this.maintainOffset)?this.lastPageX-this.initPageX:0;var C=(this.maintainOffset)?this.lastPageY-this.initPageY:0;this.setInitPosition(D,C);}else{this.setInitPosition();}if(this.constrainX){this.setXConstraint(this.leftConstraint,this.rightConstraint,this.xTickSize);}if(this.constrainY){this.setYConstraint(this.topConstraint,this.bottomConstraint,this.yTickSize);}},getTick:function(I,F){if(!F){return I;}else{if(F[0]>=I){return F[0];}else{for(var D=0,C=F.length;D<C;++D){var E=D+1;if(F[E]&&F[E]>=I){var H=I-F[D];var G=F[E]-I;return(G>H)?F[D]:F[E];}}return F[F.length-1];}}},toString:function(){return("DragDrop "+this.id);}};YAHOO.augment(YAHOO.util.DragDrop,YAHOO.util.EventProvider);})();YAHOO.util.DD=function(C,A,B){if(C){this.init(C,A,B);}};YAHOO.extend(YAHOO.util.DD,YAHOO.util.DragDrop,{scroll:true,autoOffset:function(C,B){var A=C-this.startPageX;var D=B-this.startPageY;this.setDelta(A,D);},setDelta:function(B,A){this.deltaX=B;this.deltaY=A;},setDragElPos:function(C,B){var A=this.getDragEl();this.alignElWithMouse(A,C,B);},alignElWithMouse:function(C,G,F){var E=this.getTargetCoord(G,F);if(!this.deltaSetXY){var H=[E.x,E.y];YAHOO.util.Dom.setXY(C,H);var D=parseInt(YAHOO.util.Dom.getStyle(C,"left"),10);var B=parseInt(YAHOO.util.Dom.getStyle(C,"top"),10);this.deltaSetXY=[D-E.x,B-E.y]; +}else{YAHOO.util.Dom.setStyle(C,"left",(E.x+this.deltaSetXY[0])+"px");YAHOO.util.Dom.setStyle(C,"top",(E.y+this.deltaSetXY[1])+"px");}this.cachePosition(E.x,E.y);var A=this;setTimeout(function(){A.autoScroll.call(A,E.x,E.y,C.offsetHeight,C.offsetWidth);},0);},cachePosition:function(B,A){if(B){this.lastPageX=B;this.lastPageY=A;}else{var C=YAHOO.util.Dom.getXY(this.getEl());this.lastPageX=C[0];this.lastPageY=C[1];}},autoScroll:function(J,I,E,K){if(this.scroll){var L=this.DDM.getClientHeight();var B=this.DDM.getClientWidth();var N=this.DDM.getScrollTop();var D=this.DDM.getScrollLeft();var H=E+I;var M=K+J;var G=(L+N-I-this.deltaY);var F=(B+D-J-this.deltaX);var C=40;var A=(document.all)?80:30;if(H>L&&G<C){window.scrollTo(D,N+A);}if(I<N&&N>0&&I-N<C){window.scrollTo(D,N-A);}if(M>B&&F<C){window.scrollTo(D+A,N);}if(J<D&&D>0&&J-D<C){window.scrollTo(D-A,N);}}},applyConfig:function(){YAHOO.util.DD.superclass.applyConfig.call(this);this.scroll=(this.config.scroll!==false);},b4MouseDown:function(A){this.setStartPosition();this.autoOffset(YAHOO.util.Event.getPageX(A),YAHOO.util.Event.getPageY(A));},b4Drag:function(A){this.setDragElPos(YAHOO.util.Event.getPageX(A),YAHOO.util.Event.getPageY(A));},toString:function(){return("DD "+this.id);}});YAHOO.util.DDProxy=function(C,A,B){if(C){this.init(C,A,B);this.initFrame();}};YAHOO.util.DDProxy.dragElId="ygddfdiv";YAHOO.extend(YAHOO.util.DDProxy,YAHOO.util.DD,{resizeFrame:true,centerFrame:false,createFrame:function(){var B=this,A=document.body;if(!A||!A.firstChild){setTimeout(function(){B.createFrame();},50);return ;}var G=this.getDragEl(),E=YAHOO.util.Dom;if(!G){G=document.createElement("div");G.id=this.dragElId;var D=G.style;D.position="absolute";D.visibility="hidden";D.cursor="move";D.border="2px solid #aaa";D.zIndex=999;D.height="25px";D.width="25px";var C=document.createElement("div");E.setStyle(C,"height","100%");E.setStyle(C,"width","100%");E.setStyle(C,"background-color","#ccc");E.setStyle(C,"opacity","0");G.appendChild(C);if(YAHOO.env.ua.ie){var F=document.createElement("iframe");F.setAttribute("src","javascript:");F.setAttribute("scrolling","no");F.setAttribute("frameborder","0");G.insertBefore(F,G.firstChild);E.setStyle(F,"height","100%");E.setStyle(F,"width","100%");E.setStyle(F,"position","absolute");E.setStyle(F,"top","0");E.setStyle(F,"left","0");E.setStyle(F,"opacity","0");E.setStyle(F,"zIndex","-1");E.setStyle(F.nextSibling,"zIndex","2");}A.insertBefore(G,A.firstChild);}},initFrame:function(){this.createFrame();},applyConfig:function(){YAHOO.util.DDProxy.superclass.applyConfig.call(this);this.resizeFrame=(this.config.resizeFrame!==false);this.centerFrame=(this.config.centerFrame);this.setDragElId(this.config.dragElId||YAHOO.util.DDProxy.dragElId);},showFrame:function(E,D){var C=this.getEl();var A=this.getDragEl();var B=A.style;this._resizeProxy();if(this.centerFrame){this.setDelta(Math.round(parseInt(B.width,10)/2),Math.round(parseInt(B.height,10)/2));}this.setDragElPos(E,D);YAHOO.util.Dom.setStyle(A,"visibility","visible");},_resizeProxy:function(){if(this.resizeFrame){var H=YAHOO.util.Dom;var B=this.getEl();var C=this.getDragEl();var G=parseInt(H.getStyle(C,"borderTopWidth"),10);var I=parseInt(H.getStyle(C,"borderRightWidth"),10);var F=parseInt(H.getStyle(C,"borderBottomWidth"),10);var D=parseInt(H.getStyle(C,"borderLeftWidth"),10);if(isNaN(G)){G=0;}if(isNaN(I)){I=0;}if(isNaN(F)){F=0;}if(isNaN(D)){D=0;}var E=Math.max(0,B.offsetWidth-I-D);var A=Math.max(0,B.offsetHeight-G-F);H.setStyle(C,"width",E+"px");H.setStyle(C,"height",A+"px");}},b4MouseDown:function(B){this.setStartPosition();var A=YAHOO.util.Event.getPageX(B);var C=YAHOO.util.Event.getPageY(B);this.autoOffset(A,C);},b4StartDrag:function(A,B){this.showFrame(A,B);},b4EndDrag:function(A){YAHOO.util.Dom.setStyle(this.getDragEl(),"visibility","hidden");},endDrag:function(D){var C=YAHOO.util.Dom;var B=this.getEl();var A=this.getDragEl();C.setStyle(A,"visibility","");C.setStyle(B,"visibility","hidden");YAHOO.util.DDM.moveToEl(B,A);C.setStyle(A,"visibility","hidden");C.setStyle(B,"visibility","");},toString:function(){return("DDProxy "+this.id);}});YAHOO.util.DDTarget=function(C,A,B){if(C){this.initTarget(C,A,B);}};YAHOO.extend(YAHOO.util.DDTarget,YAHOO.util.DragDrop,{toString:function(){return("DDTarget "+this.id);}});YAHOO.register("dragdrop",YAHOO.util.DragDropMgr,{version:"2.5.2",build:"1076"});YAHOO.util.Attribute=function(B,A){if(A){this.owner=A;this.configure(B,true);}};YAHOO.util.Attribute.prototype={name:undefined,value:null,owner:null,readOnly:false,writeOnce:false,_initialConfig:null,_written:false,method:null,validator:null,getValue:function(){return this.value;},setValue:function(F,B){var E;var A=this.owner;var C=this.name;var D={type:C,prevValue:this.getValue(),newValue:F};if(this.readOnly||(this.writeOnce&&this._written)){return false;}if(this.validator&&!this.validator.call(A,F)){return false;}if(!B){E=A.fireBeforeChangeEvent(D);if(E===false){return false;}}if(this.method){this.method.call(A,F);}this.value=F;this._written=true;D.type=C;if(!B){this.owner.fireChangeEvent(D);}return true;},configure:function(B,C){B=B||{};this._written=false;this._initialConfig=this._initialConfig||{};for(var A in B){if(A&&YAHOO.lang.hasOwnProperty(B,A)){this[A]=B[A];if(C){this._initialConfig[A]=B[A];}}}},resetValue:function(){return this.setValue(this._initialConfig.value);},resetConfig:function(){this.configure(this._initialConfig);},refresh:function(A){this.setValue(this.value,A);}};(function(){var A=YAHOO.util.Lang;YAHOO.util.AttributeProvider=function(){};YAHOO.util.AttributeProvider.prototype={_configs:null,get:function(C){this._configs=this._configs||{};var B=this._configs[C];if(!B){return undefined;}return B.value;},set:function(D,E,B){this._configs=this._configs||{};var C=this._configs[D];if(!C){return false;}return C.setValue(E,B);},getAttributeKeys:function(){this._configs=this._configs;var D=[];var B;for(var C in this._configs){B=this._configs[C];if(A.hasOwnProperty(this._configs,C)&&!A.isUndefined(B)){D[D.length]=C;}}return D;},setAttributes:function(D,B){for(var C in D){if(A.hasOwnProperty(D,C)){this.set(C,D[C],B);}}},resetValue:function(C,B){this._configs=this._configs||{};if(this._configs[C]){this.set(C,this._configs[C]._initialConfig.value,B);return true;}return false;},refresh:function(E,C){this._configs=this._configs;E=((A.isString(E))?[E]:E)||this.getAttributeKeys();for(var D=0,B=E.length;D<B;++D){if(this._configs[E[D]]&&!A.isUndefined(this._configs[E[D]].value)&&!A.isNull(this._configs[E[D]].value)){this._configs[E[D]].refresh(C);}}},register:function(B,C){this.setAttributeConfig(B,C);},getAttributeConfig:function(C){this._configs=this._configs||{};var B=this._configs[C]||{};var D={};for(C in B){if(A.hasOwnProperty(B,C)){D[C]=B[C];}}return D;},setAttributeConfig:function(B,C,D){this._configs=this._configs||{};C=C||{};if(!this._configs[B]){C.name=B;this._configs[B]=this.createAttribute(C);}else{this._configs[B].configure(C,D);}},configureAttribute:function(B,C,D){this.setAttributeConfig(B,C,D);},resetAttributeConfig:function(B){this._configs=this._configs||{};this._configs[B].resetConfig();},subscribe:function(B,C){this._events=this._events||{};if(!(B in this._events)){this._events[B]=this.createEvent(B);}YAHOO.util.EventProvider.prototype.subscribe.apply(this,arguments);},on:function(){this.subscribe.apply(this,arguments);},addListener:function(){this.subscribe.apply(this,arguments);},fireBeforeChangeEvent:function(C){var B="before";B+=C.type.charAt(0).toUpperCase()+C.type.substr(1)+"Change";C.type=B;return this.fireEvent(C.type,C);},fireChangeEvent:function(B){B.type+="Change";return this.fireEvent(B.type,B);},createAttribute:function(B){return new YAHOO.util.Attribute(B,this);}};YAHOO.augment(YAHOO.util.AttributeProvider,YAHOO.util.EventProvider);})();(function(){var D=YAHOO.util.Dom,F=YAHOO.util.AttributeProvider;YAHOO.util.Element=function(G,H){if(arguments.length){this.init(G,H);}};YAHOO.util.Element.prototype={DOM_EVENTS:null,appendChild:function(G){G=G.get?G.get("element"):G;this.get("element").appendChild(G);},getElementsByTagName:function(G){return this.get("element").getElementsByTagName(G);},hasChildNodes:function(){return this.get("element").hasChildNodes();},insertBefore:function(G,H){G=G.get?G.get("element"):G;H=(H&&H.get)?H.get("element"):H;this.get("element").insertBefore(G,H);},removeChild:function(G){G=G.get?G.get("element"):G;this.get("element").removeChild(G);return true;},replaceChild:function(G,H){G=G.get?G.get("element"):G;H=H.get?H.get("element"):H;return this.get("element").replaceChild(G,H);},initAttributes:function(G){},addListener:function(K,J,L,I){var H=this.get("element");I=I||this;H=this.get("id")||H;var G=this;if(!this._events[K]){if(this.DOM_EVENTS[K]){YAHOO.util.Event.addListener(H,K,function(M){if(M.srcElement&&!M.target){M.target=M.srcElement;}G.fireEvent(K,M);},L,I);}this.createEvent(K,this);}YAHOO.util.EventProvider.prototype.subscribe.apply(this,arguments);},on:function(){this.addListener.apply(this,arguments);},subscribe:function(){this.addListener.apply(this,arguments);},removeListener:function(H,G){this.unsubscribe.apply(this,arguments);},addClass:function(G){D.addClass(this.get("element"),G);},getElementsByClassName:function(H,G){return D.getElementsByClassName(H,G,this.get("element"));},hasClass:function(G){return D.hasClass(this.get("element"),G);},removeClass:function(G){return D.removeClass(this.get("element"),G);},replaceClass:function(H,G){return D.replaceClass(this.get("element"),H,G);},setStyle:function(I,H){var G=this.get("element");if(!G){return this._queue[this._queue.length]=["setStyle",arguments];}return D.setStyle(G,I,H);},getStyle:function(G){return D.getStyle(this.get("element"),G);},fireQueue:function(){var H=this._queue;for(var I=0,G=H.length;I<G;++I){this[H[I][0]].apply(this,H[I][1]);}},appendTo:function(H,I){H=(H.get)?H.get("element"):D.get(H);this.fireEvent("beforeAppendTo",{type:"beforeAppendTo",target:H});I=(I&&I.get)?I.get("element"):D.get(I);var G=this.get("element");if(!G){return false;}if(!H){return false;}if(G.parent!=H){if(I){H.insertBefore(G,I);}else{H.appendChild(G);}}this.fireEvent("appendTo",{type:"appendTo",target:H});},get:function(G){var I=this._configs||{};var H=I.element;if(H&&!I[G]&&!YAHOO.lang.isUndefined(H.value[G])){return H.value[G];}return F.prototype.get.call(this,G);},setAttributes:function(L,H){var K=this.get("element"); +for(var J in L){if(!this._configs[J]&&!YAHOO.lang.isUndefined(K[J])){this.setAttributeConfig(J);}}for(var I=0,G=this._configOrder.length;I<G;++I){if(L[this._configOrder[I]]!==undefined){this.set(this._configOrder[I],L[this._configOrder[I]],H);}}},set:function(H,J,G){var I=this.get("element");if(!I){this._queue[this._queue.length]=["set",arguments];if(this._configs[H]){this._configs[H].value=J;}return ;}if(!this._configs[H]&&!YAHOO.lang.isUndefined(I[H])){C.call(this,H);}return F.prototype.set.apply(this,arguments);},setAttributeConfig:function(G,I,J){var H=this.get("element");if(H&&!this._configs[G]&&!YAHOO.lang.isUndefined(H[G])){C.call(this,G,I);}else{F.prototype.setAttributeConfig.apply(this,arguments);}this._configOrder.push(G);},getAttributeKeys:function(){var H=this.get("element");var I=F.prototype.getAttributeKeys.call(this);for(var G in H){if(!this._configs[G]){I[G]=I[G]||H[G];}}return I;},createEvent:function(H,G){this._events[H]=true;F.prototype.createEvent.apply(this,arguments);},init:function(H,G){A.apply(this,arguments);}};var A=function(H,G){this._queue=this._queue||[];this._events=this._events||{};this._configs=this._configs||{};this._configOrder=[];G=G||{};G.element=G.element||H||null;this.DOM_EVENTS={"click":true,"dblclick":true,"keydown":true,"keypress":true,"keyup":true,"mousedown":true,"mousemove":true,"mouseout":true,"mouseover":true,"mouseup":true,"focus":true,"blur":true,"submit":true};var I=false;if(YAHOO.lang.isString(H)){C.call(this,"id",{value:G.element});}if(D.get(H)){I=true;E.call(this,G);B.call(this,G);}YAHOO.util.Event.onAvailable(G.element,function(){if(!I){E.call(this,G);}this.fireEvent("available",{type:"available",target:G.element});},this,true);YAHOO.util.Event.onContentReady(G.element,function(){if(!I){B.call(this,G);}this.fireEvent("contentReady",{type:"contentReady",target:G.element});},this,true);};var E=function(G){this.setAttributeConfig("element",{value:D.get(G.element),readOnly:true});};var B=function(G){this.initAttributes(G);this.setAttributes(G,true);this.fireQueue();};var C=function(G,I){var H=this.get("element");I=I||{};I.name=G;I.method=I.method||function(J){H[G]=J;};I.value=I.value||H[G];this._configs[G]=new YAHOO.util.Attribute(I,this);};YAHOO.augment(YAHOO.util.Element,F);})();YAHOO.register("element",YAHOO.util.Element,{version:"2.5.2",build:"1076"});YAHOO.register("utilities", YAHOO, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/yahoo-dom-event.js b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/yahoo-dom-event.js new file mode 100644 index 0000000..7b667e0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/js/yui/yahoo-dom-event.js
@@ -0,0 +1,12 @@ +/* +Copyright (c) 2008, Yahoo! Inc. All rights reserved. +Code licensed under the BSD License: +http://developer.yahoo.net/yui/license.txt +version: 2.5.2 +*/ +if(typeof YAHOO=="undefined"||!YAHOO){var YAHOO={};}YAHOO.namespace=function(){var A=arguments,E=null,C,B,D;for(C=0;C<A.length;C=C+1){D=A[C].split(".");E=YAHOO;for(B=(D[0]=="YAHOO")?1:0;B<D.length;B=B+1){E[D[B]]=E[D[B]]||{};E=E[D[B]];}}return E;};YAHOO.log=function(D,A,C){var B=YAHOO.widget.Logger;if(B&&B.log){return B.log(D,A,C);}else{return false;}};YAHOO.register=function(A,E,D){var I=YAHOO.env.modules;if(!I[A]){I[A]={versions:[],builds:[]};}var B=I[A],H=D.version,G=D.build,F=YAHOO.env.listeners;B.name=A;B.version=H;B.build=G;B.versions.push(H);B.builds.push(G);B.mainClass=E;for(var C=0;C<F.length;C=C+1){F[C](B);}if(E){E.VERSION=H;E.BUILD=G;}else{YAHOO.log("mainClass is undefined for module "+A,"warn");}};YAHOO.env=YAHOO.env||{modules:[],listeners:[]};YAHOO.env.getVersion=function(A){return YAHOO.env.modules[A]||null;};YAHOO.env.ua=function(){var C={ie:0,opera:0,gecko:0,webkit:0,mobile:null,air:0};var B=navigator.userAgent,A;if((/KHTML/).test(B)){C.webkit=1;}A=B.match(/AppleWebKit\/([^\s]*)/);if(A&&A[1]){C.webkit=parseFloat(A[1]);if(/ Mobile\//.test(B)){C.mobile="Apple";}else{A=B.match(/NokiaN[^\/]*/);if(A){C.mobile=A[0];}}A=B.match(/AdobeAIR\/([^\s]*)/);if(A){C.air=A[0];}}if(!C.webkit){A=B.match(/Opera[\s\/]([^\s]*)/);if(A&&A[1]){C.opera=parseFloat(A[1]);A=B.match(/Opera Mini[^;]*/);if(A){C.mobile=A[0];}}else{A=B.match(/MSIE\s([^;]*)/);if(A&&A[1]){C.ie=parseFloat(A[1]);}else{A=B.match(/Gecko\/([^\s]*)/);if(A){C.gecko=1;A=B.match(/rv:([^\s\)]*)/);if(A&&A[1]){C.gecko=parseFloat(A[1]);}}}}}return C;}();(function(){YAHOO.namespace("util","widget","example");if("undefined"!==typeof YAHOO_config){var B=YAHOO_config.listener,A=YAHOO.env.listeners,D=true,C;if(B){for(C=0;C<A.length;C=C+1){if(A[C]==B){D=false;break;}}if(D){A.push(B);}}}})();YAHOO.lang=YAHOO.lang||{};(function(){var A=YAHOO.lang,C=["toString","valueOf"],B={isArray:function(D){if(D){return A.isNumber(D.length)&&A.isFunction(D.splice);}return false;},isBoolean:function(D){return typeof D==="boolean";},isFunction:function(D){return typeof D==="function";},isNull:function(D){return D===null;},isNumber:function(D){return typeof D==="number"&&isFinite(D);},isObject:function(D){return(D&&(typeof D==="object"||A.isFunction(D)))||false;},isString:function(D){return typeof D==="string";},isUndefined:function(D){return typeof D==="undefined";},_IEEnumFix:(YAHOO.env.ua.ie)?function(F,E){for(var D=0;D<C.length;D=D+1){var H=C[D],G=E[H];if(A.isFunction(G)&&G!=Object.prototype[H]){F[H]=G;}}}:function(){},extend:function(H,I,G){if(!I||!H){throw new Error("extend failed, please check that "+"all dependencies are included.");}var E=function(){};E.prototype=I.prototype;H.prototype=new E();H.prototype.constructor=H;H.superclass=I.prototype;if(I.prototype.constructor==Object.prototype.constructor){I.prototype.constructor=I;}if(G){for(var D in G){if(A.hasOwnProperty(G,D)){H.prototype[D]=G[D];}}A._IEEnumFix(H.prototype,G);}},augmentObject:function(H,G){if(!G||!H){throw new Error("Absorb failed, verify dependencies.");}var D=arguments,F,I,E=D[2];if(E&&E!==true){for(F=2;F<D.length;F=F+1){H[D[F]]=G[D[F]];}}else{for(I in G){if(E||!(I in H)){H[I]=G[I];}}A._IEEnumFix(H,G);}},augmentProto:function(G,F){if(!F||!G){throw new Error("Augment failed, verify dependencies.");}var D=[G.prototype,F.prototype];for(var E=2;E<arguments.length;E=E+1){D.push(arguments[E]);}A.augmentObject.apply(this,D);},dump:function(D,I){var F,H,K=[],L="{...}",E="f(){...}",J=", ",G=" => ";if(!A.isObject(D)){return D+"";}else{if(D instanceof Date||("nodeType" in D&&"tagName" in D)){return D;}else{if(A.isFunction(D)){return E;}}}I=(A.isNumber(I))?I:3;if(A.isArray(D)){K.push("[");for(F=0,H=D.length;F<H;F=F+1){if(A.isObject(D[F])){K.push((I>0)?A.dump(D[F],I-1):L);}else{K.push(D[F]);}K.push(J);}if(K.length>1){K.pop();}K.push("]");}else{K.push("{");for(F in D){if(A.hasOwnProperty(D,F)){K.push(F+G);if(A.isObject(D[F])){K.push((I>0)?A.dump(D[F],I-1):L);}else{K.push(D[F]);}K.push(J);}}if(K.length>1){K.pop();}K.push("}");}return K.join("");},substitute:function(S,E,L){var I,H,G,O,P,R,N=[],F,J="dump",M=" ",D="{",Q="}";for(;;){I=S.lastIndexOf(D);if(I<0){break;}H=S.indexOf(Q,I);if(I+1>=H){break;}F=S.substring(I+1,H);O=F;R=null;G=O.indexOf(M);if(G>-1){R=O.substring(G+1);O=O.substring(0,G);}P=E[O];if(L){P=L(O,P,R);}if(A.isObject(P)){if(A.isArray(P)){P=A.dump(P,parseInt(R,10));}else{R=R||"";var K=R.indexOf(J);if(K>-1){R=R.substring(4);}if(P.toString===Object.prototype.toString||K>-1){P=A.dump(P,parseInt(R,10));}else{P=P.toString();}}}else{if(!A.isString(P)&&!A.isNumber(P)){P="~-"+N.length+"-~";N[N.length]=F;}}S=S.substring(0,I)+P+S.substring(H+1);}for(I=N.length-1;I>=0;I=I-1){S=S.replace(new RegExp("~-"+I+"-~"),"{"+N[I]+"}","g");}return S;},trim:function(D){try{return D.replace(/^\s+|\s+$/g,"");}catch(E){return D;}},merge:function(){var G={},E=arguments;for(var F=0,D=E.length;F<D;F=F+1){A.augmentObject(G,E[F],true);}return G;},later:function(K,E,L,G,H){K=K||0;E=E||{};var F=L,J=G,I,D;if(A.isString(L)){F=E[L];}if(!F){throw new TypeError("method undefined");}if(!A.isArray(J)){J=[G];}I=function(){F.apply(E,J);};D=(H)?setInterval(I,K):setTimeout(I,K);return{interval:H,cancel:function(){if(this.interval){clearInterval(D);}else{clearTimeout(D);}}};},isValue:function(D){return(A.isObject(D)||A.isString(D)||A.isNumber(D)||A.isBoolean(D));}};A.hasOwnProperty=(Object.prototype.hasOwnProperty)?function(D,E){return D&&D.hasOwnProperty(E);}:function(D,E){return !A.isUndefined(D[E])&&D.constructor.prototype[E]!==D[E];};B.augmentObject(A,B,true);YAHOO.util.Lang=A;A.augment=A.augmentProto;YAHOO.augment=A.augmentProto;YAHOO.extend=A.extend;})();YAHOO.register("yahoo",YAHOO,{version:"2.5.2",build:"1076"});(function(){var B=YAHOO.util,K,I,J={},F={},M=window.document;YAHOO.env._id_counter=YAHOO.env._id_counter||0;var C=YAHOO.env.ua.opera,L=YAHOO.env.ua.webkit,A=YAHOO.env.ua.gecko,G=YAHOO.env.ua.ie;var E={HYPHEN:/(-[a-z])/i,ROOT_TAG:/^body|html$/i,OP_SCROLL:/^(?:inline|table-row)$/i};var N=function(P){if(!E.HYPHEN.test(P)){return P;}if(J[P]){return J[P];}var Q=P;while(E.HYPHEN.exec(Q)){Q=Q.replace(RegExp.$1,RegExp.$1.substr(1).toUpperCase());}J[P]=Q;return Q;};var O=function(Q){var P=F[Q];if(!P){P=new RegExp("(?:^|\\s+)"+Q+"(?:\\s+|$)");F[Q]=P;}return P;};if(M.defaultView&&M.defaultView.getComputedStyle){K=function(P,S){var R=null;if(S=="float"){S="cssFloat";}var Q=P.ownerDocument.defaultView.getComputedStyle(P,"");if(Q){R=Q[N(S)];}return P.style[S]||R;};}else{if(M.documentElement.currentStyle&&G){K=function(P,R){switch(N(R)){case"opacity":var T=100;try{T=P.filters["DXImageTransform.Microsoft.Alpha"].opacity;}catch(S){try{T=P.filters("alpha").opacity;}catch(S){}}return T/100;case"float":R="styleFloat";default:var Q=P.currentStyle?P.currentStyle[R]:null;return(P.style[R]||Q);}};}else{K=function(P,Q){return P.style[Q];};}}if(G){I=function(P,Q,R){switch(Q){case"opacity":if(YAHOO.lang.isString(P.style.filter)){P.style.filter="alpha(opacity="+R*100+")";if(!P.currentStyle||!P.currentStyle.hasLayout){P.style.zoom=1;}}break;case"float":Q="styleFloat";default:P.style[Q]=R;}};}else{I=function(P,Q,R){if(Q=="float"){Q="cssFloat";}P.style[Q]=R;};}var D=function(P,Q){return P&&P.nodeType==1&&(!Q||Q(P));};YAHOO.util.Dom={get:function(R){if(R&&(R.nodeType||R.item)){return R;}if(YAHOO.lang.isString(R)||!R){return M.getElementById(R);}if(R.length!==undefined){var S=[];for(var Q=0,P=R.length;Q<P;++Q){S[S.length]=B.Dom.get(R[Q]);}return S;}return R;},getStyle:function(P,R){R=N(R);var Q=function(S){return K(S,R);};return B.Dom.batch(P,Q,B.Dom,true);},setStyle:function(P,R,S){R=N(R);var Q=function(T){I(T,R,S);};B.Dom.batch(P,Q,B.Dom,true);},getXY:function(P){var Q=function(R){if((R.parentNode===null||R.offsetParent===null||this.getStyle(R,"display")=="none")&&R!=R.ownerDocument.body){return false;}return H(R);};return B.Dom.batch(P,Q,B.Dom,true);},getX:function(P){var Q=function(R){return B.Dom.getXY(R)[0];};return B.Dom.batch(P,Q,B.Dom,true);},getY:function(P){var Q=function(R){return B.Dom.getXY(R)[1];};return B.Dom.batch(P,Q,B.Dom,true);},setXY:function(P,S,R){var Q=function(V){var U=this.getStyle(V,"position");if(U=="static"){this.setStyle(V,"position","relative");U="relative";}var X=this.getXY(V);if(X===false){return false;}var W=[parseInt(this.getStyle(V,"left"),10),parseInt(this.getStyle(V,"top"),10)];if(isNaN(W[0])){W[0]=(U=="relative")?0:V.offsetLeft;}if(isNaN(W[1])){W[1]=(U=="relative")?0:V.offsetTop;}if(S[0]!==null){V.style.left=S[0]-X[0]+W[0]+"px";}if(S[1]!==null){V.style.top=S[1]-X[1]+W[1]+"px";}if(!R){var T=this.getXY(V);if((S[0]!==null&&T[0]!=S[0])||(S[1]!==null&&T[1]!=S[1])){this.setXY(V,S,true);}}};B.Dom.batch(P,Q,B.Dom,true);},setX:function(Q,P){B.Dom.setXY(Q,[P,null]);},setY:function(P,Q){B.Dom.setXY(P,[null,Q]);},getRegion:function(P){var Q=function(R){if((R.parentNode===null||R.offsetParent===null||this.getStyle(R,"display")=="none")&&R!=R.ownerDocument.body){return false;}var S=B.Region.getRegion(R);return S;};return B.Dom.batch(P,Q,B.Dom,true);},getClientWidth:function(){return B.Dom.getViewportWidth();},getClientHeight:function(){return B.Dom.getViewportHeight();},getElementsByClassName:function(T,X,U,V){X=X||"*";U=(U)?B.Dom.get(U):null||M;if(!U){return[];}var Q=[],P=U.getElementsByTagName(X),W=O(T);for(var R=0,S=P.length;R<S;++R){if(W.test(P[R].className)){Q[Q.length]=P[R];if(V){V.call(P[R],P[R]);}}}return Q;},hasClass:function(R,Q){var P=O(Q);var S=function(T){return P.test(T.className);};return B.Dom.batch(R,S,B.Dom,true);},addClass:function(Q,P){var R=function(S){if(this.hasClass(S,P)){return false;}S.className=YAHOO.lang.trim([S.className,P].join(" "));return true;};return B.Dom.batch(Q,R,B.Dom,true);},removeClass:function(R,Q){var P=O(Q);var S=function(T){if(!Q||!this.hasClass(T,Q)){return false;}var U=T.className;T.className=U.replace(P," ");if(this.hasClass(T,Q)){this.removeClass(T,Q);}T.className=YAHOO.lang.trim(T.className);return true;};return B.Dom.batch(R,S,B.Dom,true);},replaceClass:function(S,Q,P){if(!P||Q===P){return false;}var R=O(Q);var T=function(U){if(!this.hasClass(U,Q)){this.addClass(U,P);return true;}U.className=U.className.replace(R," "+P+" ");if(this.hasClass(U,Q)){this.replaceClass(U,Q,P);}U.className=YAHOO.lang.trim(U.className);return true;};return B.Dom.batch(S,T,B.Dom,true);},generateId:function(P,R){R=R||"yui-gen";var Q=function(S){if(S&&S.id){return S.id;}var T=R+YAHOO.env._id_counter++;if(S){S.id=T;}return T;};return B.Dom.batch(P,Q,B.Dom,true)||Q.apply(B.Dom,arguments);},isAncestor:function(P,Q){P=B.Dom.get(P);Q=B.Dom.get(Q);if(!P||!Q){return false;}if(P.contains&&Q.nodeType&&!L){return P.contains(Q);}else{if(P.compareDocumentPosition&&Q.nodeType){return !!(P.compareDocumentPosition(Q)&16);}else{if(Q.nodeType){return !!this.getAncestorBy(Q,function(R){return R==P;});}}}return false;},inDocument:function(P){return this.isAncestor(M.documentElement,P);},getElementsBy:function(W,Q,R,T){Q=Q||"*";R=(R)?B.Dom.get(R):null||M;if(!R){return[];}var S=[],V=R.getElementsByTagName(Q);for(var U=0,P=V.length;U<P;++U){if(W(V[U])){S[S.length]=V[U];if(T){T(V[U]);}}}return S;},batch:function(T,W,V,R){T=(T&&(T.tagName||T.item))?T:B.Dom.get(T);if(!T||!W){return false;}var S=(R)?V:window;if(T.tagName||T.length===undefined){return W.call(S,T,V);}var U=[];for(var Q=0,P=T.length;Q<P;++Q){U[U.length]=W.call(S,T[Q],V);}return U;},getDocumentHeight:function(){var Q=(M.compatMode!="CSS1Compat")?M.body.scrollHeight:M.documentElement.scrollHeight;var P=Math.max(Q,B.Dom.getViewportHeight());return P;},getDocumentWidth:function(){var Q=(M.compatMode!="CSS1Compat")?M.body.scrollWidth:M.documentElement.scrollWidth;var P=Math.max(Q,B.Dom.getViewportWidth());return P;},getViewportHeight:function(){var P=self.innerHeight; +var Q=M.compatMode;if((Q||G)&&!C){P=(Q=="CSS1Compat")?M.documentElement.clientHeight:M.body.clientHeight;}return P;},getViewportWidth:function(){var P=self.innerWidth;var Q=M.compatMode;if(Q||G){P=(Q=="CSS1Compat")?M.documentElement.clientWidth:M.body.clientWidth;}return P;},getAncestorBy:function(P,Q){while(P=P.parentNode){if(D(P,Q)){return P;}}return null;},getAncestorByClassName:function(Q,P){Q=B.Dom.get(Q);if(!Q){return null;}var R=function(S){return B.Dom.hasClass(S,P);};return B.Dom.getAncestorBy(Q,R);},getAncestorByTagName:function(Q,P){Q=B.Dom.get(Q);if(!Q){return null;}var R=function(S){return S.tagName&&S.tagName.toUpperCase()==P.toUpperCase();};return B.Dom.getAncestorBy(Q,R);},getPreviousSiblingBy:function(P,Q){while(P){P=P.previousSibling;if(D(P,Q)){return P;}}return null;},getPreviousSibling:function(P){P=B.Dom.get(P);if(!P){return null;}return B.Dom.getPreviousSiblingBy(P);},getNextSiblingBy:function(P,Q){while(P){P=P.nextSibling;if(D(P,Q)){return P;}}return null;},getNextSibling:function(P){P=B.Dom.get(P);if(!P){return null;}return B.Dom.getNextSiblingBy(P);},getFirstChildBy:function(P,R){var Q=(D(P.firstChild,R))?P.firstChild:null;return Q||B.Dom.getNextSiblingBy(P.firstChild,R);},getFirstChild:function(P,Q){P=B.Dom.get(P);if(!P){return null;}return B.Dom.getFirstChildBy(P);},getLastChildBy:function(P,R){if(!P){return null;}var Q=(D(P.lastChild,R))?P.lastChild:null;return Q||B.Dom.getPreviousSiblingBy(P.lastChild,R);},getLastChild:function(P){P=B.Dom.get(P);return B.Dom.getLastChildBy(P);},getChildrenBy:function(Q,S){var R=B.Dom.getFirstChildBy(Q,S);var P=R?[R]:[];B.Dom.getNextSiblingBy(R,function(T){if(!S||S(T)){P[P.length]=T;}return false;});return P;},getChildren:function(P){P=B.Dom.get(P);if(!P){}return B.Dom.getChildrenBy(P);},getDocumentScrollLeft:function(P){P=P||M;return Math.max(P.documentElement.scrollLeft,P.body.scrollLeft);},getDocumentScrollTop:function(P){P=P||M;return Math.max(P.documentElement.scrollTop,P.body.scrollTop);},insertBefore:function(Q,P){Q=B.Dom.get(Q);P=B.Dom.get(P);if(!Q||!P||!P.parentNode){return null;}return P.parentNode.insertBefore(Q,P);},insertAfter:function(Q,P){Q=B.Dom.get(Q);P=B.Dom.get(P);if(!Q||!P||!P.parentNode){return null;}if(P.nextSibling){return P.parentNode.insertBefore(Q,P.nextSibling);}else{return P.parentNode.appendChild(Q);}},getClientRegion:function(){var R=B.Dom.getDocumentScrollTop(),Q=B.Dom.getDocumentScrollLeft(),S=B.Dom.getViewportWidth()+Q,P=B.Dom.getViewportHeight()+R;return new B.Region(R,S,P,Q);}};var H=function(){if(M.documentElement.getBoundingClientRect){return function(Q){var R=Q.getBoundingClientRect();var P=Q.ownerDocument;return[R.left+B.Dom.getDocumentScrollLeft(P),R.top+B.Dom.getDocumentScrollTop(P)];};}else{return function(R){var S=[R.offsetLeft,R.offsetTop];var Q=R.offsetParent;var P=(L&&B.Dom.getStyle(R,"position")=="absolute"&&R.offsetParent==R.ownerDocument.body);if(Q!=R){while(Q){S[0]+=Q.offsetLeft;S[1]+=Q.offsetTop;if(!P&&L&&B.Dom.getStyle(Q,"position")=="absolute"){P=true;}Q=Q.offsetParent;}}if(P){S[0]-=R.ownerDocument.body.offsetLeft;S[1]-=R.ownerDocument.body.offsetTop;}Q=R.parentNode;while(Q.tagName&&!E.ROOT_TAG.test(Q.tagName)){if(Q.scrollTop||Q.scrollLeft){if(!E.OP_SCROLL.test(B.Dom.getStyle(Q,"display"))){if(!C||B.Dom.getStyle(Q,"overflow")!=="visible"){S[0]-=Q.scrollLeft;S[1]-=Q.scrollTop;}}}Q=Q.parentNode;}return S;};}}();})();YAHOO.util.Region=function(C,D,A,B){this.top=C;this[1]=C;this.right=D;this.bottom=A;this.left=B;this[0]=B;};YAHOO.util.Region.prototype.contains=function(A){return(A.left>=this.left&&A.right<=this.right&&A.top>=this.top&&A.bottom<=this.bottom);};YAHOO.util.Region.prototype.getArea=function(){return((this.bottom-this.top)*(this.right-this.left));};YAHOO.util.Region.prototype.intersect=function(E){var C=Math.max(this.top,E.top);var D=Math.min(this.right,E.right);var A=Math.min(this.bottom,E.bottom);var B=Math.max(this.left,E.left);if(A>=C&&D>=B){return new YAHOO.util.Region(C,D,A,B);}else{return null;}};YAHOO.util.Region.prototype.union=function(E){var C=Math.min(this.top,E.top);var D=Math.max(this.right,E.right);var A=Math.max(this.bottom,E.bottom);var B=Math.min(this.left,E.left);return new YAHOO.util.Region(C,D,A,B);};YAHOO.util.Region.prototype.toString=function(){return("Region {"+"top: "+this.top+", right: "+this.right+", bottom: "+this.bottom+", left: "+this.left+"}");};YAHOO.util.Region.getRegion=function(D){var F=YAHOO.util.Dom.getXY(D);var C=F[1];var E=F[0]+D.offsetWidth;var A=F[1]+D.offsetHeight;var B=F[0];return new YAHOO.util.Region(C,E,A,B);};YAHOO.util.Point=function(A,B){if(YAHOO.lang.isArray(A)){B=A[1];A=A[0];}this.x=this.right=this.left=this[0]=A;this.y=this.top=this.bottom=this[1]=B;};YAHOO.util.Point.prototype=new YAHOO.util.Region();YAHOO.register("dom",YAHOO.util.Dom,{version:"2.5.2",build:"1076"});YAHOO.util.CustomEvent=function(D,B,C,A){this.type=D;this.scope=B||window;this.silent=C;this.signature=A||YAHOO.util.CustomEvent.LIST;this.subscribers=[];if(!this.silent){}var E="_YUICEOnSubscribe";if(D!==E){this.subscribeEvent=new YAHOO.util.CustomEvent(E,this,true);}this.lastError=null;};YAHOO.util.CustomEvent.LIST=0;YAHOO.util.CustomEvent.FLAT=1;YAHOO.util.CustomEvent.prototype={subscribe:function(B,C,A){if(!B){throw new Error("Invalid callback for subscriber to '"+this.type+"'");}if(this.subscribeEvent){this.subscribeEvent.fire(B,C,A);}this.subscribers.push(new YAHOO.util.Subscriber(B,C,A));},unsubscribe:function(D,F){if(!D){return this.unsubscribeAll();}var E=false;for(var B=0,A=this.subscribers.length;B<A;++B){var C=this.subscribers[B];if(C&&C.contains(D,F)){this._delete(B);E=true;}}return E;},fire:function(){this.lastError=null;var K=[],E=this.subscribers.length;if(!E&&this.silent){return true;}var I=[].slice.call(arguments,0),G=true,D,J=false;if(!this.silent){}var C=this.subscribers.slice(),A=YAHOO.util.Event.throwErrors;for(D=0;D<E;++D){var M=C[D];if(!M){J=true;}else{if(!this.silent){}var L=M.getScope(this.scope);if(this.signature==YAHOO.util.CustomEvent.FLAT){var B=null;if(I.length>0){B=I[0];}try{G=M.fn.call(L,B,M.obj);}catch(F){this.lastError=F;if(A){throw F;}}}else{try{G=M.fn.call(L,this.type,I,M.obj);}catch(H){this.lastError=H;if(A){throw H;}}}if(false===G){if(!this.silent){}break;}}}return(G!==false);},unsubscribeAll:function(){for(var A=this.subscribers.length-1;A>-1;A--){this._delete(A);}this.subscribers=[];return A;},_delete:function(A){var B=this.subscribers[A];if(B){delete B.fn;delete B.obj;}this.subscribers.splice(A,1);},toString:function(){return"CustomEvent: "+"'"+this.type+"', "+"scope: "+this.scope;}};YAHOO.util.Subscriber=function(B,C,A){this.fn=B;this.obj=YAHOO.lang.isUndefined(C)?null:C;this.override=A;};YAHOO.util.Subscriber.prototype.getScope=function(A){if(this.override){if(this.override===true){return this.obj;}else{return this.override;}}return A;};YAHOO.util.Subscriber.prototype.contains=function(A,B){if(B){return(this.fn==A&&this.obj==B);}else{return(this.fn==A);}};YAHOO.util.Subscriber.prototype.toString=function(){return"Subscriber { obj: "+this.obj+", override: "+(this.override||"no")+" }";};if(!YAHOO.util.Event){YAHOO.util.Event=function(){var H=false;var I=[];var J=[];var G=[];var E=[];var C=0;var F=[];var B=[];var A=0;var D={63232:38,63233:40,63234:37,63235:39,63276:33,63277:34,25:9};return{POLL_RETRYS:2000,POLL_INTERVAL:20,EL:0,TYPE:1,FN:2,WFN:3,UNLOAD_OBJ:3,ADJ_SCOPE:4,OBJ:5,OVERRIDE:6,lastError:null,isSafari:YAHOO.env.ua.webkit,webkit:YAHOO.env.ua.webkit,isIE:YAHOO.env.ua.ie,_interval:null,_dri:null,DOMReady:false,throwErrors:false,startInterval:function(){if(!this._interval){var K=this;var L=function(){K._tryPreloadAttach();};this._interval=setInterval(L,this.POLL_INTERVAL);}},onAvailable:function(P,M,Q,O,N){var K=(YAHOO.lang.isString(P))?[P]:P;for(var L=0;L<K.length;L=L+1){F.push({id:K[L],fn:M,obj:Q,override:O,checkReady:N});}C=this.POLL_RETRYS;this.startInterval();},onContentReady:function(M,K,N,L){this.onAvailable(M,K,N,L,true);},onDOMReady:function(K,M,L){if(this.DOMReady){setTimeout(function(){var N=window;if(L){if(L===true){N=M;}else{N=L;}}K.call(N,"DOMReady",[],M);},0);}else{this.DOMReadyEvent.subscribe(K,M,L);}},addListener:function(M,K,V,Q,L){if(!V||!V.call){return false;}if(this._isValidCollection(M)){var W=true;for(var R=0,T=M.length;R<T;++R){W=this.on(M[R],K,V,Q,L)&&W;}return W;}else{if(YAHOO.lang.isString(M)){var P=this.getEl(M);if(P){M=P;}else{this.onAvailable(M,function(){YAHOO.util.Event.on(M,K,V,Q,L);});return true;}}}if(!M){return false;}if("unload"==K&&Q!==this){J[J.length]=[M,K,V,Q,L];return true;}var Y=M;if(L){if(L===true){Y=Q;}else{Y=L;}}var N=function(Z){return V.call(Y,YAHOO.util.Event.getEvent(Z,M),Q);};var X=[M,K,V,N,Y,Q,L];var S=I.length;I[S]=X;if(this.useLegacyEvent(M,K)){var O=this.getLegacyIndex(M,K);if(O==-1||M!=G[O][0]){O=G.length;B[M.id+K]=O;G[O]=[M,K,M["on"+K]];E[O]=[];M["on"+K]=function(Z){YAHOO.util.Event.fireLegacyEvent(YAHOO.util.Event.getEvent(Z),O);};}E[O].push(X);}else{try{this._simpleAdd(M,K,N,false);}catch(U){this.lastError=U;this.removeListener(M,K,V);return false;}}return true;},fireLegacyEvent:function(O,M){var Q=true,K,S,R,T,P;S=E[M].slice();for(var L=0,N=S.length;L<N;++L){R=S[L];if(R&&R[this.WFN]){T=R[this.ADJ_SCOPE];P=R[this.WFN].call(T,O);Q=(Q&&P);}}K=G[M];if(K&&K[2]){K[2](O);}return Q;},getLegacyIndex:function(L,M){var K=this.generateId(L)+M;if(typeof B[K]=="undefined"){return -1;}else{return B[K];}},useLegacyEvent:function(L,M){if(this.webkit&&("click"==M||"dblclick"==M)){var K=parseInt(this.webkit,10);if(!isNaN(K)&&K<418){return true;}}return false;},removeListener:function(L,K,T){var O,R,V;if(typeof L=="string"){L=this.getEl(L);}else{if(this._isValidCollection(L)){var U=true;for(O=L.length-1;O>-1;O--){U=(this.removeListener(L[O],K,T)&&U);}return U;}}if(!T||!T.call){return this.purgeElement(L,false,K);}if("unload"==K){for(O=J.length-1;O>-1;O--){V=J[O];if(V&&V[0]==L&&V[1]==K&&V[2]==T){J.splice(O,1);return true;}}return false;}var P=null;var Q=arguments[3];if("undefined"===typeof Q){Q=this._getCacheIndex(L,K,T);}if(Q>=0){P=I[Q];}if(!L||!P){return false;}if(this.useLegacyEvent(L,K)){var N=this.getLegacyIndex(L,K);var M=E[N];if(M){for(O=0,R=M.length;O<R;++O){V=M[O];if(V&&V[this.EL]==L&&V[this.TYPE]==K&&V[this.FN]==T){M.splice(O,1);break;}}}}else{try{this._simpleRemove(L,K,P[this.WFN],false);}catch(S){this.lastError=S;return false;}}delete I[Q][this.WFN];delete I[Q][this.FN];I.splice(Q,1);return true;},getTarget:function(M,L){var K=M.target||M.srcElement;return this.resolveTextNode(K);},resolveTextNode:function(L){try{if(L&&3==L.nodeType){return L.parentNode;}}catch(K){}return L;},getPageX:function(L){var K=L.pageX;if(!K&&0!==K){K=L.clientX||0;if(this.isIE){K+=this._getScrollLeft();}}return K;},getPageY:function(K){var L=K.pageY;if(!L&&0!==L){L=K.clientY||0;if(this.isIE){L+=this._getScrollTop();}}return L; +},getXY:function(K){return[this.getPageX(K),this.getPageY(K)];},getRelatedTarget:function(L){var K=L.relatedTarget;if(!K){if(L.type=="mouseout"){K=L.toElement;}else{if(L.type=="mouseover"){K=L.fromElement;}}}return this.resolveTextNode(K);},getTime:function(M){if(!M.time){var L=new Date().getTime();try{M.time=L;}catch(K){this.lastError=K;return L;}}return M.time;},stopEvent:function(K){this.stopPropagation(K);this.preventDefault(K);},stopPropagation:function(K){if(K.stopPropagation){K.stopPropagation();}else{K.cancelBubble=true;}},preventDefault:function(K){if(K.preventDefault){K.preventDefault();}else{K.returnValue=false;}},getEvent:function(M,K){var L=M||window.event;if(!L){var N=this.getEvent.caller;while(N){L=N.arguments[0];if(L&&Event==L.constructor){break;}N=N.caller;}}return L;},getCharCode:function(L){var K=L.keyCode||L.charCode||0;if(YAHOO.env.ua.webkit&&(K in D)){K=D[K];}return K;},_getCacheIndex:function(O,P,N){for(var M=0,L=I.length;M<L;M=M+1){var K=I[M];if(K&&K[this.FN]==N&&K[this.EL]==O&&K[this.TYPE]==P){return M;}}return -1;},generateId:function(K){var L=K.id;if(!L){L="yuievtautoid-"+A;++A;K.id=L;}return L;},_isValidCollection:function(L){try{return(L&&typeof L!=="string"&&L.length&&!L.tagName&&!L.alert&&typeof L[0]!=="undefined");}catch(K){return false;}},elCache:{},getEl:function(K){return(typeof K==="string")?document.getElementById(K):K;},clearCache:function(){},DOMReadyEvent:new YAHOO.util.CustomEvent("DOMReady",this),_load:function(L){if(!H){H=true;var K=YAHOO.util.Event;K._ready();K._tryPreloadAttach();}},_ready:function(L){var K=YAHOO.util.Event;if(!K.DOMReady){K.DOMReady=true;K.DOMReadyEvent.fire();K._simpleRemove(document,"DOMContentLoaded",K._ready);}},_tryPreloadAttach:function(){if(F.length===0){C=0;clearInterval(this._interval);this._interval=null;return ;}if(this.locked){return ;}if(this.isIE){if(!this.DOMReady){this.startInterval();return ;}}this.locked=true;var Q=!H;if(!Q){Q=(C>0&&F.length>0);}var P=[];var R=function(T,U){var S=T;if(U.override){if(U.override===true){S=U.obj;}else{S=U.override;}}U.fn.call(S,U.obj);};var L,K,O,N,M=[];for(L=0,K=F.length;L<K;L=L+1){O=F[L];if(O){N=this.getEl(O.id);if(N){if(O.checkReady){if(H||N.nextSibling||!Q){M.push(O);F[L]=null;}}else{R(N,O);F[L]=null;}}else{P.push(O);}}}for(L=0,K=M.length;L<K;L=L+1){O=M[L];R(this.getEl(O.id),O);}C--;if(Q){for(L=F.length-1;L>-1;L--){O=F[L];if(!O||!O.id){F.splice(L,1);}}this.startInterval();}else{clearInterval(this._interval);this._interval=null;}this.locked=false;},purgeElement:function(O,P,R){var M=(YAHOO.lang.isString(O))?this.getEl(O):O;var Q=this.getListeners(M,R),N,K;if(Q){for(N=Q.length-1;N>-1;N--){var L=Q[N];this.removeListener(M,L.type,L.fn);}}if(P&&M&&M.childNodes){for(N=0,K=M.childNodes.length;N<K;++N){this.purgeElement(M.childNodes[N],P,R);}}},getListeners:function(M,K){var P=[],L;if(!K){L=[I,J];}else{if(K==="unload"){L=[J];}else{L=[I];}}var R=(YAHOO.lang.isString(M))?this.getEl(M):M;for(var O=0;O<L.length;O=O+1){var T=L[O];if(T){for(var Q=0,S=T.length;Q<S;++Q){var N=T[Q];if(N&&N[this.EL]===R&&(!K||K===N[this.TYPE])){P.push({type:N[this.TYPE],fn:N[this.FN],obj:N[this.OBJ],adjust:N[this.OVERRIDE],scope:N[this.ADJ_SCOPE],index:Q});}}}}return(P.length)?P:null;},_unload:function(Q){var K=YAHOO.util.Event,N,M,L,P,O,R=J.slice();for(N=0,P=J.length;N<P;++N){L=R[N];if(L){var S=window;if(L[K.ADJ_SCOPE]){if(L[K.ADJ_SCOPE]===true){S=L[K.UNLOAD_OBJ];}else{S=L[K.ADJ_SCOPE];}}L[K.FN].call(S,K.getEvent(Q,L[K.EL]),L[K.UNLOAD_OBJ]);R[N]=null;L=null;S=null;}}J=null;if(I){for(M=I.length-1;M>-1;M--){L=I[M];if(L){K.removeListener(L[K.EL],L[K.TYPE],L[K.FN],M);}}L=null;}G=null;K._simpleRemove(window,"unload",K._unload);},_getScrollLeft:function(){return this._getScroll()[1];},_getScrollTop:function(){return this._getScroll()[0];},_getScroll:function(){var K=document.documentElement,L=document.body;if(K&&(K.scrollTop||K.scrollLeft)){return[K.scrollTop,K.scrollLeft];}else{if(L){return[L.scrollTop,L.scrollLeft];}else{return[0,0];}}},regCE:function(){},_simpleAdd:function(){if(window.addEventListener){return function(M,N,L,K){M.addEventListener(N,L,(K));};}else{if(window.attachEvent){return function(M,N,L,K){M.attachEvent("on"+N,L);};}else{return function(){};}}}(),_simpleRemove:function(){if(window.removeEventListener){return function(M,N,L,K){M.removeEventListener(N,L,(K));};}else{if(window.detachEvent){return function(L,M,K){L.detachEvent("on"+M,K);};}else{return function(){};}}}()};}();(function(){var EU=YAHOO.util.Event;EU.on=EU.addListener; +/* DOMReady: based on work by: Dean Edwards/John Resig/Matthias Miller */ +if(EU.isIE){YAHOO.util.Event.onDOMReady(YAHOO.util.Event._tryPreloadAttach,YAHOO.util.Event,true);var n=document.createElement("p");EU._dri=setInterval(function(){try{n.doScroll("left");clearInterval(EU._dri);EU._dri=null;EU._ready();n=null;}catch(ex){}},EU.POLL_INTERVAL);}else{if(EU.webkit&&EU.webkit<525){EU._dri=setInterval(function(){var rs=document.readyState;if("loaded"==rs||"complete"==rs){clearInterval(EU._dri);EU._dri=null;EU._ready();}},EU.POLL_INTERVAL);}else{EU._simpleAdd(document,"DOMContentLoaded",EU._ready);}}EU._simpleAdd(window,"load",EU._load);EU._simpleAdd(window,"unload",EU._unload);EU._tryPreloadAttach();})();}YAHOO.util.EventProvider=function(){};YAHOO.util.EventProvider.prototype={__yui_events:null,__yui_subscribers:null,subscribe:function(A,C,F,E){this.__yui_events=this.__yui_events||{};var D=this.__yui_events[A];if(D){D.subscribe(C,F,E);}else{this.__yui_subscribers=this.__yui_subscribers||{};var B=this.__yui_subscribers;if(!B[A]){B[A]=[];}B[A].push({fn:C,obj:F,override:E});}},unsubscribe:function(C,E,G){this.__yui_events=this.__yui_events||{};var A=this.__yui_events;if(C){var F=A[C];if(F){return F.unsubscribe(E,G);}}else{var B=true;for(var D in A){if(YAHOO.lang.hasOwnProperty(A,D)){B=B&&A[D].unsubscribe(E,G);}}return B;}return false;},unsubscribeAll:function(A){return this.unsubscribe(A);},createEvent:function(G,D){this.__yui_events=this.__yui_events||{};var A=D||{};var I=this.__yui_events; +if(I[G]){}else{var H=A.scope||this;var E=(A.silent);var B=new YAHOO.util.CustomEvent(G,H,E,YAHOO.util.CustomEvent.FLAT);I[G]=B;if(A.onSubscribeCallback){B.subscribeEvent.subscribe(A.onSubscribeCallback);}this.__yui_subscribers=this.__yui_subscribers||{};var F=this.__yui_subscribers[G];if(F){for(var C=0;C<F.length;++C){B.subscribe(F[C].fn,F[C].obj,F[C].override);}}}return I[G];},fireEvent:function(E,D,A,C){this.__yui_events=this.__yui_events||{};var G=this.__yui_events[E];if(!G){return null;}var B=[];for(var F=1;F<arguments.length;++F){B.push(arguments[F]);}return G.fire.apply(G,B);},hasEvent:function(A){if(this.__yui_events){if(this.__yui_events[A]){return true;}}return false;}};YAHOO.util.KeyListener=function(A,F,B,C){if(!A){}else{if(!F){}else{if(!B){}}}if(!C){C=YAHOO.util.KeyListener.KEYDOWN;}var D=new YAHOO.util.CustomEvent("keyPressed");this.enabledEvent=new YAHOO.util.CustomEvent("enabled");this.disabledEvent=new YAHOO.util.CustomEvent("disabled");if(typeof A=="string"){A=document.getElementById(A);}if(typeof B=="function"){D.subscribe(B);}else{D.subscribe(B.fn,B.scope,B.correctScope);}function E(J,I){if(!F.shift){F.shift=false;}if(!F.alt){F.alt=false;}if(!F.ctrl){F.ctrl=false;}if(J.shiftKey==F.shift&&J.altKey==F.alt&&J.ctrlKey==F.ctrl){var G;if(F.keys instanceof Array){for(var H=0;H<F.keys.length;H++){G=F.keys[H];if(G==J.charCode){D.fire(J.charCode,J);break;}else{if(G==J.keyCode){D.fire(J.keyCode,J);break;}}}}else{G=F.keys;if(G==J.charCode){D.fire(J.charCode,J);}else{if(G==J.keyCode){D.fire(J.keyCode,J);}}}}}this.enable=function(){if(!this.enabled){YAHOO.util.Event.addListener(A,C,E);this.enabledEvent.fire(F);}this.enabled=true;};this.disable=function(){if(this.enabled){YAHOO.util.Event.removeListener(A,C,E);this.disabledEvent.fire(F);}this.enabled=false;};this.toString=function(){return"KeyListener ["+F.keys+"] "+A.tagName+(A.id?"["+A.id+"]":"");};};YAHOO.util.KeyListener.KEYDOWN="keydown";YAHOO.util.KeyListener.KEYUP="keyup";YAHOO.util.KeyListener.KEY={ALT:18,BACK_SPACE:8,CAPS_LOCK:20,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,META:224,NUM_LOCK:144,PAGE_DOWN:34,PAGE_UP:33,PAUSE:19,PRINTSCREEN:44,RIGHT:39,SCROLL_LOCK:145,SHIFT:16,SPACE:32,TAB:9,UP:38};YAHOO.register("event",YAHOO.util.Event,{version:"2.5.2",build:"1076"});YAHOO.register("yahoo-dom-event", YAHOO, {version: "2.5.2", build: "1076"});
diff --git a/_br-ode-1.X.svn/axis2-war/src/main/webapp/processes.html b/_br-ode-1.X.svn/axis2-war/src/main/webapp/processes.html new file mode 100644 index 0000000..9d7de57 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/main/webapp/processes.html
@@ -0,0 +1,93 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> +<html> + <head> + <title>Apache ODE | Processes</title> + <link rel="stylesheet" href="css/style.css" type="text/css" media="screen, projection"/> + <link rel="stylesheet" href="js/yui/css/container.css" media="screen, projection"/> + <link rel="stylesheet" href="js/yui/css/button.css" media="screen, projection"/> + <link rel="stylesheet" href="js/bubbling/assets/accordion.css" media="screen, projection"/> + <link rel="stylesheet" type="text/css" href="js/yui/tab/skins/sam/tabview.css"> + <link type="text/css" rel="stylesheet" href="css/SyntaxHighlighter.css"></link> + <script type="text/javascript" src="js/WSRequest.js"> + </script> + <script type="text/javascript" src="js/ProcessManagementAPI.js"> + </script> + + + <script type="text/javascript" src="js/yui/utilities.js"> + </script> + <script type="text/javascript" src="js/yui/button.js"></script> + <script type="text/javascript" src="js/yui/container.js"></script> + <script type="text/javascript" src="js/bubbling/bubbling.js"> + </script> + <script type="text/javascript" src="js/bubbling/accordion.js"> + </script> + <script type="text/javascript" src="js/yui/tabview.js"> + </script> + <script type="text/javascript" src="js/yui/animation.js"> + </script> + <script type="text/javascript" src="js/ODE.js"> + </script> + <script> + function init(){ + org.apache.ode.ProcessHandling.populateContent(); + setInterval('org.apache.ode.ProcessHandling.populateContent()', 15000); + } + YAHOO.util.Event.onDOMReady(init); + </script> + <style type="text/css"> + button{ + background:transparent url(../button/assets/add.gif) no-repeat scroll 10% 50%; + padding-left:2em; + } + .link{ + margin-left:5px; + color:blue; + } + .myAccordion .yui-cms-accordion .yui-cms-item { + margin-bottom:10px; + } + .bd{ + background:#FFFFFF none repeat scroll 0 0; + } + </style> + </head> + <body> + <div id="header"> + <div id="login"> + <a href="http://apache.org">Apache</a> + |<a href="http://ode.apache.org">ODE</a> + |<a href="http://ode.apache.org/user-guide.html">User Guide</a> + |<a href="http://ode.apache.org/developer-guide.html">Developer Guide</a> + </div> + <h1><img src="images/logo.png" alt="Apache ODE"/></h1> + </div> + <div id="siteNav"> + <ul> + <li> + <a href="index.html">Home</a> + </li> + <li class="current"> + <a href="#">Processes</a> + </li> + <li> + <a href="instances.html">Instances</a> + </li> + <li> + <a href="deployment.html">Deployment</a> + </li> + </ul> + </div> + <div id="wrapper"> + <div id="insideW"> + <div id="insideL"> + <div id="content" class="yui-skin-sam"> + + + </div> + </div> + </div> + </div> + + </body> +</html>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java new file mode 100644 index 0000000..48c5edf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/Axis2TestBase.java
@@ -0,0 +1,294 @@ +package org.apache.ode.axis2; + +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.ConfigurationContextFactory; +import org.apache.axis2.description.AxisOperation; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.description.Parameter; +import org.apache.axis2.description.WSDL11ToAxisServiceBuilder; +import org.apache.axis2.engine.AxisServer; +import org.apache.axis2.engine.MessageReceiver; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.hooks.ODEAxisService; +import org.apache.ode.axis2.util.Axis2UriResolver; +import org.apache.ode.axis2.util.Axis2WSDLLocator; +import org.apache.ode.tools.sendsoap.cline.HttpSoapSender; +import org.testng.annotations.AfterMethod; +import org.testng.annotations.BeforeMethod; +import org.testng.annotations.DataProvider; + + +import javax.servlet.ServletException; +import javax.wsdl.WSDLException; +import javax.xml.namespace.QName; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileNotFoundException; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.net.URI; +import java.net.URISyntaxException; +import java.net.URL; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Iterator; +import java.util.List; + +/** + * @author Matthieu Riou <mriou@apache.org> + */ +public abstract class Axis2TestBase { + + public static final int DEFAULT_TEST_PORT = 8888; + + private static final Log log = LogFactory.getLog(Axis2TestBase.class); + + protected ODEAxis2Server server; + + protected String config; + + protected static final String DO_NOT_OVERRIDE_CONFIG = "<DO_NOT_OVERRIDE_CONFIG>"; + + private static String originalOdePersistence = System.getProperty("ode.persistence"); + private static String originalOdeConfigDir = System.getProperty("org.apache.ode.configDir"); + + @DataProvider(name = "configs") + protected Iterator<Object[]> createConfigData() { + List<String> configDirList = new ArrayList<String>(); + if( !(this instanceof ODEConfigDirAware) || ((ODEConfigDirAware)this).getODEConfigDir().contains("hib")) { + addToConfigDirList(configDirList, "org.apache.ode.hibdbs"); + } + if( !(this instanceof ODEConfigDirAware) || !((ODEConfigDirAware)this).getODEConfigDir().contains("hib")) { + addToConfigDirList(configDirList, "org.apache.ode.jpadbs"); + } + + if( configDirList.isEmpty() ) { + // if no system property is set, fall back to default + if( this instanceof ODEConfigDirAware ) { + configDirList.add(((ODEConfigDirAware)this).getODEConfigDir()); + } else { + configDirList.add(DO_NOT_OVERRIDE_CONFIG); + } + } else { + System.out.println("Java system properties have been set to override ode configuration: " + configDirList); + } + + final Iterator<String> itr = configDirList.iterator(); + return new Iterator<Object[]>() { + public boolean hasNext() { + return itr.hasNext(); + } + + public Object[] next() { + config = itr.next(); + return new Object[] {}; + } + + public void remove() { + } + }; + } + + private void addToConfigDirList(List<String> configDirList, String propertyKey) { + String dbs = System.getProperty(propertyKey); + if( dbs != null ) { + String[] configDirs = dbs.split(","); + for( String configDir : configDirs ) { + String trimmed = configDir.trim(); + if( trimmed.length() > 0 ) { + configDirList.add(trimmed); + } + } + } + } + + public void startServer() throws Exception { + startServer("webapp/WEB-INF", "webapp/WEB-INF/conf/axis2.xml"); + } + + public void startServer(String axis2RepoDir, String axis2ConfLocation) throws Exception { + String odeRootAbsolutePath = getClass().getClassLoader().getResource("webapp/WEB-INF").getFile(); + String axis2RepoAbsolutePath = getClass().getClassLoader().getResource(axis2RepoDir).getFile(); + String axis2ConfAbsolutePath = axis2ConfLocation == null ? null : getClass().getClassLoader().getResource(axis2ConfLocation).getFile(); + server = new ODEAxis2Server(odeRootAbsolutePath, axis2RepoAbsolutePath, axis2ConfAbsolutePath); + server.start(); + } + + public void stopServer() throws AxisFault { + server.stop(); + } + + @BeforeMethod + protected void setUp() throws Exception { + /** + * 1. If no settings are given from buildr, the test runs with the default config directory. + * 2. If no settings are given from buildr and if the test implements ODEConfigDirAware, the test runs with + * the config directory from the interface. + * 3. If settings are given from buildr and if it's derby and openJPA, test falls back to the above 1 or 2. + * 4. If settings are given from buildr and if it's derby and hibernate, test falls back to the above 2 or + * uses -Dode.persistence=hibernate. + */ + if( config == null || DO_NOT_OVERRIDE_CONFIG.equals(config) ) { + System.out.println("Test config: default."); + } else if("<jpa>".equals(config)) { + if( this instanceof ODEConfigDirAware ) { + config = ((ODEConfigDirAware)this).getODEConfigDir(); + System.out.println("Test config: " + config + "."); + System.setProperty("org.apache.ode.configDir", config); + } else { + System.out.println("Test config: default."); + } + } else if("<hib>".equals(config)) { + if( this instanceof ODEConfigDirAware ) { + config = ((ODEConfigDirAware)this).getODEConfigDir(); + System.out.println("Test config: " + config + "."); + System.setProperty("org.apache.ode.configDir", config); + } else { + // why does this not work? +// System.out.println("Test config: -Dode.persistence=hibernate"); +// System.setProperty("ode.persistence", "hibernate"); + config = getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + System.out.println("Test config: " + config + "."); + System.setProperty("org.apache.ode.configDir", config); + } + } else { + System.out.println("Test config: " + config + "."); + System.setProperty("org.apache.ode.configDir", config); + } + + startServer(); + } + + @AfterMethod + protected void tearDown() throws Exception { + stopServer(); + + if( originalOdeConfigDir != null ) { + System.setProperty("org.apache.ode.configDir", originalOdeConfigDir); + } else { + System.clearProperty("org.apache.ode.configDir"); + } + if( originalOdeConfigDir != null ) { + System.setProperty("ode.persistence", originalOdePersistence); + } else { + System.clearProperty("ode.persistence"); + } + } + + protected class ODEAxis2Server extends AxisServer { + + ODEServer _ode; + String odeRootDir; + + protected ODEAxis2Server(String odeRootDir, String axis2RepoDir, String axis2ConfLocation) throws Exception { + super(false); + this.odeRootDir = odeRootDir; + if (log.isInfoEnabled()) { + log.info("Ode Root Dir: " + odeRootDir); + log.info("Axis2 Conf file: " + axis2ConfLocation); + log.info("Axis2 Repo dir: " + axis2RepoDir); + } + + configContext = ConfigurationContextFactory.createConfigurationContextFromFileSystem(axis2RepoDir, axis2ConfLocation); + // do not use 8080 for tests + configContext.getAxisConfiguration().getTransportIn("http").addParameter(new Parameter("port", ""+DEFAULT_TEST_PORT)); + } + + protected void start() throws AxisFault { + super.start(); + _ode = new ODEServer(); + try { + _ode.init(odeRootDir, configContext.getAxisConfiguration()); + } catch (ServletException e) { + e.printStackTrace(); + } + } + + public void stop() throws AxisFault { + _ode.shutDown(); + super.stop(); + } + + public Collection<QName> deployProcess(String bundleName) { + return _ode.getProcessStore().deploy(new File(getBundleDir(bundleName))); + } + + public void undeployProcess(String bundleName) { + _ode.getProcessStore().undeploy(new File(getBundleDir(bundleName))); + } + + public boolean isDeployed(String bundleName) { + return _ode.getProcessStore().getPackages().contains(bundleName); + } + + /** + * Creates and deploys an Axis service based on a provided MessageReceiver. The receiver + * will be invoked for all invocations of that service. + */ + protected void deployService(String bundleName, String defFile, QName serviceName, String port, + MessageReceiver receiver) throws WSDLException, IOException, URISyntaxException { + URI wsdlUri = new File(getBundleDir(bundleName) + "/" + defFile).toURI(); + + InputStream is = wsdlUri.toURL().openStream(); + WSDL11ToAxisServiceBuilder serviceBuilder = new ODEAxisService.WSDL11ToAxisPatchedBuilder(is, serviceName, port); + serviceBuilder.setBaseUri(wsdlUri.toString()); + serviceBuilder.setCustomResolver(new Axis2UriResolver()); + serviceBuilder.setCustomWSLD4JResolver(new Axis2WSDLLocator(wsdlUri)); + serviceBuilder.setServerSide(true); + + AxisService axisService = serviceBuilder.populateService(); + axisService.setName(serviceName.getLocalPart()); + axisService.setWsdlFound(true); + axisService.setCustomWsdl(true); + axisService.setClassLoader(getConfigurationContext().getAxisConfiguration().getServiceClassLoader()); + + Iterator operations = axisService.getOperations(); + while (operations.hasNext()) { + AxisOperation operation = (AxisOperation) operations.next(); + if (operation.getMessageReceiver() == null) { + operation.setMessageReceiver(receiver); + } + } + getConfigurationContext().getAxisConfiguration().addService(axisService); + } + + public String sendRequestFile(String endpoint, String bundleName, String filename) { + try { + return HttpSoapSender.doSend(new URL(endpoint), + new FileInputStream(getBundleDir(bundleName) + "/" + filename), null, 0, null, null, null); + } catch (IOException e) { + throw new RuntimeException(e); + } + } + + protected String getBundleDir(String bundleName) { + return getClass().getClassLoader().getResource(bundleName).getFile(); + } + + /** + * Convenient methods to generate a WSDL for an Axis2 service. Often nice, but also often + * generates crappy WSDL that aren't even valid (especially when faults are involved) so + * use with care. + * + * @param serviceName + * @param fileName + * @throws AxisFault + */ + protected void generateWSDL(String serviceName, String fileName) throws AxisFault { + FileOutputStream fos = null; + try { + fos = new FileOutputStream(fileName); + } catch (FileNotFoundException e) { + e.printStackTrace(); + } + configContext.getAxisConfiguration().getService(serviceName).printWSDL(fos); + } + + public ODEServer getODEServer() { + return _ode; + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java new file mode 100644 index 0000000..31245fa --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/BpelActivityTest.java
@@ -0,0 +1,55 @@ +package org.apache.ode.axis2; + +import static org.testng.Assert.fail; + +import org.apache.log4j.Logger; +import org.testng.annotations.Test; + +public class BpelActivityTest extends Axis2TestBase { + @Test(dataProvider="configs") + public void testThrowOnEvent() throws Exception { + final String bundleName = "TestThrowOnEvent"; + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + + new Thread() { + public void run() { + try { + Thread.sleep(2000); + String response = server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/", + bundleName, "testRequest.soap"); + Logger.getLogger(BpelActivityTest.class).debug("!!! : " + response); + } catch( Exception e ) { + fail(e.getMessage()); + } + } + }.start(); + +// new Thread() { +// public void run() { +// try { +// Thread.sleep(6000); +// String response = server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/", +// bundleName, "testRequest.soap"); +// Logger.getLogger(BpelActivityTest.class).debug("!!!SEAN : " + response); +// } catch( Exception e ) { +// fail(e.getMessage()); +// } +// } +// }.start(); + + try { + String response = server.sendRequestFile("http://localhost:8888/ode/processes/OnEventCorrelation/", + bundleName, "testRequest.soap"); + Logger.getLogger(BpelActivityTest.class).debug("!!! : " + response); + +// assertTrue(response.contains("helloResponse") && response.contains("Something went wrong. Fortunately, it was meant to be.")); + } finally { +// server.undeployProcess(bundleName); + } + + Thread.sleep(6000); + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/DummyException.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/DummyException.java new file mode 100644 index 0000000..d963565 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/DummyException.java
@@ -0,0 +1,16 @@ +package org.apache.ode.axis2; + +/** + * @author Matthieu Riou <mriou@apache.org> + */ +public class DummyException extends Exception { + String reason = "dummyReason"; + + public String getReason() { + return reason; + } + + public void setReason(String reason) { + this.reason = reason; + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/DummyService.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/DummyService.java new file mode 100644 index 0000000..645683f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/DummyService.java
@@ -0,0 +1,46 @@ +package org.apache.ode.axis2; + +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMFactory; +import org.apache.axis2.AxisFault; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; + +import javax.xml.namespace.QName; + +/** + * @author Matthieu Riou <mriou@apache.org> + */ +public class DummyService { + + private static final Log log = LogFactory.getLog(DummyService.class); + + public String hello(String in) { + log.debug("#### IN HELLO ####"); + return in + " world"; + } + + public String longOperation(String in) { + long delay = 120000; // == Properties.DEFAULT_MEX_TIMEOUT + try { + delay = Long.parseLong(in); + } catch (NumberFormatException ignore) {} + try { + log.debug("#### IN LONG OP: "+delay+"ms ####"); + Thread.sleep(delay); + } catch (InterruptedException ignore) { } + log.debug("#### WENT THROUGH ###"); + return "Went through " + in; + } + + public String faultTest(String in) throws DummyException, AxisFault { + OMFactory factory = OMAbstractFactory.getOMFactory(); + OMElement root = factory.createOMElement(new QName("http://axis2.ode.apache.org", "DummyException")); + OMElement reason = factory.createOMElement(new QName("", "reason")); + reason.setText("Something went wrong. Fortunately, it was meant to be."); + root.addChild(reason); + throw new AxisFault(new QName("http://schemas.xmlsoap.org/soap/envelope/", "Client"), "dummy reason", + "dummy node", "dummy role", root); + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/EndpointConfigurationTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/EndpointConfigurationTest.java new file mode 100644 index 0000000..fad118f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/EndpointConfigurationTest.java
@@ -0,0 +1,96 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.mortbay.jetty.handler.ContextHandler; +import org.mortbay.jetty.handler.HandlerList; +import org.mortbay.jetty.security.Constraint; +import org.mortbay.jetty.security.ConstraintMapping; +import org.mortbay.jetty.security.HashUserRealm; +import org.mortbay.jetty.security.SecurityHandler; +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.Test; + +/** + * + * + */ +public class EndpointConfigurationTest extends Axis2TestBase { + @Test + public void testEndpointProperties() throws Exception { + executeProcess(); + } + + protected void executeProcess() throws Exception { + executeProcess(null); + } + + protected void executeProcess(ContextHandler handler) throws Exception { + JettyWrapper jettyWrapper = new JettyWrapper(handler); + jettyWrapper.start(); + + try { + String bundleName = "TestEndpointProperties"; + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", + bundleName, "testRequest.soap"); + assertTrue(response.contains("helloResponse") && response.contains("OK!!!")); + } finally { + server.undeployProcess(bundleName); + } + } finally { + jettyWrapper.stop(); + } + } + + /** + * Redo the exact same test but with Basic Authentication activated on the external service + * @throws Exception + */ + @Test + public void testHttpAuthentication() throws Exception { + ContextHandler securedEchoContext; + { + Constraint constraint = new Constraint(); + constraint.setName(Constraint.__BASIC_AUTH); + constraint.setRoles(new String[]{"user"}); + constraint.setAuthenticate(true); + + ConstraintMapping cm = new ConstraintMapping(); + cm.setConstraint(constraint); + cm.setPathSpec("/*"); + + SecurityHandler sh = new SecurityHandler(); + sh.setUserRealm(new HashUserRealm("MyRealm", getClass().getResource("/TestEndpointProperties/jetty-realm.properties").toURI().toString())); + sh.setConstraintMappings(new ConstraintMapping[]{cm}); + + securedEchoContext = new ContextHandler(); + securedEchoContext.setContextPath("/EchoService"); + + HandlerList hc = new HandlerList(); + hc.addHandler(sh); + hc.addHandler(new JettyWrapper.EchoServiceHandler()); + securedEchoContext.addHandler(hc); + } + executeProcess(securedEchoContext); + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/EndpointTimeoutsTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/EndpointTimeoutsTest.java new file mode 100644 index 0000000..a6fbcd3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/EndpointTimeoutsTest.java
@@ -0,0 +1,32 @@ +package org.apache.ode.axis2; + +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.Test; + +/** + * Tests that timeouts set in the *.endpoint files are applied. + * The test is designed so a fault must be received. + * + * Actually, the process invokes a 3-sec long operation (see the process request). + * The specified timeouts are lesser than 3-sec, so if properly applied, a fault should be trown. + * If not applied, the default 120-sec timeouts will be used. 5sec < 120sec, so the request will succeed. + * + */ +public class EndpointTimeoutsTest extends Axis2TestBase { + @Test(dataProvider="configs") + public void testTimeouts() throws Exception { + String bundleName = "TestEndpointTimeouts"; + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", + bundleName, "testRequest.soap"); + System.out.println(response); + assertTrue("A timeout exception was expected", response.contains("<soapenv:Fault") && response.contains("Timeout or execution error when waiting for response to MEX")); + } finally { + server.undeployProcess(bundleName); + } + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/FailureInvokeTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/FailureInvokeTest.java new file mode 100644 index 0000000..0906372 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/FailureInvokeTest.java
@@ -0,0 +1,59 @@ +package org.apache.ode.axis2; + +import org.apache.axis2.AxisFault; +import org.testng.annotations.Test; + +/** + * This test requires very specific timing values to work which is why it's set to ignored, it + * probably wouldn't work on most machines. BpelRuntimeContextImpl.scheduleInvokeCheck also has to + * use a timer value of 5s instead of 180s (a bit too long for testing). + */ +public class FailureInvokeTest extends Axis2TestBase { + + @Test(enabled = false) + public void testSimpleFaultCatch() throws Exception { + String bundleName = "TestFailureInInvoke"; + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + + try { + new Thread(new Killer(this)).start(); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/invokeFailureTest", + bundleName, "testRequest.soap"); + System.out.println("=> " + response); + } catch (Exception e) { + e.printStackTrace(); + } + + startServer(); + Thread.sleep(15000); + } finally { + server.undeployProcess(bundleName); + } + } + + private class Killer implements Runnable { + private FailureInvokeTest test; + + private Killer(FailureInvokeTest test) { + this.test = test; + } + + public void run() { + try { + Thread.sleep(5000); + } catch (InterruptedException e) { + e.printStackTrace(); + } + try { + test.stopServer(); + } catch (AxisFault axisFault) { + axisFault.printStackTrace(); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/JettyWrapper.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/JettyWrapper.java new file mode 100644 index 0000000..832dbcf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/JettyWrapper.java
@@ -0,0 +1,446 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.commons.lang.StringUtils; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.utils.StreamUtils; +import org.mortbay.jetty.Handler; +import org.mortbay.jetty.Request; +import org.mortbay.jetty.Server; +import org.mortbay.jetty.handler.AbstractHandler; +import org.mortbay.jetty.handler.ContextHandler; +import org.mortbay.jetty.handler.ContextHandlerCollection; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.xml.sax.SAXException; + +import javax.servlet.ServletException; +import javax.servlet.ServletInputStream; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import java.io.IOException; +import java.util.Enumeration; + +/** + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public class JettyWrapper { + + protected Server server; + + public JettyWrapper() throws Exception { + this(7070); + } + + public JettyWrapper(int port) throws Exception { + server = new Server(port); + addDefaultHandlers(); + } + + + public JettyWrapper(ContextHandler handler) { + server = new Server(7070); + if(handler!=null) server.addHandler(handler); + else addDefaultHandlers(); + } + + + private void addDefaultHandlers() { + ContextHandler arithmeticsContext = new ContextHandler(); + arithmeticsContext.setContextPath("/HttpBindingTest/ArithmeticsService"); + arithmeticsContext.setHandler(new ArithmeticsServiceHandler()); + + ContextHandler blogContext = new ContextHandler(); + blogContext.setContextPath("/HttpBindingTest/BlogService"); + blogContext.setHandler(new BlogServiceHandler()); + + ContextHandler echoContext = new ContextHandler(); + echoContext.setContextPath("/EchoService"); + echoContext.setHandler(new EchoServiceHandler()); + + ContextHandlerCollection handlerColl = new ContextHandlerCollection(); + Handler[] handlers = {arithmeticsContext, blogContext, echoContext}; + handlerColl.setHandlers(handlers); + + server.addHandler(handlerColl); + } + + public void start() throws Exception { + server.start(); + } + + public void stop() throws Exception { + server.stop(); + } + + static public class EchoServiceHandler extends AbstractHandler { + + public void handle(String s, HttpServletRequest request, HttpServletResponse response, int i) throws IOException, ServletException { + String method = request.getMethod(); + if (request.getParameter("ping")!=null) { + response.setStatus(200); + response.getOutputStream().println("Yep, I'm here!"); + } else { + if (!"GET".equals(method) && !"POST".equals(method)) { + response.setStatus(405); + response.setHeader("Allow", "GET, POST"); + } else { + Enumeration h = request.getHeaderNames(); + // send back all headers + while (h.hasMoreElements()) { + String hname = (String) h.nextElement(); + Enumeration values = request.getHeaders(hname); + while (values.hasMoreElements()) { + String next = (String) values.nextElement(); + response.addHeader(hname, next); + } + } + + // send back the body if any + String body = new String(StreamUtils.read(request.getInputStream())); + if (StringUtils.isNotEmpty(body)) + response.getOutputStream().println(body); + + } + } + + + ((Request) request).setHandled(true); + } + } + + private class ArithmeticsServiceHandler extends AbstractHandler { + /* + 8 urls to handle: + (GET) http://localhost:8888/HttpBindingTestService/OlaElMundo-GET/plus/(left):(right) + (GET) http:// ........ /OlaElMundo-GET/minus?left=&right= + (DELETE) http://localhost:8888/HttpBindingTestService/OlaElMundo-DELETE/plus/(left):(right) + (DELETE) http:// ........ /OlaElMundo-DELETE/minus?left=&right= + (POST) http:// ........ /OlaElMundo-POST/plus + (POST) http:// ........ /OlaElMundo-POST/minus + (PUT) http:// ........ /OlaElMundo-PUT/plus + (PUT) http:// ........ /OlaElMundo-PUT/minus + (POST) http:// ........ /SalutLaTerre/addition + (POST) http:// ........ /SalutLaTerre/sumOfIntegers + */ + public void handle(String s, HttpServletRequest request, HttpServletResponse response, int i) throws IOException, ServletException { + + try { + String method = request.getMethod(); + String uri = request.getRequestURI(); + if ("/HttpBindingTestService/".equals(uri)) { + response.getWriter().println("HttpBindingTestService ready!"); + } else if (uri.contains("OlaElMundo-GET") || uri.contains("OlaElMundo-DELETE")) { +// if (!"GET".equalsIgnoreCase(method)) { + if (false) { + response.sendError(405, "Expecting method is GET"); + } else { + if (!uri.contains("plus") && !uri.contains("minus")) { + response.sendError(404); + } else { + boolean ok = true; + int left = 0, right = 0; + try { + if (uri.contains("plus")) { + int index = uri.lastIndexOf("/"); + String[] op = uri.substring(index + 1).split(":"); + left = Integer.parseInt(op[0]); + right = Integer.parseInt(op[1]); + } else if (uri.contains("minus")) { + left = Integer.parseInt(request.getParameter("left")); + right = -1 * Integer.parseInt(request.getParameter("right")); + } else { + ok = false; + } + } catch (NumberFormatException e) { + ok = false; + } + + if (!ok) { + response.sendError(400); + } else { + Document doc = DOMUtils.newDocument(); + Element resElt = doc.createElement("theresult"); + resElt.setTextContent(String.valueOf(left + right)); + response.getOutputStream().print(DOMUtils.domToString(resElt)); + response.getOutputStream().close(); + response.setStatus(200); + } + } + } + } else if (uri.contains("OlaElMundo-POST") || uri.contains("OlaElMundo-PUT")) { +// if (!"POST".equalsIgnoreCase(method)) { + if (false) { + response.sendError(405, "Expecting method is POST"); + return; + } else { + String operation; + if (!uri.contains("plus") && !uri.contains("minus")) { + response.sendError(404); + } else { + // parse body, form-urlencoded + int res = Integer.MIN_VALUE; + boolean ok = true; + StringBuffer sb = null; + String body = new String(StreamUtils.read(request.getInputStream())); + if (!body.matches("[^=]*=[+-]?\\d*&[^=]*=[+-]?\\d*")) { + ok = false; + } else { + String[] sp = body.split("&"); + String[] op0 = sp[0].split("="); + String[] op1 = sp[1].split("="); + try { + int left, right; + if (op0[0].equals("left")) { + left = Integer.valueOf(op0[1]); + right = Integer.valueOf(op1[1]); + } else { + left = Integer.valueOf(op1[1]); + right = Integer.valueOf(op0[1]); + } + if (uri.contains("minus")) { + right = -1 * right; + } + res = left + right; + } catch (NumberFormatException e) { + ok = false; + } + } + if (!ok) { + response.sendError(400); + } else { + Element resElt = DOMUtils.newDocument().createElement("theresult"); + resElt.setTextContent(String.valueOf(res)); + response.getOutputStream().print(DOMUtils.domToString(resElt)); + response.setStatus(200); + } + } + } + } else if (uri.contains("SalutLaTerre")) { + if (!"POST".equalsIgnoreCase(method)) { + response.sendError(405, "Expecting method is POST"); + return; + } else { + if (uri.contains("addition")) { + Document bodyDoc = parseBody(request.getInputStream(), response); + if (bodyDoc != null) { + // we expect the element operandList + if (!"operandList".equals(bodyDoc.getDocumentElement().getNodeName())) { + response.sendError(400, "The first element should be named operandList"); + } else { + Element firstOperand = DOMUtils.getFirstChildElement(bodyDoc.getDocumentElement()); + Element secondElement = DOMUtils.getNextSiblingElement(firstOperand); + String left = DOMUtils.getTextContent(firstOperand); + String right = DOMUtils.getTextContent(secondElement); + Element res = bodyDoc.createElementNS("http://ode/bpel/test/arithmetics", "theresult"); + res.setTextContent(String.valueOf(Integer.valueOf(left) + Integer.valueOf(right))); + response.getOutputStream().print(DOMUtils.domToString(res)); + response.setStatus(200); + } + } + + } else if (uri.contains("sumOfIntegers")) { + Document bodyDoc = parseBody(request.getInputStream(), response); + if (bodyDoc != null) { + Element firstOperand = DOMUtils.getFirstChildElement(bodyDoc.getDocumentElement()); + Element secondOperand = DOMUtils.getNextSiblingElement(firstOperand); + int left = Integer.valueOf(DOMUtils.getTextContent(firstOperand)); + int right = Integer.valueOf(DOMUtils.getTextContent(secondOperand)); + + int min = Math.min(left, right); + int max = Math.max(left, right); +// Element arrayElt = bodyDoc.createElement("sumOfInteger"); + Element anElt = bodyDoc.createElementNS("http://ode/bpel/test/arithmetics", "sumOfInteger"); + Element msg = bodyDoc.createElement("theresult"); + Element resultIs = bodyDoc.createElement("resultIs"); + msg.setTextContent("A dummy message we don't care about. Only purpose is to have a complex type"); + resultIs.setTextContent(String.valueOf((max * (max + 1) - min * (min + 1)) / 2)); + + anElt.appendChild(msg); + anElt.appendChild(resultIs); + response.getOutputStream().print(DOMUtils.domToString(anElt)); + response.setStatus(200); + } + } else { + response.sendError(404); + } + } + } + } catch (Exception e) { + response.sendError(500, e.getMessage()); + } finally { + ((Request) request).setHandled(true); + } + } + + private Document parseBody(ServletInputStream bodyStream, HttpServletResponse response) throws IOException { + if (bodyStream == null) { + response.sendError(400, "Missing body!"); + } else { + try { + return DOMUtils.parse(bodyStream); + } catch (SAXException e) { + response.sendError(400, "Failed to parse body! " + e.getMessage()); + } + } + return null; + } + } + + private class BlogServiceHandler extends AbstractHandler { + + public void handle(String s, HttpServletRequest request, HttpServletResponse response, int i) throws IOException, ServletException { + String method = request.getMethod(); + // actually we don't really care about this is. + String articleId = s.substring(s.lastIndexOf("/") + 1); + + if ("GET".equalsIgnoreCase(method)) { + doGet(request, response, articleId); + } else if ("PUT".equalsIgnoreCase(method)) { + doPut(request, response, articleId); + } else if ("POST".equalsIgnoreCase(method)) { + doPost(request, response, articleId); + } else if ("DELETE".equalsIgnoreCase(method)) { + doDelete(request, response, articleId); + } + ((Request) request).setHandled(true); + } + + private void doGet(HttpServletRequest request, HttpServletResponse response, String articleId) throws IOException { + String faultType = request.getHeader("Fault-Type"); + if ("400_not_found".equals(faultType)) { + response.setStatus(400); + } else if ("500_operation_with_no_fault_failed".equals(faultType)) { + response.setStatus(500); + } else if ("200_missing_part_in_header".equals(faultType)) { + // a part is bound to a custom header + // this test does not set it on purpose + + response.setContentType("text/xml"); + Element articleEl = createArticleDoc(articleId); + + response.getOutputStream().print(DOMUtils.domToString(articleEl)); + response.setStatus(200); + } else if ("200_missing_body".equals(faultType)) { + response.setHeader("TimestampHeader", request.getHeader("TimestampHeader")); + response.setHeader("From", request.getHeader("From")); + + response.setStatus(200); + } else if ("200_malformed_body".equals(faultType)) { + // parts to http headers, just send them back and let the caller check the received values + response.setHeader("TimestampHeader", request.getHeader("TimestampHeader")); + response.setHeader("From", request.getHeader("From")); + + response.setContentType("text/xml"); + response.getOutputStream().print("<book><abstract>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</abstract>"); + response.setStatus(200); + } else if ("202_empty_body".equals(faultType) || "204_empty_body".equals(faultType)) { + response.setHeader("TimestampHeader", request.getHeader("TimestampHeader")); + response.setHeader("From", request.getHeader("From")); + + response.setStatus(Integer.parseInt(faultType.substring(0, 3))); + } else { + // some parts are bound to http headers + // just send them back and let the caller check the received values + response.setHeader("TimestampHeader", request.getHeader("TimestampHeader")); + response.setHeader("From", request.getHeader("From")); + + response.setContentType("text/xml"); + Element articleEl = createArticleDoc(articleId); + + response.getOutputStream().print(DOMUtils.domToString(articleEl)); + response.setStatus(200); + } + } + + private Element createArticleDoc(String articleId) { + Document doc = DOMUtils.newDocument(); + Element articleEl = doc.createElementNS("http://ode/bpel/test/blog", "article"); + Element idEl = doc.createElementNS("http://ode/bpel/test/blog", "id"); + Element titleEl = doc.createElementNS("http://ode/bpel/test/blog", "title"); + + articleEl.appendChild(idEl); + articleEl.appendChild(titleEl); + + idEl.setTextContent(articleId); + titleEl.setTextContent("A title with a random number " + System.currentTimeMillis()); + return articleEl; + } + + private void doPost(HttpServletRequest request, HttpServletResponse response, String articleId) { + response.setHeader("Location", "http://examples.org/a_new_comment_on_article_" + articleId); + response.setStatus(201); // Created + } + + + private void doPut(HttpServletRequest request, HttpServletResponse response, String articleId) throws IOException { + String faultType = request.getHeader("Fault-Type"); + if ("500_no_body".equals(faultType)) { + response.setStatus(500); + } else if ("500_text_body".equals(faultType)) { + response.setContentType("text"); + response.getOutputStream().print("Lorem ipsum dolor sit amet, consectetuer adipiscing elit."); + response.setStatus(500); + } else if ("500_malformed_xml_body".equals(faultType)) { + response.setContentType("text/xml"); + response.getOutputStream().print("<book><abstract>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</abstract>"); + response.setStatus(500); + } else if ("500_unknown_xml_body".equals(faultType)) { + response.setContentType("text/xml"); + response.getOutputStream().print("<book><abstract>Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</abstract></book>"); + response.setStatus(500); + } else if ("500_expected_xml_body".equals(faultType)) { + response.setContentType("text/xml"); + + Document doc = DOMUtils.newDocument(); + Element faultEl = doc.createElementNS("http://ode/bpel/test/blog", "fault"); + Element timestamptEl = doc.createElementNS("http://ode/bpel/test/blog", "timestamp"); + Element detailsEl = doc.createElementNS("http://ode/bpel/test/blog", "details"); + + faultEl.appendChild(timestamptEl); + faultEl.appendChild(detailsEl); + + timestamptEl.setTextContent("" + System.currentTimeMillis()); + detailsEl.setTextContent("Fake fault with the expected xml body."); + + response.getOutputStream().print(DOMUtils.domToString(faultEl)); + response.setStatus(500); + } else { + response.setStatus(200); + } + } + + private void doDelete(HttpServletRequest request, HttpServletResponse response, String articleId) { + response.setHeader("TimestampHeader", request.getHeader("TimestampHeader")); + response.setHeader("User-Agent", request.getHeader("User-Agent")); + response.setStatus(204); // No content + } + } + + public static void main(String[] args) { + try { + new JettyWrapper().server.start(); + } catch (Exception e) { + e.printStackTrace(); + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/MessageStructureTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/MessageStructureTest.java new file mode 100644 index 0000000..314e65b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/MessageStructureTest.java
@@ -0,0 +1,28 @@ +package org.apache.ode.axis2; + +import org.apache.ode.utils.DOMUtils; +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.Test; +import org.w3c.dom.Element; + +public class MessageStructureTest extends Axis2TestBase { + @Test(dataProvider="configs") + public void testAttrWithNsValue() throws Exception { + String bundleName = "TestAttributeNamespaces"; + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/attrNSWorld", + bundleName, "testRequest.soap"); + Element domResponse = DOMUtils.stringToDOM(response); + Element out = DOMUtils.getFirstChildElement(DOMUtils.getFirstChildElement(DOMUtils.getFirstChildElement(domResponse))); + String nsAttr = out.getAttribute("xmlns:myns"); + System.out.println("=> " + response); + assertTrue(nsAttr != null); + } finally { + server.undeployProcess(bundleName); + } + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/ODEConfigDirAware.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/ODEConfigDirAware.java new file mode 100644 index 0000000..06e80a8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/ODEConfigDirAware.java
@@ -0,0 +1,5 @@ +package org.apache.ode.axis2; + +public interface ODEConfigDirAware { + String getODEConfigDir(); +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/ServiceFaultCatchTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/ServiceFaultCatchTest.java new file mode 100644 index 0000000..3943cc8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/ServiceFaultCatchTest.java
@@ -0,0 +1,28 @@ +package org.apache.ode.axis2; + +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.Test; + +/** + * Tests that a fault thrown by a called service can be caught and is properly + * structured so that an assign on a fault sub-element will succeed. + * + * @author Matthieu Riou <mriou@apache.org> + */ +public class ServiceFaultCatchTest extends Axis2TestBase { + @Test(dataProvider="configs") + public void testSimpleFaultCatch() throws Exception { + String bundleName = "TestStructuredFault"; + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", + bundleName, "testRequest.soap"); + assertTrue(response.contains("helloResponse") && response.contains("Something went wrong. Fortunately, it was meant to be.")); + } finally { + server.undeployProcess(bundleName); + } + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/SoapHeaderTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/SoapHeaderTest.java new file mode 100644 index 0000000..f5e58e0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/SoapHeaderTest.java
@@ -0,0 +1,72 @@ +package org.apache.ode.axis2; + +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.soap.SOAPBody; +import org.apache.axiom.soap.SOAPEnvelope; +import org.apache.axiom.soap.SOAPFactory; +import org.apache.axiom.soap.SOAPHeader; +import org.apache.axiom.soap.SOAPHeaderBlock; +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.engine.AxisEngine; +import org.apache.axis2.engine.MessageReceiver; +import org.apache.axis2.util.Utils; +import org.apache.ode.utils.DOMUtils; +import static org.testng.AssertJUnit.assertEquals; +import org.testng.annotations.Test; +import org.w3c.dom.Element; + +import javax.xml.namespace.QName; + +/** + * Tests a simple process that gets a message that includes a header, pass it on when invoking + * a dummy service, gets the changed header back and returns it. + * @author Matthieu Riou <mriou@apache.org> + */ +public class SoapHeaderTest extends Axis2TestBase { + @Test(dataProvider="configs") + public void testSimplePassing() throws Exception { + server.deployService("TestSoapHeader", "dummy-service.wsdl", + new QName("http://axis2.ode.apache.org", "DummyService"), "DummyServiceSOAP11port_http", + new MessageReceiver() { + @SuppressWarnings("deprecation") + public void receive(MessageContext messageCtx) throws AxisFault { + OMElement cidElmt = messageCtx.getEnvelope().getHeader().getFirstElement(); + assertEquals("ConversationId", cidElmt.getLocalName()); + assertEquals("ZZZXYZ", cidElmt.getText()); + + MessageContext outMsgContext = Utils.createOutMessageContext(messageCtx); + outMsgContext.getOperationContext().addMessageContext(outMsgContext); + + // Far too many lines of code... + SOAPFactory factory = OMAbstractFactory.getSOAP11Factory(); + SOAPEnvelope env = factory.createSOAPEnvelope(); + SOAPHeader header = factory.createSOAPHeader(env); + SOAPBody body = factory.createSOAPBody(env); + outMsgContext.setEnvelope(env); + OMElement respElmt = factory.createOMElement(new QName("http://axis2.ode.apache.org", "faultTestResponse")); + body.addChild(respElmt); + respElmt.setText("dummy"); + SOAPHeaderBlock headerBlock = factory.createSOAPHeaderBlock("ConversationId", + factory.createOMNamespace("http://my.company/super/protocol", "pns"), header); + headerBlock.setText("ZZYV"); + AxisEngine.send(outMsgContext); + } + }); + + if (!server.isDeployed("TestSoapHeader")) server.deployProcess("TestSoapHeader"); + + String response = server.sendRequestFile("http://localhost:8888/processes/headerTest", + "TestSoapHeader", "testRequest.soap"); + System.out.println(response); + + Element rootElemt = DOMUtils.stringToDOM(response); + Element cidElemt = DOMUtils.getFirstChildElement(DOMUtils.getFirstChildElement(rootElemt)); + assertEquals("ConversationId", cidElemt.getLocalName()); + assertEquals("ZZYV", cidElemt.getTextContent()); + + server.undeployProcess("TestStructuredFault"); + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/XSDReferencesDeployTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/XSDReferencesDeployTest.java new file mode 100644 index 0000000..93a2155 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/XSDReferencesDeployTest.java
@@ -0,0 +1,17 @@ +package org.apache.ode.axis2; + +import org.testng.annotations.Test; + +/** + * @author Matthieu Riou <mriou@apache.org> + */ +public class XSDReferencesDeployTest extends Axis2TestBase { + @Test(dataProvider="configs") + public void testSimpleFaultCatch() throws Exception { + server.deployService(DummyService.class.getCanonicalName()); + // If we have a bug, this will throw an exception, no need to assert + server.deployProcess("XSDReferences"); + + server.undeployProcess("XSDReferences"); + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinHibTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinHibTest.java new file mode 100644 index 0000000..2a944ee --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinHibTest.java
@@ -0,0 +1,8 @@ +package org.apache.ode.axis2.correlation; + +public class CorrelationJoinHibTest extends CorrelationJoinTest { + @Override + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinLazyHibTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinLazyHibTest.java new file mode 100644 index 0000000..bdbc4cc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinLazyHibTest.java
@@ -0,0 +1,8 @@ +package org.apache.ode.axis2.correlation; + +public class CorrelationJoinLazyHibTest extends CorrelationJoinLazyTest { + @Override + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinLazyTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinLazyTest.java new file mode 100644 index 0000000..5765795 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinLazyTest.java
@@ -0,0 +1,65 @@ +package org.apache.ode.axis2.correlation; + +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.DummyService; +import org.apache.ode.axis2.ODEConfigDirAware; +import org.testng.annotations.Test; + +import static org.testng.Assert.*; + +public class CorrelationJoinLazyTest extends Axis2TestBase implements ODEConfigDirAware { + /** + * Tests a message being saved by no instance waiting for it. The saved message is picked up + * when the third message arrives, and is consumed. + * + * @throws Exception + */ + @Test(dataProvider="configs") + public void testCorrelationJoin() throws Exception { + final String bundleName = "TestCorrelationJoinLazy"; + + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + + new Thread() { + public void run() { + try { + Thread.sleep(3000); + server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest2.soap"); + } catch( Exception e ) { + fail(e.getMessage()); + } + } + }.start(); + + new Thread() { + public void run() { + try { + Thread.sleep(6000); + server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest3.soap"); + } catch( Exception e ) { + fail(e.getMessage()); + } + } + }.start(); + + try { + String response = server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest.soap"); + System.out.println("=>\n" + response); + assertTrue(response.contains(">1;3;2;<")); + } catch (Exception e) { + fail(e.getMessage()); + } finally { + server.undeployProcess(bundleName); + } + } + + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.jpa-derby"; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinTest.java new file mode 100644 index 0000000..891ccc9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationJoinTest.java
@@ -0,0 +1,64 @@ +package org.apache.ode.axis2.correlation; + +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.DummyService; +import org.apache.ode.axis2.ODEConfigDirAware; +import org.testng.annotations.Test; + +import static org.testng.Assert.*; + +public class CorrelationJoinTest extends Axis2TestBase implements ODEConfigDirAware { + /** + * Tests rendezvous + * + * @throws Exception + */ + @Test(dataProvider="configs") + public void testCorrelationJoin() throws Exception { + final String bundleName = "TestCorrelationJoin"; + + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + + new Thread() { + public void run() { + try { + Thread.sleep(3000); + server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest2.soap"); + } catch( Exception e ) { + fail(e.getMessage()); + } + } + }.start(); + + new Thread() { + public void run() { + try { + Thread.sleep(6000); + server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest3.soap"); + } catch( Exception e ) { + fail(e.getMessage()); + } + } + }.start(); + + try { + String response = server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest.soap"); + System.out.println("=>\n" + response); + assertTrue(response.contains(">1;2;3;<")); + } catch (Exception e) { + fail(e.getMessage()); + } finally { + server.undeployProcess(bundleName); + } + } + + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.jpa-derby"; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationMultiHibTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationMultiHibTest.java new file mode 100644 index 0000000..d772a1d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationMultiHibTest.java
@@ -0,0 +1,8 @@ +package org.apache.ode.axis2.correlation; + +public class CorrelationMultiHibTest extends CorrelationMultiTest { + @Override + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationMultiTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationMultiTest.java new file mode 100644 index 0000000..72e5243 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/correlation/CorrelationMultiTest.java
@@ -0,0 +1,46 @@ +package org.apache.ode.axis2.correlation; + +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.DummyService; +import org.apache.ode.axis2.ODEConfigDirAware; +import org.testng.annotations.Test; + +import static org.testng.Assert.*; + +public class CorrelationMultiTest extends Axis2TestBase implements ODEConfigDirAware { + @Test(dataProvider="configs") + public void testCorrelationMulti() throws Exception { + final String bundleName = "TestCorrelationMulti"; + + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + + new Thread() { + public void run() { + try { + Thread.sleep(3000); + server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest2.soap"); + } catch( Exception e ) { + fail(e.getMessage()); + } + } + }.start(); + + try { + String response = server.sendRequestFile("http://localhost:8888/processes/correlationMultiTest", + bundleName, "testRequest.soap"); + assertTrue(response.contains(">1;2;<")); + } catch (Exception e) { + fail(e.getMessage()); + } finally { + server.undeployProcess(bundleName); + } + } + + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.jpa-derby"; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/httpbinding/HttpBindingTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/httpbinding/HttpBindingTest.java new file mode 100644 index 0000000..259f937 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/httpbinding/HttpBindingTest.java
@@ -0,0 +1,118 @@ +package org.apache.ode.axis2.httpbinding; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.JettyWrapper; +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.AfterMethod; +import org.testng.annotations.BeforeMethod; +import org.testng.annotations.Test; + +import java.util.concurrent.CountDownLatch; + +/** + * <p/> + * This unit test passes an integer to a BPEL. Then the BPEL invokes the 6 operations of Arithmetics.wsdl. + * These operations are set up to use the various Http binding configurations. + * <p/> + * From a "business" standpoint:<br/> + * Let N be the input number, stored in the testRequest1.soap file<br/> + * This test will compute the Sum of the first (N + 5) positive integers. + * <p/> + * If N=10, the expected result is 15*(15+1)/2 = 120 + * + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public class HttpBindingTest extends Axis2TestBase { + + private static final Log log = LogFactory.getLog(HttpBindingTest.class); + + protected JettyWrapper jettyWrapper; + + + @BeforeMethod + protected void setUp() throws Exception { + super.setUp(); + final CountDownLatch latch = new CountDownLatch(1); + jettyWrapper = new JettyWrapper(7070); + new Thread("HttpBindingJetty") { + public void run() { + try { + jettyWrapper.start(); + latch.countDown(); + } catch (Exception e) { + e.printStackTrace(); + } + } + }.start(); + // wait for jetty to be ready + latch.await(); + } + + @AfterMethod + protected void tearDown() throws Exception { + jettyWrapper.stop(); + super.tearDown(); + } + + @Test(dataProvider="configs") + public void testHttpBinding() throws Exception { + String bundleName = "TestHttpBinding"; + // deploy the required service + if (!server.isDeployed(bundleName)) server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", + bundleName, "testRequest.soap"); + if (log.isDebugEnabled()) log.debug(response); + int valueInSoapRequest = 100; + int n = 5 + valueInSoapRequest; + String expectedResult = String.valueOf(n * (n + 1) / 2); + assertTrue("Expected Result: " + expectedResult + ". Answer was " + response, response.indexOf(expectedResult) >= 0); + } finally { + server.undeployProcess(bundleName); + } + } + + @Test(dataProvider="configs") + public void testHttpBindingExt_GET() throws Exception { + String bundleName = "TestHttpBindingExt_GET"; + executeBundle(bundleName); + + } + + @Test(dataProvider="configs") + public void testHttpBindingExt_DELETE() throws Exception { + String bundleName = "TestHttpBindingExt_DELETE"; + executeBundle(bundleName); + } + + @Test(dataProvider="configs") + public void testHttpBindingExt_POST() throws Exception { + String bundleName = "TestHttpBindingExt_POST"; + executeBundle(bundleName); + } + + @Test(dataProvider="configs") + public void testHttpBindingExt_PUT() throws Exception { + String bundleName = "TestHttpBindingExt_PUT"; + executeBundle(bundleName); + } + + private void executeBundle(String bundleName) throws InterruptedException { + // wait for jetty to be ready + // clean up everything first + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + + // then deploy the required service + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", bundleName, "testRequest.soap"); + System.out.println("Test Response Received: "+response); + if (log.isDebugEnabled()) log.debug("Test Response Received: "+response); + assertTrue("Test failed. Response is:"+response, response.indexOf("What a success!") >= 0); + } finally { + server.undeployProcess(bundleName); + } + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java new file mode 100644 index 0000000..66f53fb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureHibTest.java
@@ -0,0 +1,30 @@ +package org.apache.ode.axis2.instancecleanup; + +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.hibernate.Query; + +public class CleanFailureHibTest extends CleanFailureTest { + @Override + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + } + + @Override + protected ProcessInstanceDAO getInstance() { + return HibDaoConnectionFactoryImpl.getInstance(); + } + + @Override + protected ProcessDAO getProcess() { + return HibDaoConnectionFactoryImpl.getProcess(); + } + + @Override + protected int getLargeDataCount(int echoCount) throws Exception { + initTM(); + Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select count(id) from HLargeData as l"); + + return ((Long)query.uniqueResult()).intValue(); + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureTest.java new file mode 100644 index 0000000..93d0c04 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFailureTest.java
@@ -0,0 +1,42 @@ +package org.apache.ode.axis2.instancecleanup; + +import org.apache.ode.axis2.DummyService; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.testng.annotations.Test; + +public class CleanFailureTest extends CleanTestBase { + @Test(dataProvider="configs") + public void testCleanAll() throws Exception { + String bundleName = "TestCleanFailure"; + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + try { + initialLargeDataCount = getLargeDataCount(0); + server.sendRequestFile("http://localhost:8888/processes/helloWorld", bundleName, "testRequest.soap"); + } finally { + ProcessDAO process = getProcess(); + server.undeployProcess(bundleName); + assertProcessCleanup(process); + } + } + + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.jpa-derby"; + } + + protected ProcessInstanceDAO getInstance() { + return JpaDaoConnectionFactoryImpl.getInstance(); + } + + protected ProcessDAO getProcess() { + return JpaDaoConnectionFactoryImpl.getProcess(); + } + + @Override + protected int getLargeDataCount(int echoCount) throws Exception { + return echoCount; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java new file mode 100644 index 0000000..5e2b91b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultHibTest.java
@@ -0,0 +1,24 @@ +package org.apache.ode.axis2.instancecleanup; + +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.hibernate.Query; + +public class CleanFaultHibTest extends CleanFaultTest { + @Override + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + } + + @Override + protected ProcessInstanceDAO getInstance() { + return HibDaoConnectionFactoryImpl.getInstance(); + } + + @Override + protected int getLargeDataCount(int echoCount) throws Exception { + initTM(); + Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select count(id) from HLargeData as l"); + + return ((Long)query.uniqueResult()).intValue(); + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java new file mode 100644 index 0000000..1a0a47f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanFaultTest.java
@@ -0,0 +1,86 @@ +package org.apache.ode.axis2.instancecleanup; + +import static org.testng.AssertJUnit.fail; + +import org.apache.ode.axis2.DummyService; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.iapi.ContextException; +import org.testng.annotations.Test; + +public class CleanFaultTest extends CleanTestBase { + @Test(dataProvider="configs") + public void testCleanNone() throws Exception { + go("TestCleanFault_None", 1, 0, 0, 1, 2, 0, 4, 2, 3, 2, 38, 47); + } + + @Test(dataProvider="configs") + public void testCleanInstance() throws Exception { + try { + go("TestCleanSuccess_Instance", 0, 0, 0, 0, 3, 0, 6, 2, 3, 6, 59, 70); + fail("Shoud throw a runtime exception: you cannot use the instance category without the variables and correlations categories."); + } catch(ContextException re) {} + } + + @Test(dataProvider="configs") + public void testCleanVariables() throws Exception { + go("TestCleanFault_Variables", 1, 0, 0, 1, 2, 0, 4, 0, 0, 0, 38, 45); + } + + @Test(dataProvider="configs") + public void testCleanMessages() throws Exception { + go("TestCleanFault_Messages", 1, 0, 0, 1, 0, 0, 0, 2, 3, 2, 38, 41); + } + + @Test(dataProvider="configs") + public void testCleanCorrelations() throws Exception { + go("TestCleanFault_Correlations", 1, 0, 0, 1, 2, 0, 4, 2, 3, 2, 38, 47); + } + + @Test(dataProvider="configs") + public void testCleanEvents() throws Exception { + go("TestCleanFault_Events", 1, 0, 0, 1, 2, 0, 4, 2, 3, 2, 0, 9); + } + + @Test(dataProvider="configs") + public void testCleanMessageCorrEvents() throws Exception { + go("TestCleanFault_MessageCorrEvents", 1, 0, 0, 1, 0, 0, 0, 2, 3, 2, 0, 3); + } + + @Test(dataProvider="configs") + public void testCleanAll() throws Exception { + go("TestCleanFault_All", 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + } + + protected void go(String bundleName, int instances, int activityRecoveries, int correlationSets, int faults, int exchanges, int routes, int messsages, int partnerLinks, int scopes, int variables, int events, int largeData) throws Exception { + // deploy the required service + server.deployService(DummyService.class.getCanonicalName()); + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + ProcessDAO process = null; + try { + initialLargeDataCount = getLargeDataCount(0); + + server.sendRequestFile("http://localhost:8888/processes/helloWorld", bundleName, "testRequest.soap"); + assertInstanceCleanup(instances, activityRecoveries, correlationSets, faults, exchanges, routes, messsages, partnerLinks, scopes, variables, events, largeData); + process = assertInstanceCleanup(instances, activityRecoveries, correlationSets, faults, exchanges, routes, messsages, partnerLinks, scopes, variables, events, largeData); + } finally { + server.undeployProcess(bundleName); + assertProcessCleanup(process); + } + } + + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.jpa-derby"; + } + + @Override + protected ProcessInstanceDAO getInstance() { + return JpaDaoConnectionFactoryImpl.getInstance(); + } + + @Override + protected int getLargeDataCount(int echoCount) throws Exception { + return echoCount; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java new file mode 100644 index 0000000..6efa945 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessHibTest.java
@@ -0,0 +1,24 @@ +package org.apache.ode.axis2.instancecleanup; + +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.hibernate.Query; + +public class CleanSuccessHibTest extends CleanSuccessTest { + @Override + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.hib-derby"; + } + + @Override + protected ProcessInstanceDAO getInstance() { + return HibDaoConnectionFactoryImpl.getInstance(); + } + + @Override + protected int getLargeDataCount(int echoCount) throws Exception { + initTM(); + Query query = HibDaoConnectionFactoryImpl.getSession().createQuery("select count(id) from HLargeData as l"); + + return ((Long)query.uniqueResult()).intValue(); + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java new file mode 100644 index 0000000..55130b1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanSuccessTest.java
@@ -0,0 +1,81 @@ +package org.apache.ode.axis2.instancecleanup; + +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.iapi.ContextException; +import org.testng.annotations.Test; + +import static org.testng.AssertJUnit.fail; + +public class CleanSuccessTest extends CleanTestBase { + @Test(dataProvider="configs") + public void testCleanNone() throws Exception { + go("TestCleanSuccess_None", 1, 0, 0, 0, 3, 0, 6, 2, 3, 6, 59, 76); + } + + @Test(dataProvider="configs") + public void testCleanInstance() throws Exception { + try { + go("TestCleanSuccess_Instance", 0, 0, 0, 0, 3, 0, 6, 2, 3, 6, 59, 70); + fail("Shoud throw a runtime exception: you cannot use the instance category without the variables and correlations categories."); + } catch(ContextException re) {} + } + + @Test(dataProvider="configs") + public void testCleanVariables() throws Exception { + go("TestCleanSuccess_Variables", 1, 0, 0, 0, 3, 0, 6, 0, 0, 0, 59, 70); + } + + @Test(dataProvider="configs") + public void testCleanMessages() throws Exception { + go("TestCleanSuccess_Messages", 1, 0, 0, 0, 0, 0, 0, 2, 3, 6, 59, 65); + } + + @Test(dataProvider="configs") + public void testCleanCorrelations() throws Exception { + go("TestCleanSuccess_Correlations", 1, 0, 0, 0, 3, 0, 6, 2, 3, 6, 59, 76); + } + + @Test(dataProvider="configs") + public void testCleanEvents() throws Exception { + go("TestCleanSuccess_Events", 1, 0, 0, 0, 3, 0, 6, 2, 3, 6, 0, 17); + } + + @Test(dataProvider="configs") + public void testCleanMessageCorrEvents() throws Exception { + go("TestCleanSuccess_MessageCorrEvents", 1, 0, 0, 0, 0, 0, 0, 2, 3, 6, 0, 6); + } + + @Test(dataProvider="configs") + public void testCleanAll() throws Exception { + go("TestCleanSuccess_All", 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); + } + + protected void go(String bundleName, int instances, int activityRecoveries, int correlationSets, int faults, int exchanges, int routes, int messsages, int partnerLinks, int scopes, int variables, int events, int largeData) throws Exception { + if (server.isDeployed(bundleName)) server.undeployProcess(bundleName); + server.deployProcess(bundleName); + ProcessDAO process = null; + try { + initialLargeDataCount = getLargeDataCount(0); + + server.sendRequestFile("http://localhost:8888/processes/FirstProcess/FirstProcess/FirstProcess/Client", bundleName, "testRequest.soap"); + process = assertInstanceCleanup(instances, activityRecoveries, correlationSets, faults, exchanges, routes, messsages, partnerLinks, scopes, variables, events, largeData); + } finally { + server.undeployProcess(bundleName); + assertProcessCleanup(process); + } + } + + public String getODEConfigDir() { + return getClass().getClassLoader().getResource("webapp").getFile() + "/WEB-INF/conf.jpa-derby"; + } + + protected ProcessInstanceDAO getInstance() { + return JpaDaoConnectionFactoryImpl.getInstance(); + } + + @Override + protected int getLargeDataCount(int echoCount) throws Exception { + return echoCount; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java new file mode 100644 index 0000000..3c00798 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/CleanTestBase.java
@@ -0,0 +1,127 @@ +package org.apache.ode.axis2.instancecleanup; + +import static org.testng.AssertJUnit.assertEquals; +import static org.testng.AssertJUnit.assertTrue; + +import java.io.File; + +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.ODEConfigDirAware; +import org.apache.ode.axis2.ODEConfigProperties; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.dao.ProcessInstanceProfileDAO; +import org.apache.ode.bpel.dao.ProcessProfileDAO; +import org.apache.ode.il.EmbeddedGeronimoFactory; +import org.apache.ode.il.dbutil.Database; +import org.testng.annotations.AfterMethod; + +import javax.transaction.TransactionManager; + +public abstract class CleanTestBase extends Axis2TestBase implements ODEConfigDirAware { + protected ProfilingBpelDAOConnection daoConn; + protected TransactionManager txm; + protected int initialLargeDataCount = 0; + + @AfterMethod + protected void tearDown() throws Exception { + stopTM(); + super.tearDown(); + } + + protected void initTM() throws Exception { + if( txm != null ) { + try { + txm.commit(); + } catch( Exception e ) { + //ignore + } + } + EmbeddedGeronimoFactory factory = new EmbeddedGeronimoFactory(); + txm = factory.getTransactionManager(); + Database db = getDatabase(); + db.setTransactionManager(txm); + db.start(); + txm.begin(); + + daoConn = (ProfilingBpelDAOConnection)db.createDaoCF().getConnection(); + } + + protected void stopTM() throws Exception { + if( txm != null ) { + try { + txm.commit(); + } catch( Exception e ) { + //ignore + } + txm = null; + } + } + + protected Database getDatabase() throws Exception { + String odeConfigDir = getODEConfigDir(); + if( config == null || DO_NOT_OVERRIDE_CONFIG.equals(config) || "<jpa>".equals(config) || "<hib>".equals(config) ) { + System.out.println("Profiling config, default: " + odeConfigDir); + } else { + System.out.println("Profiling config: " + config + "."); + odeConfigDir = config; + } + File configFile = new File(odeConfigDir); + ODEConfigProperties odeProps = new ODEConfigProperties(configFile); + odeProps.load(); + Database db = new Database(odeProps); + String webappPath = getClass().getClassLoader().getResource("webapp").getFile(); + db.setWorkRoot(new File(webappPath, "/WEB-INF")); + + return db; + } + + protected TransactionManager getTransactionManager() { + return txm; + } + + protected ProcessDAO assertInstanceCleanup(int instances, int activityRecoveries, int correlationSets, int faults, int exchanges, int routes, int messsages, int partnerLinks, int scopes, int variables, int events, int largeData) throws Exception { + initTM(); + ProcessInstanceProfileDAO profile = daoConn.createProcessInstanceProfile(getInstance()); + + assertEquals("Number of instances", instances, profile.findInstancesByProcess().size()); + assertEquals("Number of activity recoveries", activityRecoveries, profile.findActivityRecoveriesByInstance().size()); + assertEquals("Number of correlation sets", correlationSets, profile.findCorrelationSetsByInstance().size()); + assertEquals("Number of faults", faults, profile.findFaultsByInstance().size()); + assertEquals("Number of message exchanges", exchanges, profile.findMessageExchangesByInstance().size()); + assertEquals("Number of message routes", routes, profile.findMessageRoutesByInstance().size()); + assertEquals("Number of messages", messsages, profile.findMessagesByInstance().size()); + assertEquals("Number of partner links", partnerLinks, profile.findPartnerLinksByInstance().size()); + assertEquals("Number of scopes", scopes, profile.findScopesByInstance().size()); + assertEquals("Number of variables", variables, profile.findXmlDataByInstance().size()); + assertEquals("Number of events", events, profile.countEventsByInstance()); + assertEquals("Number of large data", largeData, getLargeDataCount(largeData) - initialLargeDataCount); + + return profile.getProcess(); + } + + protected void assertProcessCleanup(ProcessDAO process) throws Exception { + if( process != null ) { + initTM(); + ProcessProfileDAO profile = daoConn.createProcessProfile(process); + assertTrue("Process should have been deleted.", !profile.doesProcessExist()); + assertEquals("Number of instances", 0, profile.findInstancesByProcess().size()); + assertEquals("Number of activity recoveries", 0, profile.findActivityRecoveriesByProcess().size()); + assertEquals("Number of correlation sets", 0, profile.findCorrelationSetsByProcess().size()); + assertEquals("Number of correlators", 0, profile.findCorrelatorsByProcess().size()); + assertEquals("Number of faults", 0, profile.findFaultsByProcess().size()); + assertEquals("Number of message exchanges", 0, profile.findMessageExchangesByProcess().size()); + assertEquals("Number of message routes", 0, profile.findMessageRoutesByProcess().size()); + assertEquals("Number of messages", 0, profile.findMessagesByProcess().size()); + assertEquals("Number of partner links", 0, profile.findPartnerLinksByProcess().size()); + assertEquals("Number of scopes", 0, profile.findScopesByProcess().size()); + assertEquals("Number of variables", 0, profile.findXmlDataByProcess().size()); + assertEquals("Number of events", 0, profile.countEventsByProcess()); + assertEquals("Number of large data", 0, getLargeDataCount(0) - initialLargeDataCount); + } + } + + protected abstract ProcessInstanceDAO getInstance(); + + protected abstract int getLargeDataCount(int echoCount) throws Exception; +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/HibDaoConnectionFactoryImpl.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/HibDaoConnectionFactoryImpl.java new file mode 100644 index 0000000..9a48a88 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/HibDaoConnectionFactoryImpl.java
@@ -0,0 +1,85 @@ +package org.apache.ode.axis2.instancecleanup; + +import java.util.Properties; + +import javax.sql.DataSource; +import javax.transaction.TransactionManager; + +import org.apache.ode.bpel.dao.BpelDAOConnection; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.dao.ProcessInstanceProfileDAO; +import org.apache.ode.bpel.dao.ProcessProfileDAO; +import org.apache.ode.daohib.SessionManager; +import org.apache.ode.daohib.bpel.BpelDAOConnectionFactoryImpl; +import org.apache.ode.daohib.bpel.BpelDAOConnectionImpl; +import org.apache.ode.daohib.bpel.ProcessDaoImpl; +import org.apache.ode.daohib.bpel.ProcessInstanceDaoImpl; +import org.apache.ode.daohib.bpel.ProcessInstanceProfileDaoImpl; +import org.apache.ode.daohib.bpel.ProcessProfileDaoImpl; +import org.apache.ode.daohib.bpel.hobj.HProcess; +import org.apache.ode.daohib.bpel.hobj.HProcessInstance; +import org.hibernate.MappingException; +import org.hibernate.Session; +import org.hibernate.cfg.Configuration; +import org.hibernate.event.PostInsertEvent; +import org.hibernate.event.PostInsertEventListener; + +@SuppressWarnings("serial") +public class HibDaoConnectionFactoryImpl extends BpelDAOConnectionFactoryImpl implements PostInsertEventListener { + private static SessionManager _staticSessionManager; + private static ProcessInstanceDaoImpl instance; + private static ProcessDaoImpl process; + + @Override + protected SessionManager createSessionManager(Properties properties, DataSource ds, TransactionManager tm) { + _staticSessionManager = new SessionManager(properties, ds, tm) { + @Override + public Configuration getDefaultConfiguration() throws MappingException { + Configuration conf = super.getDefaultConfiguration(); + conf.setListener("post-insert", HibDaoConnectionFactoryImpl.this); + return conf; + } + }; + + return _staticSessionManager; + } + + public BpelDAOConnection getConnection() { + return new ProfilingBpelDAOConnectionImpl(_sessionManager); + } + + public static Session getSession() { + return _staticSessionManager.getSession(); + } + + public static ProcessInstanceDAO getInstance() { + return instance; + } + + public static ProcessDaoImpl getProcess() { + return process; + } + + public void onPostInsert(PostInsertEvent e) { + if( HProcessInstance.class.equals( e.getEntity().getClass() ) ) { + instance = new ProcessInstanceDaoImpl(_sessionManager, (HProcessInstance)e.getEntity()); + } else if( HProcess.class.equals( e.getEntity().getClass() ) ) { + process = new ProcessDaoImpl(_sessionManager, (HProcess)e.getEntity()); + } + } + + public static class ProfilingBpelDAOConnectionImpl extends BpelDAOConnectionImpl implements ProfilingBpelDAOConnection { + ProfilingBpelDAOConnectionImpl(SessionManager sm) { + super(sm); + } + + public ProcessProfileDAO createProcessProfile(ProcessDAO process) { + return new ProcessProfileDaoImpl(_sm, (ProcessDaoImpl)process); + } + + public ProcessInstanceProfileDAO createProcessInstanceProfile(ProcessInstanceDAO instance) { + return new ProcessInstanceProfileDaoImpl(_sm, (ProcessInstanceDaoImpl)instance); + } + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/JpaDaoConnectionFactoryImpl.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/JpaDaoConnectionFactoryImpl.java new file mode 100644 index 0000000..19fc5d9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/JpaDaoConnectionFactoryImpl.java
@@ -0,0 +1,70 @@ +package org.apache.ode.axis2.instancecleanup; + +import java.util.Properties; + +import javax.persistence.EntityManager; + +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.dao.ProcessInstanceProfileDAO; +import org.apache.ode.bpel.dao.ProcessProfileDAO; +import org.apache.ode.dao.jpa.BPELDAOConnectionFactoryImpl; +import org.apache.ode.dao.jpa.BPELDAOConnectionImpl; +import org.apache.ode.dao.jpa.ProcessDAOImpl; +import org.apache.ode.dao.jpa.ProcessInstanceDAOImpl; +import org.apache.ode.dao.jpa.ProcessInstanceProfileDAOImpl; +import org.apache.ode.dao.jpa.ProcessProfileDAOImpl; +import org.apache.openjpa.event.LifecycleEvent; +import org.apache.openjpa.event.PersistListener; +import org.apache.openjpa.persistence.OpenJPAEntityManagerFactorySPI; + +public class JpaDaoConnectionFactoryImpl extends BPELDAOConnectionFactoryImpl implements PersistListener { + private static ProcessInstanceDAO instance; + private static ProcessDAO process; + + public static ProcessInstanceDAO getInstance() { + return instance; + } + + public static ProcessDAO getProcess() { + return process; + } + + @Override + public void init(Properties properties) { + super.init(properties); + if( _emf instanceof OpenJPAEntityManagerFactorySPI ) { + ((OpenJPAEntityManagerFactorySPI)_emf).addLifecycleListener(this, ProcessInstanceDAOImpl.class, ProcessDAOImpl.class); + } + } + + @Override + protected BPELDAOConnectionImpl createBPELDAOConnection(EntityManager em) { + return new ProfilingBPELDAOConnectionImpl(em); + } + + public void afterPersist(LifecycleEvent event) { + if( event.getSource() instanceof ProcessInstanceDAOImpl ) { + instance = (ProcessInstanceDAOImpl)event.getSource(); + } else { + process = (ProcessDAOImpl)event.getSource(); + } + } + + public void beforePersist(LifecycleEvent event) { + } + + public static class ProfilingBPELDAOConnectionImpl extends BPELDAOConnectionImpl implements ProfilingBpelDAOConnection { + public ProfilingBPELDAOConnectionImpl(EntityManager em) { + super(em); + } + + public ProcessProfileDAO createProcessProfile(ProcessDAO process) { + return new ProcessProfileDAOImpl(_em, (ProcessDAOImpl)process); + } + + public ProcessInstanceProfileDAO createProcessInstanceProfile(ProcessInstanceDAO instance) { + return new ProcessInstanceProfileDAOImpl(_em, (ProcessInstanceDAOImpl)instance); + } + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProfilingBpelDAOConnection.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProfilingBpelDAOConnection.java new file mode 100644 index 0000000..621b35d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/instancecleanup/ProfilingBpelDAOConnection.java
@@ -0,0 +1,13 @@ +package org.apache.ode.axis2.instancecleanup; + +import org.apache.ode.bpel.dao.BpelDAOConnection; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.dao.ProcessInstanceProfileDAO; +import org.apache.ode.bpel.dao.ProcessProfileDAO; + +public interface ProfilingBpelDAOConnection extends BpelDAOConnection { + ProcessProfileDAO createProcessProfile(ProcessDAO instance); + + ProcessInstanceProfileDAO createProcessInstanceProfile(ProcessInstanceDAO instance); +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java new file mode 100644 index 0000000..65f473f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/DeploymentTest.java
@@ -0,0 +1,236 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.management; + +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMFactory; +import org.apache.axiom.om.OMNamespace; +import org.apache.axiom.om.OMText; +import org.apache.axiom.om.util.Base64; +import org.apache.axis2.AxisFault; +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.service.ServiceClientUtil; +import org.apache.ode.utils.Namespaces; +import static org.testng.AssertJUnit.*; +import org.testng.annotations.AfterMethod; +import org.testng.annotations.BeforeMethod; +import org.testng.annotations.Test; + +import javax.xml.namespace.QName; +import java.io.ByteArrayOutputStream; +import java.io.InputStream; +import java.util.ArrayList; +import java.util.Iterator; + +public class DeploymentTest extends Axis2TestBase { + + private OMFactory _factory; + private ServiceClientUtil _client; + + private ArrayList<QName> _deployed = new ArrayList<QName>(); + private String _package; + + @Test + public void testDeployUndeploy() throws Exception { + // Setup and tear down are doing ost of the job here, just checking in the middle + + // Check deployment + OMElement listRoot = _client.buildMessage("listProcesses", new String[0], new String[0]); + OMElement result = sendToPM(listRoot); + + // look for DynPartnerMain-xxx + listRoot = _client.buildMessage("listProcesses", new String[] {"filter", "orderKeys"}, + new String[] {"name="+_deployed.get(0).getLocalPart(), ""}); + result = sendToPM(listRoot); + result = result.getFirstElement(); + + assertEquals("process-info-list", result.getLocalName()); + OMElement child = result.getFirstElement(); + assertNotNull("Missing deployed process", child); + assertEquals("process-info", child.getLocalName()); + OMElement pid = child.getFirstElement(); + assertEquals(_deployed.get(0).toString(), pid.getText()); + + // look for DynPartnerResponder-xxx + listRoot = _client.buildMessage("listProcesses", new String[] {"filter", "orderKeys"}, + new String[] {"name="+_deployed.get(1).getLocalPart(), ""}); + result = sendToPM(listRoot); + result = result.getFirstElement(); + assertEquals("process-info-list", result.getLocalName()); + child = result.getFirstElement(); + assertNotNull("Missing deployed process", child); + assertEquals("process-info", child.getLocalName()); + assertEquals("process-info", child.getLocalName()); + pid = child.getFirstElement(); + assertEquals(_deployed.get(1).toString(), pid.getText()); + } + + @Test + public void testListDeployedPackages() throws Exception { + OMElement root = _client.buildMessage("listDeployedPackages", new String[] {}, new String[] {}); + OMElement result = sendToDeployment(root); + assertTrue(result.toString().indexOf(_package) > 0); + } + + @Test + public void testListProcesses() throws Exception { + OMElement root = _client.buildMessage("listProcesses", new String[] {"packagesNames"}, + new String[] {_package}); + OMElement result = sendToDeployment(root); + assertTrue(result.toString().indexOf("http://ode/bpel/unit-test")>=0); + assertTrue(result.toString().indexOf("DynPartnerMain")>=0); + assertTrue(result.toString().indexOf("http://ode/bpel/responder")>=0); + assertTrue(result.toString().indexOf("DynPartnerResponder")>=0); + } + + @Test + public void testGetProcessPackage() throws Exception { + OMElement root = _client.buildMessage("getProcessPackage", new String[] {"processId"}, + new Object[] { _deployed.get(0) } ); + OMElement result = sendToDeployment(root); + assertEquals(_package, result.getText()); + + OMElement root2 = _client.buildMessage("getProcessPackage", new String[] {"processId"}, + new Object[] { _deployed.get(1) } ); + OMElement result2 = sendToDeployment(root2); + assertEquals(_package, result2.getText()); + } + + @Test + public void testMultipleDeployUndeployVersion() throws Exception { + ArrayList<String> deployed = new ArrayList<String>(); + // Testing that versions are monotonically increased + int lastVer = Integer.parseInt(_package.substring(_package.lastIndexOf("-") + 1, _package.length())); + for (int m = 1; m <= 3; m++) { + String depPack = deploy(); + int ver = Integer.parseInt(depPack.substring(depPack.lastIndexOf("-") + 1, depPack.length())); + assertEquals(lastVer + m, ver); + deployed.add(depPack); + } + // Deploying a couple of "tagged" versions + String depPack = deploy("foo"); + int ver = Integer.parseInt(depPack.substring(depPack.lastIndexOf("-") + 1, depPack.length())); + assertTrue(lastVer + 4 <= ver); + deployed.add(depPack); + + depPack = deploy("bar"); + ver = Integer.parseInt(depPack.substring(depPack.lastIndexOf("-") + 1, depPack.length())); + assertTrue(lastVer + 5 <= ver); + deployed.add(depPack); + + // Cleaning up + for (String aDeployed : deployed) { + undeploy(aDeployed); + } + } + + @BeforeMethod + protected void setUp() throws Exception { + super.setUp(); + // Create a factory + _factory = OMAbstractFactory.getOMFactory(); + _client = new ServiceClientUtil(); + + _package = deploy(); + + assertNotNull(_package); + assertEquals(2, _deployed.size()); + + Thread.sleep(1000); + } + + @AfterMethod + protected void tearDown() throws Exception { + undeploy(_package); + super.tearDown(); + } + + private String deploy(String packageName) throws Exception { + // Use the factory to create three elements + OMNamespace depns = _factory.createOMNamespace(Namespaces.ODE_PMAPI, "deployapi"); + OMElement root = _factory.createOMElement("deploy", null); + OMElement namePart = _factory.createOMElement("name", depns); + namePart.setText(packageName); + OMElement zipPart = _factory.createOMElement("package", depns); + OMElement zipElmt = _factory.createOMElement("zip", depns); + + // Add the zip to deploy + InputStream is = this.getClass().getClassLoader().getResourceAsStream("DynPartner.zip"); + ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); + byte[] buffer = new byte[4096]; + int len; + while((len = is.read(buffer)) >= 0) { + outputStream.write(buffer, 0, len); + } + String base64Enc = Base64.encode(outputStream.toByteArray()); + OMText zipContent = _factory.createOMText(base64Enc, "application/zip", true); + root.addChild(namePart); + root.addChild(zipPart); + zipPart.addChild(zipElmt); + zipElmt.addChild(zipContent); + + // Deploy + OMElement result = sendToDeployment(root); + + _deployed.clear(); + String pakage = null; + Iterator iter = result.getChildElements(); + while (iter.hasNext()) { + OMElement e = (OMElement) iter.next(); + if (e.getLocalName().equals("name")) { + pakage = e.getText(); + } + if (e.getLocalName().equals("id")) { + _deployed.add(e.getTextAsQName()); + } + } + return pakage; + } + + private String deploy() throws Exception { + return deploy("DynPartner"); + } + + private void undeploy(String pakage) throws Exception { + // Prepare undeploy message + OMNamespace depns = _factory.createOMNamespace(Namespaces.ODE_PMAPI, "deployapi"); + OMElement root = _factory.createOMElement("undeploy", depns); + OMElement part = _factory.createOMElement("packageName", null); + part.setText(pakage); + root.addChild(part); + + // Undeploy + sendToDeployment(root); + + OMElement listRoot = _client.buildMessage("listProcesses", new String[] {"filter", "orderKeys"}, + new String[] {"name=DynPartnerMain", ""}); + OMElement result = sendToPM(listRoot); + } + + private OMElement sendToPM(OMElement msg) throws AxisFault { + return _client.send(msg, "http://localhost:8888/processes/ProcessManagement"); + } + + private OMElement sendToDeployment(OMElement msg) throws AxisFault { + return _client.send(msg, "http://localhost:8888/processes/DeploymentService"); + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java new file mode 100644 index 0000000..687f0da --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/InstanceManagementTest.java
@@ -0,0 +1,254 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.management; + +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMFactory; +import org.apache.axiom.om.OMNamespace; +import org.apache.axiom.om.OMText; +import org.apache.axiom.om.util.Base64; +import org.apache.axis2.AxisFault; +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.ode.axis2.service.ServiceClientUtil; +import org.apache.ode.tools.sendsoap.cline.HttpSoapSender; +import org.apache.ode.utils.Namespaces; +import org.testng.annotations.AfterMethod; +import org.testng.annotations.BeforeMethod; +import org.testng.annotations.Test; + +import javax.xml.namespace.QName; +import java.io.ByteArrayOutputStream; +import java.io.InputStream; +import java.net.URL; +import java.text.DateFormat; +import java.text.SimpleDateFormat; +import java.util.Calendar; +import java.util.Iterator; + +public class InstanceManagementTest extends Axis2TestBase { + + private OMFactory _factory; + private DateFormat xsdDF = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm"); + private ServiceClientUtil _client; + private String _deployedName; + + @Test + public void testListInstances() throws Exception { + OMElement listRoot = _client.buildMessage("listInstances", new String[] {"filter", "order", "limit"}, + new String[] {"name=DynPartnerMain", "", "10"}); + OMElement result = sendToIM(listRoot); + // Ensures that there's only 2 process-info string (ending and closing tags) and hence only one process + assert(result.toString().split("instance-info").length == 3); + + // Another query with more options + Calendar notSoLongAgo = Calendar.getInstance(); + notSoLongAgo.add(Calendar.MINUTE, -2); + String notSoLongAgoStr = xsdDF.format(notSoLongAgo.getTime()); + listRoot = _client.buildMessage("listInstances", new String[] {"filter", "order", "limit"}, + new String[] {"name=DynPartnerResponder namespace=http://ode/bpel/responder " + + "started>=" + notSoLongAgoStr, "", "10"}); + result = sendToIM(listRoot); + assert(result.toString().split("instance-info").length == 5); + } + + // ODE-385 please fix me + @Test + public void testListAllInstances() throws Exception { + OMElement root = _client.buildMessage("listAllInstancesWithLimit", new String[] {"limit"}, new String[] {"1"}); + OMElement result = sendToIM(root); + // We shold have only one instance (so 2 opening/closing elmts) + assert(result.toString().split("instance-info").length == 3); + // And one of our executed instances are there + assert(result.toString().indexOf("DynPartnerMain") >= 0 || + result.toString().indexOf("DynPartnerResponder") >= 0); + } + + @Test + public void testInstanceSummaryListProcess() throws Exception { + OMElement listRoot = _client.buildMessage("listProcesses", new String[] {"filter", "orderKeys"}, + new String[] {"name=DynPartnerMain", ""}); + OMElement result = sendToPM(listRoot); + // Ensures that there's only 2 process-info string (ending and closing tags) and hence only one process + String ns = "http://www.apache.org/ode/pmapi/types/2006/08/02/"; + Iterator iter = result.getFirstElement().getFirstElement().getFirstChildWithName(new QName(ns, "instance-summary")) + .getChildrenWithName(new QName(ns, "instances")); + int count = 0; + while (iter.hasNext()) { + OMElement omelmt = (OMElement) iter.next(); + count += Integer.parseInt(omelmt.getAttributeValue(new QName(null, "count"))); + } + assert(count == 1); + } + + // ODE-385 please fix me + @Test(enabled = false) + public void ode_385_testGetInstanceInfo() throws Exception { + OMElement root = _client.buildMessage("listAllInstances", new String[] {}, new String[] {}); + OMElement result = sendToIM(root); + String iid = result.getFirstElement().getFirstChildWithName(new QName(Namespaces.ODE_PMAPI, "instance-info")) + .getFirstChildWithName(new QName(Namespaces.ODE_PMAPI, "iid")).getText(); + root = _client.buildMessage("getInstanceInfo", new String[] {"iid"}, new String[] {iid}); + result = sendToIM(root); + assert(result.toString().split("instance-info").length == 3); + } + + @Test + public void testGetInstanceInfoFault() throws Exception { + // Hopefully this id won't exist + OMElement root = _client.buildMessage("getInstanceInfo", new String[] {"iid"}, new String[] {"65431"}); + try { + @SuppressWarnings("unused") + OMElement result = sendToIM(root); + } catch (AxisFault axisFault) { + assert(axisFault.getCause().toString().indexOf("InstanceNotFoundException") > 0); + } + } + + // ODE-385 please fix me + @Test + public void testGetScopeInfo() throws Exception { + OMElement root = _client.buildMessage("listInstances", new String[] {"filter", "order", "limit"}, + new String[] {"name=DynPartnerMain", "", "10"}); + OMElement result = sendToIM(root); + String siid = result.getFirstElement().getFirstChildWithName(new QName(Namespaces.ODE_PMAPI, "instance-info")) + .getFirstChildWithName(new QName(Namespaces.ODE_PMAPI, "root-scope")) + .getAttributeValue(new QName(null, "siid")); + root = _client.buildMessage("getScopeInfoWithActivity", new String[] {"siid", "activityInfo"}, + new String[] {siid, "true"}); + result = sendToIM(root); + assert(result.toString().split("scope-info").length == 3); + assert(result.toString().indexOf("activity-info") >= 0); + } + + @Test + public void testGetVariableInfo() throws Exception { + OMElement root = _client.buildMessage("listInstances", new String[] {"filter", "order", "limit"}, + new String[] {"name=DynPartnerMain", "", "10"}); + OMElement result = sendToIM(root); + String siid = result.getFirstElement().getFirstChildWithName(new QName(Namespaces.ODE_PMAPI, "instance-info")) + .getFirstChildWithName(new QName(Namespaces.ODE_PMAPI, "root-scope")) + .getAttributeValue(new QName(null, "siid")); + root = _client.buildMessage("getVariableInfo", new String[] {"sid", "varName"}, new String[] {siid, "dummy"}); + result = sendToIM(root); + assert(result.toString().indexOf("fire!") >= 0); + } + + +// TODO uncomment when events querying is fixes on OpenJPA + +// public void testListEvents() throws Exception { +// OMElement root = _client.buildMessage("listEvents", new String[] {"instanceFilter", "eventFilter", "maxCount"}, +// new String[] {"", "", "0"}); +// OMElement result = sendToIM(root); +// assert(result.toString().split("event-info").length > 10); +// } +// +// public void testGetEventTimeline() throws Exception { +// OMElement root = _client.buildMessage("getEventTimeline", new String[] {"instanceFilter", "eventFilter"}, +// new String[] {"", ""}); +// OMElement result = sendToIM(root); +// assert(result.toString().split("element").length > 10); +// } + + // ODE-385 please fix me + @Test + public void testDeleteInstances() throws Exception { + OMElement root = _client.buildMessage("listAllInstancesWithLimit", new String[] {"limit"}, new String[] {"1"}); + OMElement result = sendToIM(root); + String iid = result.getFirstElement().getFirstElement().getText(); + System.out.println("=> " + result.getFirstElement().getFirstElement().getText()); + _client.buildMessage("delete", new String[] {"piid"}, new String[] {iid}); + } + + @BeforeMethod + protected void setUp() throws Exception { + super.setUp(); + + // Create a factory + _factory = OMAbstractFactory.getOMFactory(); + _client = new ServiceClientUtil(); + + // Use the factory to create three elements + OMNamespace depns = _factory.createOMNamespace(Namespaces.ODE_PMAPI, "deployapi"); + OMElement root = _factory.createOMElement("deploy", null); + OMElement namePart = _factory.createOMElement("name", depns); + namePart.setText("DynPartner"); + OMElement zipPart = _factory.createOMElement("package", depns); + OMElement zipElmt = _factory.createOMElement("zip", depns); + + // Add the zip to deploy + InputStream is = getClass().getClassLoader().getResourceAsStream("DynPartner.zip"); + ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); + for (int b = is.read(); b >= 0; b = is.read()) { + outputStream.write((byte) b); + } + String base64Enc = Base64.encode(outputStream.toByteArray()); + OMText zipContent = _factory.createOMText(base64Enc, "application/zip", true); + root.addChild(namePart); + root.addChild(zipPart); + zipPart.addChild(zipElmt); + zipElmt.addChild(zipContent); + + // Deploy + OMElement res = sendToDeployment(root); + _deployedName = res.getFirstChildWithName(new QName(null, "name")).getText(); + + // Execute + URL svcUrl = new URL("http://localhost:8888/processes/DynMainService"); + InputStream sis = this.getClass().getClassLoader().getResourceAsStream("testDynPartnerRequest.soap"); + System.out.println(HttpSoapSender.doSend(svcUrl, sis, null, 0, null, null, null)); + // Just making sure the instance starts + Thread.sleep(1000); + } + + @AfterMethod + protected void tearDown() throws Exception { + // Prepare undeploy message + OMNamespace depns = _factory.createOMNamespace(Namespaces.ODE_PMAPI, "deployapi"); + OMElement root = _factory.createOMElement("undeploy", depns); + OMElement part = _factory.createOMElement("package", null); + part.setText(_deployedName); + root.addChild(part); + + // Undeploy + sendToDeployment(root); + + OMElement listRoot = _client.buildMessage("listProcesses", new String[] {"filter", "orderKeys"}, + new String[] {"name=DynPartnerMain", ""}); + OMElement result = sendToPM(listRoot); + assert(result.toString().indexOf("process-info") < 0); + + super.tearDown(); + } + + private OMElement sendToPM(OMElement msg) throws AxisFault { + return _client.send(msg, "http://localhost:8888/processes/ProcessManagement"); + } + + private OMElement sendToIM(OMElement msg) throws AxisFault { + return _client.send(msg, "http://localhost:8888/processes/InstanceManagement"); + } + + private OMElement sendToDeployment(OMElement msg) throws AxisFault { + return _client.send(msg, "http://localhost:8888/processes/DeploymentService"); + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/RetireTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/RetireTest.java new file mode 100644 index 0000000..47d9f92 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/management/RetireTest.java
@@ -0,0 +1,37 @@ +package org.apache.ode.axis2.management; + +import org.apache.ode.axis2.Axis2TestBase; +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.Test; + +import javax.xml.namespace.QName; + +/** + * @author Matthieu Riou <mriou@apache.org> + */ +public class RetireTest extends Axis2TestBase { + + @Test(dataProvider="configs") + public void testRetiredInstance() throws Exception { + String bundleName = "TestInstanceRetire"; + System.out.println("=> " + server.getODEServer().getProcessStore().getPackages()); + if (server.isDeployed("1")) server.undeployProcess(bundleName + "/1"); + if (server.isDeployed("2")) server.undeployProcess(bundleName + "/2"); + + QName deployedQName = server.deployProcess(bundleName + "/1").iterator().next(); + + server.sendRequestFile("http://localhost:8888/processes/testretire", + bundleName + "/1", "testRequest1.soap"); + + server.getODEServer().getProcessManagement().setRetired(deployedQName, true); + server.deployProcess(bundleName + "/2"); + + String response = server.sendRequestFile("http://localhost:8888/processes/testretire", + bundleName + "/1", "testRequest2.soap"); + + System.out.println("###############################################"); + System.out.println(response); + System.out.println("###############################################"); + assertTrue(response.indexOf("DONE") > 0); + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/basic/SecuredProcessesTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/basic/SecuredProcessesTest.java new file mode 100644 index 0000000..7f1f4c9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/basic/SecuredProcessesTest.java
@@ -0,0 +1,116 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.rampart.basic; + +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.AfterClass; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.DataProvider; +import org.testng.annotations.Test; +import org.apache.axis2.context.ConfigurationContextFactory; +import org.apache.axis2.context.ConfigurationContext; +import org.apache.axis2.client.ServiceClient; +import org.apache.axis2.client.Options; +import org.apache.axis2.addressing.EndpointReference; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMNamespace; +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMFactory; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.il.OMUtils; +import org.apache.ode.axis2.Axis2TestBase; + +import java.io.File; +import java.io.FileFilter; + +/** + * + * + */ +public class SecuredProcessesTest extends Axis2TestBase { + + private String testDir = "TestRampartBasic/secured-processes"; + + + @DataProvider(name = "secured-processes-bundles") + public Object[][] testPolicySamples() throws Exception { + File[] samples = new File(getClass().getClassLoader().getResource(testDir).getFile()).listFiles(new FileFilter() { + public boolean accept(File pathname) { + return pathname.isDirectory() && pathname.getName().matches("process-sample\\d*"); + } + }); + Object[][] bundles = new Object[samples.length][]; + String clientRepo = getClass().getClassLoader().getResource(testDir).getFile(); + for (int i = 0; i < samples.length; i++) { + String sampleName = samples[i].getName(); + String clientConfigFile = clientRepo + "/" + sampleName.split("-")[1] + "-client.axis2"; + bundles[i] = new Object[]{testDir + "/" + sampleName, clientRepo, clientConfigFile}; + } + return bundles; + } + + + @BeforeClass + protected void setUp() throws Exception { + // mind the annotation above: start the server only once for all tests + startServer(testDir, "webapp/WEB-INF/conf/axis2.xml"); + } + + @AfterClass + protected void tearDown() throws Exception { + // mind the annotation above: start the server only once for all tests + super.tearDown(); + } + + @Test(dataProvider = "secured-processes-bundles") + public void invokeSecuredProcesses(String bundleName, String clientRepo, String clientConfigFile) throws Exception { + if (server.isDeployed(new File(bundleName).getName())) { + server.undeployProcess(bundleName); + } + server.deployProcess(bundleName); + try { + ConfigurationContext ctx = ConfigurationContextFactory.createConfigurationContextFromFileSystem(clientRepo, clientConfigFile); + ServiceClient client = new ServiceClient(ctx, null); + Options options = new Options(); + options.setTo(new EndpointReference("http://localhost:8888/processes/helloWorld")); + client.setOptions(options); + + OMElement responseElement = client.sendReceive(getPayload(bundleName)); + String response = DOMUtils.domToString(OMUtils.toDOM(responseElement)); + System.out.println(response); + + System.out.println(response); + assertTrue(response.contains("<helloResponse") && response.contains("Hello " + bundleName + "!")); + } finally { + server.undeployProcess(bundleName); + } + } + + private static OMElement getPayload(String value) { + OMFactory factory = OMAbstractFactory.getOMFactory(); + OMNamespace ns = factory.createOMNamespace("http://ode/bpel/unit-test.wsdl", "ns1"); + OMElement elem = factory.createOMElement("hello", ns); + OMElement childElem = factory.createOMElement("TestPart", null); + childElem.setText(value); + elem.addChild(childElem); + + return elem; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/basic/SecuredServicesTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/basic/SecuredServicesTest.java new file mode 100644 index 0000000..6f7b912 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/basic/SecuredServicesTest.java
@@ -0,0 +1,87 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.rampart.basic; + +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.AfterClass; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.DataProvider; +import org.testng.annotations.Test; +import org.testng.annotations.BeforeTest; +import org.testng.annotations.AfterTest; +import org.apache.axis2.transport.http.server.SimpleHttpServer; +import org.apache.axis2.transport.http.SimpleHTTPServer; +import org.apache.ode.axis2.Axis2TestBase; + +import java.io.File; +import java.io.FileFilter; + +/** + * + * + */ +public class SecuredServicesTest extends Axis2TestBase { + + private String testDir= "TestRampartBasic/secured-services"; + + @DataProvider(name = "secured-services-bundles") + public Object[][] testPolicySamples() throws Exception { + File[] policies = new File(getClass().getClassLoader().getResource(testDir).getFile()).listFiles(new FileFilter() { + public boolean accept(File pathname) { + return pathname.isDirectory() && pathname.getName().matches("process-sample\\d*"); + } + }); + Object[][] bundles = new Object[policies.length][]; + for (int i = 0; i < policies.length; i++) { + bundles[i] = new Object[]{testDir + "/" + policies[i].getName()}; + } +// bundles = new Object[][]{new Object[]{"TestRampartBasic/process-basic-sample02"}}; + return bundles; + } + + + @BeforeClass + protected void setUp() throws Exception { + // mind the annotation above: start the server only once for all tests + startServer(testDir, "webapp/WEB-INF/conf/axis2.xml"); + } + + @AfterClass + protected void tearDown() throws Exception { + // mind the annotation above: start the server only once for all tests + super.tearDown(); + } + + @Test(dataProvider = "secured-services-bundles") + public void executeProcess(String bundleName) throws Exception { + if (server.isDeployed(new File(bundleName).getName())) { + server.undeployProcess(bundleName); + } + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", + bundleName, "testRequest.soap"); + System.out.println(response); + assertTrue(response.contains("helloResponse") && response.contains("Hello World")); + } finally { + server.undeployProcess(bundleName); + } + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/policy/SecuredProcessesTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/policy/SecuredProcessesTest.java new file mode 100644 index 0000000..fc454a4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/policy/SecuredProcessesTest.java
@@ -0,0 +1,132 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.rampart.policy; + +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.AfterClass; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.DataProvider; +import org.testng.annotations.Test; +import org.apache.axis2.context.ConfigurationContextFactory; +import org.apache.axis2.context.ConfigurationContext; +import org.apache.axis2.client.ServiceClient; +import org.apache.axis2.client.Options; +import org.apache.axis2.addressing.EndpointReference; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMNamespace; +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMFactory; +import org.apache.axiom.om.impl.builder.StAXOMBuilder; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.il.OMUtils; +import org.apache.ode.axis2.Axis2TestBase; +import org.apache.neethi.PolicyEngine; +import org.apache.neethi.Policy; +import org.apache.rampart.RampartMessageData; + +import java.io.File; +import java.io.FileFilter; + +/** + * + * + */ +public class SecuredProcessesTest extends Axis2TestBase { + + private String testDir = "TestRampartPolicy/secured-processes"; + + + @DataProvider(name = "secured-processes-bundles") + public Object[][] testPolicySamples() throws Exception { + File[] samples = new File(getClass().getClassLoader().getResource(testDir).getFile()).listFiles(new FileFilter() { + public boolean accept(File pathname) { + return pathname.isDirectory() && pathname.getName().matches("process-sample\\d*"); + } + }); + Object[][] bundles = new Object[samples.length][]; + String clientRepo = getClass().getClassLoader().getResource(testDir).getFile(); + for (int i = 0; i < samples.length; i++) { + String sampleIndex = samples[i].getName().replace("process-", ""); + String policyFile = clientRepo + "/" + sampleIndex + "-policy.xml"; + bundles[i] = new Object[]{testDir + "/" + samples[i].getName(), clientRepo, policyFile}; + } +// bundles = new Object[][]{new Object[]{testDir+"/process-sample04", clientRepo, clientRepo+"/sample04-policy.xml"}}; + return bundles; + } + + + @BeforeClass + protected void setUp() throws Exception { + // mind the annotation above: start the server only once for all tests + startServer(testDir, "webapp/WEB-INF/conf/axis2.xml"); + } + + @AfterClass + protected void tearDown() throws Exception { + // mind the annotation above: start the server only once for all tests + super.tearDown(); + } + + @Test(dataProvider = "secured-processes-bundles") + public void invokeSecuredProcesses(String bundleName, String clientRepo, String policyFile) throws Exception { + if (server.isDeployed(new File(bundleName).getName())) { + server.undeployProcess(bundleName); + } + server.deployProcess(bundleName); + try { + ConfigurationContext ctx = ConfigurationContextFactory.createConfigurationContextFromFileSystem(clientRepo, null); + ServiceClient client = new ServiceClient(ctx, null); + Options options = new Options(); + // Rampart SymetricBinding (sample04) blows up if not provided with a soap action + options.setAction(""); + options.setTo(new EndpointReference("http://localhost:8888/processes/helloWorld")); + options.setProperty(RampartMessageData.KEY_RAMPART_POLICY, loadPolicy(policyFile)); + client.setOptions(options); + + client.engageModule("rampart"); + client.engageModule("rahas"); + + OMElement responseElement = client.sendReceive(getPayload(bundleName)); + String response = DOMUtils.domToString(OMUtils.toDOM(responseElement)); + System.out.println(response); + + System.out.println(response); + assertTrue(response.contains("<helloResponse") && response.contains("Hello " + bundleName + "!")); + } finally { + server.undeployProcess(bundleName); + } + } + + private static Policy loadPolicy(String xmlPath) throws Exception { + StAXOMBuilder builder = new StAXOMBuilder(xmlPath); + return PolicyEngine.getPolicy(builder.getDocumentElement()); + } + + private static OMElement getPayload(String value) { + OMFactory factory = OMAbstractFactory.getOMFactory(); + OMNamespace ns = factory.createOMNamespace("http://ode/bpel/unit-test.wsdl", "ns1"); + OMElement elem = factory.createOMElement("hello", ns); + OMElement childElem = factory.createOMElement("TestPart", null); + childElem.setText(value); + elem.addChild(childElem); + + return elem; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/policy/SecuredServicesTest.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/policy/SecuredServicesTest.java new file mode 100644 index 0000000..60d4000 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/axis2/rampart/policy/SecuredServicesTest.java
@@ -0,0 +1,82 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.rampart.policy; + +import static org.testng.AssertJUnit.assertTrue; +import org.testng.annotations.AfterClass; +import org.testng.annotations.BeforeClass; +import org.testng.annotations.DataProvider; +import org.testng.annotations.Test; +import org.apache.ode.axis2.Axis2TestBase; + +import java.io.File; +import java.io.FileFilter; + +/** + * + * + */ +public class SecuredServicesTest extends Axis2TestBase { + + private String testDir = "TestRampartPolicy/secured-services"; + + @DataProvider(name = "secured-services-bundles") + public Object[][] testPolicySamples() throws Exception { + File[] policies = new File(getClass().getClassLoader().getResource(testDir).getFile()).listFiles(new FileFilter() { + public boolean accept(File pathname) { + return pathname.isDirectory() && pathname.getName().matches("process-sample\\d*\\-policy"); + } + }); + Object[][] bundles = new Object[policies.length][]; + for (int i = 0; i < policies.length; i++) { + bundles[i] = new Object[]{testDir + "/" + policies[i].getName()}; + } + return bundles; + } + + + @BeforeClass + protected void setUp() throws Exception { + // mind the annotation above also + startServer(testDir, "webapp/WEB-INF/conf/axis2.xml"); + } + + @AfterClass + protected void tearDown() throws Exception { + // simply change the annotation, see above + super.tearDown(); + } + + @Test(dataProvider = "secured-services-bundles") + public void executeProcess(String bundleName) throws Exception { + if (server.isDeployed(new File(bundleName).getName())) { + server.undeployProcess(bundleName); + } + server.deployProcess(bundleName); + try { + String response = server.sendRequestFile("http://localhost:8888/processes/helloWorld", + bundleName, "testRequest.soap"); + System.out.println(response); + assertTrue(response.contains("helloResponse") && response.contains("Hello World")); + } finally { + server.undeployProcess(bundleName); + } + } +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/bpel/dao/ProcessInstanceProfileDAO.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/bpel/dao/ProcessInstanceProfileDAO.java new file mode 100644 index 0000000..ea18f03 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/bpel/dao/ProcessInstanceProfileDAO.java
@@ -0,0 +1,46 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.bpel.dao; + +import java.util.List; + +public interface ProcessInstanceProfileDAO extends ProcessProfileDAO { + ProcessDAO getProcess(); + + List<ActivityRecoveryDAO> findActivityRecoveriesByInstance(); + + List<CorrelationSetDAO> findCorrelationSetsByInstance(); + + List<FaultDAO> findFaultsByInstance(); + + List<MessageDAO> findMessagesByInstance(); + + List<MessageExchangeDAO> findMessageExchangesByInstance(); + + List<MessageRouteDAO> findMessageRoutesByInstance(); + + List<PartnerLinkDAO> findPartnerLinksByInstance(); + + List<ScopeDAO> findScopesByInstance(); + + List<XmlDataDAO> findXmlDataByInstance(); + + int countEventsByInstance(); +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/bpel/dao/ProcessProfileDAO.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/bpel/dao/ProcessProfileDAO.java new file mode 100644 index 0000000..adcf958 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/bpel/dao/ProcessProfileDAO.java
@@ -0,0 +1,50 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.bpel.dao; + +import java.util.List; + +public interface ProcessProfileDAO { + boolean doesProcessExist(); + + List<ProcessInstanceDAO> findInstancesByProcess(); + + List<ActivityRecoveryDAO> findActivityRecoveriesByProcess(); + + List<CorrelationSetDAO> findCorrelationSetsByProcess(); + + List<CorrelatorDAO> findCorrelatorsByProcess(); + + List<FaultDAO> findFaultsByProcess(); + + List<MessageDAO> findMessagesByProcess(); + + List<MessageExchangeDAO> findMessageExchangesByProcess(); + + List<MessageRouteDAO> findMessageRoutesByProcess(); + + List<PartnerLinkDAO> findPartnerLinksByProcess(); + + List<ScopeDAO> findScopesByProcess(); + + List<XmlDataDAO> findXmlDataByProcess(); + + int countEventsByProcess(); +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/ProcessInstanceProfileDAO.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/ProcessInstanceProfileDAO.java new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/ProcessInstanceProfileDAO.java
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/ProcessProfileDAO.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/ProcessProfileDAO.java new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/ProcessProfileDAO.java
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/jpa/ProcessInstanceProfileDAOImpl.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/jpa/ProcessInstanceProfileDAOImpl.java new file mode 100644 index 0000000..d4da78f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/jpa/ProcessInstanceProfileDAOImpl.java
@@ -0,0 +1,109 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.dao.jpa; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.dao.ActivityRecoveryDAO; +import org.apache.ode.bpel.dao.CorrelationSetDAO; +import org.apache.ode.bpel.dao.FaultDAO; +import org.apache.ode.bpel.dao.MessageDAO; +import org.apache.ode.bpel.dao.MessageExchangeDAO; +import org.apache.ode.bpel.dao.MessageRouteDAO; +import org.apache.ode.bpel.dao.PartnerLinkDAO; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceProfileDAO; +import org.apache.ode.bpel.dao.ScopeDAO; +import org.apache.ode.bpel.dao.XmlDataDAO; + +import java.util.List; + +import javax.persistence.EntityManager; +import javax.persistence.Query; + +/** + * OpenJPA based {@link ProcessInstanceProfileDAO} implementation + */ +public class ProcessInstanceProfileDAOImpl extends ProcessProfileDAOImpl implements ProcessInstanceProfileDAO { + @SuppressWarnings("unused") + private static final Log __log = LogFactory.getLog(ProcessInstanceProfileDAOImpl.class); + + private ProcessInstanceDAOImpl instance; + + public ProcessInstanceProfileDAOImpl(EntityManager em, ProcessInstanceDAOImpl instance) { + super(em, (ProcessDAOImpl)instance.getProcess()); + this.instance = instance; + } + + public ProcessDAO getProcess() { + return process; + } + + public List<MessageExchangeDAO> findMessageExchangesByInstance() { + return findByInstance("select x from MessageExchangeDAOImpl as x where x._processInst = :instance"); + } + + public List<MessageRouteDAO> findMessageRoutesByInstance() { + return findByInstance("select r from MessageRouteDAOImpl as r where r._processInst = :instance"); + } + + public List<MessageDAO> findMessagesByInstance() { + return findByInstance("select m from MessageDAOImpl as m where m._messageExchange._processInst = :instance"); + } + + public List<PartnerLinkDAO> findPartnerLinksByInstance() { + return findByInstance("select p from PartnerLinkDAOImpl as p where p._scope._processInstance = :instance"); + } + + public List<ScopeDAO> findScopesByInstance() { + return findByInstance("select s from ScopeDAOImpl as s where s._processInstance = :instance"); + } + + public List<XmlDataDAO> findXmlDataByInstance() { + return findByInstance("select x from XmlDataDAOImpl as x where x._scope._processInstance = :instance"); + } + + public List<ActivityRecoveryDAO> findActivityRecoveriesByInstance() { + return findByInstance("select a from ActivityRecoveryDAOImpl as a where a._instance = :instance"); + } + + public List<CorrelationSetDAO> findCorrelationSetsByInstance() { + return findByInstance("select s from CorrelationSetDAOImpl as s where s._scope._processInstance = :instance"); + } + + public List<FaultDAO> findFaultsByInstance() { + return findByInstance("select f from FaultDAOImpl as f where f._id in (select i._fault from ProcessInstanceDAOImpl as i where i = :instance and i._fault is not null)"); + } + + public int countEventsByInstance() { + Query query = em.createQuery("select count(e._id) from EventDAOImpl as e where e._instance = :instance"); + query.setParameter("instance", instance); + + return ((Long)query.getSingleResult()).intValue(); + } + + @SuppressWarnings("unchecked") + protected <D> List<D> findByInstance(String queryString) { + Query query = em.createQuery(queryString); + query.setParameter("instance", instance); + + return query.getResultList(); + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/jpa/ProcessProfileDAOImpl.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/jpa/ProcessProfileDAOImpl.java new file mode 100644 index 0000000..01f467f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/dao/jpa/ProcessProfileDAOImpl.java
@@ -0,0 +1,122 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.dao.jpa; + +import java.util.List; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.dao.ActivityRecoveryDAO; +import org.apache.ode.bpel.dao.CorrelationSetDAO; +import org.apache.ode.bpel.dao.CorrelatorDAO; +import org.apache.ode.bpel.dao.FaultDAO; +import org.apache.ode.bpel.dao.MessageDAO; +import org.apache.ode.bpel.dao.MessageExchangeDAO; +import org.apache.ode.bpel.dao.MessageRouteDAO; +import org.apache.ode.bpel.dao.PartnerLinkDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.dao.ProcessProfileDAO; +import org.apache.ode.bpel.dao.ScopeDAO; +import org.apache.ode.bpel.dao.XmlDataDAO; + +import javax.persistence.EntityManager; +import javax.persistence.Query; + +/** + * OpenJPA based {@link ProcessProfileDAO} implementation + */ +public class ProcessProfileDAOImpl extends OpenJPADAO implements ProcessProfileDAO { + @SuppressWarnings("unused") + private static final Log __log = LogFactory.getLog(ProcessProfileDAOImpl.class); + + protected EntityManager em; + protected ProcessDAOImpl process; + + public ProcessProfileDAOImpl(EntityManager em, ProcessDAOImpl process) { + this.process = process; + this.em = em; + } + + public boolean doesProcessExist() { + Query query = em.createQuery("select count(p._id) from ProcessDAOImpl as p where p._guid = :guid"); + query.setParameter("guid", process.getGuid()); + + return ((Long)query.getSingleResult()) > 0; + } + + public List<ProcessInstanceDAO> findInstancesByProcess() { + return findByProcess("select i from ProcessInstanceDAOImpl as i where i._process = :process"); + } + + public List<MessageExchangeDAO> findMessageExchangesByProcess() { + return findByProcess("select x from MessageExchangeDAOImpl as x where x._processInst._process = :process"); + } + + public List<MessageRouteDAO> findMessageRoutesByProcess() { + return findByProcess("select r from MessageRouteDAOImpl as r where r._processInst._process = :process"); + } + + public List<MessageDAO> findMessagesByProcess() { + return findByProcess("select m from MessageDAOImpl as m where m._messageExchange._process = :process"); + } + + public List<PartnerLinkDAO> findPartnerLinksByProcess() { + return findByProcess("select p from PartnerLinkDAOImpl as p where p._scope._processInstance._process = :process"); + } + + public List<ScopeDAO> findScopesByProcess() { + return findByProcess("select s from ScopeDAOImpl as s where s._processInstance._process = :process"); + } + + public List<XmlDataDAO> findXmlDataByProcess() { + return findByProcess("select x from XmlDataDAOImpl as x where x._scope._processInstance._process = :process"); + } + + public List<ActivityRecoveryDAO> findActivityRecoveriesByProcess() { + return findByProcess("select a from ActivityRecoveryDAOImpl as a where a._instance._process = :process"); + } + + public List<CorrelationSetDAO> findCorrelationSetsByProcess() { + return findByProcess("select s from CorrelationSetDAOImpl as s where s._scope._processInstance._process = :process"); + } + + public List<CorrelatorDAO> findCorrelatorsByProcess() { + return findByProcess("select c from CorrelatorDAOImpl as c where c._process = :process"); + } + + public List<FaultDAO> findFaultsByProcess() { + return findByProcess("select f from FaultDAOImpl as f where f._id in(select i._fault from ProcessInstanceDAOImpl as i where i._process = :process and i._fault is not null)"); + } + + public int countEventsByProcess() { + Query query = em.createQuery("select count(e._id) from EventDAOImpl as e where e._instance._process = :process"); + query.setParameter("process", process); + + return ((Long)query.getSingleResult()).intValue(); + } + + @SuppressWarnings("unchecked") + protected <D> List<D> findByProcess(String queryString) { + Query query = em.createQuery(queryString); + query.setParameter("process", process); + + return query.getResultList(); + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/daohib/bpel/ProcessInstanceProfileDaoImpl.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/daohib/bpel/ProcessInstanceProfileDaoImpl.java new file mode 100644 index 0000000..ff5525d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/daohib/bpel/ProcessInstanceProfileDaoImpl.java
@@ -0,0 +1,135 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.daohib.bpel; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.dao.ActivityRecoveryDAO; +import org.apache.ode.bpel.dao.CorrelationSetDAO; +import org.apache.ode.bpel.dao.FaultDAO; +import org.apache.ode.bpel.dao.MessageDAO; +import org.apache.ode.bpel.dao.MessageExchangeDAO; +import org.apache.ode.bpel.dao.MessageRouteDAO; +import org.apache.ode.bpel.dao.PartnerLinkDAO; +import org.apache.ode.bpel.dao.ProcessDAO; +import org.apache.ode.bpel.dao.ProcessInstanceProfileDAO; +import org.apache.ode.bpel.dao.ScopeDAO; +import org.apache.ode.bpel.dao.XmlDataDAO; +import org.apache.ode.daohib.SessionManager; +import org.apache.ode.daohib.bpel.hobj.HActivityRecovery; +import org.apache.ode.daohib.bpel.hobj.HCorrelationSet; +import org.apache.ode.daohib.bpel.hobj.HCorrelatorSelector; +import org.apache.ode.daohib.bpel.hobj.HFaultData; +import org.apache.ode.daohib.bpel.hobj.HMessage; +import org.apache.ode.daohib.bpel.hobj.HMessageExchange; +import org.apache.ode.daohib.bpel.hobj.HPartnerLink; +import org.apache.ode.daohib.bpel.hobj.HScope; +import org.apache.ode.daohib.bpel.hobj.HXmlData; +import org.hibernate.Query; + +import java.lang.reflect.Constructor; +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +/** + * Hibernate based {@link ProcessInstanceProfileDao} implementation + */ +public class ProcessInstanceProfileDaoImpl extends ProcessProfileDaoImpl implements ProcessInstanceProfileDAO { + @SuppressWarnings("unused") + private static final Log __log = LogFactory.getLog(ProcessInstanceProfileDaoImpl.class); + + private ProcessInstanceDaoImpl instance; + + public ProcessInstanceProfileDaoImpl(SessionManager sm, ProcessInstanceDaoImpl instance) { + super(sm, (ProcessDaoImpl)instance.getProcess()); + entering("ProcessInstanceProfileDaoImpl.ProcessInstanceProfileDaoImpl"); + this.instance = instance; + } + + public SessionManager getSessionManager() { + return _sm; + } + + public ProcessDAO getProcess() { + return process; + } + + public List<MessageExchangeDAO> findMessageExchangesByInstance() { + return findByInstance("from HMessageExchange as x where x.instance = :instance)", MessageExchangeDaoImpl.class, HMessageExchange.class); + } + + public List<MessageRouteDAO> findMessageRoutesByInstance() { + return findByInstance("from HCorrelatorSelector as s where s.instance = :instance", MessageRouteDaoImpl.class, HCorrelatorSelector.class); + } + + public List<MessageDAO> findMessagesByInstance() { + return findByInstance("from HMessage as m where m.messageExchange.instance = :instance)", MessageDaoImpl.class, HMessage.class); + } + + public List<PartnerLinkDAO> findPartnerLinksByInstance() { + return findByInstance("from HPartnerLink as p where p.scope.instance = :instance)", PartnerLinkDAOImpl.class, HPartnerLink.class); + } + + public List<ScopeDAO> findScopesByInstance() { + return findByInstance("from HScope as s where s.instance = :instance)", ScopeDaoImpl.class, HScope.class); + } + + public List<XmlDataDAO> findXmlDataByInstance() { + return findByInstance("from HXmlData as x where x.instance = :instance", XmlDataDaoImpl.class, HXmlData.class); + } + + public List<ActivityRecoveryDAO> findActivityRecoveriesByInstance() { + return findByInstance("from HActivityRecovery as a where a.instance = :instance", ActivityRecoveryDaoImpl.class, HActivityRecovery.class); + } + + public List<CorrelationSetDAO> findCorrelationSetsByInstance() { + return findByInstance("from HCorrelationSet as s where s.instance = :instance", CorrelationSetDaoImpl.class, HCorrelationSet.class); + } + + public List<FaultDAO> findFaultsByInstance() { + return findByInstance("from HFaultData as f where f in (select i.fault from HProcessInstance as i where i = :instance and i.fault is not null)", FaultDAOImpl.class, HFaultData.class); + } + + public int countEventsByInstance() { + Query query = getSession().createQuery("select count(id) from HBpelEvent as e where e.instance = :instance"); + query.setParameter("instance", instance._hobj); + + return ((Long)query.uniqueResult()).intValue(); + } + + @SuppressWarnings("unchecked") + protected <D, H> List<D> findByInstance(String queryString, Class daoClass, Class hibClass) { + List<D> results = new ArrayList<D>(); + + try { + Query query = getSession().createQuery(queryString); + query.setParameter("instance", instance._hobj); + for( H hibObj : (Collection<H>)query.list()) { + Constructor<D> c = daoClass.getConstructor(SessionManager.class, hibClass); + results.add( c.newInstance(_sm, hibObj) ); + } + } catch( Exception e ) { + throw new RuntimeException(e); + } + + return results; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/daohib/bpel/ProcessProfileDaoImpl.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/daohib/bpel/ProcessProfileDaoImpl.java new file mode 100644 index 0000000..57eae93 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/ode/daohib/bpel/ProcessProfileDaoImpl.java
@@ -0,0 +1,156 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.daohib.bpel; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.dao.ActivityRecoveryDAO; +import org.apache.ode.bpel.dao.CorrelationSetDAO; +import org.apache.ode.bpel.dao.CorrelatorDAO; +import org.apache.ode.bpel.dao.FaultDAO; +import org.apache.ode.bpel.dao.MessageDAO; +import org.apache.ode.bpel.dao.MessageExchangeDAO; +import org.apache.ode.bpel.dao.MessageRouteDAO; +import org.apache.ode.bpel.dao.PartnerLinkDAO; +import org.apache.ode.bpel.dao.ProcessInstanceDAO; +import org.apache.ode.bpel.dao.ProcessProfileDAO; +import org.apache.ode.bpel.dao.ScopeDAO; +import org.apache.ode.bpel.dao.XmlDataDAO; +import org.apache.ode.daohib.SessionManager; +import org.apache.ode.daohib.bpel.hobj.HActivityRecovery; +import org.apache.ode.daohib.bpel.hobj.HCorrelationSet; +import org.apache.ode.daohib.bpel.hobj.HCorrelator; +import org.apache.ode.daohib.bpel.hobj.HCorrelatorSelector; +import org.apache.ode.daohib.bpel.hobj.HFaultData; +import org.apache.ode.daohib.bpel.hobj.HMessage; +import org.apache.ode.daohib.bpel.hobj.HMessageExchange; +import org.apache.ode.daohib.bpel.hobj.HPartnerLink; +import org.apache.ode.daohib.bpel.hobj.HProcess; +import org.apache.ode.daohib.bpel.hobj.HProcessInstance; +import org.apache.ode.daohib.bpel.hobj.HScope; +import org.apache.ode.daohib.bpel.hobj.HXmlData; +import org.hibernate.Query; + +import java.lang.reflect.Constructor; +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +/** + * Hibernate based {@link ProcessProfileDAO} implementation + */ +public class ProcessProfileDaoImpl extends HibernateDao implements ProcessProfileDAO { + @SuppressWarnings("unused") + private static final Log __log = LogFactory.getLog(ProcessProfileDaoImpl.class); + + protected ProcessDaoImpl process; + + public ProcessProfileDaoImpl(SessionManager sm, ProcessDaoImpl process) { + super(sm, process._hobj); + entering("ProcessProfileDaoImpl.ProcessProfileDaoImpl"); + this.process = process; + } + + public SessionManager getSessionManager() { + return _sm; + } + + @SuppressWarnings("unchecked") + public boolean doesProcessExist() { + boolean exists = false; + + Query query = getSession().createQuery("select count(id) from HProcess as p where p.guid = :guid"); + query.setParameter("guid", ((HProcess)process._hobj).getGuid()); + for( Long cnt : (List<Long>)query.list()) { + exists = cnt.intValue() > 0; + } + + return exists; + } + + public List<ProcessInstanceDAO> findInstancesByProcess() { + return findByProcess("from HProcessInstance as i where i.process = :process)", ProcessInstanceDaoImpl.class, HProcessInstance.class); + } + + public List<MessageExchangeDAO> findMessageExchangesByProcess() { + return findByProcess("from HMessageExchange as x where x.instance.process = :process)", MessageExchangeDaoImpl.class, HMessageExchange.class); + } + + public List<MessageRouteDAO> findMessageRoutesByProcess() { + return findByProcess("from HCorrelatorSelector as s where s.instance.process = :process)", MessageRouteDaoImpl.class, HCorrelatorSelector.class); + } + + public List<MessageDAO> findMessagesByProcess() { + return findByProcess("from HMessage as m where m.messageExchange.process = :process)", MessageDaoImpl.class, HMessage.class); + } + + public List<PartnerLinkDAO> findPartnerLinksByProcess() { + return findByProcess("from HPartnerLink as p where p.process = :process)", PartnerLinkDAOImpl.class, HPartnerLink.class); + } + + public List<ScopeDAO> findScopesByProcess() { + return findByProcess("from HScope as s where s.instance.process = :process", ScopeDaoImpl.class, HScope.class); + } + + public List<XmlDataDAO> findXmlDataByProcess() { + return findByProcess("from HXmlData as x where x.instance.process = :process", XmlDataDaoImpl.class, HXmlData.class); + } + + public List<ActivityRecoveryDAO> findActivityRecoveriesByProcess() { + return findByProcess("from HActivityRecovery as a where a.instance.process = :process", ActivityRecoveryDaoImpl.class, HActivityRecovery.class); + } + + public List<CorrelationSetDAO> findCorrelationSetsByProcess() { + return findByProcess("from HCorrelationSet as s where s.process = :process", CorrelationSetDaoImpl.class, HCorrelationSet.class); + } + + public List<CorrelatorDAO> findCorrelatorsByProcess() { + return findByProcess("from HCorrelator as c where c.process = :process", CorrelatorDaoImpl.class, HCorrelator.class); + } + + public List<FaultDAO> findFaultsByProcess() { + return findByProcess("from HFaultData as f where f in (select i.fault from HProcessInstance as i where i.process = :process and i.fault is not null)", FaultDAOImpl.class, HFaultData.class); + } + + public int countEventsByProcess() { + Query query = getSession().createQuery("select count(id) from HBpelEvent as e where e.instance.process = :process"); + query.setParameter("process", process._hobj); + + return ((Long)query.uniqueResult()).intValue(); + } + + @SuppressWarnings("unchecked") + protected <D, H> List<D> findByProcess(String queryString, Class daoClass, Class hibClass) { + List<D> results = new ArrayList<D>(); + + try { + Query query = getSession().createQuery(queryString); + query.setParameter("process", process._hobj); + for( H hibObj : (Collection<H>)query.list()) { + Constructor<D> c = daoClass.getConstructor(SessionManager.class, hibClass); + results.add( c.newInstance(_sm, hibObj) ); + } + } catch( Exception e ) { + throw new RuntimeException(e); + } + + return results; + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample01/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample01/PWCBHandler.java new file mode 100644 index 0000000..467892e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample01/PWCBHandler.java
@@ -0,0 +1,49 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.policy.sample01; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + + //When the server side need to authenticate the user + WSPasswordCallback pwcb = (WSPasswordCallback) callbacks[i]; + if (pwcb.getUsage() == WSPasswordCallback.USERNAME_TOKEN_UNKNOWN) { + if (pwcb.getIdentifer().equals("alice") && pwcb.getPassword().equals("bobPW")) { + return; + } else { + throw new UnsupportedCallbackException(callbacks[i], "check failed"); + } + } + + //When the client requests for the password to be added in to the + //UT element + pwcb.setPassword("bobPW"); + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample02/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample02/PWCBHandler.java new file mode 100644 index 0000000..684fb99 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample02/PWCBHandler.java
@@ -0,0 +1,42 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.policy.sample02; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample03/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample03/PWCBHandler.java new file mode 100644 index 0000000..2d8ef1f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample03/PWCBHandler.java
@@ -0,0 +1,42 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.policy.sample03; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample04/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample04/PWCBHandler.java new file mode 100644 index 0000000..c3b3a47 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample04/PWCBHandler.java
@@ -0,0 +1,42 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.policy.sample04; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample05/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample05/PWCBHandler.java new file mode 100644 index 0000000..e2573d6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/policy/sample05/PWCBHandler.java
@@ -0,0 +1,42 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.policy.sample05; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample02/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample02/PWCBHandler.java new file mode 100644 index 0000000..35074f4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample02/PWCBHandler.java
@@ -0,0 +1,40 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample02; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + String id = pwcb.getIdentifer(); + if("bob".equals(id)) { + pwcb.setPassword("bobPW"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample03/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample03/PWCBHandler.java new file mode 100644 index 0000000..cb52caf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample03/PWCBHandler.java
@@ -0,0 +1,51 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample03; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + + for (int i = 0; i < callbacks.length; i++) { + + //When the server side need to authenticate the user + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + if (pwcb.getUsage() == WSPasswordCallback.USERNAME_TOKEN_UNKNOWN) { + if(pwcb.getIdentifer().equals("bob") && pwcb.getPassword().equals("bobPW")) { + //If authentication successful, simply return + return; + } else { + throw new UnsupportedCallbackException(callbacks[i], "check failed"); + } + } + + //When the client requests for the password to be added in to the + //UT element + pwcb.setPassword("bobPW"); + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample04/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample04/PWCBHandler.java new file mode 100644 index 0000000..557755c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample04/PWCBHandler.java
@@ -0,0 +1,43 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample04; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample05/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample05/PWCBHandler.java new file mode 100644 index 0000000..b5f97d4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample05/PWCBHandler.java
@@ -0,0 +1,43 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample05; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample06/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample06/PWCBHandler.java new file mode 100644 index 0000000..148b24d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample06/PWCBHandler.java
@@ -0,0 +1,43 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample06; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample07/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample07/PWCBHandler.java new file mode 100644 index 0000000..2169966 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample07/PWCBHandler.java
@@ -0,0 +1,43 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample07; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample08/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample08/PWCBHandler.java new file mode 100644 index 0000000..98c13be --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample08/PWCBHandler.java
@@ -0,0 +1,43 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample08; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample09/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample09/PWCBHandler.java new file mode 100644 index 0000000..92adde4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample09/PWCBHandler.java
@@ -0,0 +1,50 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample09; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + private static final byte[] key = { + + (byte) 0x31, (byte) 0xfd, (byte) 0xcb, (byte) 0xda, (byte) 0xfb, + + (byte) 0xcd, (byte) 0x6b, (byte) 0xa8, (byte) 0xe6, (byte) 0x19, + + (byte) 0xa7, (byte) 0xbf, (byte) 0x51, (byte) 0xf7, (byte) 0xc7, + + (byte) 0x3e }; + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback) callbacks[i]; + + if (pwcb.getUsage() == WSPasswordCallback.KEY_NAME) { + pwcb.setKey(key); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample10/PWCBHandler.java b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample10/PWCBHandler.java new file mode 100644 index 0000000..2675cdb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/java/org/apache/rampart/samples/sample10/PWCBHandler.java
@@ -0,0 +1,43 @@ +/* + * Copyright 2004,2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.rampart.samples.sample10; + +import org.apache.ws.security.WSPasswordCallback; + +import javax.security.auth.callback.Callback; +import javax.security.auth.callback.CallbackHandler; +import javax.security.auth.callback.UnsupportedCallbackException; + +import java.io.IOException; + +public class PWCBHandler implements CallbackHandler { + + public void handle(Callback[] callbacks) throws IOException, + UnsupportedCallbackException { + for (int i = 0; i < callbacks.length; i++) { + WSPasswordCallback pwcb = (WSPasswordCallback)callbacks[i]; + + String id = pwcb.getIdentifer(); + if("client".equals(id)) { + pwcb.setPassword("apache"); + } else if("service".equals(id)) { + pwcb.setPassword("apache"); + } + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/DynPartner.zip b/_br-ode-1.X.svn/axis2-war/src/test/resources/DynPartner.zip new file mode 100644 index 0000000..db70831 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/DynPartner.zip Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/HelloWorld2.bpel new file mode 100644 index 0000000..c91cdd5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/HelloWorld2.bpel
@@ -0,0 +1,53 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpws:process exitOnStandardFault="yes" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + name="HelloWorld2" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + targetNamespace="http://ode/bpel/unit-test" + xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:tns="http://ode/bpel/unit-test" xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:myns="myns"> + <bpws:import importType="http://schemas.xmlsoap.org/wsdl/" + location="HelloWorld2.wsdl" namespace="http://ode/bpel/unit-test.wsdl"/> + <bpws:partnerLinks> + <bpws:partnerLink myRole="me" name="helloPartnerLink" partnerLinkType="test:HelloPartnerLinkType"/> + </bpws:partnerLinks> + <bpws:variables> + <bpws:variable messageType="test:helloRequest" name="inVar"/> + <bpws:variable type="myns:MagicPixie" name="tmpVar" /> + <bpws:variable messageType="test:helloResponse" name="outVar"/> + </bpws:variables> + <bpws:sequence> + <bpws:receive createInstance="yes" name="start" + operation="hello" partnerLink="helloPartnerLink" + portType="test:HelloPortType" variable="inVar"/> + <bpws:assign name="assign1" validate="yes"> + <bpws:copy> + <bpws:from variable="inVar" part="parameters"> + <bpws:query>myns:in</bpws:query> + </bpws:from> + <bpws:to variable="tmpVar"/> + </bpws:copy> + <bpws:copy> + <bpws:from> + <bpws:literal> + <myns:helloResponse> + <myns:out xmlns:foo="xsn:foo" myattr="foo:bar"/> + </myns:helloResponse> + </bpws:literal> + </bpws:from> + <bpws:to variable="outVar" part="parameters"/> + </bpws:copy> + <bpws:copy> + <bpws:from>$tmpVar</bpws:from> + <bpws:to variable="outVar" part="parameters"> + <bpws:query>myns:out</bpws:query> + </bpws:to> + </bpws:copy> + </bpws:assign> + <bpws:reply name="end" operation="hello" + partnerLink="helloPartnerLink" portType="test:HelloPortType" variable="outVar"/> + </bpws:sequence> +</bpws:process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/HelloWorld2.wsdl new file mode 100644 index 0000000..0fb76c7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/HelloWorld2.wsdl
@@ -0,0 +1,106 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:myns="myns" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + + <wsdl:types> + <xsd:schema attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="myns"> + + <xsd:complexType name="MagicPixie"> + <xsd:sequence> + <xsd:element name="value" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="DustyMagicPixie"> + <xsd:complexContent> + <xsd:extension base="myns:MagicPixie"> + <xsd:sequence> + <xsd:element name="dust" type="xsd:string"/> + </xsd:sequence> + </xsd:extension> + </xsd:complexContent> + </xsd:complexType> + + <xsd:element name="hello"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="in" type="myns:MagicPixie" nillable="false" minOccurs="1" maxOccurs="1"/> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + <xsd:element name="helloResponse"> + <xsd:complexType> + <xsd:sequence> + <xsd:element name="out" type="myns:MagicPixie" nillable="false" minOccurs="1" maxOccurs="1"/> + </xsd:sequence> + </xsd:complexType> + </xsd:element> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="myns:hello" /> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="myns:helloResponse" /> + </wsdl:message> + + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:helloRequest" name="helloRequest" /> + <wsdl:output message="tns:helloResponse" name="helloResponse" /> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction=""/> + <wsdl:input name="helloRequest"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="helloResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/attrNSWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + <plnk:role name="you" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/chooseLanguage.xsl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/chooseLanguage.xsl new file mode 100644 index 0000000..3193cb9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/chooseLanguage.xsl
@@ -0,0 +1,12 @@ +<xsl:stylesheet version="2.0" + xmlns:inspection="http://schemas.xmlsoap.org/ws/2001/10/inspection/" + xmlns:xsl="http://www.w3.org/1999/XSL/Transform" + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsl:output omit-xml-declaration="yes"/> + + <xsl:template match="/"> + <xsl:value-of select="document('language.xml')//languages/language [@name='french']/text()"/> + </xsl:template> +</xsl:stylesheet> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/deploy.xml new file mode 100644 index 0000000..2b03487 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/deploy.xml
@@ -0,0 +1,31 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl"> + + + <process name="pns:HelloWorld2"> + <!--in-memory>false</in-memory--> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/language.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/language.xml new file mode 100644 index 0000000..ba81efd --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/language.xml
@@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?> +<languages> + <language name="english"> + Hello World + </language> + <language name="french"> + Bonjour!! + </language> + <language name="spanish"> + Hola!! + </language> + <language name="urban"> + Yo! + </language> +</languages>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/testRequest.soap new file mode 100644 index 0000000..f814e78 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestAttributeNamespaces/testRequest.soap
@@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:myns="myns"> + <soapenv:Header/> + <soapenv:Body> + <myns:hello> + <myns:in xsi:type="myns:DustyMagicPixie"> + <myns:value>Test message</myns:value> + <myns:dust>fooo</myns:dust> + </myns:in> + </myns:hello> + </soapenv:Body> +</soapenv:Envelope> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/TestCorrelation1.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/TestCorrelation1.bpel new file mode 100644 index 0000000..4e966fd --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/TestCorrelation1.bpel
@@ -0,0 +1,85 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--> + +<process + name="TestCorrelation1" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:ws2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:ws2.0:sublang:xpath2.0"> + + <import location="TestCorrelation1.wsdl" + namespace="http://ode/bpel/unit-test/testCorrelation1.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="testCorrelation1PL" partnerLinkType="test:testCorrelation1Request" myRole="testCorrelation1Service"/> + </partnerLinks> + <scope name="scope1"> + <variables> + <variable messageType="test:operation1Request" name="input1"/> + <variable messageType="test:operation2Request" name="input2"/> + <variable messageType="test:operation3Request" name="input3"/> + <variable messageType="test:operation3Response" name="output3"/> + </variables> + <correlationSets> + <correlationSet name="correlationSet1" properties="test:testCorrelation1Variable1"/> + </correlationSets> + <flow> + <sequence> + <receive name="receive1" createInstance="yes" operation="operation1" partnerLink="testCorrelation1PL" portType="test:testCorrelation1PT" variable="input1"> + <correlations> + <correlation set="correlationSet1" initiate="yes"></correlation> + </correlations> + </receive> + <scope name="scope2"> + <correlationSets> + <correlationSet name="correlationSet2" properties="test:testCorrelation1Variable1"/> + </correlationSets> + <flow> + <sequence> + <receive name="receive2" createInstance="no" operation="operation2" partnerLink="testCorrelation1PL" portType="test:testCorrelation1PT" variable="input2"> + <correlations> + <correlation set="correlationSet1" initiate="no"></correlation> + <correlation initiate="yes" set="correlationSet2"/> + </correlations> + </receive> + <receive name="receive3" createInstance="no" operation="operation3" partnerLink="testCorrelation1PL" portType="test:testCorrelation1PT" variable="input3"> + <correlations> + <correlation initiate="no" set="correlationSet2"/> + </correlations> + </receive> + <assign name="assign1"> + <copy> + <from>$input2.newParameter1/ns0:from</from> + <to part="newParameter2" variable="output3"/> + </copy> + </assign> + <reply name="reply" operation="operation3" partnerLink="testCorrelation1PL" portType="test:testCorrelation1PT" variable="output3"/> + </sequence> + </flow> + </scope> + </sequence> + </flow> + </scope> +</process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/TestCorrelation1.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/TestCorrelation1.wsdl new file mode 100644 index 0000000..76c70ea --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/TestCorrelation1.wsdl
@@ -0,0 +1,106 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:ns0="http://www.w3schools.com" + xmlns:ns1="http://ode/bpel/unit-test/testCorrelation1.wsdl.types" + xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + <wsdl:types> + <xsd:schema targetNamespace="http://ode/bpel/unit-test/testCorrelation1.wsdl.types" xmlns="http://ode/bpel/unit-test/testCorrelation1.wsdl.types" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:element name="simpleString" type="xsd:string"/> + </xsd:schema> + <xs:schema elementFormDefault="qualified" targetNamespace="http://www.w3schools.com" xmlns="http://www.w3schools.com" xmlns:xs="http://www.w3.org/2001/XMLSchema"> + + <xs:element name="note"> + <xs:complexType> + <xs:sequence> + <xs:element name="to" type="xs:string"/> + <xs:element name="from" type="xs:string"/> + <xs:element name="heading" type="xs:string"/> + <xs:element name="body" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + </xs:schema> + </wsdl:types> + <wsdl:message name="operation2Request"> + <wsdl:part name="newParameter1" element="ns0:note"/> + </wsdl:message> + <wsdl:message name="operation3Request"> + <wsdl:part name="newParameter1" element="ns1:simpleString"/> + </wsdl:message> + <wsdl:message name="operation1Request"> + <wsdl:part name="newParameter1" type="xsd:string"/> + </wsdl:message> + <wsdl:message name="operation3Response"> + <wsdl:part name="newParameter2" type="xsd:string"/> + </wsdl:message> + <wsdl:portType name="testCorrelation1PT"> + <wsdl:operation name="operation3"> + <wsdl:input name="operation3Input" message="tns:operation3Request"/> + <wsdl:output name="operation3Output" message="tns:operation3Response"/> + </wsdl:operation> + <wsdl:operation name="operation2"> + <wsdl:input name="operation2Input" message="tns:operation2Request"/> + </wsdl:operation> + <wsdl:operation name="operation1"> + <wsdl:input name="operation1Input" message="tns:operation1Request"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="testCorrelation1Binding" type="tns:testCorrelation1PT"> + <wsdl:operation name="operation3"> + <wsdl:input name="operation3Input"> </wsdl:input> + <wsdl:output name="operation3Output"> </wsdl:output> + </wsdl:operation> + <wsdl:operation name="operation2"> + <wsdl:input name="operation2Input"> </wsdl:input> + </wsdl:operation> + <wsdl:operation name="operation1"> + <wsdl:input name="operation1Input"> </wsdl:input> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="testCorrelation1Service"> + <wsdl:port name="testCorrelation1Port" binding="tns:testCorrelation1Binding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="testCorrelation1Request"> + <plnk:role name="testCorrelation1Service" portType="testCorrelation1PT"/> + </plnk:partnerLinkType> + + <prop:property name="testCorrelation1Variable1" type="xsd:string"/> + <prop:propertyAlias messageType="tns:operation2Request" part="newParameter1" propertyName="tns:testCorrelation1Variable1"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0">ns0:to</prop:query> + </prop:propertyAlias> + <prop:propertyAlias messageType="tns:operation3Request" part="newParameter1" propertyName="tns:testCorrelation1Variable1"> + </prop:propertyAlias> + <prop:propertyAlias messageType="tns:operation1Request" part="newParameter1" propertyName="tns:testCorrelation1Variable1"> + </prop:propertyAlias> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/deploy.xml new file mode 100644 index 0000000..56dcc7c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/deploy.xml
@@ -0,0 +1,31 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--> + +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test/testCorrelation1" + xmlns:wns="http://ode/bpel/unit-test/testCorrelation1.wsdl"> + + + <process name="pns:TestCorrelation1"> + <active>true</active> + <provide partnerLink="testCorrelation1PL"> + <service name="wns:testCorrelation1Service" port="testCorrelation1Port"/> + </provide> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test1.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test1.properties new file mode 100644 index 0000000..17d9b74 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test1.properties
@@ -0,0 +1,21 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +namespace=http://ode/bpel/unit-test/testCorrelation1.wsdl +service=testCorrelation1Service +operation=operation1 +request1=<message><newParameter1>To Test</newParameter1></message> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test2.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test2.properties new file mode 100644 index 0000000..96a83ac --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test2.properties
@@ -0,0 +1,21 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +namespace=http://ode/bpel/unit-test/testCorrelation1.wsdl +service=testCorrelation1Service +operation=operation2 +request1=<message><newParameter1><tns2:note xmlns:tns2="http://www.w3schools.com"><tns2:to>To Test</tns2:to><tns2:from>From Test</tns2:from><tns2:heading>x</tns2:heading><tns2:body>x</tns2:body></tns2:note></newParameter1></message> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test3.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test3.properties new file mode 100644 index 0000000..d05dd24 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/test3.properties
@@ -0,0 +1,22 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +namespace=http://ode/bpel/unit-test/testCorrelation1.wsdl +service=testCorrelation1Service +operation=operation3 +request1=<message><newParameter1><ns0:simpleString xmlns:ns0="http://ode/bpel/unit-test/testCorrelation1.wsdl.types">To Test</ns0:simpleString></newParameter1></message> +response1=.*From Test.* \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/testRequest.soap new file mode 100644 index 0000000..a2a286c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanCorrelation_None/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <message><requestMessageData><requestID>Start Test5.1</requestID><requestText>Event Start Test5.1</requestText><requestEnd>no</requestEnd></requestMessageData></message> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/TimeService.wsdl new file mode 100644 index 0000000..c51e270 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://fake.nonexistentsite.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/deploy.xml new file mode 100644 index 0000000..5d1e674 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/deploy.xml
@@ -0,0 +1,21 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always" /> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFailure/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/deploy.xml new file mode 100644 index 0000000..a78eb7f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always" /> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_All/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/deploy.xml new file mode 100644 index 0000000..f0dbd2d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/deploy.xml
@@ -0,0 +1,36 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always"> + <category>correlations</category> + </cleanup> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Correlations/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/deploy.xml new file mode 100644 index 0000000..f6da043 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/deploy.xml
@@ -0,0 +1,36 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always"> + <category>events</category> + </cleanup> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Events/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/deploy.xml new file mode 100644 index 0000000..99da99d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/deploy.xml
@@ -0,0 +1,36 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always"> + <category>instance</category> + </cleanup> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Instance/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/deploy.xml new file mode 100644 index 0000000..fca366e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/deploy.xml
@@ -0,0 +1,38 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always"> + <category>messages</category> + <category>correlations</category> + <category>events</category> + </cleanup> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_MessageCorrEvents/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/deploy.xml new file mode 100644 index 0000000..ba0f6e9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/deploy.xml
@@ -0,0 +1,36 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always"> + <category>messages</category> + </cleanup> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Messages/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/deploy.xml new file mode 100644 index 0000000..91278e6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_None/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/HelloWorld2.bpel new file mode 100644 index 0000000..815cc4a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/HelloWorld2.bpel
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/deploy.xml new file mode 100644 index 0000000..424eb21 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/deploy.xml
@@ -0,0 +1,36 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + <cleanup on="always"> + <category>variables</category> + </cleanup> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/dummy-service.wsdl new file mode 100644 index 0000000..7ee46fc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/dummy-service.wsdl
@@ -0,0 +1,184 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanFault_Variables/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/deploy.xml new file mode 100644 index 0000000..5d1e674 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/deploy.xml
@@ -0,0 +1,21 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always" /> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_All/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/deploy.xml new file mode 100644 index 0000000..2028c44 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/deploy.xml
@@ -0,0 +1,23 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always"> + <dd:category>correlations</dd:category> + </dd:cleanup> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Correlations/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/deploy.xml new file mode 100644 index 0000000..529dd8d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/deploy.xml
@@ -0,0 +1,23 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always"> + <dd:category>events</dd:category> + </dd:cleanup> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Events/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/deploy.xml new file mode 100644 index 0000000..6d3bebb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--> + +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test/testFaultHandlers" + xmlns:wns="http://ode/bpel/unit-test/testFaultHandlers.wsdl"> + + + <process name="pns:TestFaultHandlersProcess"> + <active>true</active> + <provide partnerLink="request"> + <service name="wns:testFaultHandlersService" port="wns:testFaultHandlersPort"/> + </provide> + <invoke partnerLink="probe"> + <service name="ignore" port="ignore"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/test.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/test.properties new file mode 100644 index 0000000..c567f1b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/test.properties
@@ -0,0 +1,26 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +namespace=http://ode/bpel/unit-test/testFaultHandlers.wsdl +service=testFaultHandlersService +operation=request +request1=<message><requestID>Start Test2.1</requestID><requestText>Event Start Test2.1</requestText><faultIndicator1>yes</faultIndicator1><faultIndicator2>no</faultIndicator2></message> +response1=.*Event Start Test2.1 -> throw testFault -> caught testFault -> process complete.* +request2=<message><requestID>Start Test2.2</requestID><requestText>Event Start Test2.2</requestText><faultIndicator1>no</faultIndicator1><faultIndicator2>yes</faultIndicator2></message> +response2=.*Event Start Test2.2 -> throw unknown fault -> caught fault with catchAll.* +request3=<message><requestID>Start Test2.3</requestID><requestText>Event Start Test2.3</requestText><faultIndicator1>no</faultIndicator1><faultIndicator2>no</faultIndicator2></message> +response3=.*Event Start Test2.3 -> process complete.* \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/testFaultHandlers.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/testFaultHandlers.bpel new file mode 100644 index 0000000..bc23142 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/testFaultHandlers.bpel
@@ -0,0 +1,234 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--> + +<process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://docs.oasis-open.org/wsbpel/2.0/process/executable ../../../../../../../bpel-schemas/src/main/resources/wsbpel_executable.xsd" + xmlns:tns="http://ode/bpel/unit-test/testFaultHandlers" + xmlns:wns="http://ode/bpel/unit-test/testFaultHandlers.wsdl" + xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + name="TestFaultHandlersProcess" + targetNamespace="http://ode/bpel/unit-test/testFaultHandlers" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + suppressJoinFailure="yes"> + + <import location="testFaultHandlers.wsdl" + namespace="http://ode/bpel/unit-test/testFaultHandlers.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + <import location="../ProbeService/probeService.wsdl" + namespace="http://ode/bpel/unit-test/ProbeService.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + +<!-- Unit test fault handlers --> +<!-- throw --> +<!-- catch --> +<!-- catchAll --> + + <partnerLinks> + <partnerLink name="request" partnerLinkType="wns:testFaultHandlersRequest" myRole="testFaultHandlersService"/> + <partnerLink name="probe" partnerLinkType="wns:probeRequest" partnerRole="probeService" initializePartnerRole="yes"/> + </partnerLinks> + + <variables> + <variable name="request" + messageType="wns:requestMessage"/> + <variable name="probeInput" + messageType="prb:probeMessage"/> + <variable name="reply" + messageType="wns:replyMessage"/> + </variables> + + <faultHandlers> + <catchAll> + <sequence> + <assign> + <copy> + <from> + <literal><![CDATA[caught fault with catchAll]]></literal> + </from> + <to variable="probeInput" part="probeName"/> + </copy> + </assign> + <invoke name="allFaultProbe" partnerLink="probe" + portType="prb:probeMessagePT" + operation="probe" + inputVariable="probeInput" + outputVariable="probeInput"> + </invoke> + + <!-- copy internal accumulators to the reply message --> + + <assign name="allFaultAssign"> + <copy> + <from variable="probeInput" part="probeName"/> + <to variable="reply" part="replyID"/> + </copy> + <copy> + <from variable="probeInput" part="probeData"/> + <to variable="reply" part="replyText"/> + </copy> + </assign> + + <reply name="allFaultReply" partnerLink="request" portType="wns:testFaultHandlersPT" + operation="request" variable="reply"> + </reply> + </sequence> + </catchAll> + </faultHandlers> + + <sequence> + + <receive name="receive1" partnerLink="request" + portType="wns:testFaultHandlersPT" + operation="request" variable="request" + createInstance="yes"> + </receive> + + <!-- Copy input variables to internal accumulators --> + + <assign name="assign1"> + <copy> + <from variable="request" part="requestID"/> + <to variable="probeInput" part="probeName"/> + </copy> + <copy> + <from variable="request" part="requestText"/> + <to variable="probeInput" part="probeData"/> + </copy> + </assign> + + <scope name="scopeOne"> + <faultHandlers> + <catch faultName="tns:testFault"> + <sequence> + + <assign> + <copy> + <from> + <literal><![CDATA[caught testFault]]></literal> + </from> + <to variable="probeInput" part="probeName"/> + </copy> + </assign> + <invoke name="testFaultProbe" partnerLink="probe" + portType="prb:probeMessagePT" + operation="probe" + inputVariable="probeInput" + outputVariable="probeInput"> + </invoke> + + <!-- copy internal accumulators to the reply message --> + + <assign name="testFaultAssign"> + <copy> + <from variable="probeInput" part="probeName"/> + <to variable="reply" part="replyID"/> + </copy> + <copy> + <from variable="probeInput" part="probeData"/> + <to variable="reply" part="replyText"/> + </copy> + </assign> + + </sequence> + </catch> + </faultHandlers> + + <if> + <!-- throws a named fault --> + <condition>$request.faultIndicator1 = 'yes'</condition> + <sequence> + <assign> + <copy> + <from> + <literal><![CDATA[throw testFault]]></literal> + </from> + <to variable="probeInput" part="probeName"/> + </copy> + </assign> + <invoke name="probe1" partnerLink="probe" + portType="prb:probeMessagePT" + operation="probe" + inputVariable="probeInput" + outputVariable="probeInput"> + </invoke> + <throw faultName="tns:testFault"/> + </sequence> + <!-- throws an unknown fault --> + <elseif> + <condition>$request.faultIndicator2 = 'yes'</condition> + <sequence> + <assign> + <copy> + <from> + <literal><![CDATA[throw unknown fault]]></literal> + </from> + <to variable="probeInput" part="probeName"/> + </copy> + </assign> + <invoke name="probe1" partnerLink="probe" + portType="prb:probeMessagePT" + operation="probe" + inputVariable="probeInput" + outputVariable="probeInput"> + </invoke> + + <throw faultName="tns:unknownFault"/> + </sequence> + </elseif> + </if> + </scope> + + <assign> + <copy> + <from> + <literal><![CDATA[process complete]]></literal> + </from> + <to variable="probeInput" part="probeName"/> + </copy> + </assign> + + <invoke name="probe2" partnerLink="probe" + portType="prb:probeMessagePT" + operation="probe" + inputVariable="probeInput" + outputVariable="probeInput"> + </invoke> + + <!-- copy internal accumulators to the reply message --> + + <assign name="assign2"> + <copy> + <from variable="probeInput" part="probeName"/> + <to variable="reply" part="replyID"/> + </copy> + <copy> + <from variable="probeInput" part="probeData"/> + <to variable="reply" part="replyText"/> + </copy> + </assign> + + <reply name="reply" partnerLink="request" portType="wns:testFaultHandlersPT" + operation="request" variable="reply"> + </reply> + + + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/testFaultHandlers.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/testFaultHandlers.wsdl new file mode 100644 index 0000000..217ff8f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Fault/testFaultHandlers.wsdl
@@ -0,0 +1,66 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. +--> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test/testFaultHandlers.wsdl" + xmlns:tns="http://ode/bpel/unit-test/testFaultHandlers.wsdl" + xmlns="http://ode/bpel/unit-test/testFaultHandlers.wsdl" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:prb="http://ode/bpel/unit-test/ProbeService.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + + <wsdl:message name="requestMessage"> + <wsdl:part name="requestID" type="xsd:string"/> + <wsdl:part name="requestText" type="xsd:string"/> + <wsdl:part name="faultIndicator1" type="xsd:string"/> + <wsdl:part name="faultIndicator2" type="xsd:string"/> + </wsdl:message> + + <wsdl:message name="replyMessage"> + <wsdl:part name="replyID" type="xsd:string"/> + <wsdl:part name="replyText" type="xsd:string"/> + </wsdl:message> + + + <wsdl:portType name="testFaultHandlersPT"> + <wsdl:operation name="request"> + <wsdl:input message="requestMessage"/> + <wsdl:output message="replyMessage"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="testFaultHandlersBinding" type="tns:testFaultHandlersPT"> + <wsdl:operation name="request"> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="testFaultHandlersService"> + <wsdl:port name="testFaultHandlersPort" binding="tns:testFaultHandlersBinding"> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="testFaultHandlersRequest"> + <plnk:role name="testFaultHandlersService" portType="testFaultHandlersPT"/> + </plnk:partnerLinkType> + + <plnk:partnerLinkType name="probeRequest"> + <plnk:role name="probeService" portType="prb:probeMessagePT"/> + </plnk:partnerLinkType> + +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/deploy.xml new file mode 100644 index 0000000..e2a0cfa --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/deploy.xml
@@ -0,0 +1,23 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always"> + <dd:category>instance</dd:category> + </dd:cleanup> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Instance/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/deploy.xml new file mode 100644 index 0000000..9eb2ab0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/deploy.xml
@@ -0,0 +1,25 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always"> + <dd:category>messages</dd:category> + <dd:category>correlations</dd:category> + <dd:category>events</dd:category> + </dd:cleanup> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_MessageCorrEvents/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/deploy.xml new file mode 100644 index 0000000..9243fed --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/deploy.xml
@@ -0,0 +1,23 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always"> + <dd:category>messages</dd:category> + </dd:cleanup> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Messages/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/deploy.xml new file mode 100644 index 0000000..a4f780a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/deploy.xml
@@ -0,0 +1,20 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_None/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess-FirstProcess.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess-FirstProcess.bpel new file mode 100644 index 0000000..0932adc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess-FirstProcess.bpel
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:bpmn="http://www.intalio.com/bpms" xmlns:atomic="http://ode.apache.org/atomicScope" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="FirstProcess" bpmn:id="_MmE9YDEVEdyJMOclT3liPQ" name="FirstProcess" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <bpel:import namespace="http://example.com/FirstProcess" location="FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="firstProcessAndClientPlkVar" partnerLinkType="diag:FirstProcessAndClient" myRole="FirstProcess_for_Client"/> + <bpel:partnerLink name="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" partnerLinkType="diag:TimeServerAndFirstProcessForPortTimeServiceSoapPlk" initializePartnerRole="true" partnerRole="TimeServer_for_FirstProcess"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="timeServiceGetCityTimeResponseMsg" messageType="TimeService:getCityTimeSoapOut"/> + <bpel:variable name="timeServiceGetCityTimeRequestMsg" messageType="TimeService:getCityTimeSoapIn"/> + <bpel:variable name="timeServiceGetUTCTimeResponseMsg" messageType="TimeService:getUTCTimeSoapOut"/> + <bpel:variable name="timeServiceGetUTCTimeRequestMsg" messageType="TimeService:getUTCTimeSoapIn"/> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_PodJQDEVEdyJMOclT3liPQ"></bpel:receive> + <bpel:assign name="init-variables-FirstProcess"> + <bpel:copy bpmn:label="$timeServiceGetCityTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getCityTime> + <TimeService:city></TimeService:city> +</TimeService:getCityTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$timeServiceGetUTCTimeRequestMsg"> + <bpel:from> + <bpel:literal> +<TimeService:getUTCTime></TimeService:getUTCTime></bpel:literal> + </bpel:from> + <bpel:to>$timeServiceGetUTCTimeRequestMsg.parameters</bpel:to> + </bpel:copy> + <bpel:copy bpmn:label="$thisEventStartMessageResponse"> + <bpel:from> + <bpel:literal> +<ns:TimeResponse> + <ns:UTCTime></ns:UTCTime> + <ns:cityTime></ns:cityTime> +</ns:TimeResponse></bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getUTCTime" inputVariable="timeServiceGetUTCTimeRequestMsg" outputVariable="timeServiceGetUTCTimeResponseMsg" bpmn:label="getUTCTime" bpmn:id="_dyOQkDEmEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$thisEventStartMessageRequest.body/ns:city</bpel:from> + <bpel:to>$timeServiceGetCityTimeRequestMsg.parameters/TimeService:city</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar" portType="TimeService:TimeServiceSoap" operation="getCityTime" inputVariable="timeServiceGetCityTimeRequestMsg" outputVariable="timeServiceGetCityTimeResponseMsg" bpmn:label="getCityTime" bpmn:id="_SsKx4DEVEdyJMOclT3liPQ"></bpel:invoke> + <bpel:assign bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"> + <bpel:copy> + <bpel:from>$timeServiceGetCityTimeResponseMsg.parameters/TimeService:getCityTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:cityTime</bpel:to> + </bpel:copy> + <bpel:copy> + <bpel:from>$timeServiceGetUTCTimeResponseMsg.parameters/TimeService:getUTCTimeResult</bpel:from> + <bpel:to>$thisEventStartMessageResponse.body/ns:UTCTime</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:reply partnerLink="firstProcessAndClientPlkVar" portType="this:ForClient" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="_UAjK4DEVEdyJMOclT3liPQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess-FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess-FirstProcess.wsdl new file mode 100644 index 0000000..7d3a236 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess-FirstProcess.wsdl
@@ -0,0 +1,37 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" xmlns:GetTime="http://bpms.intalio.com/FirstProcess/Time" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xml="http://www.w3.org/XML/1998/namespace" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/FirstProcess/FirstProcess" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess/FirstProcess"> + <wsdl:types> + <xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time"> + <xs:include schemaLocation="GetTime.xsd"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="ns:TimeRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="ns:TimeResponse"/> + </wsdl:message> + <wsdl:portType name="ForClient"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForClient" type="this:ForClient"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/FirstProcess/FirstProcess/ForClient/EventStartMessage"/> + <wsdl:input name="EventStartMessage"> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output name="EventStartMessageResponse"> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForClient"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForClient"> + <soap:address location="http://localhost:8080/ode/processes/FirstProcess/FirstProcess/FirstProcess/Client"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess.svg b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess.svg new file mode 100644 index 0000000..66bce00 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess.svg
@@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" version="1.0" width="90mm" height="50mm"><text x="10%" y="10%" fill="black" font-size="12"><tspan x="10" dy="20">SVG will be generated at deployment.</tspan><tspan x="10" dy="20">Change the preferences to generate</tspan><tspan x="10" dy="20">it all the time.</tspan></text></svg> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess.wsdl new file mode 100644 index 0000000..a550bcc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/FirstProcess.wsdl
@@ -0,0 +1,11 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:FirstProcess="http://example.com/FirstProcess/FirstProcess" xmlns:Client="http://example.com/FirstProcess/Client" xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" xmlns:TimeService="http://ws.intalio.com/TimeService/" xmlns:diag="http://example.com/FirstProcess" xmlns:bpel="http://docs.oasis-open.org/wsbpel/2.0/process/executable" xmlns:pnlk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://example.com/FirstProcess"> + <wsdl:import namespace="http://example.com/FirstProcess/FirstProcess" location="FirstProcess-FirstProcess.wsdl"/> + <wsdl:import namespace="http://ws.intalio.com/TimeService/" location="TimeService.wsdl"/> + <pnlk:partnerLinkType name="TimeServerAndFirstProcessForPortTimeServiceSoapPlk"> + <pnlk:role name="TimeServer_for_FirstProcess" portType="TimeService:TimeServiceSoap"/> + </pnlk:partnerLinkType> + <pnlk:partnerLinkType name="FirstProcessAndClient"> + <pnlk:role name="FirstProcess_for_Client" portType="FirstProcess:ForClient"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/GetTime.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/GetTime.xsd new file mode 100644 index 0000000..26c6678 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/GetTime.xsd
@@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="utf-8"?> +<xs:schema targetNamespace="http://bpms.intalio.com/FirstProcess/Time" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + elementFormDefault="qualified"> + + + <xs:element name="TimeRequest"> + <xs:complexType> + <xs:sequence> + <xs:element name="city" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + + <xs:element name="TimeResponse"> + <xs:complexType> + <xs:sequence> + <xs:element name="UTCTime" type="xs:string"/> + <xs:element name="cityTime" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + +</xs:schema> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/TimeService.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/TimeService.wsdl new file mode 100644 index 0000000..5c52607 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/TimeService.wsdl
@@ -0,0 +1,85 @@ +<?xml version="1.0" encoding="utf-8"?> +<wsdl:definitions + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:tns="http://ws.intalio.com/TimeService/" + xmlns:s="http://www.w3.org/2001/XMLSchema" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + targetNamespace="http://ws.intalio.com/TimeService/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:types> + <s:schema elementFormDefault="qualified" targetNamespace="http://ws.intalio.com/TimeService/"> + <s:element name="getUTCTime" type="s:string" /> + <s:element name="getUTCTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getUTCTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTime"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="city" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + <s:element name="getCityTimeResponse"> + <s:complexType> + <s:sequence> + <s:element minOccurs="0" maxOccurs="1" name="getCityTimeResult" type="s:string" /> + </s:sequence> + </s:complexType> + </s:element> + </s:schema> + </wsdl:types> + <wsdl:message name="getUTCTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getUTCTime" /> + </wsdl:message> + <wsdl:message name="getUTCTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getUTCTimeResponse" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapIn"> + <wsdl:part name="parameters" element="tns:getCityTime" /> + </wsdl:message> + <wsdl:message name="getCityTimeSoapOut"> + <wsdl:part name="parameters" element="tns:getCityTimeResponse" /> + </wsdl:message> + <wsdl:portType name="TimeServiceSoap"> + <wsdl:operation name="getUTCTime"> + <wsdl:input message="tns:getUTCTimeSoapIn" /> + <wsdl:output message="tns:getUTCTimeSoapOut" /> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <wsdl:input message="tns:getCityTimeSoapIn" /> + <wsdl:output message="tns:getCityTimeSoapOut" /> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="TimeServiceSoap" type="tns:TimeServiceSoap"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" /> + <wsdl:operation name="getUTCTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getUTCTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="getCityTime"> + <soap:operation soapAction="http://ws.intalio.com/TimeService/getCityTime" style="document" /> + <wsdl:input> + <soap:body use="literal" /> + </wsdl:input> + <wsdl:output> + <soap:body use="literal" /> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TimeService"> + <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/">A sample Time service</wsdl:documentation> + <wsdl:port name="TimeServiceSoap" binding="tns:TimeServiceSoap"> + <soap:address location="http://ws.intalio.com/TimeService/" /> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/deploy.xml new file mode 100644 index 0000000..18be63c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/deploy.xml
@@ -0,0 +1,23 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"> + <dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" + xmlns:Client="http://example.com/FirstProcess/Client" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xmlns:diag="http://example.com/FirstProcess" xmlns:TimeService="http://ws.intalio.com/TimeService/" + xmlns:TimeServer="http://example.com/FirstProcess/TimeServer" + xmlns:ns="http://bpms.intalio.com/FirstProcess/Time" xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:this="http://example.com/FirstProcess/FirstProcess" name="this:FirstProcess" + fileName="FirstProcess-FirstProcess.bpel"> + <dd:property name="PATH">FirstProcess</dd:property> + <dd:property name="SVG">FirstProcess.svg + </dd:property> + <dd:provide partnerLink="firstProcessAndClientPlkVar"> + <dd:service name="this:CanonicServiceForClient" port="canonicPort"></dd:service> + </dd:provide> + <dd:invoke partnerLink="timeServerAndFirstProcessForPortTimeServiceSoapPlkVar"> + <dd:service name="TimeService:TimeService" port="TimeServiceSoap"></dd:service> + </dd:invoke> + <dd:cleanup on="always"> + <dd:category>variables</dd:category> + </dd:cleanup> + </dd:process> +</dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/testRequest.soap new file mode 100644 index 0000000..0447574 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCleanSuccess_Variables/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <TimeRequest xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:wsi-wsdl="http://www.intalio.com/BPMS/wsi/wsdl" xmlns:wsi-xf="http://www.intalio.com/BPMS/wsi/xforms" xmlns:xforms="http://www.w3.org/2002/xforms" xmlns:ns0="http://bpms.intalio.com/FirstProcess/Time" xmlns:xxforms="http://orbeon.org/oxf/xml/xforms" xmlns="http://bpms.intalio.com/FirstProcess/Time"> + <city>New York</city> + </TimeRequest> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/CorrelationMultiTest.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/CorrelationMultiTest.bpel new file mode 100644 index 0000000..791e660 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/CorrelationMultiTest.bpel
@@ -0,0 +1,118 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HeaderTest" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="CorrelationMultiTest.wsdl" namespace="http://ode/bpel/unit-test.wsdl" importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HeaderTestPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myInVar" messageType="test:HeaderTestMessage"/> + <variable name="myOutVar" messageType="test:HeaderTestMessage"/> + <variable name="input" messageType="dummy:longOperationRequest"/> + <variable name="output" messageType="dummy:longOperationResponse"/> + </variables> + <correlationSets> + <correlationSet name="testCorr1" properties="test:testCorrelationID1"/> + <correlationSet name="testCorr2" properties="test:testCorrelationID2"/> + <correlationSet name="testCorr3" properties="test:testCorrelationID3"/> + </correlationSets> + <flow> + <links> + <link name="ready"/> + <link name="continue"/> + </links> + <sequence> + <receive name="start1" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello1" variable="myInVar" createInstance="yes"> + <correlations> + <correlation set="testCorr1" initiate="join"/> + </correlations> + </receive> + <assign> + <copy> + <from>$myInVar.TestPart/requestText</from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + <sources> + <source linkName="ready"/> + </sources> + </sequence> + <sequence> + <targets> + <target linkName="ready"/> + </targets> + <receive name="start2" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello2" variable="myInVar" createInstance="yes"> + <correlations> + <correlation set="testCorr1" initiate="join"/> + </correlations> + </receive> + <assign> + <copy> + <from> + concat($myOutVar.TestPart, $myInVar.TestPart/requestText) + </from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + <sources> + <source linkName="continue"/> + </sources> + </sequence> + <sequence> + <targets> + <target linkName="continue"/> + </targets> + <receive name="receive3" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="continue" variable="myInVar"> + <correlations> + <correlation set="testCorr1" initiate="join"/> + <correlation set="testCorr2" initiate="join"/> + <correlation set="testCorr3" initiate="join"/> + </correlations> + </receive> + <assign> + <copy> + <from> + concat($myOutVar.TestPart, $myInVar.TestPart/requestText) + </from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello1" variable="myOutVar"/> + </sequence> + </flow> +</process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/CorrelationMultiTest.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/CorrelationMultiTest.wsdl new file mode 100644 index 0000000..7a7c995 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/CorrelationMultiTest.wsdl
@@ -0,0 +1,126 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:typens="http://ode/bpel/unit-test/testCorrelation.wsdl.types" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:types> + <xsd:schema + targetNamespace="http://ode/bpel/unit-test/testCorrelation.wsdl.types" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:complexType name="testMessage"> + <xsd:sequence> + <xsd:element name="correlationID1" type="xsd:string"/> + <xsd:element name="correlationID2" type="xsd:string"/> + <xsd:element name="correlationID3" type="xsd:string"/> + <xsd:element name="requestText" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="HeaderTestMessage"> + <wsdl:part name="TestPart" type="typens:testMessage"/> + </wsdl:message> + + <wsdl:portType name="HeaderTestPortType"> + <wsdl:operation name="hello1"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + <wsdl:output message="tns:HeaderTestMessage" name="TestOut"/> + </wsdl:operation> + <wsdl:operation name="hello2"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + </wsdl:operation> + <wsdl:operation name="continue"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HeaderTestSoapBinding" type="tns:HeaderTestPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello1"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello2"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + </wsdl:operation> + <wsdl:operation name="continue"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HeaderTestService"> + <wsdl:port name="HeaderTestPort" binding="tns:HeaderTestSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/correlationMultiTest"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HeaderTestPartnerLinkType"> + <plnk:role name="me" portType="tns:HeaderTestPortType"/> + <plnk:role name="you" portType="tns:HeaderTestPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> + + <prop:property name="testCorrelationID1" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID1" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID1 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID2" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID2" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID2 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID3" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID3" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID3 + </prop:query> + </prop:propertyAlias> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/deploy.xml new file mode 100644 index 0000000..788ab3d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HeaderTest"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HeaderTestService" port="HeaderTestPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/dummy-service.wsdl new file mode 100644 index 0000000..5aeb653 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/dummy-service.wsdl
@@ -0,0 +1,211 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap:operation soapAction="urn:longOperation" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest.soap new file mode 100644 index 0000000..8685041 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello1 xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><requestText>1;</requestText></TestPart> + </ns1:hello1> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest2.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest2.soap new file mode 100644 index 0000000..086accd --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest2.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello2 xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><requestText>2;</requestText></TestPart> + </ns1:hello2> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest3.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest3.soap new file mode 100644 index 0000000..a9f2dc6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoin/testRequest3.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:continue xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><requestText>3;</requestText></TestPart> + </ns1:continue> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/CorrelationMultiTest.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/CorrelationMultiTest.bpel new file mode 100644 index 0000000..e566a16 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/CorrelationMultiTest.bpel
@@ -0,0 +1,97 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HeaderTest" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="CorrelationMultiTest.wsdl" namespace="http://ode/bpel/unit-test.wsdl" importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HeaderTestPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myInVar" messageType="test:HeaderTestMessage"/> + <variable name="myOutVar" messageType="test:HeaderTestMessage"/> + <variable name="input" messageType="dummy:longOperationRequest"/> + <variable name="output" messageType="dummy:longOperationResponse"/> + </variables> + <correlationSets> + <correlationSet name="testCorr1" properties="test:testCorrelationID1"/> + <correlationSet name="testCorr2" properties="test:testCorrelationID2"/> + <correlationSet name="testCorr3" properties="test:testCorrelationID3"/> + </correlationSets> + <sequence> + <receive name="start1" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello1" variable="myInVar" createInstance="yes"> + <correlations> + <correlation set="testCorr1" initiate="join"/> + </correlations> + </receive> + <assign> + <copy> + <from>$myInVar.TestPart/requestText</from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + <receive name="receive3" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="continue" variable="myInVar"> + <correlations> + <correlation set="testCorr1" initiate="join"/> + <correlation set="testCorr2" initiate="join"/> + <correlation set="testCorr3" initiate="join"/> + </correlations> + </receive> + <assign> + <copy> + <from> + concat($myOutVar.TestPart, $myInVar.TestPart/requestText) + </from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + <receive name="start2" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello2" variable="myInVar"> + <correlations> + <correlation set="testCorr1" initiate="join"/> + <correlation set="testCorr2" initiate="join"/> + </correlations> + </receive> + <assign> + <copy> + <from> + concat($myOutVar.TestPart, $myInVar.TestPart/requestText) + </from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello1" variable="myOutVar"/> + </sequence> +</process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/CorrelationMultiTest.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/CorrelationMultiTest.wsdl new file mode 100644 index 0000000..eb4c4b1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/CorrelationMultiTest.wsdl
@@ -0,0 +1,126 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:typens="http://ode/bpel/unit-test/testCorrelation.wsdl.types" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:types> + <xsd:schema + targetNamespace="http://ode/bpel/unit-test/testCorrelation.wsdl.types" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:complexType name="testMessage"> + <xsd:sequence> + <xsd:element name="correlationID1" type="xsd:string"/> + <xsd:element name="correlationID2" type="xsd:string"/> + <xsd:element name="correlationID3" type="xsd:string"/> + <xsd:element name="requestText" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="HeaderTestMessage"> + <wsdl:part name="TestPart" type="typens:testMessage"/> + </wsdl:message> + + <wsdl:portType name="HeaderTestPortType"> + <wsdl:operation name="hello1"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + <wsdl:output message="tns:HeaderTestMessage" name="TestOut"/> + </wsdl:operation> + <wsdl:operation name="hello2"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + </wsdl:operation> + <wsdl:operation name="continue"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HeaderTestSoapBinding" type="tns:HeaderTestPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello1"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello2"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + </wsdl:operation> + <wsdl:operation name="continue"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HeaderTestService"> + <wsdl:port name="HeaderTestPort" binding="tns:HeaderTestSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/correlationMultiTest"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HeaderTestPartnerLinkType"> + <plnk:role name="me" portType="tns:HeaderTestPortType"/> + <plnk:role name="you" portType="tns:HeaderTestPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> + + <prop:property name="testCorrelationID1" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID1" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID1 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID2" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID2" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID2 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID3" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID3" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID3 + </prop:query> + </prop:propertyAlias> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/deploy.xml new file mode 100644 index 0000000..788ab3d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HeaderTest"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HeaderTestService" port="HeaderTestPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/dummy-service.wsdl new file mode 100644 index 0000000..5aeb653 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/dummy-service.wsdl
@@ -0,0 +1,211 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap:operation soapAction="urn:longOperation" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest.soap new file mode 100644 index 0000000..8685041 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello1 xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><requestText>1;</requestText></TestPart> + </ns1:hello1> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest2.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest2.soap new file mode 100644 index 0000000..086accd --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest2.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello2 xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><requestText>2;</requestText></TestPart> + </ns1:hello2> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest3.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest3.soap new file mode 100644 index 0000000..a9f2dc6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationJoinLazy/testRequest3.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:continue xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><requestText>3;</requestText></TestPart> + </ns1:continue> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/CorrelationMultiTest.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/CorrelationMultiTest.bpel new file mode 100644 index 0000000..b23e325 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/CorrelationMultiTest.bpel
@@ -0,0 +1,89 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HeaderTest" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="CorrelationMultiTest.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HeaderTestPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myInVar" messageType="test:HeaderTestMessage"/> + <variable name="myOutVar" messageType="test:HeaderTestMessage"/> + <variable name="input" messageType="dummy:longOperationRequest"/> + <variable name="output" messageType="dummy:longOperationResponse"/> + </variables> + <correlationSets> + <correlationSet name="testCorr1" properties="test:testCorrelationID1"/> + <correlationSet name="testCorr2" properties="test:testCorrelationID2"/> + <correlationSet name="testCorr3" properties="test:testCorrelationID3"/> + <correlationSet name="testCorr4" properties="test:testCorrelationID4"/> + </correlationSets> + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello" variable="myInVar" createInstance="yes"> + <correlations> + <correlation set="testCorr1" initiate="yes"/> + <correlation set="testCorr2" initiate="yes"/> + </correlations> + </receive> + + <assign> + <copy> + <from>$myInVar.TestPart/requestText</from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + + <receive name="receive2" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="continue" variable="myInVar"> + <correlations> + <correlation set="testCorr1" initiate="no"/> + <correlation set="testCorr2" initiate="no"/> + <correlation set="testCorr3" initiate="yes"/> + <correlation set="testCorr4" initiate="yes"/> + </correlations> + </receive> + <assign> + <copy> + <from> + concat($myOutVar.TestPart, $myInVar.TestPart/requestText) + </from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello" variable="myOutVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/CorrelationMultiTest.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/CorrelationMultiTest.wsdl new file mode 100644 index 0000000..325a500 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/CorrelationMultiTest.wsdl
@@ -0,0 +1,125 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:typens="http://ode/bpel/unit-test/testCorrelation.wsdl.types" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:types> + <xsd:schema + targetNamespace="http://ode/bpel/unit-test/testCorrelation.wsdl.types" + xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + + <xsd:complexType name="testMessage"> + <xsd:sequence> + <xsd:element name="correlationID1" type="xsd:string"/> + <xsd:element name="correlationID2" type="xsd:string"/> + <xsd:element name="correlationID3" type="xsd:string"/> + <xsd:element name="correlationID4" type="xsd:string"/> + <xsd:element name="requestText" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="HeaderTestMessage"> + <wsdl:part name="TestPart" type="typens:testMessage"/> + </wsdl:message> + + <wsdl:portType name="HeaderTestPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + <wsdl:output message="tns:HeaderTestMessage" name="TestOut"/> + </wsdl:operation> + <wsdl:operation name="continue"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HeaderTestSoapBinding" type="tns:HeaderTestPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="continue"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HeaderTestService"> + <wsdl:port name="HeaderTestPort" binding="tns:HeaderTestSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/correlationMultiTest"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HeaderTestPartnerLinkType"> + <plnk:role name="me" portType="tns:HeaderTestPortType"/> + <plnk:role name="you" portType="tns:HeaderTestPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> + + <prop:property name="testCorrelationID1" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID1" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID1 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID2" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID2" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID2 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID3" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID3" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID3 + </prop:query> + </prop:propertyAlias> + + <prop:property name="testCorrelationID4" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:testCorrelationID4" messageType="tns:HeaderTestMessage" part="TestPart"> + <prop:query queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + correlationID4 + </prop:query> + </prop:propertyAlias> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/deploy.xml new file mode 100644 index 0000000..788ab3d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HeaderTest"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HeaderTestService" port="HeaderTestPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/dummy-service.wsdl new file mode 100644 index 0000000..5aeb653 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/dummy-service.wsdl
@@ -0,0 +1,211 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap:operation soapAction="urn:longOperation" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/testRequest.soap new file mode 100644 index 0000000..baba725 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/testRequest.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><correlationID4>CORR4</correlationID4><requestText>1;</requestText></TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/testRequest2.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/testRequest2.soap new file mode 100644 index 0000000..77b8c45 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestCorrelationMulti/testRequest2.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:continue xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns=""><correlationID1>CORR1</correlationID1><correlationID2>CORR2</correlationID2><correlationID3>CORR3</correlationID3><correlationID4>CORR4</correlationID4><requestText>2;</requestText></TestPart> + </ns1:continue> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/Echo.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/Echo.wsdl new file mode 100644 index 0000000..90117dc --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/Echo.wsdl
@@ -0,0 +1,94 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:tns="http://ode/bpel/test/properties" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:odex="http://www.apache.org/ode/type/extension/http" + targetNamespace="http://ode/bpel/test/properties"> + + <wsdl:types> + <xsd:schema xmlns:ns="http://ode/bpel/test/properties" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://ode/bpel/test/properties"> + + <xsd:element name="credentials"> + <xsd:complexType> + <xsd:attribute name="scheme" type="xsd:string" default="server-decide"/> + <xsd:attribute name="username" type="xsd:string"/> + <xsd:attribute name="password" type="xsd:string"/> + </xsd:complexType> + </xsd:element> + </xsd:schema> + </wsdl:types> + <!-- + The goal of this test is to make sure endpoint properties are properly passed around. + Endpoint properties might be set with property files matching *.endpoint. + These files might be located in 2 different places: + . the global BPMS config directory i.e. $BPMS_HOME/var/config (A) + . the unit deployment directory i.e. $BPMS_HOME/var/processes/MyProcess (B) + If a given property is defined in the deployment unit and in the global config directory, the latter takes precedence. + HTTP headers could be set this way, but also with a message part. This is a third options (C). A message part would have precedence over the 2 other ways, A & B. + + The testcase would use various combinations of these solutions to set HTTP headers and make sure the expected value is properly assigned. + + The EchoService is a basic service that send back the headers and body received in the request. + --> + <wsdl:message name="Message"> + <wsdl:part name="header_A" type="xsd:string"/> + <wsdl:part name="header_B" type="xsd:string"/> + <wsdl:part name="header_C" type="xsd:string"/> + <wsdl:part name="header_ABC" type="xsd:string"/> + <wsdl:part name="header_AB" type="xsd:string"/> + <wsdl:part name="header_AC" type="xsd:string"/> + <wsdl:part name="header_BC" type="xsd:string"/> + <wsdl:part name="header_AA" type="xsd:string"/> + <wsdl:part name="header_BB" type="xsd:string"/> + <wsdl:part name="WWW-Authenticate" element="credentials"/> + </wsdl:message> + + + <wsdl:portType name="PropertiesPortType"> + <wsdl:operation name="GET"> + <wsdl:input message="tns:Message"/> + <wsdl:output message="tns:Message"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="binding" type="tns:PropertiesPortType"> + <wsdl:operation name="GET"> + <http:operation location=""/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlReplacement/> + <odex:header name="header_A" part="header_A"/> + <odex:header name="header_B" part="header_B"/> + <odex:header name="header_C" part="header_C"/> + <odex:header name="header_ABC" part="header_ABC"/> + <odex:header name="header_AB" part="header_AB"/> + <odex:header name="header_AC" part="header_AC"/> + <odex:header name="header_BC" part="header_BC"/> + <odex:header name="header_AA" part="header_AA"/> + <odex:header name="header_BB" part="header_BB"/> + </wsdl:input> + <wsdl:output> + <odex:header name="header_A" part="header_A"/> + <odex:header name="header_B" part="header_B"/> + <odex:header name="header_C" part="header_C"/> + <odex:header name="header_ABC" part="header_ABC"/> + <odex:header name="header_AB" part="header_AB"/> + <odex:header name="header_AC" part="header_AC"/> + <odex:header name="header_BC" part="header_BC"/> + <odex:header name="header_AA" part="header_AA"/> + <odex:header name="header_BB" part="header_BB"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="PropertiesService"> + <wsdl:port name="PropertiesPort" binding="tns:binding"> + <http:address location="http://localhost:7070/EchoService/"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/deploy.xml new file mode 100644 index 0000000..4792f8a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="http://ode/bpel/test/properties"> + + + <process name="pns:test-endpoint-properties"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="propertiesPartnerLink"> + <service name="dns:PropertiesService" port="PropertiesPort"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/endpoint-configuration.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/endpoint-configuration.properties new file mode 100644 index 0000000..0357f35 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/endpoint-configuration.properties
@@ -0,0 +1,7 @@ +# this file is named the old way to test backward compatibility +alias.myns=http://ode/bpel/test/properties + +myns.PropertiesService.ode.http.default-headers.header_B=from_deployment_unit_directory_only +myns.PropertiesService.ode.http.default-headers.header_BC=from_deployment_unit_directory_BC +myns.PropertiesService.ode.http.default-headers.header_AB=from_deployment_unit_directory_AB +myns.PropertiesService.ode.http.default-headers.header_ABC=from_deployment_unit_directory_ABC \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/jetty-realm.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/jetty-realm.properties new file mode 100644 index 0000000..187309a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/jetty-realm.properties
@@ -0,0 +1,3 @@ + +#username=password, role, role, ... +superuser=topsecret, user
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties-deploy-unit_headerBB_1.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties-deploy-unit_headerBB_1.endpoint new file mode 100644 index 0000000..5520ff6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties-deploy-unit_headerBB_1.endpoint
@@ -0,0 +1,4 @@ + +alias.myns1=http://ode/bpel/test/properties + +myns1.PropertiesService.ode.http.default-headers.header_BB=from_deployment_unit#file1 \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties-deploy-unit_headerBB_2.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties-deploy-unit_headerBB_2.endpoint new file mode 100644 index 0000000..cd237f7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties-deploy-unit_headerBB_2.endpoint
@@ -0,0 +1,4 @@ + +alias.myns2=http://ode/bpel/test/properties + +myns2.PropertiesService.ode.http.default-headers.header_BB=from_deployment_unit#file2 \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties.bpel new file mode 100644 index 0000000..3b1bbfe --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties.bpel
@@ -0,0 +1,188 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="test-endpoint-properties" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://ode/bpel/test/properties" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="test-endpoint-properties.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="propertiesPartnerLink" + partnerLinkType="test:PropertiesLinkType" partnerRole="you"/> + </partnerLinks> + + <variables> + <variable name="inputVar" messageType="test:HelloMessage"/> + <variable name="reqMsg" messageType="dummy:Message"/> + <variable name="respMsg" messageType="dummy:Message"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar" createInstance="yes"/> + + <!-- + A, B, C denote the 3 different way to assign a property (a header in that particular case): + A. value set in the global configuration directory + B. value set in the deployment unit directory + C. value set in the BPEL process with an assignment + This order is also order the precedence order. Meaning that B has precedence over A, C over B. + --> + <!-- + <odex:header name="header_A" part="header_A" /> + <odex:header name="header_B" part="header_B" /> + <odex:header name="header_C" part="header_C" /> + <odex:header name="header_ABC" part="header_ABC"/> + <odex:header name="header_AB" part="header_AB"/> + <odex:header name="header_AC" part="header_AC"/> + <odex:header name="header_BC" part="header_BC"/> + <odex:header name="header_CC" part="header_AA"/> + <odex:header name="header_BB" part="header_BB"/> + --> + + <!-- Assign all header parts --> + <assign> + + <copy> + <from><literal><credentials username="superuser" password="topsecret"/></literal></from> + <to>$reqMsg.WWW-Authenticate</to> + </copy> + <!-- header_A will be set through a property file in the global config dir --> + <!-- header_B will be set through a property file in the deployment unit dir --> + + <copy> + <from>$inputVar.TestPart</from> + <to>$reqMsg.header_C</to> + </copy> + <!-- header_ABC is set with the 3 ways, the expected value is the one from the BPEL assignment --> + <copy> + <from>'from_bpel_assignment_ABC'</from> + <to>$reqMsg.header_ABC</to> + </copy> + <!-- header_AC is set from a global property file and from the BPRL process, the expected value is the one from the BPEL assignment --> + <copy> + <from>'from_bpel_assignment_AC'</from> + <to>$reqMsg.header_AC</to> + </copy> + <!-- header_BC is set from a deploy-unit property file and from the BPRL process, the expected value is the one from the BPEL assignment --> + <copy> + <from>'from_bpel_assignment_BC'</from> + <to>$reqMsg.header_BC</to> + </copy> + </assign> + + + <invoke partnerLink="propertiesPartnerLink" portType="dummy:PropertiesPortType" + operation="GET" inputVariable="reqMsg" outputVariable="respMsg"/> + + + <if> + <condition>$respMsg.header_A = 'from_global_conf_directory_only'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_global_conf_directory_only"/> + </else> + </if> + + <if> + <condition>$respMsg.header_B = 'from_deployment_unit_directory_only'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_deployment_unit_directory_only"/> + </else> + </if> + + <if> + <condition>$respMsg.header_C = $inputVar.TestPart</condition> + <empty/> + <else> + <throw faultName="FAILED-from_bpel_process_only"/> + </else> + </if> + + + <if> + <condition>$respMsg.header_ABC = 'from_bpel_assignment_ABC'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_bpel_assignment_ABC"/> + </else> + </if> + + <if> + <condition>$respMsg.header_AB = 'from_deployment_unit_directory_AB'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_deployment_unit_directory_AB"/> + </else> + </if> + + <if> + <condition>$respMsg.header_AC = 'from_bpel_assignment_AC'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_bpel_assignment_AC"/> + </else> + </if> + + <if> + <condition>$respMsg.header_BC = 'from_bpel_assignment_BC'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_bpel_assignment_BC"/> + </else> + </if> + + <if> + <condition>$respMsg.header_AA = 'from_global_conf#file2'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_global_conf#file2"/> + </else> + </if> + + <if> + <condition>$respMsg.header_BB = 'from_deployment_unit#file2'</condition> + <empty/> + <else> + <throw faultName="FAILED-from_deployment_unit#file2"/> + </else> + </if> + + <assign> + <copy> + <from>'OK!!!'</from> + <to>$inputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar"/> + </sequence> + +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties.wsdl new file mode 100644 index 0000000..794865a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://ode/bpel/test/properties" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" + location="Echo.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="PropertiesLinkType"> + <plnk:role name="you" portType="dummy:PropertiesPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf.endpoint new file mode 100644 index 0000000..b89cd47 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf.endpoint
@@ -0,0 +1,7 @@ + +alias.myns1=http://ode/bpel/test/properties + +myns1.PropertiesService.ode.http.default-headers.header_A=from_global_conf_directory_only +myns1.PropertiesService.ode.http.default-headers.header_ABC=from_global_conf_directory_ABC +myns.PropertiesService.ode.http.default-headers.header_AB=from_global_conf_directory_AB +myns1.PropertiesService.ode.http.default-headers.header_AC=from_global_conf_directory_AC \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf_headerAA_1.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf_headerAA_1.endpoint new file mode 100644 index 0000000..97c41d0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf_headerAA_1.endpoint
@@ -0,0 +1,4 @@ + +alias.myns1=http://ode/bpel/test/properties + +myns1.PropertiesService.ode.http.default-headers.header_AA=from_global_conf#file1
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf_headerAA_2.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf_headerAA_2.endpoint new file mode 100644 index 0000000..86b772e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/test-endpoint-properties_global_conf_headerAA_2.endpoint
@@ -0,0 +1,5 @@ + +alias.myns1=http://ode/bpel/test/properties + +myns1.PropertiesService.ode.http.default-headers.header_AA=from_global_conf#file2 +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/testRequest.soap new file mode 100644 index 0000000..afc8fb7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointProperties/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">100</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/HelloWorld2.bpel new file mode 100644 index 0000000..9b34dfe --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/HelloWorld2.bpel
@@ -0,0 +1,81 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you"/> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="input" messageType="dummy:longOperationRequest"/> + <variable name="output" messageType="dummy:longOperationResponse"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from> + <literal> + <dummy:faultTest> + <dummy:in></dummy:in> + </dummy:faultTest> + </literal> + </from> + <to>$input.parameters</to> + </copy> + <copy> + <from>$myVar.TestPart</from> + <to>$input.parameters/dummy:in</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="longOperation" inputVariable="input" outputVariable="output"/> + + <assign> + <copy> + <from>$output.parameters/return</from> + <to>$myVar.TestPart</to> + </copy> + </assign> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/deploy.xml new file mode 100644 index 0000000..91278e6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/dummy-service.wsdl new file mode 100644 index 0000000..4ad7491 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/dummy-service.wsdl
@@ -0,0 +1,142 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap:operation soapAction="urn:longOperation" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/testRequest.soap new file mode 100644 index 0000000..433a842 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/testRequest.soap
@@ -0,0 +1,29 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <!-- this defines how long the operation would take. see #DummyService.java--> + <TestPart xmlns="">3000</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/timeouts.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/timeouts.endpoint new file mode 100644 index 0000000..3ab6980 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestEndpointTimeouts/timeouts.endpoint
@@ -0,0 +1,10 @@ + + +# timeout in milliseconds until the ODE will wait for answer. +mex.timeout=2000 + +# timeout in milliseconds until a connection is established +#http.connection.timeout=480000 + +# timeout in milliseconds for waiting for data +http.socket.timeout=1000
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/FailureInvokeTest.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/FailureInvokeTest.bpel new file mode 100644 index 0000000..46a7cb6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/FailureInvokeTest.bpel
@@ -0,0 +1,71 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HeaderTest" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="FailureInvokeTest.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HeaderTestPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myInVar" messageType="test:HeaderTestMessage"/> + <variable name="myOutVar" messageType="test:HeaderTestMessage"/> + <variable name="input" messageType="dummy:longOperationRequest"/> + <variable name="output" messageType="dummy:longOperationResponse"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello" variable="myInVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$input.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="longOperation" inputVariable="input" outputVariable="output"/> + + <assign> + <copy> + <from>$output.parameters/return</from> + <to>$myOutVar.TestPart</to> + </copy> + </assign> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello" variable="myOutVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/FailureInvokeTest.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/FailureInvokeTest.wsdl new file mode 100644 index 0000000..e4d995f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/FailureInvokeTest.wsdl
@@ -0,0 +1,70 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HeaderTestMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HeaderTestPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + <wsdl:output message="tns:HeaderTestMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HeaderTestSoapBinding" type="tns:HeaderTestPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HeaderTestService"> + <wsdl:port name="HeaderTestPort" binding="tns:HeaderTestSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/invokeFailureTest"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HeaderTestPartnerLinkType"> + <plnk:role name="me" portType="tns:HeaderTestPortType"/> + <plnk:role name="you" portType="tns:HeaderTestPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/deploy.xml new file mode 100644 index 0000000..788ab3d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HeaderTest"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HeaderTestService" port="HeaderTestPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/dummy-service.wsdl new file mode 100644 index 0000000..5aeb653 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/dummy-service.wsdl
@@ -0,0 +1,211 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap:operation soapAction="urn:longOperation" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/testRequest.soap new file mode 100644 index 0000000..f250b44 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestFailureInInvoke/testRequest.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/Arithmetics.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/Arithmetics.wsdl new file mode 100644 index 0000000..046c20e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/Arithmetics.wsdl
@@ -0,0 +1,253 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:tns="http://ode/bpel/test/arithmetics" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:odex="http://www.apache.org/ode/type/extension/http" + targetNamespace="http://ode/bpel/test/arithmetics"> + + + <wsdl:types> + <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ode/bpel/test/arithmetics"> + <xsd:complexType name="operandListType"> + <xsd:sequence> + <xsd:element name="operand" type="xsd:string" maxOccurs="unbounded" minOccurs="2"/> + </xsd:sequence> + </xsd:complexType> + + <xsd:element name="operandList" type="tns:operandListType"/> + + <xsd:complexType name="resultType"> + <xsd:sequence> + <xsd:element name="msg" type="xsd:string"/> + <xsd:element name="resultIs" type="xsd:int"/> + </xsd:sequence> + </xsd:complexType> + + <xsd:element name="theresult" type="xsd:int"/> + </xsd:schema> + </wsdl:types> + + + <wsdl:message name="twoOperandRequest"> + <wsdl:part name="left" type="xsd:integer"/> + <wsdl:part name="right" type="xsd:integer"/> + </wsdl:message> + <wsdl:message name="resultResponse"> + <wsdl:part name="result" type="xsd:integer"/> + </wsdl:message> + <wsdl:message name="additionRequest"> + <wsdl:part name="operands" element="tns:operandList"/> + </wsdl:message> + <wsdl:message name="additionResponse"> + <wsdl:part name="result" element="tns:theresult"/> + </wsdl:message> + <wsdl:message name="sumOfIntegersRequest"> + <wsdl:part name="range" element="tns:operandList"/> + </wsdl:message> + <wsdl:message name="sumOfIntegersResponse"> + <wsdl:part name="result" type="tns:resultType"/> + </wsdl:message> + + + <wsdl:portType name="OlaElMundoPortType"> + <!-- will use with GET + urlReplacement + simple types (input/output)--> + <wsdl:operation name="plus"> + <wsdl:input message="tns:twoOperandRequest"/> + <wsdl:output message="tns:resultResponse"/> + </wsdl:operation> + <!-- will use with GET + urlEncoded + simple types (input/output) --> + <wsdl:operation name="minus"> + <wsdl:input message="tns:twoOperandRequest"/> + <wsdl:output message="tns:resultResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:portType name="SalutLaTerrePortType"> + <!-- will use with POST + text/xml + elements (input/output) --> + <wsdl:operation name="addition"> + <wsdl:input message="tns:additionRequest"/> + <wsdl:output message="tns:additionResponse"/> + </wsdl:operation> + <!-- will use with POST + text/xml + complex type (input/output) --> + <wsdl:operation name="sumOfIntegers"> + <wsdl:input message="tns:sumOfIntegersRequest"/> + <wsdl:output message="tns:sumOfIntegersResponse"/> + </wsdl:operation> + </wsdl:portType> + + + <wsdl:binding name="OlaElMundoHttpBinding-GET" type="tns:OlaElMundoPortType"> + <!-- /!\ no http:binding element here, see operation binding --> + <!-- It's meant to test a wsdl extension defined for RESTful BPEL --> + <wsdl:operation name="plus"> + <http:operation location="plus/(left):(right)"/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlReplacement/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="minus"> + <http:operation location="minus"/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlEncoded/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + <wsdl:binding name="OlaElMundoHttpBinding-POST" type="tns:OlaElMundoPortType"> + <!-- /!\ here the verb is GET and not POST --> + <!-- It's meant to test a verb overridding, see wsdl extensions for RESTful BPEL --> + <http:binding verb="GET"/> + <wsdl:operation name="plus"> + <http:operation location="plus"/> + <odex:binding verb="POST"/> + <wsdl:input> + <mime:content type="application/x-www-form-urlencoded"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="minus"> + <http:operation location="minus"/> + <odex:binding verb="POST"/> + <wsdl:input> + <http:urlEncoded/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + + <wsdl:binding name="OlaElMundoHttpBinding-PUT" type="tns:OlaElMundoPortType"> + <http:binding verb="PUT"/> + <wsdl:operation name="plus"> + <http:operation location="plus"/> + <wsdl:input> + <mime:content type="application/x-www-form-urlencoded"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="minus"> + <http:operation location="minus"/> + <wsdl:input> + <http:urlEncoded/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + + <wsdl:binding name="OlaElMundoHttpBinding-DELETE" type="tns:OlaElMundoPortType"> + <http:binding verb="DELETE"/> + <wsdl:operation name="plus"> + <http:operation location="plus/(left):(right)"/> + <wsdl:input> + <http:urlReplacement/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="minus"> + <http:operation location="minus"/> + <wsdl:input> + <http:urlEncoded/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + + <wsdl:binding name="SalutLaTerreHttpBinding" type="tns:SalutLaTerrePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="addition"> + <http:operation location="addition"/> + <wsdl:input> + <mime:content type="text/xml" part="operands"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="sumOfIntegers"> + <http:operation location="sumOfIntegers"/> + <wsdl:input> + <mime:content type="text/xml" part="range"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="result"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + + + <!-- + 8 urls to handle: + (GET) http://localhost:8888/HttpBindingTestService/OlaElMundo-GET/plus/(left):(right) + (GET) http:// ........ /OlaElMundo-GET/minus?left=&right= + (DELETE) http://localhost:8888/HttpBindingTestService/OlaElMundo-DELETE/plus/(left):(right) + (DELETE) http:// ........ /OlaElMundo-DELETE/minus?left=&right= + (POST) http:// ........ /OlaElMundo-POST/plus + (POST) http:// ........ /OlaElMundo-POST/minus + (PUT) http:// ........ /OlaElMundo-PUT/plus + (PUT) http:// ........ /OlaElMundo-PUT/minus + (POST) http:// ........ /SalutLaTerre/addition + (POST) http:// ........ /SalutLaTerre/sumOfIntegers + --> + <wsdl:service name="ArithmeticsService"> + <wsdl:port name="OlaElMundo-GET_httpport" binding="tns:OlaElMundoHttpBinding-GET"> + <http:address location="http://localhost:7070/HttpBindingTest/ArithmeticsService/OlaElMundo-GET"/> + </wsdl:port> + <wsdl:port name="OlaElMundo-POST_httpport" binding="tns:OlaElMundoHttpBinding-POST"> + <http:address location="http://localhost:7070/HttpBindingTest/ArithmeticsService/OlaElMundo-POST"/> + </wsdl:port> + <wsdl:port name="OlaElMundo-PUT_httpport" binding="tns:OlaElMundoHttpBinding-PUT"> + <http:address location="http://localhost:7070/HttpBindingTest/ArithmeticsService/OlaElMundo-PUT"/> + </wsdl:port> + <wsdl:port name="OlaElMundo-DELETE_httpport" binding="tns:OlaElMundoHttpBinding-DELETE"> + <http:address location="http://localhost:7070/HttpBindingTest/ArithmeticsService/OlaElMundo-DELETE"/> + </wsdl:port> + <wsdl:port name="SalutLaTerre_httpport" binding="tns:SalutLaTerreHttpBinding"> + <http:address location="http://localhost:7070/HttpBindingTest/ArithmeticsService/SalutLaTerre"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/deploy.xml new file mode 100644 index 0000000..91df1e6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/deploy.xml
@@ -0,0 +1,46 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="http://ode/bpel/test/arithmetics"> + + + <process name="pns:HttpBindingTest"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="salutPartnerLink"> + <service name="dns:ArithmeticsService" port="SalutLaTerre_httpport"/> + </invoke> + <invoke partnerLink="olaGetPartnerLink"> + <service name="dns:ArithmeticsService" port="OlaElMundo-GET_httpport"/> + </invoke> + <invoke partnerLink="olaPostPartnerLink"> + <service name="dns:ArithmeticsService" port="OlaElMundo-POST_httpport"/> + </invoke> + <invoke partnerLink="olaPutPartnerLink"> + <service name="dns:ArithmeticsService" port="OlaElMundo-PUT_httpport"/> + </invoke> + <invoke partnerLink="olaDeletePartnerLink"> + <service name="dns:ArithmeticsService" port="OlaElMundo-DELETE_httpport"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/http-binding-test.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/http-binding-test.bpel new file mode 100644 index 0000000..ad20b91 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/http-binding-test.bpel
@@ -0,0 +1,246 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HttpBindingTest" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://ode/bpel/test/arithmetics" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="http-binding-test.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="salutPartnerLink" + partnerLinkType="test:SalutLinkType" partnerRole="salut"/> + <partnerLink name="olaGetPartnerLink" + partnerLinkType="test:OlaLinkType" partnerRole="ola"/> + <partnerLink name="olaPostPartnerLink" + partnerLinkType="test:OlaLinkType" partnerRole="ola"/> + <partnerLink name="olaPutPartnerLink" + partnerLinkType="test:OlaLinkType" partnerRole="ola"/> + <partnerLink name="olaDeletePartnerLink" + partnerLinkType="test:OlaLinkType" partnerRole="ola"/> + </partnerLinks> + + <variables> + <variable name="inputVar" messageType="test:HelloMessage"/> + <variable name="outputVar" messageType="test:HelloMessage"/> + <variable name="operands" messageType="dummy:twoOperandRequest"/> + <variable name="result" messageType="dummy:resultResponse"/> + <variable name="additionInput" messageType="dummy:additionRequest"/> + <variable name="additionOutput" messageType="dummy:additionResponse"/> + <variable name="sumOfIntegersInput" messageType="dummy:sumOfIntegersRequest"/> + <variable name="sumOfIntegersOutput" messageType="dummy:sumOfIntegersResponse"/> + </variables> + + <!-- ###################################################### --> + <!-- ###################################################### --> + <!-- let N be the input number --> + <!-- This sequence will compute the Sum of the first (N + 5) positive integers --> + <!-- ###################################################### --> + <!-- ###################################################### --> + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar" createInstance="yes"/> + + <!-- Compute r = x + 1 --> + <assign> + <copy> + <from>$inputVar.TestPart</from> + <to>$operands.left</to> + </copy> + <copy> + <from>1</from> + <to>$operands.right</to> + </copy> + </assign> + + <invoke partnerLink="olaGetPartnerLink" portType="dummy:OlaElMundoPortType" + operation="plus" inputVariable="operands" outputVariable="result"/> + + <!-- Compute r = r - 2 (= x - 1) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>2</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaGetPartnerLink" portType="dummy:OlaElMundoPortType" + operation="minus" inputVariable="operands" outputVariable="result"/> + + <!-- Compute r = r + 3 (= x + 2) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>3</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaPostPartnerLink" portType="dummy:OlaElMundoPortType" + operation="plus" inputVariable="operands" outputVariable="result"/> + + <!-- Compute r = r - 4 (= x - 2) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>4</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaPostPartnerLink" portType="dummy:OlaElMundoPortType" + operation="minus" inputVariable="operands" outputVariable="result"/> + + + + <!-- Compute r = r + 5 (= x + 3) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>5</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaDeletePartnerLink" portType="dummy:OlaElMundoPortType" + operation="plus" inputVariable="operands" outputVariable="result"/> + + <!-- Compute r = r - 6 (= x - 3) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>6</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaDeletePartnerLink" portType="dummy:OlaElMundoPortType" + operation="minus" inputVariable="operands" outputVariable="result"/> + + + + <!-- Compute r = r + 7 (= x + 4) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>7</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaPutPartnerLink" portType="dummy:OlaElMundoPortType" + operation="plus" inputVariable="operands" outputVariable="result"/> + + <!-- Compute r = r - 9 (= x - 5) --> + <assign> + <copy> + <from>$result.result</from> + <to>$operands.left</to> + </copy> + <copy> + <from>9</from> + <to>$operands.right</to> + </copy> + </assign> + <invoke partnerLink="olaPutPartnerLink" portType="dummy:OlaElMundoPortType" + operation="minus" inputVariable="operands" outputVariable="result"/> + + + <!-- Compute r = r + 10 (= x + 5) --> + <assign> + <!-- First, build the proper element --> + <copy> + <from> + <literal> + <dummy:operandList> + <dummy:operand></dummy:operand> + <dummy:operand>10</dummy:operand> + </dummy:operandList> + </literal> + </from> + <to>$additionInput.operands</to> + </copy> + <!-- then assign the value from the previous result --> + <copy> + <from>$result.result</from> + <to>$additionInput.operands/dummy:operand[1]</to> + <!--<to>$additionInput.operands//dummy:operandList/dummy:operand[1]</to>--> + </copy> + </assign> + <invoke partnerLink="salutPartnerLink" portType="dummy:SalutLaTerrePortType" + operation="addition" inputVariable="additionInput" outputVariable="additionOutput"/> + + + <assign> + <!-- First, build the proper element --> + <copy> + <from> + <literal> + <dummy:operandList> + <dummy:operand>0</dummy:operand> + <dummy:operand></dummy:operand> + </dummy:operandList> + </literal> + </from> + <to>$sumOfIntegersInput.range</to> + </copy> + <!-- then assign the value from the previous result --> + <copy> + <from>$additionOutput.result</from> + <to>$sumOfIntegersInput.range/dummy:operand[2]</to> + <!--<to>$additionInput.operands//dummy:operandList/dummy:operand[1]</to>--> + </copy> + </assign> + <invoke partnerLink="salutPartnerLink" portType="dummy:SalutLaTerrePortType" + operation="sumOfIntegers" inputVariable="sumOfIntegersInput" outputVariable="sumOfIntegersOutput"/> + + + <assign> + <copy> + <from>$sumOfIntegersOutput.result/dummy:resultIs</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/http-binding-test.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/http-binding-test.wsdl new file mode 100644 index 0000000..244139c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/http-binding-test.wsdl
@@ -0,0 +1,77 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://ode/bpel/test/arithmetics" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" + location="Arithmetics.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:int"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="SalutLinkType"> + <plnk:role name="salut" portType="dummy:SalutLaTerrePortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="OlaLinkType"> + <plnk:role name="ola" portType="dummy:OlaElMundoPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/testRequest.soap new file mode 100644 index 0000000..afc8fb7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBinding/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">100</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/Blog.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/Blog.wsdl new file mode 100644 index 0000000..0c90239 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/Blog.wsdl
@@ -0,0 +1,151 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:tns="http://ode/bpel/test/blog" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:odex="http://www.apache.org/ode/type/extension/http" + targetNamespace="http://ode/bpel/test/blog"> + + + <!-- ## USE CASE ## --> + <!-- + Describe a REST service to access a blog article. + The article is a resource available at http://ex.org/blog/article/42 (for instance) + + For demonstration purpose, some requests/responses will have a custom header: TimestampHeader. + This header will be mapped to a part of the message. + + Also for demonstration, the User-agent header will be set in some requests. + --> + <wsdl:types> + <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ode/bpel/test/blog"> + <xsd:element name="article" type="tns:ArticleType"/> + <xsd:element name="comment" type="tns:CommentType"/> + <xsd:element name="fault" type="tns:FaultType"/> + <xsd:element name="from" type="xsd:string"/> + <xsd:complexType name="ArticleType"> + <xsd:sequence> + <xsd:element name="id" type="xsd:string"/> + <xsd:element name="title" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="CommentType"> + <xsd:sequence> + <xsd:element name="author" type="xsd:string"/> + <xsd:element name="content" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="FaultType"> + <xsd:sequence> + <xsd:element name="timestamp" type="xsd:string"/> + <xsd:element name="details" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="IdMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="from" element="tns:from"/> + <wsdl:part name="articleId" type="xsd:string"/> + </wsdl:message> + <wsdl:message name="ArticleMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="PUTRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="CommentRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="comment" element="tns:comment"/> + </wsdl:message> + <wsdl:message name="UpdateFault"> + <wsdl:part name="faultDetails" element="tns:fault"/> + </wsdl:message> + <wsdl:message name="NoPartMessage"/> + + + <wsdl:portType name="BlogPortType"> + <wsdl:operation name="doGET"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:ArticleMessage"/> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <wsdl:input message="tns:PUTRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + <wsdl:fault name="UpdateException" message="tns:UpdateFault"/> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <wsdl:input message="tns:CommentRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="binding" type="tns:BlogPortType"> + <wsdl:operation name="doGET"> + <http:operation location=""/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlReplacement/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + <odex:header name="From" part="from"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="article"/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <http:operation location=""/> + <odex:binding verb="DELETE"/> + <wsdl:input> + <http:urlReplacement/> + <odex:header name="TimestampHeader" part="timestamp"/> + <!-- a static value mapped to a standard header --> + <odex:header name="User-Agent" value="MyKillerApp"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <http:operation location=""/> + <odex:binding verb="PUT"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="article"/> + </wsdl:input> + <wsdl:output/> + <!-- fault binding --> + <wsdl:fault name="UpdateException"> + <!-- name attribute is optional --> + <!--<odex:fault name="UpdateException"/>--> + <odex:fault/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <http:operation location=""/> + <odex:binding verb="POST"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="comment"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="BlogService"> + <wsdl:port name="BlogPort" binding="tns:binding"> + <http:address location="http://localhost:7070/HttpBindingTest/BlogService/article/{articleId}"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/deploy.xml new file mode 100644 index 0000000..2739d85 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="http://ode/bpel/test/blog"> + + + <process name="pns:http-binding-ext-DELETE"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="blogPartnerLink"> + <service name="dns:BlogService" port="BlogPort"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/http-binding-ext-DELETE.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/http-binding-ext-DELETE.bpel new file mode 100644 index 0000000..60baa7c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/http-binding-ext-DELETE.bpel
@@ -0,0 +1,137 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="http-binding-ext-DELETE" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://ode/bpel/test/blog" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="http-binding-ext-DELETE.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="blogPartnerLink" + partnerLinkType="test:BlogLinkType" partnerRole="you"/> + </partnerLinks> + + <variables> + <variable name="inputVar" messageType="test:HelloMessage"/> + <variable name="outputVar" messageType="test:HelloMessage"/> + <variable name="idMsg" messageType="dummy:IdMessage"/> + <variable name="noPartMsg" messageType="dummy:NoPartMessage"/> + <variable name="noPartMsg2" messageType="dummy:NoPartMessage"/> + <variable name="generatedTimestamp" type="xsd:string"/> + <variable name="receivedTimestamp" type="xsd:string"/> + <variable name="receivedUserAgent" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar" createInstance="yes"/> + + <!-- Initialize output var --> + <assign> + <copy> + <from>'What a success!'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + + <!-- Prepare the input message --> + <assign> + <copy> + <from>string(round(seconds-from-dateTime(current-dateTime())))</from> + <to>$generatedTimestamp</to> + </copy> + </assign> + <assign> + <copy> + <from>$generatedTimestamp</from> + <to>$idMsg.timestamp</to> + </copy> + <copy> + <from>string(round(seconds-from-dateTime(current-dateTime()))+100)</from> + <to>$idMsg.articleId</to> + </copy> + </assign> + + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doDELETE" inputVariable="idMsg" outputVariable="noPartMsg"/> + + <!-- Check the TimestampHeader --> + <assign> + <!-- here we take a chance to make sure the header assignment works fine, + so duplicate the header value to another temp header, if the value is passed around then we're good. --> + <copy> + <from variable="noPartMsg" header="TimestampHeader"/> + <to variable="noPartMsg2" header="TimestampHeader"/> + </copy> + <copy> + <from variable="noPartMsg2" header="TimestampHeader"/> + <to>$receivedTimestamp</to> + </copy> + </assign> + + <if> + <condition>$receivedTimestamp = $generatedTimestamp</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Wrong Timestamp Header received. Check if the request header was properly set.'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + + <!-- Check the User-Agent--> + <assign> + <copy> + <from variable="noPartMsg" header="User-Agent"/> + <to>$receivedUserAgent</to> + </copy> + </assign> + + <if> + <!-- This value is specified in Blog.wsdl --> + <condition>$receivedUserAgent = 'MyKillerApp'</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Wrong User-Agent. Check if the request header was properly set.'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/http-binding-ext-DELETE.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/http-binding-ext-DELETE.wsdl new file mode 100644 index 0000000..6ad1ac4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/http-binding-ext-DELETE.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://ode/bpel/test/blog" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" + location="Blog.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="BlogLinkType"> + <plnk:role name="you" portType="dummy:BlogPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/testRequest.soap new file mode 100644 index 0000000..afc8fb7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_DELETE/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">100</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/Blog.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/Blog.wsdl new file mode 100644 index 0000000..0c90239 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/Blog.wsdl
@@ -0,0 +1,151 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:tns="http://ode/bpel/test/blog" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:odex="http://www.apache.org/ode/type/extension/http" + targetNamespace="http://ode/bpel/test/blog"> + + + <!-- ## USE CASE ## --> + <!-- + Describe a REST service to access a blog article. + The article is a resource available at http://ex.org/blog/article/42 (for instance) + + For demonstration purpose, some requests/responses will have a custom header: TimestampHeader. + This header will be mapped to a part of the message. + + Also for demonstration, the User-agent header will be set in some requests. + --> + <wsdl:types> + <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ode/bpel/test/blog"> + <xsd:element name="article" type="tns:ArticleType"/> + <xsd:element name="comment" type="tns:CommentType"/> + <xsd:element name="fault" type="tns:FaultType"/> + <xsd:element name="from" type="xsd:string"/> + <xsd:complexType name="ArticleType"> + <xsd:sequence> + <xsd:element name="id" type="xsd:string"/> + <xsd:element name="title" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="CommentType"> + <xsd:sequence> + <xsd:element name="author" type="xsd:string"/> + <xsd:element name="content" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="FaultType"> + <xsd:sequence> + <xsd:element name="timestamp" type="xsd:string"/> + <xsd:element name="details" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="IdMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="from" element="tns:from"/> + <wsdl:part name="articleId" type="xsd:string"/> + </wsdl:message> + <wsdl:message name="ArticleMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="PUTRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="CommentRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="comment" element="tns:comment"/> + </wsdl:message> + <wsdl:message name="UpdateFault"> + <wsdl:part name="faultDetails" element="tns:fault"/> + </wsdl:message> + <wsdl:message name="NoPartMessage"/> + + + <wsdl:portType name="BlogPortType"> + <wsdl:operation name="doGET"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:ArticleMessage"/> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <wsdl:input message="tns:PUTRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + <wsdl:fault name="UpdateException" message="tns:UpdateFault"/> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <wsdl:input message="tns:CommentRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="binding" type="tns:BlogPortType"> + <wsdl:operation name="doGET"> + <http:operation location=""/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlReplacement/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + <odex:header name="From" part="from"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="article"/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <http:operation location=""/> + <odex:binding verb="DELETE"/> + <wsdl:input> + <http:urlReplacement/> + <odex:header name="TimestampHeader" part="timestamp"/> + <!-- a static value mapped to a standard header --> + <odex:header name="User-Agent" value="MyKillerApp"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <http:operation location=""/> + <odex:binding verb="PUT"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="article"/> + </wsdl:input> + <wsdl:output/> + <!-- fault binding --> + <wsdl:fault name="UpdateException"> + <!-- name attribute is optional --> + <!--<odex:fault name="UpdateException"/>--> + <odex:fault/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <http:operation location=""/> + <odex:binding verb="POST"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="comment"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="BlogService"> + <wsdl:port name="BlogPort" binding="tns:binding"> + <http:address location="http://localhost:7070/HttpBindingTest/BlogService/article/{articleId}"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/deploy.xml new file mode 100644 index 0000000..efbea37 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="http://ode/bpel/test/blog"> + + + <process name="pns:http-binding-ext-GET"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="blogPartnerLink"> + <service name="dns:BlogService" port="BlogPort"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/http-binding-ext-GET.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/http-binding-ext-GET.bpel new file mode 100644 index 0000000..61579da --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/http-binding-ext-GET.bpel
@@ -0,0 +1,407 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="http-binding-ext-GET" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://ode/bpel/test/blog" + xmlns:fn="http://www.w3.org/2005/02/xpath-functions" + xmlns:ext="http://ode.apache.org/activityRecovery" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="http-binding-ext-GET.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="blogPartnerLink" + partnerLinkType="test:BlogLinkType" partnerRole="you"/> + </partnerLinks> + + <variables> + <variable name="inputVar" messageType="test:HelloMessage"/> + <variable name="outputVar" messageType="test:HelloMessage"/> + <variable name="idMsg" messageType="dummy:IdMessage"/> + <variable name="articleMsg" messageType="dummy:ArticleMessage"/> + <variable name="generatedTimestamp" type="xsd:string"/> + <variable name="articleId" type="xsd:string"/> + <variable name="tmpVar" type="xsd:string"/> + <variable name="statusLine" type="xsd:anyType"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar" createInstance="yes"/> + + <!-- Initialize output var --> + <assign> + <copy> + <from>'What a success!'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + + <!-- Prepare the input message --> + <assign> + <copy> + <!-- generate a random number --> + <from>string(round(seconds-from-dateTime(current-dateTime())))</from> + <to>$generatedTimestamp</to> + </copy> + <copy> + <from>$generatedTimestamp</from> + <to>$idMsg.timestamp</to> + </copy> + <copy> + <from>'alexis@test.com'</from> + <to>$idMsg.from</to> + </copy> + <copy> + <!-- generate a random number --> + <from>string(round(seconds-from-dateTime(current-dateTime()))+100)</from> + <to>$articleId</to> + </copy> + <copy> + <from>$articleId</from> + <to>$idMsg.articleId</to> + </copy> + </assign> + + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + + <!-- Check the answer --> + <if> + <condition>$articleMsg.timestamp = $generatedTimestamp</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Wrong Timestamp Header received. Check if the request header was properly set.'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + + <assign> + <copy> + <from variable="articleMsg" header="From"/> + <to variable="tmpVar"/> + </copy> + </assign> + <if> + <condition>compare($tmpVar, 'alexis@test.com') = 0</condition> + <empty/> + <else> + <assign> + <copy> + <from>concat('Wrong From Header received. Check if the request header was properly set. Received value is: ', $tmpVar) + </from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + <if> + <condition>$articleMsg.article/dummy:id = $articleId</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Wrong Article Id received.'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + + <!-- ##################################################### --> + <!-- Check HTTP StatusLine information --> + <!-- ##################################################### --> + <!-- Every message must have a Status-Line element in headers --> + <assign> + <copy> + <from variable="articleMsg" header="Status-Line"/> + <to>$statusLine</to> + </copy> + </assign> + <if> + <condition>string-length($statusLine/original) > 0</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Status-Line is missing'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + <if> + <condition>string-length($statusLine/Status-Code) > 0</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Status-Code is missing'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + <if> + <condition>string-length($statusLine/HTTP-Version) > 0</condition> + <empty/> + <else> + <assign> + <copy> + <from>'HTTP-Version is missing'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + <if> + <condition>string-length($statusLine/Reason-Phrase) > 0</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Reason-Phrase is missing'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + + + <!-- ############################################### --> + <!-- 200_malformed_body - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'200_malformed_body'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + <assign> + <copy> + <from>'200_malformed_body: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 200_missing_body - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'200_missing_body'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + <assign> + <copy> + <from>'200_missing_body: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 202_empty_body - Should pass --> + <!-- ############################################### --> + <!-- 202/Accepted status code explicitly states that there is no body, + so we should not fail even if a part is bound to the body response --> + <scope> + <sequence> + <assign> + <copy> + <from>'202_empty_body'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 204_empty_body - Should pass --> + <!-- ############################################### --> + <!-- 204/No Content status code explicitly states that there is no body, + so we should not fail even if a part is bound to the body response --> + <scope> + <sequence> + <assign> + <copy> + <from>'204_empty_body'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 200_missing_part_in_header - should pass, missing or empty header are allowed --> + <!-- ############################################### --> + <scope> + <sequence> + <assign> + <copy> + <from>'200_missing_part_in_header'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 400_not_found - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'400_not_found'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + <assign> + <copy> + <from>'400_not_found: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 500_operation_with_no_fault_failed - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_operation_with_no_fault_failed'</from> + <to variable="idMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doGET" inputVariable="idMsg" outputVariable="articleMsg"/> + <assign> + <copy> + <from>'500_operation_with_no_fault_failed: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/http-binding-ext-GET.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/http-binding-ext-GET.wsdl new file mode 100644 index 0000000..6ad1ac4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/http-binding-ext-GET.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://ode/bpel/test/blog" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" + location="Blog.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="BlogLinkType"> + <plnk:role name="you" portType="dummy:BlogPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/testRequest.soap new file mode 100644 index 0000000..afc8fb7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_GET/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">100</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/Blog.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/Blog.wsdl new file mode 100644 index 0000000..0c90239 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/Blog.wsdl
@@ -0,0 +1,151 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:tns="http://ode/bpel/test/blog" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:odex="http://www.apache.org/ode/type/extension/http" + targetNamespace="http://ode/bpel/test/blog"> + + + <!-- ## USE CASE ## --> + <!-- + Describe a REST service to access a blog article. + The article is a resource available at http://ex.org/blog/article/42 (for instance) + + For demonstration purpose, some requests/responses will have a custom header: TimestampHeader. + This header will be mapped to a part of the message. + + Also for demonstration, the User-agent header will be set in some requests. + --> + <wsdl:types> + <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ode/bpel/test/blog"> + <xsd:element name="article" type="tns:ArticleType"/> + <xsd:element name="comment" type="tns:CommentType"/> + <xsd:element name="fault" type="tns:FaultType"/> + <xsd:element name="from" type="xsd:string"/> + <xsd:complexType name="ArticleType"> + <xsd:sequence> + <xsd:element name="id" type="xsd:string"/> + <xsd:element name="title" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="CommentType"> + <xsd:sequence> + <xsd:element name="author" type="xsd:string"/> + <xsd:element name="content" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="FaultType"> + <xsd:sequence> + <xsd:element name="timestamp" type="xsd:string"/> + <xsd:element name="details" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="IdMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="from" element="tns:from"/> + <wsdl:part name="articleId" type="xsd:string"/> + </wsdl:message> + <wsdl:message name="ArticleMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="PUTRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="CommentRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="comment" element="tns:comment"/> + </wsdl:message> + <wsdl:message name="UpdateFault"> + <wsdl:part name="faultDetails" element="tns:fault"/> + </wsdl:message> + <wsdl:message name="NoPartMessage"/> + + + <wsdl:portType name="BlogPortType"> + <wsdl:operation name="doGET"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:ArticleMessage"/> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <wsdl:input message="tns:PUTRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + <wsdl:fault name="UpdateException" message="tns:UpdateFault"/> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <wsdl:input message="tns:CommentRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="binding" type="tns:BlogPortType"> + <wsdl:operation name="doGET"> + <http:operation location=""/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlReplacement/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + <odex:header name="From" part="from"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="article"/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <http:operation location=""/> + <odex:binding verb="DELETE"/> + <wsdl:input> + <http:urlReplacement/> + <odex:header name="TimestampHeader" part="timestamp"/> + <!-- a static value mapped to a standard header --> + <odex:header name="User-Agent" value="MyKillerApp"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <http:operation location=""/> + <odex:binding verb="PUT"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="article"/> + </wsdl:input> + <wsdl:output/> + <!-- fault binding --> + <wsdl:fault name="UpdateException"> + <!-- name attribute is optional --> + <!--<odex:fault name="UpdateException"/>--> + <odex:fault/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <http:operation location=""/> + <odex:binding verb="POST"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="comment"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="BlogService"> + <wsdl:port name="BlogPort" binding="tns:binding"> + <http:address location="http://localhost:7070/HttpBindingTest/BlogService/article/{articleId}"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/deploy.xml new file mode 100644 index 0000000..124f12b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="http://ode/bpel/test/blog"> + + + <process name="pns:http-binding-ext-POST"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="blogPartnerLink"> + <service name="dns:BlogService" port="BlogPort"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/http-binding-ext-POST.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/http-binding-ext-POST.bpel new file mode 100644 index 0000000..801c778 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/http-binding-ext-POST.bpel
@@ -0,0 +1,110 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="http-binding-ext-POST" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://ode/bpel/test/blog" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="http-binding-ext-POST.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="blogPartnerLink" + partnerLinkType="test:BlogLinkType" partnerRole="you"/> + </partnerLinks> + + <variables> + <variable name="inputVar" messageType="test:HelloMessage"/> + <variable name="outputVar" messageType="test:HelloMessage"/> + <variable name="commentMsg" messageType="dummy:CommentRequest"/> + <variable name="noPartMsg" messageType="dummy:NoPartMessage"/> + <variable name="myvar" type="xsd:string"/> + </variables> + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar" createInstance="yes"/> + + <!-- Initialize output var --> + <assign> + <copy> + <from>'What a success!'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + + <!-- Prepare the input message --> + <assign> + <copy> + <from>string(round(seconds-from-dateTime(current-dateTime())))</from> + <to>$commentMsg.articleId</to> + </copy> + <copy> + <from>string(round(seconds-from-dateTime(current-dateTime())))</from> + <to>$commentMsg.articleId</to> + </copy> + <copy> + <from> + <litteral> + <dummy:comment> + <dummy:author>Voltaire</dummy:author> + <dummy:content>When it is a question of money, everybody is of the same religion.</dummy:content> + </dummy:comment> + </litteral> + </from> + <to>$commentMsg.comment</to> + </copy> + </assign> + + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPOST" inputVariable="commentMsg" outputVariable="noPartMsg"/> + + <!-- Check the Location Header --> + <assign> + <copy> + <from variable="noPartMsg" header="Location"/> + <to>$myvar</to> + </copy> + </assign> + + <if> + <condition>string-length($myvar) != 0</condition> + <empty/> + <else> + <assign> + <copy> + <from>'Empty Location Header received.'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + </else> + </if> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/http-binding-ext-POST.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/http-binding-ext-POST.wsdl new file mode 100644 index 0000000..6ad1ac4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/http-binding-ext-POST.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://ode/bpel/test/blog" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" + location="Blog.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="BlogLinkType"> + <plnk:role name="you" portType="dummy:BlogPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/testRequest.soap new file mode 100644 index 0000000..afc8fb7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_POST/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">100</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/Blog.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/Blog.wsdl new file mode 100644 index 0000000..0c90239 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/Blog.wsdl
@@ -0,0 +1,151 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:tns="http://ode/bpel/test/blog" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:odex="http://www.apache.org/ode/type/extension/http" + targetNamespace="http://ode/bpel/test/blog"> + + + <!-- ## USE CASE ## --> + <!-- + Describe a REST service to access a blog article. + The article is a resource available at http://ex.org/blog/article/42 (for instance) + + For demonstration purpose, some requests/responses will have a custom header: TimestampHeader. + This header will be mapped to a part of the message. + + Also for demonstration, the User-agent header will be set in some requests. + --> + <wsdl:types> + <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ode/bpel/test/blog"> + <xsd:element name="article" type="tns:ArticleType"/> + <xsd:element name="comment" type="tns:CommentType"/> + <xsd:element name="fault" type="tns:FaultType"/> + <xsd:element name="from" type="xsd:string"/> + <xsd:complexType name="ArticleType"> + <xsd:sequence> + <xsd:element name="id" type="xsd:string"/> + <xsd:element name="title" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="CommentType"> + <xsd:sequence> + <xsd:element name="author" type="xsd:string"/> + <xsd:element name="content" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + <xsd:complexType name="FaultType"> + <xsd:sequence> + <xsd:element name="timestamp" type="xsd:string"/> + <xsd:element name="details" type="xsd:string"/> + </xsd:sequence> + </xsd:complexType> + </xsd:schema> + </wsdl:types> + + <wsdl:message name="IdMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="from" element="tns:from"/> + <wsdl:part name="articleId" type="xsd:string"/> + </wsdl:message> + <wsdl:message name="ArticleMessage"> + <wsdl:part name="timestamp" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="PUTRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="article" element="tns:article"/> + </wsdl:message> + <wsdl:message name="CommentRequest"> + <wsdl:part name="articleId" type="xsd:string"/> + <wsdl:part name="comment" element="tns:comment"/> + </wsdl:message> + <wsdl:message name="UpdateFault"> + <wsdl:part name="faultDetails" element="tns:fault"/> + </wsdl:message> + <wsdl:message name="NoPartMessage"/> + + + <wsdl:portType name="BlogPortType"> + <wsdl:operation name="doGET"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:ArticleMessage"/> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <wsdl:input message="tns:IdMessage"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <wsdl:input message="tns:PUTRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + <wsdl:fault name="UpdateException" message="tns:UpdateFault"/> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <wsdl:input message="tns:CommentRequest"/> + <wsdl:output message="tns:NoPartMessage"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="binding" type="tns:BlogPortType"> + <wsdl:operation name="doGET"> + <http:operation location=""/> + <odex:binding verb="GET"/> + <wsdl:input> + <http:urlReplacement/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + <odex:header name="From" part="from"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="article"/> + <!-- a part mapped to a non-standard header --> + <odex:header name="TimestampHeader" part="timestamp"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="doDELETE"> + <http:operation location=""/> + <odex:binding verb="DELETE"/> + <wsdl:input> + <http:urlReplacement/> + <odex:header name="TimestampHeader" part="timestamp"/> + <!-- a static value mapped to a standard header --> + <odex:header name="User-Agent" value="MyKillerApp"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + <wsdl:operation name="doPUT"> + <http:operation location=""/> + <odex:binding verb="PUT"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="article"/> + </wsdl:input> + <wsdl:output/> + <!-- fault binding --> + <wsdl:fault name="UpdateException"> + <!-- name attribute is optional --> + <!--<odex:fault name="UpdateException"/>--> + <odex:fault/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="doPOST"> + <http:operation location=""/> + <odex:binding verb="POST"/> + <wsdl:input> + <http:urlReplacement/> + <mime:content type="text/xml" part="comment"/> + </wsdl:input> + <wsdl:output/> + </wsdl:operation> + </wsdl:binding> + + <wsdl:service name="BlogService"> + <wsdl:port name="BlogPort" binding="tns:binding"> + <http:address location="http://localhost:7070/HttpBindingTest/BlogService/article/{articleId}"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/deploy.xml new file mode 100644 index 0000000..ae9a95b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="http://ode/bpel/test/blog"> + + + <process name="pns:http-binding-ext-PUT"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="blogPartnerLink"> + <service name="dns:BlogService" port="BlogPort"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/http-binding-ext-PUT.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/http-binding-ext-PUT.bpel new file mode 100644 index 0000000..dd43df5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/http-binding-ext-PUT.bpel
@@ -0,0 +1,313 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="http-binding-ext-PUT" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://ode/bpel/test/blog" + xmlns:ext="http://ode.apache.org/activityRecovery" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="http-binding-ext-PUT.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/"/> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me"/> + <partnerLink name="blogPartnerLink" + partnerLinkType="test:BlogLinkType" partnerRole="you"/> + </partnerLinks> + + <variables> + <variable name="inputVar" messageType="test:HelloMessage"/> + <variable name="outputVar" messageType="test:HelloMessage"/> + <variable name="faultVar" messageType="dummy:UpdateFault"/> + <variable name="putMsg" messageType="dummy:PUTRequest"/> + <variable name="noPartMsg" messageType="dummy:NoPartMessage"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inputVar" createInstance="yes"/> + + <!-- Initialize output var --> + <!-- Change this value to make the test fail. --> + <assign> + <copy> + <from>'What a success!'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + + <!-- Prepare the input message --> + <assign> + <copy> + <from> + <literal> + <dummy:article> + <dummy:id></dummy:id> + <dummy:title>Whatever could be a nice blog title</dummy:title> + </dummy:article> + </literal> + </from> + <to>$putMsg.article</to> + </copy> + <copy> + <from>string(round(seconds-from-dateTime(current-dateTime())))</from> + <to>$putMsg.articleId</to> + </copy> + <copy> + <from>$putMsg.articleId</from> + <to>$putMsg.article/dummy:id</to> + </copy> + </assign> + + + <!-- ############################################### --> + <!-- regular PUT --> + <!-- ############################################### --> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"/> + <!-- no real test to make here --> + + + <!-- ############################################### --> + <!-- 500_expected_xml_body - Fault expected --> + <!-- ############################################### --> + <scope> + <faultHandlers> + <catch faultMessageType="dummy:UpdateFault" faultName="dummy:UpdateException" faultVariable="faultVar"> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_expected_xml_body'</from> + <to variable="putMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"/> + <assign> + <copy> + <from>'500_expected_xml_body: A fault should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + + <!-- ############################################### --> + <!-- 500_no_body - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_no_body'</from> + <to variable="putMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"> + </invoke> + <assign> + <copy> + <from>'500_no_body: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 500_text_body - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_text_body'</from> + <to variable="putMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"/> + <assign> + <copy> + <from>'500_text_body: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 500_unknown_xml_body - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_unknown_xml_body'</from> + <to variable="putMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"> + </invoke> + <assign> + <copy> + <from>'500_unknown_xml_body: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 500_malformed_xml_body - failure expected --> + <!-- ############################################### --> + <scope> + <ext:failureHandling> + <ext:faultOnFailure>true</ext:faultOnFailure> + </ext:failureHandling> + <faultHandlers> + <catch faultName="ext:activityFailure"> + <!-- expected result--> + <!-- + Warning #1!! At this point what we know for sure is that a failure occured + but we don't know which failure exactly. + We would like to test if the the failure is really the one we triggered on purpose and not a TimeoutFailure for instance. + --> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_malformed_xml_body'</from> + <to variable="putMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"> + </invoke> + <assign> + <copy> + <from>'500_not-well-formed_xml_body: A failure should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + <!-- ############################################### --> + <!-- 500_expected_xml_body - Fault expected --> + <!-- ############################################### --> + <scope> + <faultHandlers> + <catch faultMessageType="dummy:UpdateFault" faultName="dummy:UpdateException" faultVariable="faultVar"> + <empty/> + </catch> + </faultHandlers> + <sequence> + <assign> + <copy> + <from>'500_expected_xml_body'</from> + <to variable="putMsg" header="Fault-Type"/> + </copy> + </assign> + <invoke partnerLink="blogPartnerLink" portType="dummy:BlogPortType" + operation="doPUT" inputVariable="putMsg" outputVariable="noPartMsg"/> + <assign> + <copy> + <from>'500_expected_xml_body: A fault should have been thrown'</from> + <to>$outputVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + </scope> + + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outputVar"/> + </sequence> + +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/http-binding-ext-PUT.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/http-binding-ext-PUT.wsdl new file mode 100644 index 0000000..6ad1ac4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/http-binding-ext-PUT.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://ode/bpel/test/blog" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" + location="Blog.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="BlogLinkType"> + <plnk:role name="you" portType="dummy:BlogPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/testRequest.soap new file mode 100644 index 0000000..afc8fb7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestHttpBindingExt_PUT/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">100</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/TestRetire.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/TestRetire.bpel new file mode 100644 index 0000000..907deda --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/TestRetire.bpel
@@ -0,0 +1,66 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<process name="TestRetire" + targetNamespace="http://ode/bpel/test/retire" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/responder" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:resp="http://ode/bpel/test/retire/responder.wsdl"> + + <import location="TestRetire.wsdl" namespace="http://ode/bpel/test/retire.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="testRetirePartnerLink" partnerLinkType="resp:TestRetirePartnerLinkType" myRole="responder"/> + </partnerLinks> + + <variables> + <variable name="dummy" messageType="resp:TestRetireMessage"/> + </variables> + + <correlationSets> + <correlationSet name="dummyCorr" properties="resp:dummyProp" /> + </correlationSets> + + <sequence> + <receive name="start" partnerLink="testRetirePartnerLink" variable="dummy" operation="first" createInstance="yes"> + <correlations> + <correlation set="dummyCorr" initiate="yes"/> + </correlations> + </receive> + <reply name="reply-endpoint" partnerLink="testRetirePartnerLink" operation="first" variable="dummy"/> + + + <receive name="second" partnerLink="testRetirePartnerLink" variable="dummy" operation="second"> + <correlations> + <correlation set="dummyCorr" initiate="no"/> + </correlations> + </receive> + <assign> + <copy> + <from><literal>DONE</literal></from> + <to>$dummy.TestPart</to> + </copy> + </assign> + <reply name="reply-ack" partnerLink="testRetirePartnerLink" operation="second" variable="dummy"/> + + </sequence> +</process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/TestRetire.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/TestRetire.wsdl new file mode 100644 index 0000000..0ac4e77 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/TestRetire.wsdl
@@ -0,0 +1,74 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/test/retire/responder.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/test/retire/responder.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop"> + + <wsdl:message name="TestRetireMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="TestRetirePortType"> + <wsdl:operation name="first"> + <wsdl:input message="tns:TestRetireMessage" name="TestIn"/> + <wsdl:output message="tns:TestRetireMessage" name="TestOut"/> + </wsdl:operation> + <wsdl:operation name="second"> + <wsdl:input message="tns:TestRetireMessage" name="TestIn"/> + <wsdl:output message="tns:TestRetireMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="TestRetireSoapBinding" type="tns:TestRetirePortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="first"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input><soap:body namespace="http://ode/bpel/test/retire/responder.wsdl" use="literal"/></wsdl:input> + <wsdl:output><soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/></wsdl:output> + </wsdl:operation> + <wsdl:operation name="second"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input><soap:body namespace="http://ode/bpel/test/retire/responder.wsdl" use="literal"/></wsdl:input> + <wsdl:output><soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/></wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TestRetireService"> + <wsdl:port name="TestRetirePort" binding="tns:TestRetireSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/testretire"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="TestRetirePartnerLinkType"> + <plnk:role name="responder" portType="tns:TestRetirePortType"/> + </plnk:partnerLinkType> + + <prop:property name="dummyProp" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:dummyProp" messageType="tns:TestRetireMessage" part="TestPart"/> + +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/deploy.xml new file mode 100644 index 0000000..a48b45e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/deploy.xml
@@ -0,0 +1,29 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/test/retire" + xmlns:wns="http://ode/bpel/test/retire/responder.wsdl"> + + <process name="pns:TestRetire"> + <active>true</active> + <provide partnerLink="testRetirePartnerLink"> + <service name="wns:TestRetireService" port="TestRetirePort"/> + </provide> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/testRequest1.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/testRequest1.soap new file mode 100644 index 0000000..ad47884 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/testRequest1.soap
@@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Body> + <tns:first xmlns:tns="http://ode/bpel/test/retire/responder.wsdl"><TestPart>XYZ</TestPart></tns:first> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/testRequest2.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/testRequest2.soap new file mode 100644 index 0000000..d827cf3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/1/testRequest2.soap
@@ -0,0 +1,25 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Body> + <tns:second xmlns:tns="http://ode/bpel/test/retire/responder.wsdl"><TestPart>XYZ</TestPart></tns:second> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/TestRetire.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/TestRetire.bpel new file mode 100644 index 0000000..f374b0a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/TestRetire.bpel
@@ -0,0 +1,59 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<process name="TestRetire" + targetNamespace="http://ode/bpel/test/retire" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/responder" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:resp="http://ode/bpel/test/retire/responder.wsdl"> + + <import location="TestRetire.wsdl" namespace="http://ode/bpel/test/retire.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="testRetirePartnerLink" partnerLinkType="resp:TestRetirePartnerLinkType" myRole="responder"/> + </partnerLinks> + + <variables> + <variable name="dummy" messageType="resp:TestRetireMessage"/> + </variables> + + <correlationSets> + <correlationSet name="dummyCorr" properties="resp:dummyProp" /> + </correlationSets> + + <sequence> + <receive name="start" partnerLink="testRetirePartnerLink" variable="dummy" operation="first" createInstance="yes"> + <correlations> + <correlation set="dummyCorr" initiate="yes"/> + </correlations> + </receive> + <reply name="reply-endpoint" partnerLink="testRetirePartnerLink" operation="first" variable="dummy"/> + + <receive name="second" partnerLink="testRetirePartnerLink" variable="dummy" operation="second"> + <correlations> + <correlation set="dummyCorr" initiate="no"/> + </correlations> + </receive> + <reply name="reply-ack" partnerLink="testRetirePartnerLink" operation="second" variable="dummy"/> + + </sequence> +</process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/TestRetire.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/TestRetire.wsdl new file mode 100644 index 0000000..0ac4e77 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/TestRetire.wsdl
@@ -0,0 +1,74 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/test/retire/responder.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/test/retire/responder.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:prop="http://docs.oasis-open.org/wsbpel/2.0/varprop"> + + <wsdl:message name="TestRetireMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="TestRetirePortType"> + <wsdl:operation name="first"> + <wsdl:input message="tns:TestRetireMessage" name="TestIn"/> + <wsdl:output message="tns:TestRetireMessage" name="TestOut"/> + </wsdl:operation> + <wsdl:operation name="second"> + <wsdl:input message="tns:TestRetireMessage" name="TestIn"/> + <wsdl:output message="tns:TestRetireMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="TestRetireSoapBinding" type="tns:TestRetirePortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="first"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input><soap:body namespace="http://ode/bpel/test/retire/responder.wsdl" use="literal"/></wsdl:input> + <wsdl:output><soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/></wsdl:output> + </wsdl:operation> + <wsdl:operation name="second"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input><soap:body namespace="http://ode/bpel/test/retire/responder.wsdl" use="literal"/></wsdl:input> + <wsdl:output><soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/></wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="TestRetireService"> + <wsdl:port name="TestRetirePort" binding="tns:TestRetireSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/testretire"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="TestRetirePartnerLinkType"> + <plnk:role name="responder" portType="tns:TestRetirePortType"/> + </plnk:partnerLinkType> + + <prop:property name="dummyProp" type="xsd:string"/> + <prop:propertyAlias propertyName="tns:dummyProp" messageType="tns:TestRetireMessage" part="TestPart"/> + +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/deploy.xml new file mode 100644 index 0000000..a48b45e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestInstanceRetire/2/deploy.xml
@@ -0,0 +1,29 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/test/retire" + xmlns:wns="http://ode/bpel/test/retire/responder.wsdl"> + + <process name="pns:TestRetire"> + <active>true</active> + <provide partnerLink="testRetirePartnerLink"> + <service name="wns:TestRetireService" port="TestRetirePort"/> + </provide> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample02.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample02.txt new file mode 100644 index 0000000..de24747 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample02.txt
@@ -0,0 +1,10 @@ +UsernameToken authentication + +The client is configured to add a UsernameToken to the outgoing message. + - See the "OutflowSecurity" parameter in the client.axis2.xml + +The service is configured to process it. + - See the "InflowSecurity" parameter in the services.xml + +Note how org.apache.rampart.samples.sample02.PWCBHandler supplies the password +to wss4j to compute the digest for comparison.
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample03.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample03.txt new file mode 100644 index 0000000..1446348 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample03.txt
@@ -0,0 +1,12 @@ +UsernameToken authentication with a plain text password + +The client is configured to add a UsernameToken to the outgoing message. + - See the "OutflowSecurity" parameter in the client.axis2.xml + - Note the <passwordType>PasswordText</passwordType> element + +The service is configured to process it. + - See the "InflowSecurity" parameter in the services.xml + +Note how org.apache.rampart.samples.sample03.PWCBHandler authenticates the +password +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample04.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample04.txt new file mode 100644 index 0000000..df4599d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample04.txt
@@ -0,0 +1,7 @@ +Message integrity and non-repudiation with signature + +Both client and servce are configured to sign the outgoing message and to verify +the signature of the incoming message using their key pairs. + - See the "OutflowSecurity" and "InflowSecurity" parameters in the + client.axis2.xml and serivces.xml files +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample05.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample05.txt new file mode 100644 index 0000000..8ca2fd8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample05.txt
@@ -0,0 +1,7 @@ +Encrypting messages + +Both client and servce are configured to encrypt the outgoing message and to +decrypt incoming message using their key pairs. + - See the "OutflowSecurity" and "InflowSecurity" parameters in the + client.axis2.xml and serivces.xml files +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample06.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample06.txt new file mode 100644 index 0000000..54642b5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample06.txt
@@ -0,0 +1,8 @@ +Sign and encrypt messages + +Both client and servce are configured to first sign and then encrypt the +outgoing message and to decrypt and verify the incoming message using their +key pairs. + - See the "OutflowSecurity" and "InflowSecurity" parameters in the + client.axis2.xml and serivces.xml files +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample07.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample07.txt new file mode 100644 index 0000000..f524604 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample07.txt
@@ -0,0 +1,8 @@ +Encrypt and sign messages + +Both client and servce are configured to first encrypt and then sign the +outgoing message and to verify and decrypt the incoming message using their +key pairs. + - See the "OutflowSecurity" and "InflowSecurity" parameters in the + client.axis2.xml and serivces.xml files +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample08.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample08.txt new file mode 100644 index 0000000..4643e47 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample08.txt
@@ -0,0 +1,10 @@ +Signing twice + +The client is configured to sign the outgoing message twice + - See the "OutflowSecurity" parameter in the client.axis2.xml + - Note the aditional <action> element that defines the second signature. + +The service is configured to process it. + - See the "InflowSecurity" parameter in the services.xml. Not that we + simply use "Signature Signature" as action items. +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample09.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample09.txt new file mode 100644 index 0000000..7202cc6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample09.txt
@@ -0,0 +1,8 @@ +Encryption with a key known to both parties + +Both client and servce are configured to encrypt the outgoing message and to +decrypt incoming message using a known named key + - See the "OutflowSecurity" and "InflowSecurity" parameters in the + client.axis2.xml and serivces.xml files + - Note the use of <EmbeddedKeyName>SessionKey</EmbeddedKeyName> + - Note that org.apache.rampart.samples.sample09.PWCBHandler sets the key
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample10.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample10.txt new file mode 100644 index 0000000..0ad0c6a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/README-sample10.txt
@@ -0,0 +1,8 @@ +Sign and encrypt messages + +Both client and servce are configured to first sign and then encrypt the +outgoing message and to decrypt and verify the incoming message using their +key pairs. + - See the "OutflowSecurity" and "InflowSecurity" parameters in the + client.axis2.xml and serivces.xml files + - Note the use of <optimizeParts>[xpath expression]</optimizeParts>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/client.jks b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/client.jks new file mode 100644 index 0000000..e3dabb9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/client.jks Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/client.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/client.properties new file mode 100644 index 0000000..08ddd3e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/client.properties
@@ -0,0 +1,4 @@ +org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin +org.apache.ws.security.crypto.merlin.keystore.type=jks +org.apache.ws.security.crypto.merlin.keystore.password=apache +org.apache.ws.security.crypto.merlin.file=TestRampartBasic/secured-processes/client.jks \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/HelloWorld2.bpel new file mode 100644 index 0000000..db8f6c2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/HelloWorld2.bpel
@@ -0,0 +1,55 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + </partnerLinks> + + <variables> + <variable name="inVar" messageType="test:HelloMessage"/> + <variable name="outVar" messageType="test:HelloMessage"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inVar" createInstance="yes"/> + + <assign> + <copy> + <from>concat(concat("Hello ", $inVar.TestPart), "!")</from> + <to>$outVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/HelloWorld2.wsdl new file mode 100644 index 0000000..11d7acb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/HelloWorld2.wsdl
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8080/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/deploy.xml new file mode 100644 index 0000000..b675017 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/process-template/deploy.xml
@@ -0,0 +1,30 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample02-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample02-client.axis2 new file mode 100644 index 0000000..b6a7c7e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample02-client.axis2
@@ -0,0 +1,227 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart"/> + + <parameter name="OutflowSecurity"> + <action> + <items>UsernameToken Timestamp</items> + <user>bob</user> + <passwordCallbackClass>org.apache.rampart.samples.sample02.PWCBHandler</passwordCallbackClass> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample02-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample02-service.xml new file mode 100644 index 0000000..2aebd86 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample02-service.xml
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-2 : Timestamp and UsernameToken--> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>UsernameToken Timestamp</items> + <passwordCallbackClass>org.apache.rampart.samples.sample02.PWCBHandler</passwordCallbackClass> + </action> + </parameter> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample03-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample03-client.axis2 new file mode 100644 index 0000000..e864e46 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample03-client.axis2
@@ -0,0 +1,229 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>UsernameToken</items> + <user>bob</user> + <passwordCallbackClass>org.apache.rampart.samples.sample03.PWCBHandler</passwordCallbackClass> + <passwordType>PasswordText</passwordType> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample03-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample03-service.xml new file mode 100644 index 0000000..cd9056e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample03-service.xml
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-3 : Timestamp and UsernameToken (with plaintext password)--> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>UsernameToken</items> + <passwordCallbackClass>org.apache.rampart.samples.sample03.PWCBHandler</passwordCallbackClass> + </action> + </parameter> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample04-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample04-client.axis2 new file mode 100644 index 0000000..f0434c2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample04-client.axis2
@@ -0,0 +1,239 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature</items> + <user>client</user> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + <passwordCallbackClass>org.apache.rampart.samples.sample04.PWCBHandler</passwordCallbackClass> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature</items> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample04-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample04-service.xml new file mode 100644 index 0000000..c682df0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample04-service.xml
@@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-4 : Signature only --> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature</items> + <signaturePropFile>service.properties</signaturePropFile> + </action> + </parameter> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature</items> + <user>service</user> + <passwordCallbackClass>org.apache.rampart.samples.sample04.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + </action> + </parameter> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample05-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample05-client.axis2 new file mode 100644 index 0000000..5db21e6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample05-client.axis2
@@ -0,0 +1,236 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Encrypt</items> + <encryptionUser>service</encryptionUser> + <encryptionPropFile>TestRampartBasic/secured-processes/client.properties</encryptionPropFile> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample05.PWCBHandler</passwordCallbackClass> + <decryptionPropFile>TestRampartBasic/secured-processes/client.properties</decryptionPropFile> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample05-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample05-service.xml new file mode 100644 index 0000000..e1293fa --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample05-service.xml
@@ -0,0 +1,40 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-5 : Encryption only --> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample05.PWCBHandler</passwordCallbackClass> + <decryptionPropFile>service.properties</decryptionPropFile> + </action> + </parameter> + + <parameter name="OutflowSecurity"> + <action> + <items>Encrypt</items> + <encryptionUser>client</encryptionUser> + <encryptionPropFile>service.properties</encryptionPropFile> + </action> + </parameter> + + + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample06-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample06-client.axis2 new file mode 100644 index 0000000..3b1cd04 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample06-client.axis2
@@ -0,0 +1,242 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <!--Signature and Encryption : Using the request's certificate--> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample06.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>service</encryptionUser> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample06.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample06-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample06-service.xml new file mode 100644 index 0000000..a623803 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample06-service.xml
@@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-6 : Signature and Encryption : Using the request's certificate--> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample06.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + </action> + </parameter> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <user>service</user> + <passwordCallbackClass>org.apache.rampart.samples.sample06.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>useReqSigCert</encryptionUser> + </action> + </parameter> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample07-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample07-client.axis2 new file mode 100644 index 0000000..4a2602a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample07-client.axis2
@@ -0,0 +1,240 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Encrypt Signature</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample07.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>service</encryptionUser> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Encrypt Signature</items> + <passwordCallbackClass>org.apache.rampart.samples.sample07.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample07-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample07-service.xml new file mode 100644 index 0000000..a9f52d6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample07-service.xml
@@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-7 : Encryption and Signature --> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Encrypt Signature</items> + <passwordCallbackClass>org.apache.rampart.samples.sample07.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + </action> + </parameter> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Encrypt Signature</items> + <user>service</user> + <passwordCallbackClass>org.apache.rampart.samples.sample07.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>useReqSigCert</encryptionUser> + </action> + </parameter> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample08-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample08-client.axis2 new file mode 100644 index 0000000..2175acf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample08-client.axis2
@@ -0,0 +1,241 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <!-- sample-8 : Double Signature --> + <parameter name="OutflowSecurity"> + + <action> + <items>Timestamp Signature NoSerialization</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample08.PWCBHandler</passwordCallbackClass> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <signatureParts>{Element}{http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd}Timestamp</signatureParts> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + </action> + + <action> + <items>Signature</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample08.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + </action> + + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample08-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample08-service.xml new file mode 100644 index 0000000..67ead81 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample08-service.xml
@@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-8 : Double Signature --> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Signature</items> + <passwordCallbackClass>org.apache.rampart.samples.sample08.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + </action> + </parameter> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample09-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample09-client.axis2 new file mode 100644 index 0000000..4ba661a --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample09-client.axis2
@@ -0,0 +1,239 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Encrypt</items> + <user>client</user> + <encryptionKeyIdentifier>EmbeddedKeyName</encryptionKeyIdentifier> + <EmbeddedKeyCallbackClass>org.apache.rampart.samples.sample09.PWCBHandler</EmbeddedKeyCallbackClass> + <encryptionPropFile>TestRampartBasic/secured-processes/client.properties</encryptionPropFile> + <EmbeddedKeyName>SessionKey</EmbeddedKeyName> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample09.PWCBHandler</passwordCallbackClass> + <decryptionPropFile>TestRampartBasic/secured-processes/client.properties</decryptionPropFile> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample09-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample09-service.xml new file mode 100644 index 0000000..ca993f4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample09-service.xml
@@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-9 : Encryption using a known key --> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample09.PWCBHandler</passwordCallbackClass> + <decryptionPropFile>service.properties</decryptionPropFile> + </action> + </parameter> + + <parameter name="OutflowSecurity"> + <action> + <items>Encrypt</items> + <user>service</user> + <encryptionKeyIdentifier>EmbeddedKeyName</encryptionKeyIdentifier> + <encryptionPropFile>service.properties</encryptionPropFile> + <EmbeddedKeyCallbackClass>org.apache.rampart.samples.sample09.PWCBHandler</EmbeddedKeyCallbackClass> + <EmbeddedKeyName>SessionKey</EmbeddedKeyName> + </action> + </parameter> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample10-client.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample10-client.axis2 new file mode 100644 index 0000000..1a673b2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample10-client.axis2
@@ -0,0 +1,245 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<axisconfig name="AxisJava2.0"> + + <module ref="rampart" /> + + <!-- sample-10 : MTOM optimize encrypted content --> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample10.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>service</encryptionUser> + + <optimizeParts>//xenc:EncryptedData/xenc:CipherData/xenc:CipherValue</optimizeParts> + + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample10.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-processes/client.properties</signaturePropFile> + </action> + </parameter> + + <!-- ================================================= --> + <!-- Parameters --> + <!-- ================================================= --> + <parameter name="hotdeployment" locked="false">true</parameter> + <parameter name="hotupdate" locked="false">false</parameter> + <parameter name="enableMTOM" locked="false">false</parameter> + + <!--During a fault, stacktrace can be sent with the fault message. The following flag will control --> + <!--that behaviour.--> + <parameter name="sendStacktraceDetailsWithFaults" locked="false">true</parameter> + + <!--If there aren't any information available to find out the fault reason, we set the message of the exception--> + <!--as the faultreason/Reason. But when a fault is thrown from a service or some where, it will be --> + <!--wrapped by different levels. Due to this the initial exception message can be lost. If this flag--> + <!--is set then, Axis2 tries to get the first exception and set its message as the faultreason/Reason.--> + <parameter name="DrillDownToRootCauseForFaultReason" locked="false">false</parameter> + + <!--This is the user name and password of admin console--> + <parameter name="userName" locked="false">admin</parameter> + <parameter name="password" locked="false">axis2</parameter> + + <!--To override repository/services you need to uncomment following parameter and value SHOULD be absolute file path.--> + <!--<parameter name="services" locked="false">service</parameter>--> + <!--To override repository/modules you need to uncomment following parameter and value SHOULD be absolute file path--> + <!--<parameter name="modules" locked="false">modules</parameter>--> + + <!--Following params will set the proper context paths for invocations. All the endpoints will have a commons context--> + <!--root which can configured using the following contextRoot parameter--> + <!--<parameter name="contextRoot" locked="false">axis2</parameter>--> + + <!--Our HTTP endpoints can handle both REST and SOAP. Following parameters can be used to distinguish those endpoints--> + <!--<parameter name="servicePath" locked="false">services</parameter>--> + <!--<parameter name="restPath" locked="false">rest</parameter>--> + + <!--Set the flag to true if you want to enable transport level session management--> + <parameter name="manageTransportSession" locked="false">false</parameter> + + <!--Following two parameters will be used to handle REST in Axis2. The default settings will make Axis2 to have two--> + <!--different endpoints, one for REST (AxisRESTServlet) one for SOAP message handling (AxisServlet). But following--> + <!--parameters help to tweak the message handling of two main servlets. --> + + <!-- If the enableRESTInAxis2MainServlet is true, then Axis2MainServlet will handle both SOAP and REST messages --> + <parameter name="enableRESTInAxis2MainServlet" locked="true">true</parameter> + + <!-- Following parameter will completely disable REST handling in both the servlets--> + <parameter name="disableREST" locked="true">false</parameter> + + <!-- This will disable the separate servlet we have for REST handling. --> + <parameter name="disableSeparateEndpointForREST" locked="true">false</parameter> + + + + <!-- ================================================= --> + <!-- Message Receivers --> + <!-- ================================================= --> + <!--This is the Default Message Receiver for the system , if you want to have MessageReceivers for --> + <!--all the other MEP implement it and add the correct entry to here , so that you can refer from--> + <!--any operation --> + <!--Note : You can override this for particular service by adding the same element with your requirement--> + <messageReceivers> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-only" + class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/> + <messageReceiver mep="http://www.w3.org/2004/08/wsdl/in-out" + class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/> + </messageReceivers> + + <!-- ================================================= --> + <!-- Target Resolvers --> + <!-- ================================================= --> + <!-- Uncomment the following and specify the class name for your TargetResolver to add --> + <!-- a TargetResolver. TargetResolvers are used to process the To EPR for example to --> + <!-- choose a server in a cluster --> + <!--<targetResolvers>--> + <!--<targetResolver class="" />--> + <!--</targetResolvers>--> + + + <!-- ================================================= --> + <!-- Transport Ins --> + <!-- ================================================= --> + <transportReceiver name="http" + class="org.apache.axis2.transport.http.SimpleHTTPServer"> + <parameter name="port" locked="false">6060</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">http://myApp.com/ws</parameter>--> + </transportReceiver> + + <transportReceiver name="tcp" + class="org.apache.axis2.transport.tcp.TCPServer"> + <parameter name="port" locked="false">6061</parameter> + <!--If you want to give your own host address for EPR generation--> + <!--uncomment following parameter , and set as you required.--> + <!--<parameter name="hostname" locked="false">tcp://myApp.com/ws</parameter>--> + </transportReceiver> + + <!-- ================================================= --> + <!-- Transport Outs --> + <!-- ================================================= --> + + <transportSender name="jms" + class="org.apache.axis2.transport.jms.JMSSender"/> + <transportSender name="tcp" + class="org.apache.axis2.transport.tcp.TCPTransportSender"/> + <transportSender name="local" + class="org.apache.axis2.transport.local.LocalTransportSender"/> + <transportSender name="http" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + <transportSender name="https" + class="org.apache.axis2.transport.http.CommonsHTTPTransportSender"> + <parameter name="PROTOCOL" locked="false">HTTP/1.1</parameter> + <parameter name="Transfer-Encoding" locked="false">chunked</parameter> + </transportSender> + + <!-- ================================================= --> + <!-- Phases --> + <!-- ================================================= --> + <phaseOrder type="InFlow"> + <!-- System pre-defined phases --> + <phase name="Transport"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Transport"/> + </handler> + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Transport"/> + </handler> + </phase> + <phase name="Security"/> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- System pre defined phases --> + <!-- After Postdispatch phase module author or or service author can add any phase he want --> + <phase name="OperationInPhase"/> + </phaseOrder> + <phaseOrder type="OutFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutPhase"/> + <!--system predefined phase--> + <!--these phase will run irrespective of the service--> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + <phase name="Security"/> + </phaseOrder> + <phaseOrder type="InFaultFlow"> + <phase name="PreDispatch"/> + <phase name="Dispatch" class="org.apache.axis2.engine.DispatchPhase"> + <handler name="RequestURIBasedDispatcher" + class="org.apache.axis2.engine.RequestURIBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPActionBasedDispatcher" + class="org.apache.axis2.engine.SOAPActionBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="AddressingBasedDispatcher" + class="org.apache.axis2.engine.AddressingBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + + <handler name="SOAPMessageBodyBasedDispatcher" + class="org.apache.axis2.engine.SOAPMessageBodyBasedDispatcher"> + <order phase="Dispatch"/> + </handler> + <handler name="InstanceDispatcher" + class="org.apache.axis2.engine.InstanceDispatcher"> + <order phase="Dispatch"/> + </handler> + </phase> + <!-- user can add his own phases to this area --> + <phase name="OperationInFaultPhase"/> + </phaseOrder> + <phaseOrder type="OutFaultFlow"> + <!-- user can add his own phases to this area --> + <phase name="OperationOutFaultPhase"/> + <phase name="PolicyDetermination"/> + <phase name="MessageOut"/> + </phaseOrder> +</axisconfig> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample10-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample10-service.xml new file mode 100644 index 0000000..e6c0f73 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/sample10-service.xml
@@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-10 : MTOM optimize encrypted content --> +<service> + <module ref="rampart" /> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample10.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + </action> + </parameter> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <user>service</user> + <passwordCallbackClass>org.apache.rampart.samples.sample10.PWCBHandler</passwordCallbackClass> + <signaturePropFile>service.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>useReqSigCert</encryptionUser> + </action> + </parameter> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/service.jks b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/service.jks new file mode 100644 index 0000000..1a06520 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/service.jks Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/service.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/service.properties new file mode 100644 index 0000000..cdd231c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-processes/service.properties
@@ -0,0 +1,4 @@ +org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin +org.apache.ws.security.crypto.merlin.keystore.type=jks +org.apache.ws.security.crypto.merlin.keystore.password=apache +org.apache.ws.security.crypto.merlin.file=service.jks \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/client.jks b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/client.jks new file mode 100644 index 0000000..e3dabb9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/client.jks Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/client.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/client.properties new file mode 100644 index 0000000..5e0a0ea --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/client.properties
@@ -0,0 +1,4 @@ +org.apache.ws.security.crypto.provider=org.apache.ws.security.components.crypto.Merlin +org.apache.ws.security.crypto.merlin.keystore.type=jks +org.apache.ws.security.crypto.merlin.keystore.password=apache +org.apache.ws.security.crypto.merlin.file=TestRampartBasic/secured-services/client.jks
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/HelloWorld2.bpel new file mode 100644 index 0000000..3f21bd5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/HelloWorld2.bpel
@@ -0,0 +1,73 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="{sample.namespace}" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="samplePartnerLink" + partnerLinkType="test:samplePartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="req" messageType="dummy:echoRequest"/> + <variable name="resp" messageType="dummy:echoResponse"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:echo><dummy:param0>foo</dummy:param0></dummy:echo></literal></from> + <to>$req.parameters</to> + </copy> + <copy> + <from>$myVar.TestPart</from> + <to>$req.parameters/dummy:param0</to> + </copy> + </assign> + + <invoke partnerLink="samplePartnerLink" portType="dummy:{sample.service.name}PortType" + operation="echo" inputVariable="req" outputVariable="resp"/> + + <assign> + <copy> + <from>$resp.parameters/dummy:return</from> + <to>$myVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/HelloWorld2.wsdl new file mode 100644 index 0000000..e9b6b22 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="{sample.namespace}" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="{sample.namespace}" location="echo-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8080/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="samplePartnerLinkType"> + <plnk:role name="you" portType="dummy:{sample.service.name}PortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/deploy.xml new file mode 100644 index 0000000..1cada77 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="{sample.namespace}"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="samplePartnerLink"> + <service name="dns:{sample.service.name}" port="{sample.service.name}SOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/echo-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/echo-service.wsdl new file mode 100644 index 0000000..9f85da8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/echo-service.wsdl
@@ -0,0 +1,62 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="{sample.namespace}" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://org.apache.axis2/xsd" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="{sample.namespace}"> + <wsdl:types> + <xs:schema xmlns:ns="{sample.namespace}" + attributeFormDefault="qualified" + elementFormDefault="qualified" + targetNamespace="{sample.namespace}"> + <xs:element name="echo"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="param0" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="echoResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="echoRequest"> + <wsdl:part name="parameters" element="ns0:echo"/> + </wsdl:message> + <wsdl:message name="echoResponse"> + <wsdl:part name="parameters" element="ns0:echoResponse"/> + </wsdl:message> + <wsdl:portType name="{sample.service.name}PortType"> + <wsdl:operation name="echo"> + <wsdl:input message="ns0:echoRequest" wsaw:Action="urn:echo"/> + <wsdl:output message="ns0:echoResponse" wsaw:Action="urn:echoResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="{sample.service.name}SOAP11Binding" type="ns0:{sample.service.name}PortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="echo"> + <soap:operation soapAction="urn:echo" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="{sample.service.name}"> + <wsdl:port name="{sample.service.name}SOAP11port_http" binding="ns0:{sample.service.name}SOAP11Binding"> + <soap:address location="http://localhost:8888/axis2/processes/{sample.service.name}"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/testRequest.soap new file mode 100644 index 0000000..df16ecf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/process-template/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello World</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/readme.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/readme.txt new file mode 100644 index 0000000..b5e1920 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/readme.txt
@@ -0,0 +1,7 @@ + + +How does TestRampartBasic bundle work? +======================================== + +please refer to TestRampartPolicy/readme.txt + \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample02.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample02.axis2 new file mode 100644 index 0000000..ec18e07 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample02.axis2
@@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart"/> + + <parameter name="OutflowSecurity"> + <action> + <items>UsernameToken Timestamp</items> + <user>bob</user> + <passwordCallbackClass>org.apache.rampart.samples.sample02.PWCBHandler</passwordCallbackClass> + </action> + </parameter> + +</service> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample03.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample03.axis2 new file mode 100644 index 0000000..e169e9c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample03.axis2
@@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>UsernameToken</items> + <user>bob</user> + <passwordCallbackClass>org.apache.rampart.samples.sample03.PWCBHandler</passwordCallbackClass> + <passwordType>PasswordText</passwordType> + </action> + </parameter> + +</service> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample04.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample04.axis2 new file mode 100644 index 0000000..2e51671 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample04.axis2
@@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature</items> + <user>client</user> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + <passwordCallbackClass>org.apache.rampart.samples.sample04.PWCBHandler</passwordCallbackClass> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature</items> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + </action> + </parameter> + + </service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample05.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample05.axis2 new file mode 100644 index 0000000..1469c5e --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample05.axis2
@@ -0,0 +1,37 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Encrypt</items> + <encryptionUser>service</encryptionUser> + <encryptionPropFile>TestRampartBasic/secured-services/client.properties</encryptionPropFile> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample05.PWCBHandler</passwordCallbackClass> + <decryptionPropFile>TestRampartBasic/secured-services/client.properties</decryptionPropFile> + </action> + </parameter> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample06.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample06.axis2 new file mode 100644 index 0000000..809f376 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample06.axis2
@@ -0,0 +1,44 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <!--Signature and Encryption : Using the request's certificate--> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample06.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>service</encryptionUser> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample06.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + </action> + </parameter> + + </service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample07.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample07.axis2 new file mode 100644 index 0000000..a89ee64 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample07.axis2
@@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Encrypt Signature</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample07.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>service</encryptionUser> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Encrypt Signature</items> + <passwordCallbackClass>org.apache.rampart.samples.sample07.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + </action> + </parameter> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample08.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample08.axis2 new file mode 100644 index 0000000..1d973a8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample08.axis2
@@ -0,0 +1,42 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart" /> + + <!-- sample-8 : Double Signature --> + <parameter name="OutflowSecurity"> + + <action> + <items>Timestamp Signature NoSerialization</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample08.PWCBHandler</passwordCallbackClass> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <signatureParts>{Element}{http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd}Timestamp</signatureParts> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + </action> + + <action> + <items>Signature</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample08.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + </action> + + </parameter> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample09.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample09.axis2 new file mode 100644 index 0000000..b12e91f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample09.axis2
@@ -0,0 +1,41 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart" /> + + <parameter name="OutflowSecurity"> + <action> + <items>Encrypt</items> + <user>client</user> + <encryptionKeyIdentifier>EmbeddedKeyName</encryptionKeyIdentifier> + <EmbeddedKeyCallbackClass>org.apache.rampart.samples.sample09.PWCBHandler</EmbeddedKeyCallbackClass> + <encryptionPropFile>TestRampartBasic/secured-services/client.properties</encryptionPropFile> + <EmbeddedKeyName>SessionKey</EmbeddedKeyName> + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample09.PWCBHandler</passwordCallbackClass> + <decryptionPropFile>TestRampartBasic/secured-services/client.properties</decryptionPropFile> + </action> + </parameter> + + </service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample10.axis2 b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample10.axis2 new file mode 100644 index 0000000..f392bc3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/sample10.axis2
@@ -0,0 +1,47 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<service> + + <module ref="rampart" /> + + <!-- sample-10 : MTOM optimize encrypted content --> + + <parameter name="OutflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <user>client</user> + <passwordCallbackClass>org.apache.rampart.samples.sample10.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + <signatureKeyIdentifier>DirectReference</signatureKeyIdentifier> + <encryptionKeyIdentifier>SKIKeyIdentifier</encryptionKeyIdentifier> + <encryptionUser>service</encryptionUser> + + <optimizeParts>//xenc:EncryptedData/xenc:CipherData/xenc:CipherValue</optimizeParts> + + </action> + </parameter> + + <parameter name="InflowSecurity"> + <action> + <items>Timestamp Signature Encrypt</items> + <passwordCallbackClass>org.apache.rampart.samples.sample10.PWCBHandler</passwordCallbackClass> + <signaturePropFile>TestRampartBasic/secured-services/client.properties</signaturePropFile> + </action> + </parameter> + + </service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample02.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample02.aar new file mode 100644 index 0000000..4534109 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample02.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample03.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample03.aar new file mode 100644 index 0000000..b407d22 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample03.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample04.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample04.aar new file mode 100644 index 0000000..e1ff1b2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample04.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample05.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample05.aar new file mode 100644 index 0000000..d4194ff --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample05.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample06.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample06.aar new file mode 100644 index 0000000..92fa90d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample06.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample07.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample07.aar new file mode 100644 index 0000000..76adfbe --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample07.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample08.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample08.aar new file mode 100644 index 0000000..193023f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample08.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample09.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample09.aar new file mode 100644 index 0000000..d204a18 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample09.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample10.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample10.aar new file mode 100644 index 0000000..bafc5a7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartBasic/secured-services/services/sample10.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample01-policy.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample01-policy.txt new file mode 100644 index 0000000..ad75ce6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample01-policy.txt
@@ -0,0 +1,8 @@ +UsernameToken Authentication + +The policy uses a TransportBinding and requires a SignedSupportingToken which +is a UsernameToken and the inclusion of a TimeStamp. + +Note that Rampart does not enforce the use of HTTPS transport and that +{http://ws.apache.org/rampart/policy}RampartConfig assertion provides +additional information required to secure the message. \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample02-policy.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample02-policy.txt new file mode 100644 index 0000000..47a2fa7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample02-policy.txt
@@ -0,0 +1,7 @@ +Sign only + +An AsymmetricBinding is used. Entire headers and body to be signed. +Algorithm suite is TripleDesRsa15 + +Note that {http://ws.apache.org/rampart/policy}RampartConfig assertion provides +additional information required to secure the message. \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample03-policy.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample03-policy.txt new file mode 100644 index 0000000..57bf529 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample03-policy.txt
@@ -0,0 +1,9 @@ +Sign and Encrypt messages + +An AsymmetricBinding is used. Entire headers and body to be signed. +EncryptionParts specifies the Body to be encrypted. + +Algorithm suite is TripleDesRsa15 + +Note that {http://ws.apache.org/rampart/policy}RampartConfig assertion provides +additional information required to secure the message. \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample04-policy.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample04-policy.txt new file mode 100644 index 0000000..33a0168 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/README-sample04-policy.txt
@@ -0,0 +1,15 @@ +SecureConversation + +The secure session is bootstrapped using a SymetricBinding which uses +derived keys based on an ephemeral key. + +Messages in the secure conversation : + - Includes a timestamp + - All headers are signed along with the timestamp + - Signature encrypted + - Body encrypted + +Algorithm suite is Basic128Rsa15 + +Note that {http://ws.apache.org/rampart/policy}RampartConfig assertion provides +additional information required to secure the message. \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/client.jks b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/client.jks new file mode 100644 index 0000000..e3dabb9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/client.jks Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/HelloWorld2.bpel new file mode 100644 index 0000000..db8f6c2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/HelloWorld2.bpel
@@ -0,0 +1,55 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + </partnerLinks> + + <variables> + <variable name="inVar" messageType="test:HelloMessage"/> + <variable name="outVar" messageType="test:HelloMessage"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="inVar" createInstance="yes"/> + + <assign> + <copy> + <from>concat(concat("Hello ", $inVar.TestPart), "!")</from> + <to>$outVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="outVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/HelloWorld2.wsdl new file mode 100644 index 0000000..11d7acb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/HelloWorld2.wsdl
@@ -0,0 +1,68 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8080/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/deploy.xml new file mode 100644 index 0000000..b675017 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/process-template/deploy.xml
@@ -0,0 +1,30 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample01-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample01-policy.xml new file mode 100644 index 0000000..7e7209d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample01-policy.xml
@@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<wsp:Policy wsu:Id="UTOverTransport" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:TransportBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:TransportToken> + <wsp:Policy> + <sp:HttpsToken RequireClientCertificate="false"/> + </wsp:Policy> + </sp:TransportToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic256/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Lax/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + </wsp:Policy> + </sp:TransportBinding> + <sp:SignedSupportingTokens xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:UsernameToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient" /> + </wsp:Policy> + </sp:SignedSupportingTokens> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>alice</ramp:user> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample01.PWCBHandler</ramp:passwordCallbackClass> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample01-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample01-service.xml new file mode 100644 index 0000000..2606144 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample01-service.xml
@@ -0,0 +1,60 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-1 : UsernameToken--> +<service> + + <module ref="rampart" /> + + <wsp:Policy wsu:Id="UTOverTransport" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:TransportBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:TransportToken> + <wsp:Policy> + <sp:HttpsToken RequireClientCertificate="false"/> + </wsp:Policy> + </sp:TransportToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic256/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Lax/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + </wsp:Policy> + </sp:TransportBinding> + <sp:SignedSupportingTokens xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:UsernameToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient" /> + </wsp:Policy> + </sp:SignedSupportingTokens> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample01.PWCBHandler</ramp:passwordCallbackClass> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> + </wsp:Policy> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample02-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample02-policy.xml new file mode 100644 index 0000000..5804192 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample02-policy.xml
@@ -0,0 +1,81 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<wsp:Policy wsu:Id="SigOnly" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:AsymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:InitiatorToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:InitiatorToken> + <sp:RecipientToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:RecipientToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:TripleDesRsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:AsymmetricBinding> + <sp:Wss10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + </wsp:Policy> + </sp:Wss10> + <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:SignedParts> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>client</ramp:user> + <ramp:encryptionUser>service</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample02.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample02-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample02-service.xml new file mode 100644 index 0000000..8c4488b --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample02-service.xml
@@ -0,0 +1,87 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-2 : Sign only--> +<service> + + <module ref="rampart" /> + + <wsp:Policy wsu:Id="SigOnly" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:AsymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:InitiatorToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:InitiatorToken> + <sp:RecipientToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:RecipientToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:TripleDesRsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:AsymmetricBinding> + <sp:Wss10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + </wsp:Policy> + </sp:Wss10> + <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:SignedParts> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>service</ramp:user> + <ramp:encryptionUser>client</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample02.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">service.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> + </wsp:Policy> +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample03-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample03-policy.xml new file mode 100644 index 0000000..3c93757 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample03-policy.xml
@@ -0,0 +1,92 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> + +<wsp:Policy wsu:Id="SigEncr" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:AsymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:InitiatorToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:InitiatorToken> + <sp:RecipientToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:RecipientToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:TripleDesRsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:AsymmetricBinding> + <sp:Wss10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + </wsp:Policy> + </sp:Wss10> + <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:SignedParts> + <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:EncryptedParts> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>client</ramp:user> + <ramp:encryptionUser>service</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample03.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + <ramp:encryptionCypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:encryptionCypto> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample03-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample03-service.xml new file mode 100644 index 0000000..ea78807 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample03-service.xml
@@ -0,0 +1,98 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-2 : Sign only--> +<service> + + <module ref="rampart" /> + +<wsp:Policy wsu:Id="SigEncr" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:AsymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:InitiatorToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:InitiatorToken> + <sp:RecipientToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:RecipientToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:TripleDesRsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:AsymmetricBinding> + <sp:Wss10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + </wsp:Policy> + </sp:Wss10> + <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:SignedParts> + <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:EncryptedParts> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>service</ramp:user> + <ramp:encryptionUser>client</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample03.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">service.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + <ramp:encryptionCypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">service.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:encryptionCypto> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample04-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample04-policy.xml new file mode 100644 index 0000000..1311a37 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample04-policy.xml
@@ -0,0 +1,150 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> + +<wsp:Policy wsu:Id="SecConvPolicy2" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:SymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:ProtectionToken> + <wsp:Policy> + <sp:SecureConversationToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:RequireDerivedKeys/> + <sp:BootstrapPolicy> + <wsp:Policy> + <sp:EncryptedParts> + <sp:Body/> + </sp:EncryptedParts> + <sp:SymmetricBinding> + <wsp:Policy> + <sp:ProtectionToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:RequireDerivedKeys/> + <sp:RequireThumbprintReference/> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:ProtectionToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic128Rsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:EncryptSignature/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:SymmetricBinding> + <sp:EndorsingSupportingTokens> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:RequireThumbprintReference/> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:EndorsingSupportingTokens> + <sp:Wss11> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + <sp:MustSupportRefThumbprint/> + <sp:MustSupportRefEncryptedKey/> + <sp:RequireSignatureConfirmation/> + </wsp:Policy> + </sp:Wss11> + <sp:Trust10> + <wsp:Policy> + <sp:MustSupportIssuedTokens/> + <sp:RequireClientEntropy/> + <sp:RequireServerEntropy/> + </wsp:Policy> + </sp:Trust10> + </wsp:Policy> + </sp:BootstrapPolicy> + </wsp:Policy> + </sp:SecureConversationToken> + </wsp:Policy> + </sp:ProtectionToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic128Rsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:EncryptSignature/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:SymmetricBinding> + <sp:Wss11 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + <sp:MustSupportRefThumbprint/> + <sp:MustSupportRefEncryptedKey/> + </wsp:Policy> + </sp:Wss11> + <sp:Trust10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportIssuedTokens/> + <sp:RequireClientEntropy/> + <sp:RequireServerEntropy/> + </wsp:Policy> + </sp:Trust10> + <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:EncryptedParts> + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>client</ramp:user> + <ramp:encryptionUser>service</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample04.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + <ramp:encryptionCypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:encryptionCypto> + + </ramp:RampartConfig> + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample04-service.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample04-service.xml new file mode 100644 index 0000000..199bd20 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/sample04-service.xml
@@ -0,0 +1,192 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<!-- services.xml of sample-2 : Sign only--> +<service> + <module ref="rampart" /> + <module ref="rahas" /> + + <wsp:Policy wsu:Id="SecConvPolicy" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:SymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:ProtectionToken> + <wsp:Policy> + <sp:SecureConversationToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:RequireDerivedKeys/> + <sp:BootstrapPolicy> + <wsp:Policy> + <sp:EncryptedParts> + <sp:Body/> + </sp:EncryptedParts> + <sp:SymmetricBinding> + <wsp:Policy> + <sp:ProtectionToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:RequireDerivedKeys/> + <sp:RequireThumbprintReference/> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:ProtectionToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic128Rsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:EncryptSignature/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:SymmetricBinding> + <sp:EndorsingSupportingTokens> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:RequireThumbprintReference/> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:EndorsingSupportingTokens> + <sp:Wss11> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + <sp:MustSupportRefThumbprint/> + <sp:MustSupportRefEncryptedKey/> + <sp:RequireSignatureConfirmation/> + </wsp:Policy> + </sp:Wss11> + <sp:Trust10> + <wsp:Policy> + <sp:MustSupportIssuedTokens/> + <sp:RequireClientEntropy/> + <sp:RequireServerEntropy/> + </wsp:Policy> + </sp:Trust10> + </wsp:Policy> + </sp:BootstrapPolicy> + </wsp:Policy> + </sp:SecureConversationToken> + </wsp:Policy> + </sp:ProtectionToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic128Rsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:EncryptSignature/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:SymmetricBinding> + <sp:Wss11 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + <sp:MustSupportRefThumbprint/> + <sp:MustSupportRefEncryptedKey/> + </wsp:Policy> + </sp:Wss11> + <sp:Trust10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportIssuedTokens/> + <sp:RequireClientEntropy/> + <sp:RequireServerEntropy/> + </wsp:Policy> + </sp:Trust10> + <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:EncryptedParts> + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>service</ramp:user> + <ramp:encryptionUser>client</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample04.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/service.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + <ramp:encryptionCypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/service.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:encryptionCypto> + + </ramp:RampartConfig> + </wsp:All> + </wsp:ExactlyOne> + </wsp:Policy> + + <parameter name="sct-issuer-config"> + <sct-issuer-config> + <cryptoProperties> + <crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</property> + <property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-processes/sts.jks</property> + <property name="org.apache.ws.security.crypto.merlin.keystore.password">password</property> + </crypto> + </cryptoProperties> + <addRequestedAttachedRef /> + <addRequestedUnattachedRef /> + + <!-- + Key computation mechanism + 1 - Use Request Entropy + 2 - Provide Entropy + 3 - Use Own Key + --> + <keyComputation>3</keyComputation> + + <!-- + proofKeyType element is valid only if the keyComputation is set to 3 + i.e. Use Own Key + + Valid values are: EncryptedKey & BinarySecret + --> + <proofKeyType>BinarySecret</proofKeyType> + </sct-issuer-config> + </parameter> + + <parameter name="token-canceler-config"> + <token-canceler-config> + + </token-canceler-config> + </parameter> + +</service>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/service.jks b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/service.jks new file mode 100644 index 0000000..1a06520 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-processes/service.jks Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/client.jks b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/client.jks new file mode 100644 index 0000000..e3dabb9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/client.jks Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/HelloWorld2.bpel new file mode 100644 index 0000000..3f21bd5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/HelloWorld2.bpel
@@ -0,0 +1,73 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="{sample.namespace}" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="samplePartnerLink" + partnerLinkType="test:samplePartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="req" messageType="dummy:echoRequest"/> + <variable name="resp" messageType="dummy:echoResponse"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:echo><dummy:param0>foo</dummy:param0></dummy:echo></literal></from> + <to>$req.parameters</to> + </copy> + <copy> + <from>$myVar.TestPart</from> + <to>$req.parameters/dummy:param0</to> + </copy> + </assign> + + <invoke partnerLink="samplePartnerLink" portType="dummy:{sample.service.name}PortType" + operation="echo" inputVariable="req" outputVariable="resp"/> + + <assign> + <copy> + <from>$resp.parameters/dummy:return</from> + <to>$myVar.TestPart</to> + </copy> + </assign> + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/HelloWorld2.wsdl new file mode 100644 index 0000000..e9b6b22 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="{sample.namespace}" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="{sample.namespace}" location="echo-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8080/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="samplePartnerLinkType"> + <plnk:role name="you" portType="dummy:{sample.service.name}PortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/config.endpoint b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/config.endpoint new file mode 100644 index 0000000..ba59320 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/config.endpoint
@@ -0,0 +1,6 @@ + + +alias.sample-ns={sample.namespace} +sample-ns.{sample.service.name}.ode.security.policy={sample.service.name}.xml + +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/deploy.xml new file mode 100644 index 0000000..1cada77 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/deploy.xml
@@ -0,0 +1,34 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" + xmlns:dns="{sample.namespace}"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="samplePartnerLink"> + <service name="dns:{sample.service.name}" port="{sample.service.name}SOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/echo-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/echo-service.wsdl new file mode 100644 index 0000000..9f85da8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/echo-service.wsdl
@@ -0,0 +1,62 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="{sample.namespace}" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://org.apache.axis2/xsd" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="{sample.namespace}"> + <wsdl:types> + <xs:schema xmlns:ns="{sample.namespace}" + attributeFormDefault="qualified" + elementFormDefault="qualified" + targetNamespace="{sample.namespace}"> + <xs:element name="echo"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="param0" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="echoResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="echoRequest"> + <wsdl:part name="parameters" element="ns0:echo"/> + </wsdl:message> + <wsdl:message name="echoResponse"> + <wsdl:part name="parameters" element="ns0:echoResponse"/> + </wsdl:message> + <wsdl:portType name="{sample.service.name}PortType"> + <wsdl:operation name="echo"> + <wsdl:input message="ns0:echoRequest" wsaw:Action="urn:echo"/> + <wsdl:output message="ns0:echoResponse" wsaw:Action="urn:echoResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="{sample.service.name}SOAP11Binding" type="ns0:{sample.service.name}PortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="echo"> + <soap:operation soapAction="urn:echo" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="{sample.service.name}"> + <wsdl:port name="{sample.service.name}SOAP11port_http" binding="ns0:{sample.service.name}SOAP11Binding"> + <soap:address location="http://localhost:8888/axis2/processes/{sample.service.name}"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/testRequest.soap new file mode 100644 index 0000000..df16ecf --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/process-template/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello World</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/readme.txt b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/readme.txt new file mode 100644 index 0000000..d0f2e6d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/readme.txt
@@ -0,0 +1,19 @@ + + +How does TestRampartPolicy bundle work? +======================================== + +The goal of this test is to make sure Rampart is integrated properly. +Rampart comes with a set of samples [1]. A subset of them test the same service with different security policies. + +Here we reuse the policy samples and for each of them generate a process bundle based on the TestRampartPolicy/process-template. +The qname of the services vary so two variables are replaced: +{sample.namespace} +{sample.service.name} + +This is done before running the tests in the Rakefile, see task :prepare_rampart_policy_test. + +The external services are packaged as Axis archives in TestRampartPolicy/services. +The Password Callback Handler classes are in src/test/java. + +[1] https://svn.apache.org/repos/asf/webservices/rampart/trunk/java/modules/rampart-samples/policy/ \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample01-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample01-policy.xml new file mode 100644 index 0000000..7e7209d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample01-policy.xml
@@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<wsp:Policy wsu:Id="UTOverTransport" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:TransportBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:TransportToken> + <wsp:Policy> + <sp:HttpsToken RequireClientCertificate="false"/> + </wsp:Policy> + </sp:TransportToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic256/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Lax/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + </wsp:Policy> + </sp:TransportBinding> + <sp:SignedSupportingTokens xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:UsernameToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient" /> + </wsp:Policy> + </sp:SignedSupportingTokens> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>alice</ramp:user> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample01.PWCBHandler</ramp:passwordCallbackClass> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample02-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample02-policy.xml new file mode 100644 index 0000000..4cfaf61 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample02-policy.xml
@@ -0,0 +1,81 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> +<wsp:Policy wsu:Id="SigOnly" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:AsymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:InitiatorToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:InitiatorToken> + <sp:RecipientToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:RecipientToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:TripleDesRsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:AsymmetricBinding> + <sp:Wss10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + </wsp:Policy> + </sp:Wss10> + <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:SignedParts> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>client</ramp:user> + <ramp:encryptionUser>service</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample02.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-services/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample03-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample03-policy.xml new file mode 100644 index 0000000..1ce91a8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample03-policy.xml
@@ -0,0 +1,92 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> + +<wsp:Policy wsu:Id="SigEncr" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:AsymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:InitiatorToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:InitiatorToken> + <sp:RecipientToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:RecipientToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:TripleDesRsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:AsymmetricBinding> + <sp:Wss10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + </wsp:Policy> + </sp:Wss10> + <sp:SignedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:SignedParts> + <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:EncryptedParts> + + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>client</ramp:user> + <ramp:encryptionUser>service</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample03.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-services/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + <ramp:encryptionCypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-services/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:encryptionCypto> + </ramp:RampartConfig> + + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample04-policy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample04-policy.xml new file mode 100644 index 0000000..ea79541 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/sample04-policy.xml
@@ -0,0 +1,150 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ! + ! Copyright 2006 The Apache Software Foundation. + ! + ! Licensed under the Apache License, Version 2.0 (the "License"); + ! you may not use this file except in compliance with the License. + ! You may obtain a copy of the License at + ! + ! http://www.apache.org/licenses/LICENSE-2.0 + ! + ! Unless required by applicable law or agreed to in writing, software + ! distributed under the License is distributed on an "AS IS" BASIS, + ! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + ! See the License for the specific language governing permissions and + ! limitations under the License. + !--> + +<wsp:Policy wsu:Id="SecConvPolicy2" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> + <wsp:ExactlyOne> + <wsp:All> + <sp:SymmetricBinding xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:ProtectionToken> + <wsp:Policy> + <sp:SecureConversationToken sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:RequireDerivedKeys/> + <sp:BootstrapPolicy> + <wsp:Policy> + <sp:EncryptedParts> + <sp:Body/> + </sp:EncryptedParts> + <sp:SymmetricBinding> + <wsp:Policy> + <sp:ProtectionToken> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never"> + <wsp:Policy> + <sp:RequireDerivedKeys/> + <sp:RequireThumbprintReference/> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:ProtectionToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic128Rsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:EncryptSignature/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:SymmetricBinding> + <sp:EndorsingSupportingTokens> + <wsp:Policy> + <sp:X509Token sp:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient"> + <wsp:Policy> + <sp:RequireThumbprintReference/> + <sp:WssX509V3Token10/> + </wsp:Policy> + </sp:X509Token> + </wsp:Policy> + </sp:EndorsingSupportingTokens> + <sp:Wss11> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + <sp:MustSupportRefThumbprint/> + <sp:MustSupportRefEncryptedKey/> + <sp:RequireSignatureConfirmation/> + </wsp:Policy> + </sp:Wss11> + <sp:Trust10> + <wsp:Policy> + <sp:MustSupportIssuedTokens/> + <sp:RequireClientEntropy/> + <sp:RequireServerEntropy/> + </wsp:Policy> + </sp:Trust10> + </wsp:Policy> + </sp:BootstrapPolicy> + </wsp:Policy> + </sp:SecureConversationToken> + </wsp:Policy> + </sp:ProtectionToken> + <sp:AlgorithmSuite> + <wsp:Policy> + <sp:Basic128Rsa15/> + </wsp:Policy> + </sp:AlgorithmSuite> + <sp:Layout> + <wsp:Policy> + <sp:Strict/> + </wsp:Policy> + </sp:Layout> + <sp:IncludeTimestamp/> + <sp:EncryptSignature/> + <sp:OnlySignEntireHeadersAndBody/> + </wsp:Policy> + </sp:SymmetricBinding> + <sp:Wss11 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportRefKeyIdentifier/> + <sp:MustSupportRefIssuerSerial/> + <sp:MustSupportRefThumbprint/> + <sp:MustSupportRefEncryptedKey/> + </wsp:Policy> + </sp:Wss11> + <sp:Trust10 xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <wsp:Policy> + <sp:MustSupportIssuedTokens/> + <sp:RequireClientEntropy/> + <sp:RequireServerEntropy/> + </wsp:Policy> + </sp:Trust10> + <sp:EncryptedParts xmlns:sp="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy"> + <sp:Body/> + </sp:EncryptedParts> + <ramp:RampartConfig xmlns:ramp="http://ws.apache.org/rampart/policy"> + <ramp:user>client</ramp:user> + <ramp:encryptionUser>service</ramp:encryptionUser> + <ramp:passwordCallbackClass>org.apache.rampart.samples.policy.sample04.PWCBHandler</ramp:passwordCallbackClass> + + <ramp:signatureCrypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-services/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:signatureCrypto> + <ramp:encryptionCypto> + <ramp:crypto provider="org.apache.ws.security.components.crypto.Merlin"> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.type">JKS</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.file">TestRampartPolicy/secured-services/client.jks</ramp:property> + <ramp:property name="org.apache.ws.security.crypto.merlin.keystore.password">apache</ramp:property> + </ramp:crypto> + </ramp:encryptionCypto> + + </ramp:RampartConfig> + </wsp:All> + </wsp:ExactlyOne> +</wsp:Policy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample01-policy.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample01-policy.aar new file mode 100644 index 0000000..9335a39 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample01-policy.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample02-policy.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample02-policy.aar new file mode 100644 index 0000000..1a42deb --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample02-policy.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample03-policy.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample03-policy.aar new file mode 100644 index 0000000..1f32b4d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample03-policy.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample04-policy.aar b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample04-policy.aar new file mode 100644 index 0000000..254917d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestRampartPolicy/secured-services/services/sample04-policy.aar Binary files differ
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/HeaderTest.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/HeaderTest.bpel new file mode 100644 index 0000000..4a0e869 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/HeaderTest.bpel
@@ -0,0 +1,82 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HeaderTest" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HeaderTest.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HeaderTestPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HeaderTestMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <assign> + <copy> + <from variable="myVar" header="ConversationId"/> + <to variable="faultInput" header="ConversationId"/> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"/> + + <assign> + <copy> + <from variable="faultOutput" header="ConversationId"/> + <to variable="myVar" header="ConversationId"/> + </copy> + <copy> + <from variable="faultOutput" header="ConversationId"/> + <to variable="myVar" header="ConversationId"/> + </copy> + </assign> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HeaderTestPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/HeaderTest.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/HeaderTest.wsdl new file mode 100644 index 0000000..65066e3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/HeaderTest.wsdl
@@ -0,0 +1,70 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HeaderTestMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HeaderTestPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HeaderTestMessage" name="TestIn"/> + <wsdl:output message="tns:HeaderTestMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HeaderTestSoapBinding" type="tns:HeaderTestPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body namespace="http://ode/bpel/unit-test.wsdl" use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HeaderTestService"> + <wsdl:port name="HeaderTestPort" binding="tns:HeaderTestSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/headerTest"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HeaderTestPartnerLinkType"> + <plnk:role name="me" portType="tns:HeaderTestPortType"/> + <plnk:role name="you" portType="tns:HeaderTestPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/deploy.xml new file mode 100644 index 0000000..788ab3d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HeaderTest"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HeaderTestService" port="HeaderTestPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/dummy-service.wsdl new file mode 100644 index 0000000..4f45120 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/dummy-service.wsdl
@@ -0,0 +1,160 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyException"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyException" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceSOAP12Binding" type="ns1:DummyServicePortType"> + <soap12:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap12:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap12:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap12:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap12:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap12:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:binding name="DummyServiceHttpBinding" type="ns1:DummyServicePortType"> + <http:binding verb="POST"/> + <wsdl:operation name="faultTest"> + <http:operation location="DummyService/faultTest"/> + <wsdl:input> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="faultTest"/> + </wsdl:output> + </wsdl:operation> + <wsdl:operation name="hello"> + <http:operation location="DummyService/hello"/> + <wsdl:input> + <mime:content type="text/xml" part="hello"/> + </wsdl:input> + <wsdl:output> + <mime:content type="text/xml" part="hello"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceSOAP12port_http" binding="ns1:DummyServiceSOAP12Binding"> + <soap12:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + <wsdl:port name="DummyServiceHttpport" binding="ns1:DummyServiceHttpBinding"> + <http:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/testRequest.soap new file mode 100644 index 0000000..f250b44 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestSoapHeader/testRequest.soap
@@ -0,0 +1,31 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <SOAP-ENV:Header> + <myns:ConversationId xmlns:myns="http://my.company/super/protocol">ZZZXYZ</myns:ConversationId> + </SOAP-ENV:Header> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/HelloWorld2.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/HelloWorld2.bpel new file mode 100644 index 0000000..e5a3c2f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/HelloWorld2.bpel
@@ -0,0 +1,76 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<process name="HelloWorld2" + targetNamespace="http://ode/bpel/unit-test" + xmlns="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:tns="http://ode/bpel/unit-test" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:test="http://ode/bpel/unit-test.wsdl" + xmlns:dummy="http://axis2.ode.apache.org" + queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" + expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0"> + + <import location="HelloWorld2.wsdl" + namespace="http://ode/bpel/unit-test.wsdl" + importType="http://schemas.xmlsoap.org/wsdl/" /> + + <partnerLinks> + <partnerLink name="helloPartnerLink" + partnerLinkType="test:HelloPartnerLinkType" myRole="me" /> + <partnerLink name="dummyPartnerLink" + partnerLinkType="test:DummyPartnerLinkType" partnerRole="you" /> + </partnerLinks> + + <variables> + <variable name="myVar" messageType="test:HelloMessage"/> + <variable name="faultInput" messageType="dummy:faultTestRequest"/> + <variable name="faultOutput" messageType="dummy:faultTestResponse"/> + <variable name="faultVar" messageType="dummy:DummyExceptionType"/> + <variable name="tmpVar" type="xsd:string"/> + </variables> + + <sequence> + <receive name="start" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar" createInstance="yes"/> + + <assign> + <copy> + <from><literal><dummy:faultTest><dummy:in>Hello</dummy:in></dummy:faultTest></literal></from> + <to>$faultInput.parameters</to> + </copy> + </assign> + + <invoke partnerLink="dummyPartnerLink" portType="test:DummyServicePortType" + operation="faultTest" inputVariable="faultInput" outputVariable="faultOutput"> + <catch faultMessageType="dummy:DummyExceptionType" faultName="dummy:DummyException" faultVariable="faultVar"> + <sequence> + <assign> + <copy> + <from>$faultVar.parameters/reason</from> + <to>$myVar.TestPart</to> + </copy> + </assign> + </sequence> + </catch> + </invoke> + + <reply name="end" partnerLink="helloPartnerLink" portType="test:HelloPortType" + operation="hello" variable="myVar"/> + </sequence> +</process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/HelloWorld2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/HelloWorld2.wsdl new file mode 100644 index 0000000..cab04f9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/HelloWorld2.wsdl
@@ -0,0 +1,73 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<wsdl:definitions + targetNamespace="http://ode/bpel/unit-test.wsdl" + xmlns="http://schemas.xmlsoap.org/wsdl/" + xmlns:tns="http://ode/bpel/unit-test.wsdl" + xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:xsd="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + xmlns:dummy="http://axis2.ode.apache.org" + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"> + + <wsdl:import namespace="http://axis2.ode.apache.org" location="dummy-service.wsdl"/> + + <wsdl:message name="HelloMessage"> + <wsdl:part name="TestPart" type="xsd:string"/> + </wsdl:message> + + <wsdl:portType name="HelloPortType"> + <wsdl:operation name="hello"> + <wsdl:input message="tns:HelloMessage" name="TestIn"/> + <wsdl:output message="tns:HelloMessage" name="TestOut"/> + </wsdl:operation> + </wsdl:portType> + + <wsdl:binding name="HelloSoapBinding" type="tns:HelloPortType"> + <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="hello"> + <soap:operation soapAction="" style="rpc"/> + <wsdl:input> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body + namespace="http://ode/bpel/unit-test.wsdl" + use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="HelloService"> + <wsdl:port name="HelloPort" binding="tns:HelloSoapBinding"> + <soap:address location="http://localhost:8888/ode/processes/helloWorld"/> + </wsdl:port> + </wsdl:service> + + <plnk:partnerLinkType name="HelloPartnerLinkType"> + <plnk:role name="me" portType="tns:HelloPortType"/> + </plnk:partnerLinkType> + <plnk:partnerLinkType name="DummyPartnerLinkType"> + <plnk:role name="you" portType="dummy:DummyServicePortType"/> + </plnk:partnerLinkType> +</wsdl:definitions> +
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/deploy.xml new file mode 100644 index 0000000..91278e6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/deploy.xml
@@ -0,0 +1,33 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> +<deploy xmlns="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:pns="http://ode/bpel/unit-test" + xmlns:wns="http://ode/bpel/unit-test.wsdl" xmlns:dns="http://axis2.ode.apache.org"> + + + <process name="pns:HelloWorld2"> + <active>true</active> + <provide partnerLink="helloPartnerLink"> + <service name="wns:HelloService" port="HelloPort"/> + </provide> + <invoke partnerLink="dummyPartnerLink"> + <service name="dns:DummyService" port="DummyServiceSOAP11port_http"/> + </invoke> + </process> +</deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/dummy-service.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/dummy-service.wsdl new file mode 100644 index 0000000..e342207 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/dummy-service.wsdl
@@ -0,0 +1,133 @@ +<?xml version="1.0" encoding="UTF-8"?> +<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" + xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" + xmlns:ns0="http://axis2.ode.apache.org/xsd" + xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" + xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" + xmlns:ns1="http://axis2.ode.apache.org" + xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" + targetNamespace="http://axis2.ode.apache.org"> + <wsdl:types> + <xs:schema xmlns:ns="http://axis2.ode.apache.org" attributeFormDefault="qualified" + elementFormDefault="unqualified" targetNamespace="http://axis2.ode.apache.org"> + + <xs:element name="DummyException"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="reason" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTest"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="faultTestResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="hello"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="helloResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperation"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="in" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + <xs:element name="longOperationResponse"> + <xs:complexType> + <xs:sequence> + <xs:element minOccurs="0" name="return" nillable="true" type="xs:string"/> + </xs:sequence> + </xs:complexType> + </xs:element> + </xs:schema> + </wsdl:types> + <wsdl:message name="faultTestRequest"> + <wsdl:part name="parameters" element="ns1:faultTest"/> + </wsdl:message> + <wsdl:message name="faultTestResponse"> + <wsdl:part name="parameters" element="ns1:faultTestResponse"/> + </wsdl:message> + <wsdl:message name="DummyExceptionType"> + <wsdl:part name="parameters" element="ns1:DummyException"/> + </wsdl:message> + <wsdl:message name="helloRequest"> + <wsdl:part name="parameters" element="ns1:hello"/> + </wsdl:message> + <wsdl:message name="helloResponse"> + <wsdl:part name="parameters" element="ns1:helloResponse"/> + </wsdl:message> + <wsdl:message name="longOperationRequest"> + <wsdl:part name="parameters" element="ns1:longOperation"/> + </wsdl:message> + <wsdl:message name="longOperationResponse"> + <wsdl:part name="parameters" element="ns1:longOperationResponse"/> + </wsdl:message> + <wsdl:portType name="DummyServicePortType"> + <wsdl:operation name="faultTest"> + <wsdl:input message="ns1:faultTestRequest" wsaw:Action="urn:faultTest"/> + <wsdl:output message="ns1:faultTestResponse" wsaw:Action="urn:faultTestResponse"/> + <wsdl:fault message="ns1:DummyExceptionType" name="DummyException" + wsaw:Action="urn:faultTestDummyException"/> + </wsdl:operation> + <wsdl:operation name="hello"> + <wsdl:input message="ns1:helloRequest" wsaw:Action="urn:hello"/> + <wsdl:output message="ns1:helloResponse" wsaw:Action="urn:helloResponse"/> + </wsdl:operation> + <wsdl:operation name="longOperation"> + <wsdl:input message="ns1:longOperationRequest" wsaw:Action="urn:longOperation"/> + <wsdl:output message="ns1:longOperationResponse" wsaw:Action="urn:longOperationResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="DummyServiceSOAP11Binding" type="ns1:DummyServicePortType"> + <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/> + <wsdl:operation name="faultTest"> + <soap:operation soapAction="urn:faultTest" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + <wsdl:fault name="DummyException"> + <soap:fault use="literal" name="DummyException"/> + </wsdl:fault> + </wsdl:operation> + <wsdl:operation name="hello"> + <soap:operation soapAction="urn:hello" style="document"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="DummyService"> + <wsdl:port name="DummyServiceSOAP11port_http" binding="ns1:DummyServiceSOAP11Binding"> + <soap:address location="http://localhost:8888/processes/DummyService"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/testRequest.soap new file mode 100644 index 0000000..6ac42a1 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestStructuredFault/testRequest.soap
@@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8" ?> +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns1:hello xmlns:ns1="http://ode/bpel/unit-test.wsdl"> + <TestPart xmlns="">Hello</TestPart> + </ns1:hello> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.bpel new file mode 100644 index 0000000..ba7a05c --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.bpel
@@ -0,0 +1,64 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpws:process exitOnStandardFault="yes" name="OnEventCorrelation" + suppressJoinFailure="yes" + targetNamespace="http://sample.bpel.org/bpel/sample" + xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable" + xmlns:ns="http://sample.bpel.org/bpel/sampleArtifacts" xmlns:tns="http://sample.bpel.org/bpel/sample"> + <bpws:import importType="http://schemas.xmlsoap.org/wsdl/" + location="OnEventCorrelation.wsdl" namespace="http://sample.bpel.org/bpel/sample"/> + <bpws:import importType="http://schemas.xmlsoap.org/wsdl/" + location="OnEventCorrelationArtifacts.wsdl" namespace="http://sample.bpel.org/bpel/sampleArtifacts"/> + <bpws:import importType="http://www.w3.org/2001/XMLSchema" + location="OnEventCorrelation.xsd" namespace="http://sample.bpel.org/bpel/sample"/> + <bpws:partnerLinks> + <bpws:partnerLink myRole="OnEventCorrelationProvider" + name="client" partnerLinkType="tns:OnEventCorrelation"/> + </bpws:partnerLinks> + <bpws:variables> + <bpws:variable + messageType="tns:OnEventCorrelationRequestMessage" name="input"/> + </bpws:variables> + <bpws:correlationSets> + <bpws:correlationSet name="CorrelationSet" properties="ns:input"/> + </bpws:correlationSets> + <bpws:sequence name="main"> + <bpws:receive createInstance="yes" operation="initiate" + partnerLink="client" portType="tns:OnEventCorrelation" variable="input"> + <bpws:correlations> + <bpws:correlation initiate="yes" set="CorrelationSet"/> + </bpws:correlations> + </bpws:receive> + <bpws:scope> + <bpws:faultHandlers> + <bpws:catch faultName="Repeated"> + <bpws:empty/> + </bpws:catch> + </bpws:faultHandlers> + <bpws:scope> + <bpws:eventHandlers> + <bpws:onEvent operation="initiate" + partnerLink="client" + portType="tns:OnEventCorrelation" variable="input" messageType="tns:OnEventCorrelationRequestMessage"> + <bpws:correlations> + <bpws:correlation initiate="no" set="CorrelationSet"/> + </bpws:correlations> + <bpws:scope> + <bpws:sequence> + <bpws:throw faultName="Repeated"/> + </bpws:sequence> + </bpws:scope> + </bpws:onEvent> + </bpws:eventHandlers> + <bpws:wait> + <bpws:for><![CDATA['PT4S']]></bpws:for> + </bpws:wait> + </bpws:scope> + </bpws:scope> + <bpws:receive operation="initiate" partnerLink="client" + portType="tns:OnEventCorrelation" variable="input"> + <bpws:correlations> + <bpws:correlation initiate="no" set="CorrelationSet"/> + </bpws:correlations> + </bpws:receive> + </bpws:sequence> +</bpws:process>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.wsdl new file mode 100644 index 0000000..882dec0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.wsdl
@@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:tns="http://sample.bpel.org/bpel/sample" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" name="OnEventCorrelation" targetNamespace="http://sample.bpel.org/bpel/sample"> + <types> + <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + <xsd:import namespace="http://sample.bpel.org/bpel/sample" schemaLocation="OnEventCorrelation.xsd"/> + </xsd:schema> + </types> + <message name="OnEventCorrelationRequestMessage"> + <part element="tns:OnEventCorrelationRequest" name="payload"> + </part> + </message> + <message name="OnEventCorrelationResponseMessage"> + <part element="tns:OnEventCorrelationResponse" name="payload"> + </part> + </message> + <portType name="OnEventCorrelation"> + <operation name="initiate"> + <input message="tns:OnEventCorrelationRequestMessage"> + </input> + </operation> + </portType> + <binding name="OnEventCorrelationBinding" type="tns:OnEventCorrelation"> + <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <operation name="initiate"> + <wsdlsoap:operation soapAction=""/> + <input> + <wsdlsoap:body use="literal"/> + </input> + </operation> + </binding> + <service name="OnEventCorrelation"> + <port binding="tns:OnEventCorrelationBinding" name="OnEventCorrelation"> + <wsdlsoap:address location="http://localhost:8888/ode/processes/OnEventCorrelation/"/> + </port> + </service> + <plnk:partnerLinkType name="OnEventCorrelation"> + <plnk:role name="OnEventCorrelationProvider" portType="tns:OnEventCorrelation"/> + </plnk:partnerLinkType> +</definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.xsd new file mode 100644 index 0000000..cb86625 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelation.xsd
@@ -0,0 +1,23 @@ +<schema attributeFormDefault="unqualified" + elementFormDefault="qualified" + targetNamespace="http://sample.bpel.org/bpel/sample" + xmlns="http://www.w3.org/2001/XMLSchema" + > + + <element name="OnEventCorrelationRequest"> + <complexType> + <sequence> + <element name="input" type="string" /> + </sequence> + </complexType> + </element> + + <element name="OnEventCorrelationResponse"> + <complexType> + <sequence> + <element name="result" type="string"/> + </sequence> + </complexType> + </element> + +</schema>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelationArtifacts.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelationArtifacts.wsdl new file mode 100644 index 0000000..8541819 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/OnEventCorrelationArtifacts.wsdl
@@ -0,0 +1,17 @@ +<?xml version="1.0" encoding="UTF-8"?> +<definitions + xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" + xmlns:tns="http://sample.bpel.org/bpel/sampleArtifacts" + xmlns:vprop="http://docs.oasis-open.org/wsbpel/2.0/varprop" + xmlns:xs="http://www.w3.org/2001/XMLSchema" + xmlns:bpel="http://sample.bpel.org/bpel/sample" + name="OnEventCorrelationArtifacts" + targetNamespace="http://sample.bpel.org/bpel/sampleArtifacts" + xmlns="http://schemas.xmlsoap.org/wsdl/" + > +<vprop:property name="input" type="xs:string"/> +<vprop:propertyAlias messageType="bpel:OnEventCorrelationRequestMessage" part="payload" propertyName="tns:input"> +<vprop:query><![CDATA[bpel:input]]></vprop:query> +</vprop:propertyAlias> +<import location="OnEventCorrelation.wsdl" namespace="http://sample.bpel.org/bpel/sample"/> +</definitions>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/deploy.xml new file mode 100644 index 0000000..47213ed --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/deploy.xml
@@ -0,0 +1,13 @@ +<?xml version='1.0' encoding='UTF-8'?> +<dd:deploy xmlns:dd="http://www.apache.org/ode/schemas/dd/2007/03" + xmlns:bpel="http://sample.bpel.org/bpel/sample" + > + + <dd:process + name="bpel:OnEventCorrelation" fileName="OnEventCorrelation.bpel"> + <!--dd:process-events generate="none"/--> + <dd:provide partnerLink="client"> + <dd:service name="bpel:OnEventCorrelation" port="OnEventCorrelation" /> + </dd:provide> + </dd:process> +</dd:deploy>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/testRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/testRequest.soap new file mode 100644 index 0000000..8c7b523 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/TestThrowOnEvent/testRequest.soap
@@ -0,0 +1,8 @@ +<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sam="http://sample.bpel.org/bpel/sample"> + <soapenv:Header/> + <soapenv:Body> + <sam:OnEventCorrelationRequest> + <sam:input>101</sam:input> + </sam:OnEventCorrelationRequest> + </soapenv:Body> +</soapenv:Envelope> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.bpel b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.bpel new file mode 100644 index 0000000..f098fad --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.bpel
@@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="UTF-8"?> +<bpel:process xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/" xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:xreftst="http://ode.apache.org/test/xsdref-test" xmlns:Pooldo="http://example.com/BPMN/NewDiagram2/Pooldo" xmlns:diag="http://example.com/BPMN/NewDiagram2" xmlns:this="http://example.com/BPMN/NewDiagram2/Pool0" xmlns:bpmn="http://www.intalio.com/bpms" queryLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" expressionLanguage="urn:oasis:names:tc:wsbpel:2.0:sublang:xpath2.0" bpmn:label="Pool0" bpmn:id="_9TjBEHjqEdyMF-4bCGAcTQ" name="Pool0" targetNamespace="http://example.com/BPMN/NewDiagram2/Pool0"> + <bpel:import namespace="http://example.com/BPMN/NewDiagram2" location="NewDiagram2.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:import namespace="http://example.com/BPMN/NewDiagram2/Pool0" location="NewDiagram2-Pool0.wsdl" importType="http://schemas.xmlsoap.org/wsdl/"/> + <bpel:partnerLinks> + <bpel:partnerLink name="pool0AndPooldoPlkVar" partnerLinkType="diag:Pool0AndPooldo" myRole="Pool0_for_Pooldo"/> + </bpel:partnerLinks> + <bpel:variables> + <bpel:variable name="thisEventStartMessageRequest" messageType="this:EventStartMessageRequest"/> + <bpel:variable name="thisEventStartMessageResponse" messageType="this:EventStartMessageResponse"/> + </bpel:variables> + <bpel:sequence> + <bpel:receive partnerLink="pool0AndPooldoPlkVar" portType="this:ForPooldo" operation="EventStartMessage" variable="thisEventStartMessageRequest" createInstance="yes" bpmn:label="EventStartMessage" bpmn:id="_9mUzIHjqEdyMF-4bCGAcTQ"></bpel:receive> + <bpel:assign name="init-variables-Pool0"> + <bpel:copy bpmn:label="$thisEventStartMessageResponse out:_BpmbUHjrEdyMF-4bCGAcTQ"> + <bpel:from> + <bpel:literal> +<xreftst:Listexreftst> + <xreftst:xreftst> + <xreftst:LigneMatrice> + <xreftst:Type> + </xreftst:Type> + <xreftst:Montant> + </xreftst:Montant> + <xreftst:ProduitCouvrant> + </xreftst:ProduitCouvrant> + </xreftst:LigneMatrice> + </xreftst:xreftst> +</xreftst:Listexreftst> + </bpel:literal> + </bpel:from> + <bpel:to>$thisEventStartMessageResponse.body</bpel:to> + </bpel:copy> + </bpel:assign> + <bpel:empty bpmn:label="task" bpmn:id="_-IlysHjqEdyMF-4bCGAcTQ"/> + <bpel:reply partnerLink="pool0AndPooldoPlkVar" portType="this:ForPooldo" operation="EventStartMessage" variable="thisEventStartMessageResponse" bpmn:label="EventEndMessage" bpmn:id="__fUVEHjqEdyMF-4bCGAcTQ"></bpel:reply> + </bpel:sequence> +</bpel:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.deploy b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.deploy new file mode 100644 index 0000000..f926bc7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.deploy
@@ -0,0 +1,8 @@ +<?xml version='1.0' encoding='utf-8'?> +<dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" xmlns:MatricePriseEnCharge="http://www.agora.msa.fr/TarifMaladie" xmlns:Pooldo="http://example.com/BPMN/NewDiagram2/Pooldo" xmlns:diag="http://example.com/BPMN/NewDiagram2" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/BPMN/NewDiagram2/Pool0" name="this:Pool0" fileName="BPMN/NewDiagram2-Pool0.bpel"> + <dd:property name="PATH">BPMN/NewDiagram2</dd:property> + <dd:property name="SVG">BPMN/NewDiagram2.svg</dd:property> + <dd:provide partnerLink="pool0AndPooldoPlkVar"> + <dd:service name="this:CanonicServiceForPooldo" port="canonicPort"/> + </dd:provide> +</dd:process> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.wsdl new file mode 100644 index 0000000..e1e9210 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2-Pool0.wsdl
@@ -0,0 +1,40 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:xreftst="http://ode.apache.org/test/xsdref-test" xmlns:Pooldo="http://example.com/BPMN/NewDiagram2/Pooldo" xmlns:diag="http://example.com/BPMN/NewDiagram2" xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/" xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:this="http://example.com/BPMN/NewDiagram2/Pool0" targetNamespace="http://example.com/BPMN/NewDiagram2/Pool0"> + <wsdl:types> + <xs:schema targetNamespace="http://ode.apache.org/test/xsdref-test"> + <xs:include schemaLocation="../XSDSchema/xreftst.xsd"/> + </xs:schema> + <xs:schema elementFormDefault="qualified" targetNamespace="http://example.com/BPMN/NewDiagram2/Pool0"> + <xs:element name="EventStartMessageRequest" type="xs:string"/> + </xs:schema> + </wsdl:types> + <wsdl:message name="EventStartMessageRequest"> + <wsdl:part name="body" element="this:EventStartMessageRequest"/> + </wsdl:message> + <wsdl:message name="EventStartMessageResponse"> + <wsdl:part name="body" element="xreftst:Listexreftst"/> + </wsdl:message> + <wsdl:portType name="ForPooldo"> + <wsdl:operation name="EventStartMessage"> + <wsdl:input message="this:EventStartMessageRequest" name="EventStartMessage"/> + <wsdl:output message="this:EventStartMessageResponse" name="EventStartMessageResponse"/> + </wsdl:operation> + </wsdl:portType> + <wsdl:binding name="CanonicBindingForPooldo" type="this:ForPooldo"> + <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/> + <wsdl:operation name="EventStartMessage"> + <soap:operation style="document" soapAction="http://example.com/BPMN/NewDiagram2/Pool0/ForPooldo/EventStartMessage"/> + <wsdl:input> + <soap:body use="literal"/> + </wsdl:input> + <wsdl:output> + <soap:body use="literal"/> + </wsdl:output> + </wsdl:operation> + </wsdl:binding> + <wsdl:service name="CanonicServiceForPooldo"> + <wsdl:port name="canonicPort" binding="this:CanonicBindingForPooldo"> + <soap:address location="http://localhost:8888/ode/processes/testXSDko/BPMN/NewDiagram2/Pool0/Pooldo"/> + </wsdl:port> + </wsdl:service> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2.wsdl b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2.wsdl new file mode 100644 index 0000000..877a293 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/BPMN/NewDiagram2.wsdl
@@ -0,0 +1,7 @@ +<?xml version='1.0' encoding='utf-8'?> +<wsdl:definitions xmlns:bpdm="http://www.intalio/designer/business-process-data-modeling" xmlns:Pooldo="http://example.com/BPMN/NewDiagram2/Pooldo" xmlns:diag="http://example.com/BPMN/NewDiagram2" xmlns:bpel="http://schemas.xmlsoap.org/ws/2004/03/business-process/" xmlns:pnlk="http://schemas.xmlsoap.org/ws/2004/03/partner-link/" xmlns:PGMD_CURMED="http://www.agora.msa.fr/CURMED" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:ResultatControleFacturation="http://ode.apache.org/test/xsdref-test" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:Pool0="http://example.com/BPMN/NewDiagram2/Pool0" targetNamespace="http://example.com/BPMN/NewDiagram2"> + <wsdl:import namespace="http://example.com/BPMN/NewDiagram2/Pool0" location="NewDiagram2-Pool0.wsdl"/> + <pnlk:partnerLinkType name="Pool0AndPooldo"> + <pnlk:role name="Pool0_for_Pooldo" portType="Pool0:ForPooldo"/> + </pnlk:partnerLinkType> +</wsdl:definitions> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/XSDSchema/ListeProduit.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/XSDSchema/ListeProduit.xsd new file mode 100644 index 0000000..8c5917d --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/XSDSchema/ListeProduit.xsd
@@ -0,0 +1,24 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- edited with XMLSpy v2008 (http://www.altova.com) by none (none) --> +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://ode.apache.org/test/xsdref-test" targetNamespace="http://ode.apache.org/test/xsdref-test" elementFormDefault="qualified" attributeFormDefault="unqualified"> + <xs:element name="ListeProduits" type="ListeProduitsType"> + <xs:annotation> + <xs:documentation>Liste de produits</xs:documentation> + </xs:annotation> + </xs:element> + <xs:complexType name="ListeProduitsType"> + <xs:sequence> + <xs:element ref="ReferenceProduit" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:complexType> + <xs:element name="ReferenceProduit" type="ReferenceProduitType"> + <xs:annotation> + <xs:documentation>Reference de produit</xs:documentation> + </xs:annotation> + </xs:element> + <xs:simpleType name="ReferenceProduitType"> + <xs:restriction base="xs:string"> + <xs:minLength value="1"/> + </xs:restriction> + </xs:simpleType> +</xs:schema>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/XSDSchema/xreftst.xsd b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/XSDSchema/xreftst.xsd new file mode 100644 index 0000000..26c9d74 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/XSDSchema/xreftst.xsd
@@ -0,0 +1,70 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- edited with XMLSpy v2008 (http://www.altova.com) by none (none) --> +<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://ode.apache.org/test/xsdref-test" targetNamespace="http://ode.apache.org/test/xsdref-test" elementFormDefault="qualified" attributeFormDefault="unqualified"> + <xs:include schemaLocation="ListeProduit.xsd"/> + <xs:element name="Listexreftst" type="ListexreftstType"> + <xs:annotation> + <xs:documentation>Liste de matrice de prise en charge</xs:documentation> + </xs:annotation> + </xs:element> + <xs:complexType name="ListexreftstType"> + <xs:sequence> + <xs:element ref="xreftst" minOccurs="0" maxOccurs="unbounded"/> + </xs:sequence> + </xs:complexType> + <xs:element name="xreftst" type="xreftstType"> + <xs:annotation> + <xs:documentation>Matrice de prise en charge</xs:documentation> + </xs:annotation> + </xs:element> + <xs:complexType name="xreftstType"> + <xs:sequence> + <xs:element ref="LigneMatrice" maxOccurs="unbounded"/> + </xs:sequence> + </xs:complexType> + <xs:element name="LigneMatrice" type="LigneMatriceType"> + <xs:annotation> + <xs:documentation>Ligne de la matrice</xs:documentation> + </xs:annotation> + </xs:element> + <xs:complexType name="LigneMatriceType"> + <xs:sequence> + <xs:element ref="Type"/> + <xs:element ref="Montant"/> + <xs:element ref="ProduitCouvrant"/> + </xs:sequence> + </xs:complexType> + <xs:element name="Type"> + <xs:annotation> + <xs:documentation>Type + Exemples de valeur : Depense, Ticket moderateur, Depassement, Participation forfaitaire, Majoration de TM, PO de base)</xs:documentation> + </xs:annotation> + <xs:simpleType> + <xs:restriction base="xs:string"> + <xs:enumeration value="Depense"/> + <xs:enumeration value="Ticket moderateur"/> + <xs:enumeration value="Depassement"/> + <xs:enumeration value="Participation forfaitaire"/> + <xs:enumeration value="Majoration de TM"/> + <xs:enumeration value="PO de base"/> + </xs:restriction> + </xs:simpleType> + </xs:element> + <xs:element name="Montant" type="xs:decimal"> + <xs:annotation> + <xs:documentation>Montant</xs:documentation> + </xs:annotation> + </xs:element> + <xs:element name="ProduitCouvrant" type="ReferenceProduitType"> + <xs:annotation> + <xs:documentation>produit couvrant</xs:documentation> + </xs:annotation> + </xs:element> + <!-- + <xs:simpleType name="ReferenceProduitType2"> + <xs:restriction base="xs:string"> + <xs:minLength value="1"/> + </xs:restriction> + </xs:simpleType> + --> +</xs:schema>
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/deploy.xml b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/deploy.xml new file mode 100644 index 0000000..bae575f --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/XSDReferences/deploy.xml
@@ -0,0 +1,7 @@ +<?xml version='1.0' encoding='UTF-8'?><dd:deploy xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd"><dd:process xmlns:dd="http://ode.fivesight.com/schemas/2006/06/27/dd" xmlns:xreftst="http://ode.apache.org/test/xsdref-test" xmlns:Pooldo="http://example.com/BPMN/NewDiagram2/Pooldo" xmlns:diag="http://example.com/BPMN/NewDiagram2" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:this="http://example.com/BPMN/NewDiagram2/Pool0" name="this:Pool0" fileName="BPMN/NewDiagram2-Pool0.bpel"> + <dd:property name="PATH">BPMN/NewDiagram2</dd:property> + <dd:property name="SVG">BPMN/NewDiagram2.svg</dd:property> + <dd:provide partnerLink="pool0AndPooldoPlkVar"> + <dd:service name="this:CanonicServiceForPooldo" port="canonicPort" /> + </dd:provide> +</dd:process></dd:deploy> \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/test-log4j.properties b/_br-ode-1.X.svn/axis2-war/src/test/resources/test-log4j.properties new file mode 100644 index 0000000..d657ae4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/test-log4j.properties
@@ -0,0 +1,34 @@ +# +# Licensed to the Apache Software Foundation (ASF) under one or more +# contributor license agreements. See the NOTICE file distributed with +# this work for additional information regarding copyright ownership. +# The ASF licenses this file to You under the Apache License, Version 2.0 +# (the "License"); you may not use this file except in compliance with +# the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# Set root logger level to WARN and its only appender to CONSOLE +log4j.rootLogger=WARN, CONSOLE + +# log4j properties to work with commandline tools. +log4j.category.org.mortbay=ERROR +log4j.category.org.hibernate.type=WARN +log4j.category.org.objectweb=ERROR +log4j.category.org.apache.ode.axis2=DEBUG +log4j.category.org.apache.ode.axis2.hooks.SessionInHandler=INFO +log4j.category.org.apache.ode.bpel.engine=INFO +log4j.category.org.apache.ode.daohib.bpel.CorrelatorDaoImpl=DEBUG +log4j.category.org.apache.ode.bpel.epr=INFO + +# Console appender +log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender +log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout +log4j.appender.CONSOLE.layout.ConversionPattern=%p - %C{1}.%M(%L) | %m%n
diff --git a/_br-ode-1.X.svn/axis2-war/src/test/resources/testDynPartnerRequest.soap b/_br-ode-1.X.svn/axis2-war/src/test/resources/testDynPartnerRequest.soap new file mode 100644 index 0000000..0bc19e9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2-war/src/test/resources/testDynPartnerRequest.soap
@@ -0,0 +1,25 @@ +<!-- + ~ Licensed to the Apache Software Foundation (ASF) under one + ~ or more contributor license agreements. See the NOTICE file + ~ distributed with this work for additional information + ~ regarding copyright ownership. The ASF licenses this file + ~ to you under the Apache License, Version 2.0 (the + ~ "License"); you may not use this file except in compliance + ~ with the License. You may obtain a copy of the License at + ~ + ~ http://www.apache.org/licenses/LICENSE-2.0 + ~ + ~ Unless required by applicable law or agreed to in writing, + ~ software distributed under the License is distributed on an + ~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~ KIND, either express or implied. See the License for the + ~ specific language governing permissions and limitations + ~ under the License. + --> + +<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"> + <!-- test soap message --> + <SOAP-ENV:Body> + <ns2:dummy xmlns:ns2="http://ode/bpel/responder.wsdl">fire!</ns2:dummy> + </SOAP-ENV:Body> +</SOAP-ENV:Envelope>
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/AuthenticationHelper.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/AuthenticationHelper.java new file mode 100644 index 0000000..b1bf1a7 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/AuthenticationHelper.java
@@ -0,0 +1,102 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.axis2.client.Options; +import org.apache.axis2.transport.http.HTTPConstants; +import org.apache.axis2.transport.http.HttpTransportProperties; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange; +import org.apache.ode.utils.DOMUtils; +import org.w3c.dom.Element; + +/** + * HTTP Authentication Helper + * + * @author Alex Boisvert <boisvert at apache dot org> + */ +public class AuthenticationHelper { + + private static final Log __log = LogFactory.getLog(AuthenticationHelper.class); + + private static final String AUTHENTICATE_ELEMENT = "authenticate"; + + private static final String AUTHENTICATION_NS = "urn:ode.apache.org/authentication"; + + private static final String USERNAME_ELEMENT = "username"; + + private static final String PASSWORD_ELEMENT = "password"; + + private static final String DOMAIN_ELEMENT = "domain"; + + private static final String REALM_ELEMENT = "realm"; + + private static final String TOKEN_ELEMENT = "token"; + + public static void setHttpAuthentication(PartnerRoleMessageExchange odeMex, Options options) { + Element msg = odeMex.getRequest().getMessage(); + if (msg != null) { + Element part = DOMUtils.getFirstChildElement(msg); + while (part != null) { + Element content = DOMUtils.getFirstChildElement(part); + if (content != null) { + if (AUTHENTICATION_NS.equals(content.getNamespaceURI()) && AUTHENTICATE_ELEMENT.equals(content.getLocalName())) { + setOptions(options, content); + msg.removeChild(part); + break; + } + } + part = DOMUtils.getNextSiblingElement(part); + } + } + } + + protected static void setOptions(Options options, Element auth) { + String username = null; + String password = null; + String domain = null; + String realm = null; + Element e = DOMUtils.getFirstChildElement(auth); + while (e != null) { + if (USERNAME_ELEMENT.equals(e.getLocalName())) { + username = DOMUtils.getTextContent(e); + } + if (PASSWORD_ELEMENT.equals(e.getLocalName())) { + password = DOMUtils.getTextContent(e); + } + if (DOMAIN_ELEMENT.equals(e.getLocalName())) { + domain = DOMUtils.getTextContent(e); + } + if (REALM_ELEMENT.equals(e.getLocalName())) { + realm = DOMUtils.getTextContent(e); + } + e = DOMUtils.getNextSiblingElement(e); + } + + HttpTransportProperties.Authenticator authenticator = new HttpTransportProperties.Authenticator(); + authenticator.setUsername(username); + authenticator.setPassword(password); + authenticator.setDomain(domain); + authenticator.setRealm(realm); + options.setProperty(HTTPConstants.AUTHENTICATE, authenticator); + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java new file mode 100644 index 0000000..c897323 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/BindingContextImpl.java
@@ -0,0 +1,84 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + + +package org.apache.ode.axis2; + +import org.apache.axis2.AxisFault; +import org.apache.ode.bpel.iapi.BindingContext; +import org.apache.ode.bpel.iapi.ContextException; +import org.apache.ode.bpel.iapi.Endpoint; +import org.apache.ode.bpel.iapi.EndpointReference; +import org.apache.ode.bpel.iapi.PartnerRoleChannel; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.bpel.iapi.ProcessStore; + +import javax.wsdl.Definition; +import javax.wsdl.PortType; +import javax.xml.namespace.QName; + +/** + * AXIS2 implementation of the {@link org.apache.ode.bpel.iapi.BindingContext} + * interface. Deals with the activation of endpoints. + * + * @author Maciej Szefler - m s z e f l e r @ g m a i l . c o m + * + */ +public class BindingContextImpl implements BindingContext { + private ODEServer _server; + private ProcessStore _store; + + public BindingContextImpl(ODEServer server, ProcessStore store) { + _server = server; + _store = store; + } + + public EndpointReference activateMyRoleEndpoint(QName processId, Endpoint myRoleEndpoint) { + try { + ProcessConf pconf = _store.getProcessConfiguration(processId); + Definition wsdl = pconf.getDefinitionForService(myRoleEndpoint.serviceName); + if (wsdl == null) + throw new ContextException("Unable to access WSDL definition to activate MyRole endpoint for service " + myRoleEndpoint.serviceName + + " and port " + myRoleEndpoint.portName); + ODEService svc = _server.createService(pconf, myRoleEndpoint.serviceName, myRoleEndpoint.portName); + return svc.getMyServiceRef(); + } catch (AxisFault axisFault) { + throw new ContextException("Could not activate endpoint for service " + myRoleEndpoint.serviceName + + " and port " + myRoleEndpoint.portName, axisFault); + } + } + + public void deactivateMyRoleEndpoint(Endpoint myRoleEndpoint) { + _server.destroyService(myRoleEndpoint.serviceName, myRoleEndpoint.portName); + } + + public PartnerRoleChannel createPartnerRoleChannel(QName processId, PortType portType, + Endpoint initialPartnerEndpoint) { + // NOTE: This implementation assumes that the initial value of the + // partner role determines the binding. + ProcessConf pconf = _store.getProcessConfiguration(processId); + Definition wsdl = pconf.getDefinitionForService(initialPartnerEndpoint.serviceName); + if (wsdl == null) { + throw new ContextException("Cannot find definition for service " + initialPartnerEndpoint.serviceName + + " in the context of process "+processId); + } + return _server.createExternalService(pconf, initialPartnerEndpoint.serviceName, initialPartnerEndpoint.portName); + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/EndpointReferenceContextImpl.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/EndpointReferenceContextImpl.java new file mode 100644 index 0000000..5eb3f04 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/EndpointReferenceContextImpl.java
@@ -0,0 +1,57 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import javax.xml.namespace.QName; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.epr.EndpointFactory; +import org.apache.ode.bpel.epr.MutableEndpoint; +import org.apache.ode.bpel.iapi.EndpointReference; +import org.apache.ode.bpel.iapi.EndpointReferenceContext; +import org.apache.ode.utils.DOMUtils; +import org.w3c.dom.Element; + +import java.util.Map; +import java.util.HashMap; + +public class EndpointReferenceContextImpl implements EndpointReferenceContext { + + private static final Log __log = LogFactory.getLog(EndpointReferenceContextImpl.class); + + public EndpointReferenceContextImpl(ODEServer server) { + } + + public EndpointReference resolveEndpointReference(Element element) { + if (__log.isDebugEnabled()) + __log.debug("Resolving endpoint reference " + DOMUtils.domToString(element)); + return EndpointFactory.createEndpoint(element); + } + + public EndpointReference convertEndpoint(QName qName, Element element) { + EndpointReference endpoint = EndpointFactory.convert(qName, element); + return endpoint; + } + + public Map getConfigLookup(EndpointReference epr) { + return ((MutableEndpoint)epr).toMap(); + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ExternalService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ExternalService.java new file mode 100644 index 0000000..b298195 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ExternalService.java
@@ -0,0 +1,36 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.ode.bpel.iapi.PartnerRoleChannel; +import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange; + +import javax.xml.namespace.QName; + +/** + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public interface ExternalService extends PartnerRoleChannel { + void invoke(PartnerRoleMessageExchange odeMex); + + String getPortName(); + + QName getServiceName(); +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/MessageExchangeContextImpl.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/MessageExchangeContextImpl.java new file mode 100644 index 0000000..b64faff --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/MessageExchangeContextImpl.java
@@ -0,0 +1,62 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.iapi.BpelEngineException; +import org.apache.ode.bpel.iapi.ContextException; +import org.apache.ode.bpel.iapi.MessageExchangeContext; +import org.apache.ode.bpel.iapi.MyRoleMessageExchange; +import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange; + +/** + * Implementation of the ODE {@link org.apache.ode.bpel.iapi.MessageExchangeContext} + * interface. This class is used by the ODE engine to make invocation of external + * services using Axis. + */ +public class MessageExchangeContextImpl implements MessageExchangeContext { + + private static final Log __log = LogFactory.getLog(MessageExchangeContextImpl.class); + + private ODEServer _server; + + public MessageExchangeContextImpl(ODEServer server) { + _server = server; + } + + public void invokePartner(PartnerRoleMessageExchange partnerRoleMessageExchange) throws ContextException { + if (__log.isDebugEnabled()) + __log.debug("Invoking a partner operation: " + partnerRoleMessageExchange.getOperationName()); + + ExternalService service = (ExternalService)partnerRoleMessageExchange.getChannel(); + if (__log.isDebugEnabled()) + __log.debug("The service to invoke is the external service " + service.getServiceName()+":"+service.getPortName()); + service.invoke(partnerRoleMessageExchange); + } + + public void onAsyncReply(MyRoleMessageExchange myRoleMessageExchange) throws BpelEngineException { + if (__log.isDebugEnabled()) + __log.debug("Processing an async reply from service " + myRoleMessageExchange.getServiceName()); + + // Nothing to do, no callback is necessary, the client just synchornizes itself with the + // mex reply when invoking the engine. + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/Messages.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/Messages.java new file mode 100644 index 0000000..a95c30d --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/Messages.java
@@ -0,0 +1,135 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.ode.utils.msg.MessageBundle; + +import javax.xml.namespace.QName; +import java.io.File; + +public class Messages extends MessageBundle { + + public String msgOdeInstallErrorCfgNotFound(File configFile) { + return format("Config file {0} not found, default values will be used.", configFile); + } + + public String msgOdeInstallErrorCfgReadError(File configFile) { + return format("Error installing ODE component: config file {0} could not be read.", configFile); + } + + public String msgOdeInstalled(String dir) { + return format("ODE Service Engine installed in {0}", dir); + } + + public String msgOdeInitHibernatePropertiesNotFound(File expected) { + return format("Hibernate configuration file \"{0}\" not found, defaults will be used.", expected); + } + + public String msgOdeUsingExternalDb(String dbDataSource) { + return format("ODE using external DataSource \"{0}\".", dbDataSource); + } + + public String msgOdeInitExternalDbFailed(String dbDataSource) { + return format("Failed to resolved external DataSource at \"{0}\".", dbDataSource); + } + + public String msgOdeInitDAOErrorReadingProperties(File propfile) { + return format("Error reading DAO properties file \"{0}\".", propfile); + } + + public String msgOdeStarting() { + return format("Starting ODE ServiceEngine."); + } + + public String msgOdeStarted() { + return format("ODE Service Engine has been started."); + } + + public String msgPollingStarted(String path) { + return format("Process deployment polling started on path {0}.", path); + } + + public String msgOdeInitialized() { + return "ODE BPEL Server Initialized."; + } + + public String msgOdeDbPoolStartupFailed(String url) { + return format("Error starting connection pool for \"{0}\".", url); + } + + public String msgOdeBpelServerStartFailure() { + return format("ODE BPEL Server failed to start."); + } + + public String msgOdeProcessDeploymentFailed(File dd, String suid) { + return format("Error deploying process described by deployment descriptor \"{0}\" for service unit \"{1}\".", + dd, suid); + } + + public String msgOdeProcessUndeploymentFailed(QName pid) { + return format("Error undeploying process \"{0}\".", pid); + } + + public String msgServiceUnitDeployFailed(String serviceUnitID) { + return format("Error deploying service unit \"{0}\".", serviceUnitID); + } + + public String msgServiceUnitInitFailed(String serviceUnitID) { + return format("Error initializing service unit \"{0}\".", serviceUnitID); + } + + public String msgServiceUnitStartFailed(String serviceUnitID) { + return format("Error starting service unit \"{0}\".", serviceUnitID); + } + + public String msgServiceUnitStopFailed(String serviceUnitID) { + return format("Error stopping service unit \"{0}\".", serviceUnitID); + } + + public String msgServiceUnitShutdownFailed(String serviceUnitID) { + return format("Error shutting down service unit \"{0}\".", serviceUnitID); + } + + public String msgBpelEventListenerRegistered(String listenerCN) { + return format("Registered custom BPEL event listener: {0}", listenerCN); + } + + public String msgMessageExchangeInterceptorRegistered(String interceptorCN) { + return format("Registered message exchange interceptor: {0}", interceptorCN); + } + + public String msgOdeShutdownCompleted() { + return "Shutdown completed. "; + } + + public String msgOdeUsingDAOImpl(String className) { + return format("Using DAO Connection Factory class {0}.", className); + } + + public String msgDAOInstantiationFailed(String className) { + return format("Error instantiating DAO Connection Factory class {0}.", className); + + } + + public String msgOdeDbConfigError() { + return format("Error starting database connections, check the database configuration!"); + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEConfigProperties.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEConfigProperties.java new file mode 100644 index 0000000..6e8ed59 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEConfigProperties.java
@@ -0,0 +1,38 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import java.io.File; + +import org.apache.ode.il.config.OdeConfigProperties; + +public class ODEConfigProperties extends OdeConfigProperties { + + private static final long serialVersionUID = 1L; + private static final String CONFIG_FILE_NAME = "ode-axis2.properties"; + + + public ODEConfigProperties(File installRoot) { + super(new File(installRoot, ODEConfigProperties.CONFIG_FILE_NAME),"ode-axis2."); + } + + + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java new file mode 100644 index 0000000..47d05b3 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
@@ -0,0 +1,721 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.axis2.AxisFault; +import org.apache.axis2.description.AxisOperation; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.commons.collections.map.MultiKeyMap; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.deploy.DeploymentPoller; +import org.apache.ode.axis2.hooks.ODEAxisService; +import org.apache.ode.axis2.hooks.ODEMessageReceiver; +import org.apache.ode.axis2.service.DeploymentWebService; +import org.apache.ode.axis2.service.ManagementService; +import org.apache.ode.axis2.httpbinding.HttpExternalService; +import org.apache.ode.bpel.connector.BpelServerConnector; +import org.apache.ode.bpel.dao.BpelDAOConnectionFactory; +import org.apache.ode.bpel.engine.BpelServerImpl; +import org.apache.ode.bpel.engine.CountLRUDehydrationPolicy; +import org.apache.ode.bpel.extvar.jdbc.JdbcExternalVariableModule; +import org.apache.ode.bpel.iapi.BpelEventListener; +import org.apache.ode.bpel.iapi.ContextException; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.bpel.iapi.ProcessStoreEvent; +import org.apache.ode.bpel.iapi.ProcessStoreListener; +import org.apache.ode.bpel.iapi.Scheduler; +import org.apache.ode.bpel.iapi.EndpointReferenceContext; +import org.apache.ode.bpel.intercept.MessageExchangeInterceptor; +import org.apache.ode.bpel.memdao.BpelDAOConnectionFactoryImpl; +import org.apache.ode.bpel.pmapi.InstanceManagement; +import org.apache.ode.bpel.pmapi.ProcessManagement; +import org.apache.ode.il.dbutil.Database; +import org.apache.ode.scheduler.simple.JdbcDelegate; +import org.apache.ode.scheduler.simple.SimpleScheduler; +import org.apache.ode.store.ProcessStoreImpl; +import org.apache.ode.utils.GUID; +import org.apache.ode.utils.wsdl.WsdlUtils; +import org.apache.ode.utils.fs.TempFileManager; + +import javax.servlet.ServletConfig; +import javax.servlet.ServletException; +import javax.sql.DataSource; +import javax.transaction.HeuristicMixedException; +import javax.transaction.HeuristicRollbackException; +import javax.transaction.InvalidTransactionException; +import javax.transaction.NotSupportedException; +import javax.transaction.RollbackException; +import javax.transaction.Synchronization; +import javax.transaction.SystemException; +import javax.transaction.Transaction; +import javax.transaction.TransactionManager; +import javax.transaction.xa.XAResource; +import javax.wsdl.Definition; +import javax.xml.namespace.QName; +import java.io.File; +import java.io.FileNotFoundException; +import java.util.StringTokenizer; +import java.util.Iterator; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; +import java.util.concurrent.ThreadFactory; + +/** + * Server class called by our Axis hooks to handle all ODE lifecycle management. + * + * @author Matthieu Riou <mriou at apache dot org> + */ +public class ODEServer { + + protected final Log __log = LogFactory.getLog(getClass()); + protected final Log __logTx = LogFactory.getLog("org.apache.ode.tx"); + + private static final Messages __msgs = Messages.getMessages(Messages.class); + + protected File _appRoot; + + protected File _workRoot; + + protected File _configRoot; + + protected BpelServerImpl _server; + + protected ProcessStoreImpl _store; + + protected ODEConfigProperties _odeConfig; + + protected AxisConfiguration _axisConfig; + + protected TransactionManager _txMgr; + + protected BpelDAOConnectionFactory _daoCF; + + protected ExecutorService _executorService; + + protected Scheduler _scheduler; + + protected Database _db; + + private DeploymentPoller _poller; + + private MultiKeyMap _services = new MultiKeyMap(); + + private MultiKeyMap _externalServices = new MultiKeyMap(); + + private BpelServerConnector _connector; + + private ManagementService _mgtService; + + + public void init(ServletConfig config, AxisConfiguration axisConf) throws ServletException { + init(config.getServletContext().getRealPath("/WEB-INF"), axisConf); + } + + public void init(String contextPath, AxisConfiguration axisConf) throws ServletException { + boolean success = false; + try { + _axisConfig = axisConf; + String rootDir = System.getProperty("org.apache.ode.rootDir"); + if (rootDir != null) _appRoot = new File(rootDir); + else _appRoot = new File(contextPath); + + if(!_appRoot.isDirectory()) throw new IllegalArgumentException(_appRoot+" does not exist or is not a directory"); + TempFileManager.setWorkingDirectory(_appRoot); + + __log.debug("Loading properties"); + String confDir = System.getProperty("org.apache.ode.configDir"); + _configRoot = confDir == null ? new File(_appRoot, "conf") : new File(confDir); + if(!_configRoot.isDirectory()) throw new IllegalArgumentException(_configRoot+" does not exist or is not a directory"); + + _odeConfig = new ODEConfigProperties(_configRoot); + + try { + _odeConfig.load(); + } catch (FileNotFoundException fnf) { + String errmsg = __msgs.msgOdeInstallErrorCfgNotFound(_odeConfig.getFile()); + __log.warn(errmsg); + } catch (Exception ex) { + String errmsg = __msgs.msgOdeInstallErrorCfgReadError(_odeConfig.getFile()); + __log.error(errmsg, ex); + throw new ServletException(errmsg, ex); + } + + String wdir = _odeConfig.getWorkingDir(); + if (wdir == null) _workRoot = _appRoot; + else _workRoot = new File(wdir.trim()); + if(!_workRoot.isDirectory()) throw new IllegalArgumentException(_workRoot+" does not exist or is not a directory"); + + __log.debug("Initializing transaction manager"); + initTxMgr(); + __log.debug("Creating data source."); + initDataSource(); + __log.debug("Starting DAO."); + initDAO(); + EndpointReferenceContextImpl eprContext = new EndpointReferenceContextImpl(this); + __log.debug("Initializing BPEL process store."); + initProcessStore(eprContext); + __log.debug("Initializing BPEL server."); + initBpelServer(eprContext); + + // Register BPEL event listeners configured in axis2.properties file. + registerEventListeners(); + registerMexInterceptors(); + + registerExternalVariableModules(); + + _store.loadAll(); + + try { + _server.start(); + } catch (Exception ex) { + String errmsg = __msgs.msgOdeBpelServerStartFailure(); + __log.error(errmsg, ex); + throw new ServletException(errmsg, ex); + } + + _poller = new DeploymentPoller(_store.getDeployDir(), this); + + _mgtService = new ManagementService(); + _mgtService.enableService(_axisConfig, _server, _store, _appRoot.getAbsolutePath()); + + new DeploymentWebService().enableService(_axisConfig, _server, _store, _poller, _appRoot.getAbsolutePath(), _workRoot + .getAbsolutePath()); + + __log.debug("Starting scheduler"); + _scheduler.start(); + + __log.debug("Initializing JCA adapter."); + initConnector(); + + _poller.start(); + __log.info(__msgs.msgPollingStarted(_store.getDeployDir().getAbsolutePath())); + __log.info(__msgs.msgOdeStarted()); + success = true; + } finally { + if (!success) + try { + // shutDown(); + } catch (Exception ex) { + // Problem rolling back start(). Not so important + __log.debug("Error rolling back incomplete shutdown.", ex); + } + } + + } + + private void initDataSource() throws ServletException { + _db = new Database(_odeConfig); + _db.setTransactionManager(_txMgr); + _db.setWorkRoot(_workRoot); + + try { + _db.start(); + } catch (Exception ex) { + String errmsg = __msgs.msgOdeDbConfigError(); + __log.error(errmsg, ex); + throw new ServletException(errmsg, ex); + } + + } + + /** + * Shutdown the service engine. This performs cleanup before the BPE is terminated. Once this method has been called, init() + * must be called before the transformation engine can be started again with a call to start(). + * + * @throws AxisFault if the engine is unable to shut down. + */ + public void shutDown() throws AxisFault { + + ClassLoader old = Thread.currentThread().getContextClassLoader(); + Thread.currentThread().setContextClassLoader(getClass().getClassLoader()); + try { + if (_poller != null) + try { + __log.debug("shutting down poller"); + _poller.stop(); + _poller = null; + } catch (Throwable t) { + __log.debug("Error stopping poller.", t); + } + + if (_server != null) + try { + __log.debug("shutting down ODE server."); + _server.shutdown(); + _server = null; + } catch (Throwable ex) { + __log.debug("Error stopping services.", ex); + } + + if (_scheduler != null) + try { + __log.debug("shutting down quartz scheduler."); + _scheduler.shutdown(); + _scheduler = null; + } catch (Exception ex) { + __log.debug("Scheduler couldn't be shutdown.", ex); + } + + if (_store != null) + try { + _store.shutdown(); + _store = null; + } catch (Throwable t) { + __log.debug("Store could not be shutdown.", t); + } + + if (_daoCF != null) + try { + _daoCF.shutdown(); + } catch (Throwable ex) { + __log.debug("DOA shutdown failed.", ex); + } finally { + _daoCF = null; + } + + if (_db != null) + try { + _db.shutdown(); + + } catch (Throwable ex) { + __log.debug("DB shutdown failed.", ex); + } finally { + _db = null; + } + + if (_txMgr != null) { + __log.debug("shutting down transaction manager."); + _txMgr = null; + } + + if (_connector != null) { + try { + __log.debug("shutdown BpelConnector"); + _connector.shutdown(); + } catch (Throwable t) { + __log.error("Unable to cleanup temp files.", t); + } + } + + try { + __log.debug("cleaning up temporary files."); + TempFileManager.cleanup(); + } catch (Throwable t) { + __log.error("Unable to cleanup temp files.", t); + } + + + __log.info(__msgs.msgOdeShutdownCompleted()); + } finally { + Thread.currentThread().setContextClassLoader(old); + } + } + + public ODEService createService(ProcessConf pconf, QName serviceName, String portName) throws AxisFault { + // Since multiple processes may provide services at the same (JMS) endpoint, qualify + // the (JMS) endpoint-specific NCName with a process-relative URI, if necessary. + QName uniqueServiceName = new QName( + ODEAxisService.extractServiceName(pconf, serviceName, portName)); + + destroyService(uniqueServiceName, portName); + + AxisService axisService = ODEAxisService.createService( + _axisConfig, pconf, serviceName, portName, uniqueServiceName.getLocalPart()); + ODEService odeService = new ODEService(axisService, pconf, serviceName, portName, _server, _txMgr); + + _services.put(uniqueServiceName, portName, odeService); + + // Setting our new service on the ODE receiver + Iterator operationIterator = axisService.getOperations(); + while(operationIterator.hasNext()){ + AxisOperation op = (AxisOperation) operationIterator.next(); + if(op.getMessageReceiver() instanceof ODEMessageReceiver){ + ((ODEMessageReceiver) op.getMessageReceiver()).setService(odeService); + break; + } + } + + // We're public! + _axisConfig.addService(axisService); + __log.debug("Created Axis2 service " + serviceName); + return odeService; + } + + public ExternalService createExternalService(ProcessConf pconf, QName serviceName, String portName) throws ContextException { + ExternalService extService = (ExternalService) _externalServices.get(serviceName); + if (extService != null) + return extService; + + Definition def = pconf.getDefinitionForService(serviceName); + try { + if (WsdlUtils.useHTTPBinding(def, serviceName, portName)) { + if(__log.isDebugEnabled())__log.debug("Creating HTTP-bound external service " + serviceName); + extService = new HttpExternalService(pconf, serviceName, portName, _executorService, _scheduler, _server); + } else if (WsdlUtils.useSOAPBinding(def, serviceName, portName)) { + if(__log.isDebugEnabled())__log.debug("Creating SOAP-bound external service " + serviceName); + extService = new SoapExternalService(pconf, serviceName, portName, _executorService, _axisConfig, _scheduler, _server); + } + } catch (Exception ex) { + __log.error("Could not create external service.", ex); + throw new ContextException("Error creating external service! name:"+serviceName+", port:"+portName, ex); + } + + // if not SOAP nor HTTP binding + if(extService==null){ + throw new ContextException("Only SOAP and HTTP binding supported!"); + } + + _externalServices.put(serviceName, portName, extService); + __log.debug("Created external service " + serviceName); + return extService; + } + + public void destroyService(QName serviceName, String portName) { + __log.debug("Destroying service " + serviceName + " port " + portName); + ODEService service = (ODEService) _services.remove(serviceName, portName); + if (service != null) { + try { + _axisConfig.removeService(service.getAxisService().getName()); + } catch (AxisFault axisFault) { + __log.error("Couldn't destroy service " + serviceName); + } + } else { + __log.debug("Couldn't find service " + serviceName + " port " + portName + " to destroy."); + } + } + + public ODEService getService(QName serviceName, String portName) { + return (ODEService) _services.get(serviceName, portName); + } + + public ODEService getService(QName serviceName, QName portTypeName) { + // TODO Normally this lookup should't exist as there could be more one + // than port + // TODO for a portType. See MessageExchangeContextImpl. + for (Object o : _services.values()) { + ODEService service = (ODEService) o; + if (service.respondsTo(serviceName, portTypeName)) + return service; + } + return null; + } + + public ExternalService getExternalService(QName serviceName, String portName) { + return (ExternalService) _externalServices.get(serviceName, portName); + } + + private void initTxMgr() throws ServletException { + String txFactoryName = _odeConfig.getTxFactoryClass(); + __log.debug("Initializing transaction manager using " + txFactoryName); + try { + Class txFactClass = this.getClass().getClassLoader().loadClass(txFactoryName); + Object txFact = txFactClass.newInstance(); + _txMgr = (TransactionManager) txFactClass.getMethod("getTransactionManager", (Class[]) null).invoke(txFact); + if (__logTx.isDebugEnabled() && System.getProperty("ode.debug.tx") != null) + _txMgr = new DebugTxMgr(_txMgr); + } catch (Exception e) { + __log.fatal("Couldn't initialize a transaction manager with factory: " + txFactoryName, e); + throw new ServletException("Couldn't initialize a transaction manager with factory: " + txFactoryName, e); + } + } + + private void initConnector() throws ServletException { + int port = _odeConfig.getConnectorPort(); + if (port == 0) { + __log.info("Skipping connector initialization."); + } else { + _connector = new BpelServerConnector(); + _connector.setBpelServer(_server); + _connector.setProcessStore(_store); + _connector.setPort(_odeConfig.getConnectorPort()); + _connector.setId("jcaServer"); + try { + _connector.start(); + } catch (Exception e) { + __log.error("Failed to initialize JCA connector.", e); + } + } + } + + /** + * Initialize the DAO. + * + * @throws ServletException + */ + protected void initDAO() throws ServletException { + __log.info(__msgs.msgOdeUsingDAOImpl(_odeConfig.getDAOConnectionFactory())); + try { + _daoCF = _db.createDaoCF(); + } catch (Exception ex) { + String errmsg = __msgs.msgDAOInstantiationFailed(_odeConfig.getDAOConnectionFactory()); + __log.error(errmsg, ex); + throw new ServletException(errmsg, ex); + + } + } + + protected void initProcessStore(EndpointReferenceContext eprContext) { + _store = createProcessStore(eprContext, _db.getDataSource()); + _store.registerListener(new ProcessStoreListenerImpl()); + _store.setDeployDir(new File(_workRoot, "processes")); + _store.setConfigDir(_configRoot); + } + + protected ProcessStoreImpl createProcessStore(EndpointReferenceContext eprContext, DataSource ds) { + return new ProcessStoreImpl(eprContext, ds, _odeConfig.getDAOConnectionFactory(), _odeConfig, false); + } + + protected Scheduler createScheduler() { + SimpleScheduler scheduler = new SimpleScheduler(new GUID().toString(), + new JdbcDelegate(_db.getDataSource()), _odeConfig.getProperties()); + scheduler.setExecutorService(_executorService); + scheduler.setTransactionManager(_txMgr); + return scheduler; + } + + private void initBpelServer(EndpointReferenceContextImpl eprContext) { + if (__log.isDebugEnabled()) { + __log.debug("ODE initializing"); + } + ThreadFactory threadFactory = new ThreadFactory() { + int threadNumber = 0; + public Thread newThread(Runnable r) { + threadNumber += 1; + Thread t = new Thread(r, "ODEServer-"+threadNumber); + t.setDaemon(true); + return t; + } + }; + + if (_odeConfig.getThreadPoolMaxSize() == 0) + _executorService = Executors.newCachedThreadPool(threadFactory); + else + _executorService = Executors.newFixedThreadPool(_odeConfig.getThreadPoolMaxSize(), threadFactory); + + _server = new BpelServerImpl(); + _scheduler = createScheduler(); + _scheduler.setJobProcessor(_server); + + _server.setDaoConnectionFactory(_daoCF); + _server.setInMemDaoConnectionFactory(new BpelDAOConnectionFactoryImpl(_scheduler, _odeConfig.getInMemMexTtl())); + _server.setEndpointReferenceContext(eprContext); + _server.setMessageExchangeContext(new MessageExchangeContextImpl(this)); + _server.setBindingContext(new BindingContextImpl(this, _store)); + _server.setScheduler(_scheduler); + if (_odeConfig.isDehydrationEnabled()) { + CountLRUDehydrationPolicy dehy = new CountLRUDehydrationPolicy(); + // dehy.setProcessMaxAge(10000); + _server.setDehydrationPolicy(dehy); + } + _server.setConfigProperties(_odeConfig.getProperties()); + _server.init(); + } + + public ProcessStoreImpl getProcessStore() { + return _store; + } + + public BpelServerImpl getBpelServer() { + return _server; + } + + public InstanceManagement getInstanceManagement() { + return _mgtService.getInstanceMgmt(); + } + + public ProcessManagement getProcessManagement() { + return _mgtService.getProcessMgmt(); + } + + public File getAppRoot() { + return _appRoot; + } + + private void registerEventListeners() { + String listenersStr = _odeConfig.getEventListeners(); + if (listenersStr != null) { + for (StringTokenizer tokenizer = new StringTokenizer(listenersStr, ",;"); tokenizer.hasMoreTokens();) { + String listenerCN = tokenizer.nextToken(); + try { + _server.registerBpelEventListener((BpelEventListener) Class.forName(listenerCN).newInstance()); + __log.info(__msgs.msgBpelEventListenerRegistered(listenerCN)); + } catch (Exception e) { + __log.warn("Couldn't register the event listener " + listenerCN + ", the class couldn't be " + + "loaded properly: " + e); + } + } + + } + } + + private void registerMexInterceptors() { + String listenersStr = _odeConfig.getMessageExchangeInterceptors(); + if (listenersStr != null) { + for (StringTokenizer tokenizer = new StringTokenizer(listenersStr, ",;"); tokenizer.hasMoreTokens();) { + String interceptorCN = tokenizer.nextToken(); + try { + _server.registerMessageExchangeInterceptor((MessageExchangeInterceptor) Class.forName(interceptorCN).newInstance()); + __log.info(__msgs.msgMessageExchangeInterceptorRegistered(interceptorCN)); + } catch (Exception e) { + __log.warn("Couldn't register the event listener " + interceptorCN + ", the class couldn't be " + + "loaded properly: " + e); + } + } + } + } + + private void registerExternalVariableModules() { + JdbcExternalVariableModule jdbcext; + jdbcext = new JdbcExternalVariableModule(); + jdbcext.registerDataSource("ode", _db.getDataSource()); + _server.registerExternalVariableEngine(jdbcext); + + } + + private class ProcessStoreListenerImpl implements ProcessStoreListener { + + public void onProcessStoreEvent(ProcessStoreEvent event) { + handleEvent(event); + } + + } + + private void handleEvent(ProcessStoreEvent pse) { + __log.debug("Process store event: " + pse); + switch (pse.type) { + case ACTVIATED: + case RETIRED: + // bounce the process + _server.unregister(pse.pid); + ProcessConf pconf = _store.getProcessConfiguration(pse.pid); + if (pconf != null) _server.register(pconf); + else __log.debug("slighly odd: recevied event " + pse + " for process not in store!"); + break; + case DISABLED: + case UNDEPLOYED: + _server.unregister(pse.pid); + _server.cleanupProcess(pse.pid); + break; + default: + __log.debug("Ignoring store event: " + pse); + } + } + + // Transactional debugging stuff, to track down all these little annoying bugs. + private class DebugTxMgr implements TransactionManager { + private TransactionManager _tm; + + public DebugTxMgr(TransactionManager tm) { + _tm = tm; + } + + public void begin() throws NotSupportedException, SystemException { + __logTx.debug("Txm begin"); + _tm.begin(); + } + + public void commit() throws HeuristicMixedException, HeuristicRollbackException, IllegalStateException, RollbackException, SecurityException, SystemException { + __logTx.debug("Txm commit"); + for (StackTraceElement traceElement : Thread.currentThread().getStackTrace()) { + __logTx.debug(traceElement.toString()); + } + _tm.commit(); + } + + public int getStatus() throws SystemException { + __logTx.debug("Txm status"); + return _tm.getStatus(); + } + + public Transaction getTransaction() throws SystemException { + Transaction tx = _tm.getTransaction(); + __logTx.debug("Txm get tx " + tx); + return tx == null ? null : new DebugTx(tx); + } + + public void resume(Transaction transaction) throws IllegalStateException, InvalidTransactionException, SystemException { + __logTx.debug("Txm resume"); + _tm.resume(transaction); + } + + public void rollback() throws IllegalStateException, SecurityException, SystemException { + __logTx.debug("Txm rollback"); + _tm.rollback(); + } + + public void setRollbackOnly() throws IllegalStateException, SystemException { + __logTx.debug("Txm set rollback"); + _tm.setRollbackOnly(); + } + + public void setTransactionTimeout(int i) throws SystemException { + __logTx.debug("Txm set tiemout " + i); + _tm.setTransactionTimeout(i); + } + + public Transaction suspend() throws SystemException { + __logTx.debug("Txm suspend"); + return _tm.suspend(); + } + } + + private class DebugTx implements Transaction { + private Transaction _tx; + + public DebugTx(Transaction tx) { + _tx = tx; + } + + public void commit() throws HeuristicMixedException, HeuristicRollbackException, RollbackException, SecurityException, SystemException { + __logTx.debug("Tx commit"); + _tx.commit(); + } + + public boolean delistResource(XAResource xaResource, int i) throws IllegalStateException, SystemException { + return _tx.delistResource(xaResource, i); + } + + public boolean enlistResource(XAResource xaResource) throws IllegalStateException, RollbackException, SystemException { + return _tx.enlistResource(xaResource); + } + + public int getStatus() throws SystemException { + return _tx.getStatus(); + } + + public void registerSynchronization(Synchronization synchronization) throws IllegalStateException, RollbackException, SystemException { + __logTx.debug("Synchronization registration on " + synchronization.getClass().getName()); + _tx.registerSynchronization(synchronization); + } + + public void rollback() throws IllegalStateException, SystemException { + __logTx.debug("Tx rollback"); + _tx.rollback(); + } + + public void setRollbackOnly() throws IllegalStateException, SystemException { + __logTx.debug("Tx set rollback"); + _tx.setRollbackOnly(); + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEService.java new file mode 100644 index 0000000..410efd5 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/ODEService.java
@@ -0,0 +1,391 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.axiom.soap.SOAPEnvelope; +import org.apache.axiom.soap.SOAPFactory; +import org.apache.axiom.soap.SOAPFault; +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.transport.jms.JMSConstants; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.util.SoapMessageConverter; +import org.apache.ode.bpel.epr.EndpointFactory; +import org.apache.ode.bpel.epr.MutableEndpoint; +import org.apache.ode.bpel.epr.WSAEndpoint; +import org.apache.ode.bpel.iapi.BpelServer; +import org.apache.ode.bpel.iapi.EndpointReference; +import org.apache.ode.bpel.iapi.Message; +import org.apache.ode.bpel.iapi.MessageExchange; +import org.apache.ode.bpel.iapi.MyRoleMessageExchange; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.utils.GUID; +import org.apache.ode.utils.Namespaces; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.xml.sax.SAXException; + +import javax.transaction.TransactionManager; +import javax.wsdl.Definition; +import javax.wsdl.Port; +import javax.wsdl.Service; +import javax.wsdl.extensions.UnknownExtensibilityElement; +import javax.wsdl.extensions.http.HTTPAddress; +import javax.wsdl.extensions.soap.SOAPAddress; +import javax.xml.namespace.QName; + +import java.io.IOException; +import java.io.StringBufferInputStream; +import java.util.concurrent.Future; +import java.util.concurrent.TimeUnit; + +/** + * A running service, encapsulates the Axis service, its receivers and our + * receivers as well. + */ +public class ODEService { + + private static final Log __log = LogFactory.getLog(ODEService.class); + + private AxisService _axisService; + private BpelServer _server; + private TransactionManager _txManager; + private ProcessConf _pconf; + private Definition _wsdlDef; + private QName _serviceName; + private String _portName; + private WSAEndpoint _serviceRef; + private SoapMessageConverter _converter; + + public ODEService(AxisService axisService, ProcessConf pconf, QName serviceName, String portName, BpelServer server, + TransactionManager txManager) throws AxisFault { + _axisService = axisService; + _server = server; + _txManager = txManager; + _pconf = pconf; + _wsdlDef = pconf.getDefinitionForService(serviceName); + _serviceName = serviceName; + _portName = portName; + _serviceRef = EndpointFactory.convertToWSA(createServiceRef(genEPRfromWSDL(_wsdlDef, serviceName, portName))); + _converter = new SoapMessageConverter(_wsdlDef, serviceName, portName); + + } + + public void onAxisMessageExchange(MessageContext msgContext, MessageContext outMsgContext, SOAPFactory soapFactory) + throws AxisFault { + boolean success = true; + MyRoleMessageExchange odeMex = null; + Future responseFuture = null; + try { + _txManager.begin(); + if (__log.isDebugEnabled()) __log.debug("Starting transaction."); + + // Creating message exchange + String messageId = new GUID().toString(); + odeMex = _server.getEngine().createMessageExchange("" + messageId, _serviceName, + msgContext.getAxisOperation().getName().getLocalPart()); + __log.debug("ODE routed to operation " + odeMex.getOperation() + " from service " + _serviceName); + + if (odeMex.getOperation() != null) { + // Preparing message to send to ODE + Message odeRequest = odeMex.createMessage(odeMex.getOperation().getInput().getMessage().getQName()); + _converter.parseSoapRequest(odeRequest, msgContext.getEnvelope(), odeMex.getOperation()); + readHeader(msgContext, odeMex); + + if (__log.isDebugEnabled()) { + __log.debug("Invoking ODE using MEX " + odeMex); + __log.debug("Message content: " + DOMUtils.domToString(odeRequest.getMessage())); + } + + // Invoke ODE + responseFuture = odeMex.invoke(odeRequest); + + __log.debug("Commiting ODE MEX " + odeMex); + try { + if (__log.isDebugEnabled()) __log.debug("Commiting transaction."); + _txManager.commit(); + } catch (Exception e) { + __log.error("Commit failed", e); + success = false; + } + } else { + success = false; + } + } catch (Exception e) { + __log.error("Exception occured while invoking ODE", e); + success = false; + throw new OdeFault("An exception occured while invoking ODE.", e); + } finally { + if (!success) { + if (odeMex != null) odeMex.release(success); + try { + _txManager.rollback(); + } catch (Exception e) { + throw new OdeFault("Rollback failed", e); + } + } + } + + if (odeMex.getOperation().getOutput() != null) { + // Waits for the response to arrive + try { + responseFuture.get(getTimeout(), TimeUnit.MILLISECONDS); + } catch (Exception e) { + String errorMsg = "Timeout or execution error when waiting for response to MEX " + + odeMex + " " + e.toString(); + __log.error(errorMsg, e); + throw new OdeFault(errorMsg); + } + + if (outMsgContext != null) { + SOAPEnvelope envelope = soapFactory.getDefaultEnvelope(); + outMsgContext.setEnvelope(envelope); + + // Hopefully we have a response + __log.debug("Handling response for MEX " + odeMex); + boolean commit = false; + try { + if (__log.isDebugEnabled()) __log.debug("Starting transaction."); + _txManager.begin(); + } catch (Exception ex) { + throw new OdeFault("Error starting transaction!", ex); + } + try { + // Refreshing the message exchange + odeMex = (MyRoleMessageExchange) _server.getEngine().getMessageExchange(odeMex.getMessageExchangeId()); + onResponse(odeMex, outMsgContext); + commit = true; + } catch (AxisFault af) { + __log.warn("MEX produced a fault " + odeMex, af); + commit = true; + throw af; + } catch (Exception e) { + __log.error("Error processing response for MEX " + odeMex, e); + throw new OdeFault("An exception occured when invoking ODE.", e); + } finally { + odeMex.release(commit); + if (commit) { + try { + if (__log.isDebugEnabled()) __log.debug("Comitting transaction."); + _txManager.commit(); + } catch (Exception e) { + throw new OdeFault("Commit failed!", e); + } + } else { + try { + _txManager.rollback(); + } catch (Exception ex) { + throw new OdeFault("Rollback failed!", ex); + } + } + } + } + if (!success) { + throw new OdeFault("Message was either unroutable or timed out!"); + } + } else { + // One ways cleanup + odeMex.release(true); + } + } + + public boolean respondsTo(QName serviceName, QName portTypeName) { + boolean result = _serviceName.equals(serviceName); + result = result + && _wsdlDef.getService(_serviceName).getPort(_portName).getBinding().getPortType().getQName().equals( + portTypeName); + return result; + } + + /** + * do not store the value so it can be dynamically updated + */ + private long getTimeout() { + String timeout = _pconf.getEndpointProperties(_serviceRef).get(Properties.PROP_MEX_TIMEOUT); + if (timeout != null) { + try { + return Long.parseLong(timeout); + } catch (NumberFormatException e) { + if(__log.isWarnEnabled()) __log.warn("Mal-formatted Property: ["+ Properties.PROP_MEX_TIMEOUT+"="+timeout+"] Default value ("+Properties.DEFAULT_MEX_TIMEOUT+") will be used"); + } + } + return Properties.DEFAULT_MEX_TIMEOUT; + } + + private void onResponse(MyRoleMessageExchange mex, MessageContext msgContext) throws AxisFault { + switch (mex.getStatus()) { + case FAULT: + if (__log.isDebugEnabled()) + __log.debug("Fault response message: " + mex.getFault()); + SOAPFault fault = _converter.createSoapFault(mex.getFaultResponse().getMessage(), mex.getFault(), mex.getOperation()); + msgContext.getEnvelope().getBody().addFault(fault); + + if (__log.isDebugEnabled()) + __log.debug("Returning fault: " + msgContext.getEnvelope().toString()); + break; + case ASYNC: + case RESPONSE: + _converter.createSoapResponse(msgContext, mex.getResponse(), mex.getOperation()); + if (__log.isDebugEnabled()) + __log.debug("Response message " + msgContext.getEnvelope()); + writeHeader(msgContext, mex); + break; + case FAILURE: + throw new OdeFault("Message exchange failure"); + default: + throw new OdeFault("Received ODE message exchange in unexpected state: " + mex.getStatus()); + } + } + + /** + * Extracts endpoint information from Axis MessageContext (taken from WSA + * headers) to stuff them into ODE mesage exchange. + */ + private void readHeader(MessageContext msgContext, MyRoleMessageExchange odeMex) { + String correlationId = (String) msgContext.getProperty(JMSConstants.JMS_COORELATION_ID); + if (correlationId != null) { + odeMex.setProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID, correlationId); + } else { + Object otse = msgContext.getProperty("targetSessionEndpoint"); + if (otse != null) { + Element serviceEpr = (Element) otse; + WSAEndpoint endpoint = new WSAEndpoint(); + endpoint.set(serviceEpr); + // Extract the session ID for the local process. + odeMex.setProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID, endpoint.getSessionId()); + } + } + + Object ocse = msgContext.getProperty("callbackSessionEndpoint"); + if (ocse != null) { + Element serviceEpr = (Element) ocse; + WSAEndpoint endpoint = new WSAEndpoint(); + endpoint.set(serviceEpr); + + // Save the session id of the remote process. Also, magically + // initialize the EPR + // of the partner to the EPR provided. + odeMex.setProperty(MessageExchange.PROPERTY_SEP_PARTNERROLE_SESSIONID, endpoint.getSessionId()); + odeMex.setProperty(MessageExchange.PROPERTY_SEP_PARTNERROLE_EPR, DOMUtils.domToString(serviceEpr)); + } + } + + /** + * Handle callback endpoints for the case where partner contact process + * my-role which results in an "updated" my-role EPR due to session id + * injection. + */ + private void writeHeader(MessageContext msgContext, MyRoleMessageExchange odeMex) { + EndpointReference targetEPR = odeMex.getEndpointReference(); + if (targetEPR == null) + return; + + // The callback endpoint is going to be the same as the target + // endpoint in this case, except that it is updated with session + // information (if available). + if (odeMex.getProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID) != null) { + WSAEndpoint sessionAwareEndPoint = new WSAEndpoint(_serviceRef); + sessionAwareEndPoint.setSessionId(odeMex.getProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID)); + msgContext.setProperty("callbackSessionEndpoint", sessionAwareEndPoint); + } + + } + + public AxisService getAxisService() { + return _axisService; + } + + /** + * Return the service-ref element that will be used to represent this + * endpoint. + * + * @return my service endpoint + */ + public EndpointReference getMyServiceRef() { + return _serviceRef; + } + + /** + * Get the EPR of this service from the WSDL. + * + * @param name service name + * @param portName port name + * @return XML representation of the EPR + */ + public static Element genEPRfromWSDL(Definition wsdlDef, QName name, String portName) { + Service serviceDef = wsdlDef.getService(name); + if (serviceDef != null) { + Port portDef = serviceDef.getPort(portName); + if (portDef != null) { + Document doc = DOMUtils.newDocument(); + Element service = doc.createElementNS(Namespaces.WSDL_11, "service"); + service.setAttribute("name", serviceDef.getQName().getLocalPart()); + service.setAttribute("targetNamespace", serviceDef.getQName().getNamespaceURI()); + Element port = doc.createElementNS(Namespaces.WSDL_11, "port"); + service.appendChild(port); + port.setAttribute("name", portDef.getName()); + port.setAttributeNS("http://www.w3.org/2000/xmlns/", "xmlns:bindns", portDef.getBinding().getQName() + .getNamespaceURI()); + port.setAttribute("bindns:binding", portDef.getName()); + for (Object extElmt : portDef.getExtensibilityElements()) { + if (extElmt instanceof SOAPAddress) { + Element soapAddr = doc.createElementNS(Namespaces.SOAP_NS, "address"); + port.appendChild(soapAddr); + soapAddr.setAttribute("location", ((SOAPAddress) extElmt).getLocationURI()); + } else if (extElmt instanceof HTTPAddress) { + Element httpAddr = doc.createElementNS(Namespaces.HTTP_NS, "address"); + port.appendChild(httpAddr); + httpAddr.setAttribute("location", ((HTTPAddress) extElmt).getLocationURI()); + } else { + port.appendChild(doc.importNode(((UnknownExtensibilityElement) extElmt).getElement(), true)); + } + } + return service; + } + } + return null; + } + + /** + * Create-and-copy a service-ref element. + * + * @param elmt + * @return wrapped element + */ + public static MutableEndpoint createServiceRef(Element elmt) { + Document doc = DOMUtils.newDocument(); + QName elQName = new QName(elmt.getNamespaceURI(), elmt.getLocalName()); + // If we get a service-ref, just copy it, otherwise make a service-ref + // wrapper + if (!EndpointReference.SERVICE_REF_QNAME.equals(elQName)) { + Element serviceref = doc.createElementNS(EndpointReference.SERVICE_REF_QNAME.getNamespaceURI(), + EndpointReference.SERVICE_REF_QNAME.getLocalPart()); + serviceref.appendChild(doc.importNode(elmt, true)); + doc.appendChild(serviceref); + } else { + doc.appendChild(doc.importNode(elmt, true)); + } + + return EndpointFactory.createEndpoint(doc.getDocumentElement()); + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java new file mode 100644 index 0000000..d24000e --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/OdeFault.java
@@ -0,0 +1,49 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import javax.xml.namespace.QName; + +import org.apache.axis2.AxisFault; + +/** + * User-friendly version of AxisFault + */ +public class OdeFault extends AxisFault { + + public static final QName FAULT = new QName("http://incubator.apache.org/ode", "Fault"); + + public OdeFault(String message) { + super(FAULT, message, null); + } + + public OdeFault(Throwable cause) { + this(cause.getMessage(), cause); + if (cause instanceof AxisFault) { + AxisFault f = (AxisFault) cause; + setFaultCode(f.getFaultCode()); + } + } + + public OdeFault(String message, Throwable cause) { + super(new QName("java:"+cause.getClass().getPackage(), cause.getClass().getName(), "java"), message, cause); + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/Properties.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/Properties.java new file mode 100644 index 0000000..dc90306 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/Properties.java
@@ -0,0 +1,382 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.axis2.Constants; +import org.apache.axis2.client.Options; +import org.apache.axis2.transport.http.HTTPConstants; +import org.apache.axis2.transport.http.HttpTransportProperties; +import org.apache.axis2.transport.jms.JMSConstants; +import org.apache.commons.httpclient.Header; +import org.apache.commons.httpclient.HttpVersion; +import org.apache.commons.httpclient.ProtocolException; +import org.apache.commons.httpclient.params.DefaultHttpParams; +import org.apache.commons.httpclient.params.HostParams; +import org.apache.commons.httpclient.params.HttpClientParams; +import org.apache.commons.httpclient.params.HttpConnectionParams; +import org.apache.commons.httpclient.params.HttpMethodParams; +import org.apache.commons.httpclient.params.HttpParams; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.Map; + +/** + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public class Properties { + + /** + * Property used to define how long (in miiliseconds) the message will wait for a response. Default value is {@link #DEFAULT_MEX_TIMEOUT} + */ + public static final String PROP_MEX_TIMEOUT = "mex.timeout"; + // its default value + public static final int DEFAULT_MEX_TIMEOUT = 2 * 60 * 1000; + + + public static final String PROP_HTTP_CONNECTION_TIMEOUT = HttpConnectionParams.CONNECTION_TIMEOUT; + public static final String PROP_HTTP_SOCKET_TIMEOUT = HttpMethodParams.SO_TIMEOUT; + public static final String PROP_HTTP_PROTOCOL_VERSION = HttpMethodParams.PROTOCOL_VERSION; + public static final String PROP_HTTP_HEADER_PREFIX = "http.default-headers."; + public static final String PROP_HTTP_PROXY_PREFIX = "http.proxy."; + public static final String PROP_HTTP_PROXY_HOST = PROP_HTTP_PROXY_PREFIX + "host"; + public static final String PROP_HTTP_PROXY_PORT = PROP_HTTP_PROXY_PREFIX + "port"; + public static final String PROP_HTTP_PROXY_DOMAIN = PROP_HTTP_PROXY_PREFIX + "domain"; + public static final String PROP_HTTP_PROXY_USER = PROP_HTTP_PROXY_PREFIX + "user"; + public static final String PROP_HTTP_PROXY_PASSWORD = PROP_HTTP_PROXY_PREFIX + "password"; + /** + * @deprecated use org.apache.commons.httpclient.params.HttpMethodParams#HTTP_CONTENT_CHARSET (="http.protocol.content-charset") + */ + public static final String PROP_HTTP_PROTOCOL_ENCODING = "http.protocol.encoding"; + + // Httpclient specific + public static final String PROP_HTTP_MAX_REDIRECTS = HttpClientParams.MAX_REDIRECTS; + + // Axis2-specific + public static final String PROP_HTTP_REQUEST_CHUNK = "http.request.chunk"; + public static final String PROP_HTTP_REQUEST_GZIP = "http.request.gzip"; + public static final String PROP_HTTP_ACCEPT_GZIP = "http.accept.gzip"; + public static final String PROP_SECURITY_POLICY = "security.policy"; + public static final String PROP_JMS_REPLY_DESTINATION = "jms.reply.destination"; + public static final String PROP_JMS_REPLY_TIMEOUT = "jms.reply.timeout"; + public static final String PROP_SEND_WS_ADDRESSING_HEADERS = "ws-adddressing.headers"; + + + protected static final Log log = LogFactory.getLog(Properties.class); + + public static Object[] getProxyAndHeaders(Map<String, String> properties) { + ArrayList<Header> headers = null; // /!\ Axis2 requires an ArrayList (not a List implementation) + HttpTransportProperties.ProxyProperties proxy = null; + for (Map.Entry<String, String> e : properties.entrySet()) { + final String k = e.getKey(); + final String v = e.getValue(); + if (k.startsWith(PROP_HTTP_HEADER_PREFIX)) { + if (headers == null) headers = new ArrayList<Header>(); + // extract the header name + String name = k.substring(PROP_HTTP_HEADER_PREFIX.length()); + headers.add(new Header(name, v)); + } else if (k.startsWith(PROP_HTTP_PROXY_PREFIX)) { + if (proxy == null) proxy = new HttpTransportProperties.ProxyProperties(); + + if (PROP_HTTP_PROXY_HOST.equals(k)) proxy.setProxyName(v); + else if (PROP_HTTP_PROXY_PORT.equals(k)) proxy.setProxyPort(Integer.parseInt(v)); + else if (PROP_HTTP_PROXY_DOMAIN.equals(k)) proxy.setDomain(v); + else if (PROP_HTTP_PROXY_USER.equals(k)) proxy.setUserName(v); + else if (PROP_HTTP_PROXY_PASSWORD.equals(k)) proxy.setPassWord(v); + else if (log.isWarnEnabled()) + log.warn("Unknown proxy properties [" + k + "]. " + PROP_HTTP_PROXY_PREFIX + " is a refix reserved for proxy properties."); + } + } + if (proxy != null) { + String host = proxy.getProxyHostName(); + if (host == null || host.length() == 0) { + // disable proxy if the host is not null + proxy = null; + if (log.isDebugEnabled()) log.debug("Proxy host is null. Proxy will not be taken into account."); + } + } + + return new Object[]{proxy, headers}; + } + + public static class Axis2 { + + public static Options translate(Map<String, String> properties) { + return translate(properties, new Options()); + } + + public static Options translate(Map<String, String> properties, Options options) { + if (log.isDebugEnabled()) log.debug("Translating Properties for Axis2"); + if (properties.isEmpty()) return options; + + // First set any default values to make sure they can be overwriten + // set the default encoding for HttpClient (HttpClient uses ISO-8859-1 by default) + options.setProperty(Constants.Configuration.CHARACTER_SET_ENCODING, "UTF-8"); + + /*then add all property pairs so that new properties (with string value) + are automatically handled (i.e no translation needed) */ + for (Map.Entry<String, String> e : properties.entrySet()) { + options.setProperty(e.getKey(), e.getValue()); + } + if (properties.containsKey(PROP_HTTP_CONNECTION_TIMEOUT)) { + final String value = properties.get(PROP_HTTP_CONNECTION_TIMEOUT); + try { + options.setProperty(HTTPConstants.CONNECTION_TIMEOUT, Integer.valueOf(value)); + } catch (NumberFormatException e) { + if (log.isWarnEnabled()) + log.warn("Mal-formatted Property: [" + Properties.PROP_HTTP_CONNECTION_TIMEOUT + "=" + value + "]. Integer expected. Property will be skipped."); + } + } + if (properties.containsKey(PROP_HTTP_SOCKET_TIMEOUT)) { + final String value = properties.get(PROP_HTTP_SOCKET_TIMEOUT); + try { + options.setProperty(HTTPConstants.SO_TIMEOUT, Integer.valueOf(value)); + } catch (NumberFormatException e) { + if (log.isWarnEnabled()) + log.warn("Mal-formatted Property: [" + Properties.PROP_HTTP_SOCKET_TIMEOUT + "=" + value + "]. Integer expected. Property will be skipped."); + } + } + if (properties.containsKey(PROP_HTTP_PROTOCOL_ENCODING)) { + if(log.isWarnEnabled())log.warn("Deprecated property: http.protocol.encoding. Use http.protocol.content-charset"); + options.setProperty(Constants.Configuration.CHARACTER_SET_ENCODING, properties.get(PROP_HTTP_PROTOCOL_ENCODING)); + } + if (properties.containsKey(HttpMethodParams.HTTP_CONTENT_CHARSET)) { + options.setProperty(Constants.Configuration.CHARACTER_SET_ENCODING, properties.get(HttpMethodParams.HTTP_CONTENT_CHARSET)); + } + if (properties.containsKey(PROP_HTTP_PROTOCOL_VERSION)) { + options.setProperty(HTTPConstants.HTTP_PROTOCOL_VERSION, properties.get(PROP_HTTP_PROTOCOL_VERSION)); + } + if (properties.containsKey(PROP_HTTP_REQUEST_CHUNK)) { + options.setProperty(HTTPConstants.CHUNKED, properties.get(PROP_HTTP_REQUEST_CHUNK)); + } + if (properties.containsKey(PROP_HTTP_REQUEST_GZIP)) { + options.setProperty(HTTPConstants.MC_GZIP_REQUEST, properties.get(PROP_HTTP_REQUEST_GZIP)); + } + if (properties.containsKey(PROP_HTTP_ACCEPT_GZIP)) { + options.setProperty(HTTPConstants.MC_ACCEPT_GZIP, properties.get(PROP_HTTP_ACCEPT_GZIP)); + } + if (properties.containsKey(PROP_HTTP_MAX_REDIRECTS)) { + if (log.isWarnEnabled()) log.warn("Property Not Supported: " + PROP_HTTP_MAX_REDIRECTS); + } + if (properties.containsKey(PROP_JMS_REPLY_DESTINATION)) { + options.setProperty(JMSConstants.REPLY_PARAM, properties.get(PROP_JMS_REPLY_DESTINATION)); + } + if (properties.containsKey(PROP_JMS_REPLY_TIMEOUT)) { + String value = properties.get(PROP_JMS_REPLY_TIMEOUT); + try { + options.setProperty(JMSConstants.JMS_WAIT_REPLY, Long.valueOf(value)); + } catch (NumberFormatException e) { + if (log.isWarnEnabled()) + log.warn("Mal-formatted Property: [" + Properties.PROP_JMS_REPLY_TIMEOUT + "=" + value + "]. Long expected. Property will be skipped."); + } + } + if(properties.containsKey(PROP_SEND_WS_ADDRESSING_HEADERS)){ + String value = properties.get(PROP_SEND_WS_ADDRESSING_HEADERS); + options.setProperty(PROP_SEND_WS_ADDRESSING_HEADERS, Boolean.parseBoolean(value)); + } + + // iterate through the properties to get Headers & Proxy information + Object[] o = getProxyAndHeaders(properties); + HttpTransportProperties.ProxyProperties proxy = (HttpTransportProperties.ProxyProperties) o[0]; + ArrayList<Header> headers = (ArrayList<Header>) o[1]; // /!\ Axis2 requires an ArrayList (not a List implementation) + if (headers != null && !headers.isEmpty()) options.setProperty(HTTPConstants.HTTP_HEADERS, headers); + if (proxy != null) options.setProperty(HTTPConstants.PROXY, proxy); + + return options; + } + } + + + public static class HttpClient { + public static HttpParams translate(Map<String, String> properties) { + return translate(properties, new DefaultHttpParams()); + } + + public static HttpParams translate(Map<String, String> properties, HttpParams p) { + if (log.isDebugEnabled()) + log.debug("Translating Properties for HttpClient. Properties size=" + properties.size()); + if (properties.isEmpty()) return p; + + // First set any default values to make sure they can be overwriten + // set the default encoding for HttpClient (HttpClient uses ISO-8859-1 by default) + p.setParameter(HttpMethodParams.HTTP_CONTENT_CHARSET, "UTF-8"); + + /*then all property pairs so that new properties (with string value) + are automatically handled (i.e no translation needed) */ + for (Map.Entry<String, String> e : properties.entrySet()) { + p.setParameter(e.getKey(), e.getValue()); + } + + // initialize the collection of headers + p.setParameter(HostParams.DEFAULT_HEADERS, new ArrayList()); + + if (properties.containsKey(PROP_HTTP_CONNECTION_TIMEOUT)) { + final String value = properties.get(PROP_HTTP_CONNECTION_TIMEOUT); + try { + p.setParameter(HttpConnectionParams.CONNECTION_TIMEOUT, Integer.valueOf(value)); + } catch (NumberFormatException e) { + if (log.isWarnEnabled()) + log.warn("Mal-formatted Property: [" + Properties.PROP_HTTP_CONNECTION_TIMEOUT + "=" + value + "] Property will be skipped."); + } + } + if (properties.containsKey(PROP_HTTP_SOCKET_TIMEOUT)) { + final String value = properties.get(PROP_HTTP_SOCKET_TIMEOUT); + try { + p.setParameter(HttpMethodParams.SO_TIMEOUT, Integer.valueOf(value)); + } catch (NumberFormatException e) { + if (log.isWarnEnabled()) + log.warn("Mal-formatted Property: [" + Properties.PROP_HTTP_SOCKET_TIMEOUT + "=" + value + "] Property will be skipped."); + } + } + + if (properties.containsKey(PROP_HTTP_PROTOCOL_ENCODING)) { + if(log.isWarnEnabled())log.warn("Deprecated property: http.protocol.encoding. Use http.protocol.content-charset"); + p.setParameter(HttpMethodParams.HTTP_CONTENT_CHARSET, properties.get(PROP_HTTP_PROTOCOL_ENCODING)); + } + // the next one is redundant because HttpMethodParams.HTTP_CONTENT_CHARSET accepts a string and we use the same property name + // so the property has already been added. + if (properties.containsKey(HttpMethodParams.HTTP_CONTENT_CHARSET)) { + p.setParameter(HttpMethodParams.HTTP_CONTENT_CHARSET, properties.get(HttpMethodParams.HTTP_CONTENT_CHARSET)); + } + + if (properties.containsKey(PROP_HTTP_PROTOCOL_VERSION)) { + try { + p.setParameter(HttpMethodParams.PROTOCOL_VERSION, HttpVersion.parse(properties.get(PROP_HTTP_PROTOCOL_VERSION))); + } catch (ProtocolException e) { + if (log.isWarnEnabled()) + + + log.warn("Mal-formatted Property: [" + PROP_HTTP_PROTOCOL_VERSION + "]", e); + } + } + if (properties.containsKey(PROP_HTTP_REQUEST_CHUNK)) { + // see org.apache.commons.httpclient.methods.EntityEnclosingMethod.setContentChunked() + p.setBooleanParameter(PROP_HTTP_REQUEST_CHUNK, Boolean.parseBoolean(properties.get(PROP_HTTP_REQUEST_CHUNK))); + } + if (properties.containsKey(PROP_HTTP_REQUEST_GZIP)) { + if (log.isWarnEnabled()) + log.warn("Property not supported by HTTP External Services: " + PROP_HTTP_REQUEST_GZIP); + } + + if (Boolean.parseBoolean(properties.get(PROP_HTTP_ACCEPT_GZIP))) { + // append gzip to the list of accepted encoding + // HttpClient does not support compression natively + // Additional code would be necessary to handle it. +// ((Collection) p.getParameter(HostParams.DEFAULT_HEADERS)).add(new Header("Accept-Encoding", "gzip")); + if (log.isWarnEnabled()) + log.warn("Property not supported by HTTP External Services: " + PROP_HTTP_ACCEPT_GZIP); + } + + if (properties.containsKey(PROP_HTTP_MAX_REDIRECTS)) { + final String value = properties.get(PROP_HTTP_MAX_REDIRECTS); + try { + p.setParameter(HttpClientParams.MAX_REDIRECTS, Integer.valueOf(value)); + } catch (NumberFormatException e) { + if (log.isWarnEnabled()) + log.warn("Mal-formatted Property: [" + Properties.PROP_HTTP_MAX_REDIRECTS + "=" + value + "] Property will be skipped."); + } + } + + Object[] o = getProxyAndHeaders(properties); + HttpTransportProperties.ProxyProperties proxy = (HttpTransportProperties.ProxyProperties) o[0]; + Collection headers = (Collection) o[1]; + if (headers != null && !headers.isEmpty()) + ((Collection) p.getParameter(HostParams.DEFAULT_HEADERS)).addAll(headers); + if (proxy != null) p.setParameter(PROP_HTTP_PROXY_PREFIX, proxy); + + return new UnmodifiableHttpParams(p); + } + + static class UnmodifiableHttpParams implements HttpParams { + + final HttpParams p; + + private UnmodifiableHttpParams(HttpParams p) { + this.p = p; + } + + public void setBooleanParameter(String name, boolean value) { + throw new UnsupportedOperationException(); + } + + public void setDefaults(HttpParams params) { + throw new UnsupportedOperationException(); + } + + public void setDoubleParameter(String name, double value) { + throw new UnsupportedOperationException(); + } + + public void setIntParameter(String name, int value) { + throw new UnsupportedOperationException(); + } + + public void setLongParameter(String name, long value) { + throw new UnsupportedOperationException(); + } + + public void setParameter(String name, Object value) { + throw new UnsupportedOperationException(); + } + + public boolean getBooleanParameter(String name, boolean defaultValue) { + return p.getBooleanParameter(name, defaultValue); + } + + public HttpParams getDefaults() { + return null; + } + + public double getDoubleParameter(String name, double defaultValue) { + return p.getDoubleParameter(name, defaultValue); + } + + public int getIntParameter(String name, int defaultValue) { + return p.getIntParameter(name, defaultValue); + } + + public long getLongParameter(String name, long defaultValue) { + return p.getLongParameter(name, defaultValue); + } + + public Object getParameter(String name) { + return p.getParameter(name); + } + + public boolean isParameterFalse(String name) { + return p.isParameterFalse(name); + } + + public boolean isParameterSet(String name) { + return p.isParameterSet(name); + } + + public boolean isParameterSetLocally(String name) { + return p.isParameterSetLocally(name); + } + + public boolean isParameterTrue(String name) { + return p.isParameterTrue(name); + } + } + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java new file mode 100644 index 0000000..325de03 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/SoapExternalService.java
@@ -0,0 +1,591 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2; + +import org.apache.axiom.soap.SOAPEnvelope; +import org.apache.axis2.AxisFault; +import org.apache.axis2.addressing.EndpointReference; +import org.apache.axis2.client.OperationClient; +import org.apache.axis2.client.Options; +import org.apache.axis2.client.ServiceClient; +import org.apache.axis2.context.ConfigurationContext; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.description.OutInAxisOperation; +import org.apache.axis2.description.OutOnlyAxisOperation; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.transport.jms.JMSConstants; +import org.apache.axis2.wsdl.WSDLConstants; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.neethi.Policy; +import org.apache.neethi.PolicyEngine; +import org.apache.ode.axis2.util.SoapMessageConverter; +import org.apache.ode.bpel.epr.EndpointFactory; +import org.apache.ode.bpel.epr.MutableEndpoint; +import org.apache.ode.bpel.epr.WSAEndpoint; +import org.apache.ode.bpel.iapi.BpelServer; +import org.apache.ode.bpel.iapi.Message; +import org.apache.ode.bpel.iapi.MessageExchange; +import org.apache.ode.bpel.iapi.MessageExchange.FailureType; +import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.bpel.iapi.Scheduler; +import org.apache.ode.il.OMUtils; +import org.apache.ode.utils.*; +import org.apache.ode.utils.fs.FileUtils; +import org.apache.ode.utils.uuid.UUID; +import org.apache.ode.utils.wsdl.Messages; +import org.apache.rampart.RampartMessageData; +import org.w3c.dom.Document; +import org.w3c.dom.Element; + +import javax.wsdl.Definition; +import javax.wsdl.Fault; +import javax.wsdl.Operation; +import javax.xml.namespace.QName; +import java.io.File; +import java.io.IOException; +import java.io.InputStream; +import java.net.URI; +import java.util.Map; +import java.util.concurrent.Callable; +import java.util.concurrent.ExecutorService; + +/** + * Acts as a service not provided by ODE. Used mainly for invocation as a way to maintain the WSDL description of used + * services. + * + * @author Matthieu Riou <mriou at apache dot org> + */ +public class SoapExternalService implements ExternalService { + + private static final Log __log = LogFactory.getLog(SoapExternalService.class); + + private static final org.apache.ode.utils.wsdl.Messages msgs = Messages.getMessages(Messages.class); + + + private static ThreadLocal<ServiceClient> _cachedClients = new ThreadLocal<ServiceClient>(); + private WatchDog<Map, OptionsObserver> _axisOptionsWatchDog; + private WatchDog<Long, ServiceFileObserver> _axisServiceWatchDog; + private ConfigurationContext _configContext; + + + private ExecutorService _executorService; + private Definition _definition; + private QName _serviceName; + private String _portName; + protected WSAEndpoint endpointReference; + private AxisConfiguration _axisConfig; + private SoapMessageConverter _converter; + private Scheduler _sched; + private BpelServer _server; + private ProcessConf _pconf; + + public SoapExternalService(ProcessConf pconf, QName serviceName, String portName, ExecutorService executorService, + AxisConfiguration axisConfig, Scheduler sched, BpelServer server) throws AxisFault { + _definition = pconf.getDefinitionForService(serviceName); + _serviceName = serviceName; + _portName = portName; + _executorService = executorService; + _axisConfig = axisConfig; + _sched = sched; + _converter = new SoapMessageConverter(_definition, serviceName, portName); + _server = server; + _pconf = pconf; + + File fileToWatch = new File(_pconf.getBaseURI().resolve(_serviceName.getLocalPart() + ".axis2")); + _axisServiceWatchDog = WatchDog.watchFile(fileToWatch, new ServiceFileObserver(fileToWatch)); + _axisOptionsWatchDog = new WatchDog<Map, OptionsObserver>(new EndpointPropertiesMutable(), new OptionsObserver()); + _configContext = new ConfigurationContext(_axisConfig); + + // initial endpoint reference + Element eprElmt = ODEService.genEPRfromWSDL(_definition, serviceName, portName); + if (eprElmt == null) + throw new IllegalArgumentException(msgs.msgPortDefinitionNotFound(serviceName, portName)); + endpointReference = EndpointFactory.convertToWSA(ODEService.createServiceRef(eprElmt)); + } + + public void invoke(final PartnerRoleMessageExchange odeMex) { + boolean isTwoWay = odeMex.getMessageExchangePattern() == org.apache.ode.bpel.iapi.MessageExchange.MessageExchangePattern.REQUEST_RESPONSE; + try { + + ServiceClient client = getServiceClient(); + + // Override options are passed to the axis MessageContext so we can + // retrieve them in our session out changeHandler. + MessageContext mctx = new MessageContext(); + /* make the given options the parent so it becomes the defaults of the MessageContexgt. That allows the user to override + * specific options on a given message context and not affect the overall options. + */ + mctx.getOptions().setParent(client.getOptions()); + writeHeader(mctx, odeMex); + + _converter.createSoapRequest(mctx, odeMex.getRequest(), odeMex.getOperation()); + + SOAPEnvelope soapEnv = mctx.getEnvelope(); + EndpointReference axisEPR = new EndpointReference(((MutableEndpoint) odeMex.getEndpointReference()) + .getUrl()); + if (__log.isDebugEnabled()) { + __log.debug("Axis2 sending message to " + axisEPR.getAddress() + " using MEX " + odeMex); + __log.debug("Message: " + soapEnv); + } + + final OperationClient operationClient = client.createClient(isTwoWay ? ServiceClient.ANON_OUT_IN_OP + : ServiceClient.ANON_OUT_ONLY_OP); + operationClient.addMessageContext(mctx); + // this Options can be alter without impacting the ServiceClient options (which is a requirement) + Options operationOptions = operationClient.getOptions(); + + // provide HTTP credentials if any + AuthenticationHelper.setHttpAuthentication(odeMex, operationOptions); + + operationOptions.setAction(mctx.getSoapAction()); + operationOptions.setTo(axisEPR); + + if (isTwoWay) { + final String mexId = odeMex.getMessageExchangeId(); + final Operation operation = odeMex.getOperation(); + + // Defer the invoke until the transaction commits. + _sched.registerSynchronizer(new Scheduler.Synchronizer() { + public void afterCompletion(boolean success) { + // If the TX is rolled back, then we don't send the request. + if (!success) return; + + // The invocation must happen in a separate thread, holding on the afterCompletion + // blocks other operations that could have been listed there as well. + _executorService.submit(new Callable<Object>() { + public Object call() throws Exception { + try { + operationClient.execute(true); + MessageContext response = operationClient.getMessageContext(WSDLConstants.MESSAGE_LABEL_IN_VALUE); + MessageContext flt = operationClient.getMessageContext(WSDLConstants.MESSAGE_LABEL_FAULT_VALUE); + if (response != null && __log.isDebugEnabled()) + __log.debug("Service response:\n" + response.getEnvelope().toString()); + + if (flt != null) { + reply(mexId, operation, flt, true); + } else { + reply(mexId, operation, response, response.isFault()); + } + } catch (Throwable t) { + String errmsg = "Error sending message (mex=" + odeMex + "): " + t.getMessage(); + __log.error(errmsg, t); + replyWithFailure(mexId, MessageExchange.FailureType.COMMUNICATION_ERROR, errmsg, null); + } + return null; + } + }); + } + + public void beforeCompletion() { + } + }); + odeMex.replyAsync(); + + } else { /** one-way case * */ + _executorService.submit(new Callable<Object>() { + public Object call() throws Exception { + operationClient.execute(false); + return null; + } + }); + odeMex.replyOneWayOk(); + } + } catch (AxisFault axisFault) { + String errmsg = "Error sending message to Axis2 for ODE mex " + odeMex; + __log.error(errmsg, axisFault); + odeMex.replyWithFailure(MessageExchange.FailureType.COMMUNICATION_ERROR, errmsg, null); + } + } + + private ServiceClient getServiceClient() throws AxisFault { + try { + // call manually the check procedure + // we dont want a dedicated thread for that + _axisServiceWatchDog.check(); + _axisOptionsWatchDog.check(); + } catch (RuntimeException e) { + throw AxisFault.makeFault(e.getCause() != null ? e.getCause() : e); + } + + // apply the options to the service client + ServiceClient serviceClient = _cachedClients.get(); + if (serviceClient == null) { + serviceClient = new ServiceClient(_configContext, null); + _cachedClients.set(serviceClient); + } + AxisService anonymousService = _axisServiceWatchDog.getObserver().anonymousService; + serviceClient.setAxisService(anonymousService); + serviceClient.setOptions(_axisOptionsWatchDog.getObserver().options); + + applySecuritySettings(serviceClient); + + return serviceClient; + } + private void applySecuritySettings(ServiceClient serviceClient) throws AxisFault { + Options options = serviceClient.getOptions(); + if (options.getProperty(Properties.PROP_SECURITY_POLICY) != null) { + String policy = (String) options.getProperty(Properties.PROP_SECURITY_POLICY); + // if the policy path is relative, the full uri is resolved against the process conf directory + URI policyUri; + if (FileUtils.isRelative(policy)) { + policyUri = _pconf.getBaseURI().resolve(policy); + } else { + policyUri = new File(policy).toURI(); + } + try { + InputStream policyStream = policyUri.toURL().openStream(); + try { + Policy policyDoc = PolicyEngine.getPolicy(policyStream); + options.setProperty(RampartMessageData.KEY_RAMPART_POLICY, policyDoc); + + // make sure the proper modules are engaged + if (!serviceClient.getAxisService().getAxisConfiguration().isEngaged("rampart") + && !serviceClient.getAxisService().isEngaged("rampart")) { + serviceClient.engageModule("rampart"); + } + } finally { + policyStream.close(); + } + } catch (IOException e) { + throw new IllegalArgumentException("Exception while parsing policy: " + policyUri, e); + } + } + } + + /** + * Extracts the action to be used for the given operation. It first checks to see + * if a value is specified using WS-Addressing in the portType, it then falls back onto + * getting it from the SOAP Binding. + * + * @param operation the name of the operation to get the Action for + * @return The action value for the specified operation + */ + private String getAction(String operation) { + String action = _converter.getWSAInputAction(operation); + if (action == null || "".equals(action)) { + action = _converter.getSoapAction(operation); + } + return action; + } + + /** + * Extracts endpoint information from ODE message exchange to stuff them into Axis MessageContext. + */ + private void writeHeader(MessageContext ctxt, PartnerRoleMessageExchange odeMex) { + Options options = ctxt.getOptions(); + WSAEndpoint targetWSAEPR = EndpointFactory.convertToWSA((MutableEndpoint) odeMex.getEndpointReference()); + WSAEndpoint myRoleWSAEPR = EndpointFactory.convertToWSA((MutableEndpoint) odeMex.getMyRoleEndpointReference()); + WSAEndpoint targetEPR = new WSAEndpoint(targetWSAEPR); + + EndpointReference replyEPR = null; + + String partnerSessionId = odeMex.getProperty(MessageExchange.PROPERTY_SEP_PARTNERROLE_SESSIONID); + String myRoleSessionId = odeMex.getProperty(MessageExchange.PROPERTY_SEP_MYROLE_SESSIONID); + + if (partnerSessionId != null) { + if (__log.isDebugEnabled()) { + __log.debug("Partner session identifier found for WSA endpoint: " + partnerSessionId); + } + targetEPR.setSessionId(partnerSessionId); + } + options.setProperty("targetSessionEndpoint", targetEPR); + + if (myRoleWSAEPR != null) { + WSAEndpoint myRoleEPR = new WSAEndpoint(myRoleWSAEPR); + if (myRoleSessionId != null) { + if (__log.isDebugEnabled()) { + __log.debug("MyRole session identifier found for myrole (callback) WSA endpoint: " + + myRoleSessionId); + } + myRoleEPR.setSessionId(myRoleSessionId); + } + options.setProperty("callbackSessionEndpoint", myRoleEPR); + + // Map My Session ID to JMS Correlation ID + Document callbackEprXml = odeMex.getMyRoleEndpointReference().toXML(); + Element serviceElement = callbackEprXml.getDocumentElement(); + + if (myRoleSessionId != null) { + options.setProperty(JMSConstants.JMS_COORELATION_ID, myRoleSessionId); + } else { + if (myRoleWSAEPR.getSessionId() != null) { + options.setProperty(JMSConstants.JMS_COORELATION_ID, myRoleSessionId); + } + } + + Element address = DOMUtils.findChildByName(serviceElement, + new QName(Namespaces.WS_ADDRESSING_NS, "Address"), true); + if (__log.isDebugEnabled()) { + __log.debug("The system-defined wsa address is : " + + address); + } + if (address != null) { + String url = address.getTextContent(); + String jmsDestination = (String) options.getProperty(JMSConstants.REPLY_PARAM); + if (__log.isDebugEnabled()) { + __log.debug("The user-defined JMS replyTo destination is: " + + jmsDestination); + __log.debug("The user-defined JMS wait timeout is: " + + options.getProperty(JMSConstants.JMS_WAIT_REPLY)); + } + if (jmsDestination == null || "".equals(jmsDestination.trim())) { + // If the REPLY_PARAM property is not user-defined, then use the default value from myRole EPR + int startIndex = url.indexOf("jms:/"); + if (startIndex != -1) { + startIndex += "jms:/".length(); + if (url.charAt(startIndex + 1) == '/') { + // startIndex++; // treat "/" as valid start character for queue name + } + if (url.startsWith("dynamic")) { + startIndex += "dynamicQueues".length(); + } + int jmsEndIndex = url.indexOf("?", startIndex); + if (jmsEndIndex == -1) { + jmsEndIndex = url.length(); + } + jmsDestination = url.substring(startIndex, jmsEndIndex); + options.setProperty(JMSConstants.REPLY_PARAM, jmsDestination); + replyEPR = new EndpointReference(url); + } else { + startIndex = url.indexOf("http://"); + if (startIndex != -1) { + startIndex = url.indexOf("/processes/"); + if (startIndex != -1) { + startIndex += "/processes/".length(); + jmsDestination = url.substring(startIndex); + options.setProperty(JMSConstants.REPLY_PARAM, jmsDestination); + } + } + } + } else { + replyEPR = new EndpointReference("jms:/" + jmsDestination); + } + } + } else { + __log.debug("My-Role EPR not specified, SEP will not be used."); + } + + String action = getAction(odeMex.getOperationName()); + ctxt.setSoapAction(action); + + if (replyEPR == null) { + if (MessageExchange.MessageExchangePattern.REQUEST_RESPONSE == odeMex.getMessageExchangePattern()) { + replyEPR = new EndpointReference(Namespaces.WS_ADDRESSING_ANON_URI); + } + } + if (replyEPR != null) { + ctxt.setReplyTo(replyEPR); + ctxt.setMessageID("uuid:" + new UUID().toString()); + } + } + + public org.apache.ode.bpel.iapi.EndpointReference getInitialEndpointReference() { + return endpointReference; + } + + public void close() { + // nothing + } + + public String getPortName() { + return _portName; + } + + public QName getServiceName() { + return _serviceName; + } + + private void replyWithFailure(final String odeMexId, final FailureType error, final String errmsg, + final Element details) { + // ODE MEX needs to be invoked in a TX. + try { + _sched.execIsolatedTransaction(new Callable<Void>() { + public Void call() throws Exception { + PartnerRoleMessageExchange odeMex = (PartnerRoleMessageExchange) _server.getEngine().getMessageExchange(odeMexId); + odeMex.replyWithFailure(error, errmsg, details); + return null; + } + }); + + } catch (Exception e) { + String emsg = "Error executing replyWithFailure transaction; reply will be lost."; + __log.error(emsg, e); + + } + + } + + private void reply(final String odeMexId, final Operation operation, final MessageContext reply, final boolean isFault) { + // ODE MEX needs to be invoked in a TX. + try { + _sched.execIsolatedTransaction(new Callable<Void>() { + public Void call() throws Exception { + PartnerRoleMessageExchange odeMex = (PartnerRoleMessageExchange) _server.getEngine().getMessageExchange(odeMexId); + // Setting the response + try { + if (__log.isDebugEnabled()) __log.debug("Received response for MEX " + odeMex); + if (isFault) { + Document odeMsg = DOMUtils.newDocument(); + Element odeMsgEl = odeMsg.createElementNS(null, "message"); + odeMsg.appendChild(odeMsgEl); + Fault fault = _converter.parseSoapFault(odeMsgEl, reply.getEnvelope(), operation); + + if (fault != null) { + if (__log.isWarnEnabled()) + __log.warn("Fault response: faultName=" + fault.getName() + " faultType=" + fault.getMessage().getQName() + "\n" + DOMUtils.domToString(odeMsgEl)); + + QName faultType = fault.getMessage().getQName(); + QName faultName = new QName(_definition.getTargetNamespace(), fault.getName()); + Message response = odeMex.createMessage(faultType); + response.setMessage(odeMsgEl); + + odeMex.replyWithFault(faultName, response); + } else { + if (__log.isWarnEnabled()) + __log.warn("Fault response: faultType=(unkown)\n" + reply.getEnvelope().toString()); + odeMex.replyWithFailure(FailureType.OTHER, reply.getEnvelope().getBody() + .getFault().getText(), OMUtils.toDOM(reply.getEnvelope().getBody())); + } + } else { + Message response = odeMex.createMessage(odeMex.getOperation().getOutput().getMessage().getQName()); + _converter.parseSoapResponse(response, reply.getEnvelope(), operation); + if (__log.isInfoEnabled()) __log.info("Response:\n" + (response.getMessage() != null ? + DOMUtils.domToString(response.getMessage()) : "empty")); + odeMex.reply(response); + } + } catch (Exception ex) { + String errmsg = "Unable to process response: " + ex.getMessage(); + __log.error(errmsg, ex); + odeMex.replyWithFailure(FailureType.OTHER, errmsg, null); + } + return null; + } + }); + + } catch (Exception e) { + String errmsg = "Error executing reply transaction; reply will be lost."; + __log.error(errmsg, e); + } + + } + + + /** + * This class wraps a {@link org.apache.axis2.client.ServiceClient} and watches changes (deletions,creations,updates) + * on a Axis2 service config file named {service-name}.axis2.<p/> + * The {@link org.apache.axis2.client.ServiceClient} instance is created from the main Axis2 config instance and + * this service-specific config file. + */ + private class ServiceFileObserver extends WatchDog.DefaultObserver { + String serviceName = "anonymous_service_" + new GUID().toString(); + AxisService anonymousService; + File file; + + private ServiceFileObserver(File file) { + this.file = file; + } + + public boolean isInitialized() { + return anonymousService != null; + } + + public void init() { + // create an anonymous axis service that will be used by the ServiceClient + // this service will be added to the AxisConfig so do not reuse the name of the external service + // as it could blow up if the service is deployed in the same axis2 instance + anonymousService = new AxisService(serviceName); + anonymousService.setParent(_axisConfig); + + OutOnlyAxisOperation outOnlyOperation = new OutOnlyAxisOperation(ServiceClient.ANON_OUT_ONLY_OP); + anonymousService.addOperation(outOnlyOperation); + + OutInAxisOperation outInOperation = new OutInAxisOperation(ServiceClient.ANON_OUT_IN_OP); + anonymousService.addOperation(outInOperation); + } + + public void onUpdate() { + // axis2 service configuration + // if the config file has been modified (i.e added or updated), re-create a ServiceClient + // and load the new config. + init(); // create a new ServiceClient instance + try { + AxisUtils.configureService(_configContext, anonymousService, file.toURI().toURL()); + // do not allow the service.xml file to change the service name + anonymousService.setName(serviceName); + } catch (Exception e) { + if (__log.isWarnEnabled()) __log.warn("Exception while configuring service: " + _serviceName, e); + throw new RuntimeException("Exception while configuring service: " + _serviceName, e); + } + } + } + + private class OptionsObserver extends WatchDog.DefaultObserver { + + Options options; + + public boolean isInitialized() { + return options != null; + } + + public void init() { + options = new Options(); + // set defaults values + options.setExceptionToBeThrownOnSOAPFault(false); + + // this value does NOT override Properties.PROP_HTTP_CONNECTION_TIMEOUT + // nor Properties.PROP_HTTP_SOCKET_TIMEOUT. + // it will be applied only if the laters are not set. + options.setTimeOutInMilliSeconds(60000); + } + + public void onUpdate() { + init(); + + // note: don't make this map an instance attribute, so we always get the latest version + final Map<String, String> properties = _pconf.getEndpointProperties(endpointReference); + Properties.Axis2.translate(properties, options); + } + } + + private class EndpointPropertiesMutable implements WatchDog.Mutable<Map> { + // ProcessConf#getProperties(String...) cannot return null (by contract) + public boolean exists() { + return true; + } + + public boolean hasChangedSince(Map since) { + Map latest = lastModified(); // cannot be null but better be prepared + // check if mappings are equal + return !CollectionUtils.equals(latest, since); + } + + public Map lastModified() { + return _pconf.getEndpointProperties(endpointReference); + } + + public String toString() { + return "Properties for Endpoint: " + endpointReference; + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java new file mode 100644 index 0000000..bd62c41 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/deploy/DeploymentPoller.java
@@ -0,0 +1,223 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.deploy; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.ODEServer; + +import javax.xml.namespace.QName; +import java.io.File; +import java.io.FileFilter; +import java.io.FilenameFilter; +import java.io.IOException; +import java.util.Collection; + +/** + * Polls a directory for the deployment of a new deployment unit. + */ +public class DeploymentPoller { + + private static Log __log = LogFactory.getLog(DeploymentPoller.class); + + /** The polling interval. */ + private static final long POLL_TIME = 3000; + + private File _deployDir; + + private PollingThread _poller; + + private ODEServer _odeServer; + + private boolean _onHold = false; + + /** Filter accepting directories containing a .odedd file. */ + private static final FileFilter _fileFilter = new FileFilter() { + public boolean accept(File path) { + if (path.isDirectory()) { + return path.listFiles(new FilenameFilter() { + public boolean accept(File dir, String name) { + return name.toLowerCase().equals("deploy.xml"); + } + }).length == 1; + } else + return false; + } + }; + + /** Filter accepting *.deployed files. */ + private static final FileFilter _deployedFilter = new FileFilter() { + public boolean accept(File path) { + return path.isFile() && path.getName().endsWith(".deployed"); + } + }; + + public DeploymentPoller(File deployDir, ODEServer odeServer) { + _odeServer = odeServer; + _deployDir = deployDir; + if (!_deployDir.exists()) + _deployDir.mkdir(); + } + + public void start() { + _poller = new PollingThread(); + _poller.start(); + __log.info("Poller started."); + } + + public void stop() { + _poller.kill(); + _poller = null; + } + + /** + * Scan the directory for new (or removed) files (called mainly from {@link PollingThread}) and calls whoever is in charge of + * the actual deployment (or undeployment). + */ + private void check() { + File[] files = _deployDir.listFiles(_fileFilter); + + // Checking for new deployment directories + for (File file : files) { + File deployXml = new File(file, "deploy.xml"); + File deployedMarker = new File(_deployDir, file.getName() + ".deployed"); + + if (!deployXml.exists()) { + // Skip if deploy.xml is abset + __log.debug("Not deploying " + file + " (missing deploy.xml)"); + } + + if (deployedMarker.exists()) { + continue; + } + + try { + deployedMarker.createNewFile(); + } catch (IOException e1) { + __log.error("Error creating deployed marker file, " + file + " will not be deployed"); + continue; + } + + try { + _odeServer.getProcessStore().undeploy(file); + } catch (Exception ex) { + __log.error("Error undeploying " + file.getName()); + } + + try { + Collection<QName> deployed = _odeServer.getProcessStore().deploy(file); + __log.info("Deployment of artifact " + file.getName() + " successful: " + deployed ); + } catch (Exception e) { + __log.error("Deployment of " + file.getName() + " failed, aborting for now.", e); + } + } + + // Removing deployments that disappeared + File[] deployed = _deployDir.listFiles(_deployedFilter); + for (File file : deployed) { + String pkg = file.getName().substring(0, file.getName().length() - ".deployed".length()); + File deployDir = new File(_deployDir, pkg); + if (!deployDir.exists()) { + Collection<QName> undeployed = _odeServer.getProcessStore().undeploy(deployDir); + file.delete(); + if (undeployed.size() > 0) + __log.info("Successfully undeployed " + pkg); + } + } + } + + /** + * Thread that does the actual polling for new files. + */ + private class PollingThread extends Thread { + private boolean _active = true; + + /** Stop this poller, and block until it terminates. */ + void kill() { + synchronized (this) { + _active = false; + this.notifyAll(); + } + try { + join(); + } catch (InterruptedException ie) { + __log.fatal("Thread unexpectedly interrupted.", ie); + } + } + + public void run() { + try { + while (_active) { + if (!_onHold) + check(); + synchronized (this) { + try { + this.wait(POLL_TIME); + } catch (InterruptedException e) { + } + } + } + } catch (Throwable t) { + __log.fatal("Encountered an unexpected error. Exiting poller...", t); + } + } + } + + public void hold() { + _onHold = true; + } + + public void release() { + _onHold = false; + } + + public void markAsDeployed(File file) { + File deployedMarker = new File(_deployDir, file.getName() + ".deployed"); + try { + deployedMarker.createNewFile(); + } catch (IOException e) { + __log.error("Couldn't create marker file for " + file.getName()); + } + } + + public void markAsUndeployed(File file) { + File deployedMarker = new File(_deployDir, file.getName() + ".deployed"); + deployedMarker.delete(); + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisOperationDispatcher.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisOperationDispatcher.java new file mode 100644 index 0000000..63c52a6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisOperationDispatcher.java
@@ -0,0 +1,130 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import org.apache.axiom.om.OMElement; +import org.apache.axis2.AxisFault; +import org.apache.axis2.addressing.EndpointReference; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisOperation; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.description.HandlerDescription; +import org.apache.axis2.engine.AbstractDispatcher; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.i18n.Messages; +import org.apache.commons.collections.map.MultiKeyMap; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; + +import javax.xml.namespace.QName; + +/** + * Dispatches the service based on the information from the target endpoint URL. + */ +public class ODEAxisOperationDispatcher extends AbstractDispatcher { + + private static MultiKeyMap _elmtToOperation = new MultiKeyMap(); + + /** Field NAME */ + public static final String NAME = "ODEAxisOperationDispatcher"; + private static final Log log = LogFactory.getLog(ODEAxisOperationDispatcher.class); + QName operationName = null; + + public AxisOperation findOperation(AxisService service, MessageContext messageContext) + throws AxisFault { + AxisOperation operation; + + // Start with the wsaAction. We assume wsaAction is the more reliable + // way to identify the operation. + String action = messageContext.getWSAAction(); + if (action != null) { + log.debug(Messages.getMessage("checkingoperation", action)); + operation = service.getOperationByAction(action); + if (operation != null) + return operation; + } + + // Failing that, look at the body of the SOAP message. We expect one + // element that has the same (local) name as the operation. This works + // well for RPC, not always for Doc/Lit. + OMElement bodyFirstChild = messageContext.getEnvelope().getBody().getFirstElement(); + if (bodyFirstChild != null) { + String localName = bodyFirstChild.getLocalName(); + log.debug("Checking for Operation using SOAP message body's first child's local name : " + + localName); + operation = service.getOperation(new QName(localName)); + if (operation != null) { + log.debug("Found operation " + operation); + return operation; + } + + // Of course, the element name most likely uses the suffix + // Request or Response, so look for those and strip them. + int index = localName.lastIndexOf("Request"); + if (index >=0 && index + "Request".length() == localName.length()) { + AxisOperation op = service.getOperation(new QName(localName.substring(0, index))); + if (op != null) return op; + } + index = localName.lastIndexOf("Response"); + if (index >=0 && index + "Response".length() == localName.length()) { + AxisOperation op = service.getOperation(new QName(localName.substring(0, index))); + if (op != null) return op; + } + + // Seems the operation still couldn't be found, let's check our operation => element + // mapping if we can find something (useful for doc/lit when people have the bad idea + // of using a different name for their operation and part element) + String opName = (String) _elmtToOperation.get(service.getName(), localName); + if (opName != null) { + operation = service.getOperation(new QName(opName)); + return operation; + } + } + log.warn("No operation has been found!"); + return null; + } + + /* + * (non-Javadoc) + * @see org.apache.axis2.engine.AbstractDispatcher#findService(org.apache.axis2.context.MessageContext) + */ + public AxisService findService(MessageContext messageContext) throws AxisFault { + // #ODEAxisServiceDispatcher will do that + return null; + } + + public void initDispatcher() { + init(new HandlerDescription(NAME)); + } + + /** + * Associates an operation and the corresponding message part element name. Only + * makes sense for doc/lit services (only one part) for which the operation can't + * easily be guessed from the message element name. + * @param axisServiceName the service name as registered in Axis2 + * @param operationName operation local name + * @param elmtName element local name + */ + public static void addElmtToOpMapping(String axisServiceName, String operationName, String elmtName) { + if (operationName.equals(elmtName)) return; + _elmtToOperation.put(axisServiceName, elmtName, operationName); + } + +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java new file mode 100644 index 0000000..1afded2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisService.java
@@ -0,0 +1,323 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import java.io.File; +import java.io.FileNotFoundException; +import java.io.IOException; +import java.io.InputStream; +import java.net.URI; +import java.net.URL; +import java.util.Collection; +import java.util.Iterator; +import java.util.List; + +import javax.wsdl.Definition; +import javax.wsdl.Operation; +import javax.wsdl.Part; +import javax.wsdl.Port; +import javax.wsdl.Service; +import javax.wsdl.extensions.soap.SOAPAddress; +import javax.xml.namespace.QName; + +import org.apache.axis2.AxisFault; +import org.apache.axis2.description.*; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.engine.MessageReceiver; +import org.apache.axis2.transport.jms.JMSConstants; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.OdeFault; +import org.apache.ode.axis2.util.Axis2UriResolver; +import org.apache.ode.axis2.util.Axis2WSDLLocator; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.utils.AxisUtils; +import org.apache.ws.commons.schema.XmlSchema; +import org.apache.ws.commons.schema.XmlSchemaCollection; +import org.w3c.dom.Element; + +/** + * Implementation of Axis Service used by ODE iapi to enlist itself its service. Allows us to build the service using a + * WSDL definition using our own receiver. + */ +public class ODEAxisService { + + private static final Log LOG = LogFactory.getLog(ODEAxisService.class); + + public static AxisService createService(AxisConfiguration axisConfig, ProcessConf pconf, QName wsdlServiceName, + String portName, String axisServiceName) throws AxisFault { + Definition wsdlDefinition = pconf.getDefinitionForService(wsdlServiceName); + + if (LOG.isDebugEnabled()) { + LOG.debug("Create AxisService:"+" service="+wsdlServiceName+" port="+portName + +" WSDL="+wsdlDefinition.getDocumentBaseURI()+" BPEL="+pconf.getBpelDocument()); + } + + try { + URI baseUri = pconf.getBaseURI().resolve(wsdlDefinition.getDocumentBaseURI()); + InputStream is = baseUri.toURL().openStream(); + WSDL11ToAxisServiceBuilder serviceBuilder = new WSDL11ToAxisPatchedBuilder(is, wsdlServiceName, portName); + serviceBuilder.setBaseUri(baseUri.toString()); + serviceBuilder.setCustomResolver(new Axis2UriResolver()); + serviceBuilder.setCustomWSLD4JResolver(new Axis2WSDLLocator(baseUri)); + serviceBuilder.setServerSide(true); + + AxisService axisService = serviceBuilder.populateService(); + axisService.setParent(axisConfig); + axisService.setName(axisServiceName); + axisService.setWsdlFound(true); + axisService.setCustomWsdl(true); + axisService.setClassLoader(axisConfig.getServiceClassLoader()); + + URL wsdlUrl = null; + for (File file : pconf.getFiles()) { + if (file.getAbsolutePath().indexOf(wsdlDefinition.getDocumentBaseURI()) > 0) + wsdlUrl = file.toURI().toURL(); + } + if (wsdlUrl != null) axisService.setFileName(wsdlUrl); + + // axis2 service configuration + URL service_file = pconf.getBaseURI().resolve(wsdlServiceName.getLocalPart()+".axis2").toURL(); + LOG.debug("Looking for Axis2 service configuration file: "+service_file); + try { + AxisUtils.configureService(axisService, service_file); + } catch (FileNotFoundException except) { + LOG.debug("Axis2 service configuration not found: " + service_file); + } catch (IOException except) { + LOG.warn("Exception while configuring service: " + service_file, except); + } + + // In doc/lit we need to declare a mapping between operations and message element names + // to be able to route properly. + declarePartsElements(wsdlDefinition, wsdlServiceName, axisServiceName, portName); + + Iterator operations = axisService.getOperations(); + ODEMessageReceiver msgReceiver = new ODEMessageReceiver(); + while (operations.hasNext()) { + AxisOperation operation = (AxisOperation) operations.next(); + if (operation.getMessageReceiver() == null) { + operation.setMessageReceiver(msgReceiver); + } + } + + // Set the JMS destination name on the Axis Service + if (isJmsEndpoint(pconf, wsdlServiceName, portName)) { + axisService.addParameter(new Parameter(JMSConstants.DEST_PARAM, + extractJMSDestinationName(axisServiceName, deriveBaseServiceUri(pconf)))); + } + + return axisService; + } catch (Exception e) { + throw AxisFault.makeFault(e); + } + } + + /** + * Extract the JMS destination name that is embedded in the Axis service name. + * @param serviceName the name of the axis service + * @return the corresponding JMS destination name + */ + private static String extractJMSDestinationName(String serviceName, String baseUri) { + String destinationPrefix = "dynamicQueues/"; + int index = serviceName.indexOf(destinationPrefix); + if (index == -1) { + destinationPrefix = "dynamicTopics/"; + index = serviceName.indexOf(destinationPrefix); + } + if (index == -1) { + destinationPrefix = baseUri + "/"; + index = serviceName.indexOf(destinationPrefix); + return (index != -1) ? serviceName.substring(destinationPrefix.length()) : serviceName; + } else { + return serviceName.substring(index); + } + } + + public static AxisService createService(AxisConfiguration axisConfig, QName serviceQName, String port, + String axisName, Definition wsdlDef, MessageReceiver receiver) throws AxisFault { + + WSDL11ToAxisServiceBuilder serviceBuilder = new WSDL11ToAxisServiceBuilder(wsdlDef, serviceQName, port); + AxisService axisService = serviceBuilder.populateService(); + axisService.setName(axisName); + axisService.setWsdlFound(true); + axisService.setClassLoader(axisConfig.getServiceClassLoader()); + Iterator operations = axisService.getOperations(); + while (operations.hasNext()) { + AxisOperation operation = (AxisOperation) operations.next(); + if (operation.getMessageReceiver() == null) { + operation.setMessageReceiver(receiver); + } + } + return axisService; + } + + private static String extractEndpointUri(ProcessConf pconf, QName wsdlServiceName, String portName) + throws AxisFault { + Definition wsdlDefinition = pconf.getDefinitionForService(wsdlServiceName); + String url = null; + Service service = wsdlDefinition.getService(wsdlServiceName); + if (service == null) { + throw new OdeFault("Unable to find service " + wsdlServiceName + " from service WSDL definition " + + wsdlDefinition.getDocumentBaseURI()); + } + Port port = service.getPort(portName); + if (port == null) { + throw new OdeFault("Couldn't find port " + portName + " in definition " + wsdlServiceName); + } + for (Object oext : port.getExtensibilityElements()) { + if (oext instanceof SOAPAddress) + url = ((SOAPAddress) oext).getLocationURI(); + } + if (url == null) { + throw new OdeFault("Could not extract any soap:address from service WSDL definition " + wsdlServiceName + + " (necessary to establish the process target address)!"); + } + return url; + } + + private static boolean isJmsEndpoint(ProcessConf pconf, QName wsdlServiceName, String portName) + throws AxisFault { + String url = extractEndpointUri(pconf, wsdlServiceName, portName); + return url.startsWith("jms:"); + } + + public static String extractServiceName(ProcessConf pconf, QName wsdlServiceName, String portName) + throws AxisFault { + String serviceName = parseURLForService(extractEndpointUri(pconf, wsdlServiceName, portName), deriveBaseServiceUri(pconf)); + if (serviceName == null) { + throw new OdeFault("The soap:address used for service WSDL definition " + wsdlServiceName + " and port " + + portName + " should be of the form http://hostname:port/ode/processes/myProcessEndpointName"); + } + return serviceName; + } + + /** + * Obtain the service name from the request URL. The request URL is expected to use the path "/processes/" under + * which all processes and their services are listed. Returns null if the path does not contain this part. + */ + protected static String parseURLForService(String path, String baseUri) { + // Assume that path is HTTP-based, by default + String servicePrefix = "/processes/"; + // Don't assume JMS-based paths start the same way + if (path.startsWith("jms:/")) { + servicePrefix = "jms:/"; + } + int index = path.indexOf(servicePrefix); + if (-1 != index) { + String service; + + int serviceStart = index + servicePrefix.length(); + if (path.length() > serviceStart + 1) { + service = path.substring(serviceStart); + // Path may contain query string, not interesting for us. + int queryIndex = service.indexOf('?'); + if (queryIndex > 0) { + service = service.substring(0, queryIndex); + } + // Qualify shared JMS names with unique baseUri + if (path.startsWith("jms:/")) { + boolean slashPresent = baseUri.endsWith("/") || service.startsWith("/"); + // service = baseUri + (slashPresent ? "" : "/") + service; // allow successive slashes ("//") in the URI + service = baseUri + "/" + service; + } + return service; + } + } + return null; + } + + private static void declarePartsElements(Definition wsdlDefinition, QName wsdlServiceName, String axisServiceName, + String portName) { + List wsldOps = wsdlDefinition.getService(wsdlServiceName).getPort(portName).getBinding().getPortType() + .getOperations(); + for (Object wsldOp : wsldOps) { + Operation wsdlOp = (Operation) wsldOp; + Collection parts = wsdlOp.getInput().getMessage().getParts().values(); + // More than one part, it's rpc/enc, no mapping needs to be declared + if (parts.size() == 1) { + Part part = (Part) parts.iterator().next(); + // Parts are types, it's rpc/enc, no mapping needs to be declared + if (part.getElementName() != null) + ODEAxisOperationDispatcher.addElmtToOpMapping(axisServiceName, wsdlOp.getName(), part.getElementName() + .getLocalPart()); + } + } + } + + // Axis2 monkey patching to force the usage of the read(element,baseUri) method + // of XmlSchema as the normal read is broken. + public static class WSDL11ToAxisPatchedBuilder extends WSDL11ToAxisServiceBuilder { + public WSDL11ToAxisPatchedBuilder(InputStream in, QName serviceName, String portName) { + super(in, serviceName, portName); + } + public WSDL11ToAxisPatchedBuilder(Definition def, QName serviceName, String portName) { + super(def, serviceName, portName); + } + public WSDL11ToAxisPatchedBuilder(Definition def, QName serviceName, String portName, boolean isAllPorts) { + super(def, serviceName, portName, isAllPorts); + } + public WSDL11ToAxisPatchedBuilder(InputStream in, AxisService service) { + super(in, service); + } + public WSDL11ToAxisPatchedBuilder(InputStream in) { + super(in); + } + + protected XmlSchema getXMLSchema(Element element, String baseUri) { + XmlSchemaCollection schemaCollection = new XmlSchemaCollection(); + if (baseUri != null) { + schemaCollection.setBaseUri(baseUri); + } + return schemaCollection.read(element, baseUri); + } + } + + /* + * Generates a URI of the following form: + * ${deploy_bundleNcName}/${diagram_relativeURL}/${process_relativeURL} + * When a service name (local part only) is qualified (prefixed) with the above, + * it results in a unique identifier that may be used as that service's name. + */ + public static String deriveBaseServiceUri(ProcessConf pconf) { + if (pconf != null) { + StringBuffer baseServiceUri = new StringBuffer(); + String bundleName = pconf.getPackage(); + if (bundleName != null) { + baseServiceUri.append(bundleName).append("/"); + if (pconf.getBpelDocument() != null) { + String bpelDocumentName = pconf.getBpelDocument(); + if (bpelDocumentName.indexOf(".") > 0) { + bpelDocumentName = bpelDocumentName.substring(0, bpelDocumentName.indexOf(".")); + } + baseServiceUri.append(bpelDocumentName).append("/"); + String processName = pconf.getType() != null + ? pconf.getType().getLocalPart() : null; + if (processName != null) { + baseServiceUri.append(processName); + return baseServiceUri.toString(); + } + } + } + + } + return null; + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisServiceDispatcher.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisServiceDispatcher.java new file mode 100644 index 0000000..b672bd0 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisServiceDispatcher.java
@@ -0,0 +1,108 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import org.apache.axiom.om.OMElement; +import org.apache.axis2.AxisFault; +import org.apache.axis2.addressing.EndpointReference; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisOperation; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.description.HandlerDescription; +import org.apache.axis2.engine.AbstractDispatcher; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.i18n.Messages; +import org.apache.commons.collections.map.MultiKeyMap; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; + +import javax.xml.namespace.QName; + +/** + * Dispatches the service based on the information from the target endpoint URL. + */ +public class ODEAxisServiceDispatcher extends AbstractDispatcher { + + /** Field NAME */ + public static final String NAME = "ODEAxisServiceDispatcher"; + private static final Log log = LogFactory.getLog(ODEAxisServiceDispatcher.class); + QName operationName = null; + + public AxisOperation findOperation(AxisService service, MessageContext messageContext) + throws AxisFault { + // #ODEAxisOperationDispatcher will do that + return null; + } + + /* + * (non-Javadoc) + * @see org.apache.axis2.engine.AbstractDispatcher#findService(org.apache.axis2.context.MessageContext) + */ + public AxisService findService(MessageContext messageContext) throws AxisFault { + EndpointReference toEPR = messageContext.getTo(); + + if (toEPR != null) { + log.debug("Checking for Service using target endpoint address : " + toEPR.getAddress()); + + // The only thing we understand if a service name that + // follows /processes/ in the request URL. + String path = parseRequestURLForService(toEPR.getAddress()); + if (path != null) { + AxisConfiguration registry = + messageContext.getConfigurationContext().getAxisConfiguration(); + AxisService service = registry.getService(path); + log.debug("Found service in registry from name " + path + ": " + service); + return service; + } + } + log.warn("No service has been found!"); + return null; + } + + public void initDispatcher() { + init(new HandlerDescription(NAME)); + } + + /** + * Obtain the service name from the request URL. The request URL is + * expected to use the path "/processes/" under which all processes + * and their services are listed. Returns null if the path does not + * contain this part. + */ + protected String parseRequestURLForService(String path) { + int index = path.indexOf("/processes/"); + if (-1 != index) { + String service; + + int serviceStart = index + "/processes/".length(); + if (path.length() > serviceStart + 1) { + service = path.substring(serviceStart); + // Path may contain query string, not interesting for us. + int queryIndex = service.indexOf('?'); + if (queryIndex > 0) { + service = service.substring(0, queryIndex); + } + return service; + } + } + return null; + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisServlet.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisServlet.java new file mode 100644 index 0000000..ab987a6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEAxisServlet.java
@@ -0,0 +1,82 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import javax.servlet.ServletConfig; +import javax.servlet.ServletException; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; + +import org.apache.axis2.AxisFault; +import org.apache.axis2.transport.http.AxisServlet; +import org.apache.ode.axis2.ODEServer; +import org.apache.ode.axis2.service.DeploymentBrowser; + +import java.io.*; + +/** + * Overrides standard AxisServlet to handle our service configurations and + * deployment ourselves. + */ +public class ODEAxisServlet extends AxisServlet { + private static final long serialVersionUID = 4898351526757154917L; + + private ODEServer _odeServer; + private DeploymentBrowser _browser; + + /** + * Initialize the Axis configuration context + * + * @param config Servlet configuration + * @throws ServletException + */ + public void init(ServletConfig config) throws ServletException { + super.init(config); + _odeServer = createODEServer(); + _odeServer.init(config, axisConfiguration); + _browser = new DeploymentBrowser(_odeServer.getProcessStore(), axisConfiguration, _odeServer.getAppRoot()); + } + + protected void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { + if (!_browser.doFilter(request, response)) super.doGet(request, response); + } + + + public void stop() throws AxisFault { + super.stop(); + _odeServer.shutDown(); + } + + protected ODEServer createODEServer() { + return new ODEServer(); + } + + /** + * Returns the ODEServer instance which has been created by the servlet. + * Must be called after init() has been called by the servlet engine + * or null will be returned. + * @return the ODEServer instance being used by the servlet or null if + * init() has not yet been called by the servlet engine + */ + public ODEServer getODEServer(){ + return _odeServer; + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEMessageReceiver.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEMessageReceiver.java new file mode 100644 index 0000000..a23346f --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/ODEMessageReceiver.java
@@ -0,0 +1,89 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisOperation; +import org.apache.axis2.engine.AxisEngine; +import org.apache.axis2.receivers.AbstractMessageReceiver; +import org.apache.axis2.util.Utils; +import org.apache.axis2.wsdl.WSDLConstants; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.ODEService; + +/** + * Receives messages forwarded by Axis. + */ +public class ODEMessageReceiver extends AbstractMessageReceiver { + + private static final Log __log = LogFactory.getLog(ODEMessageReceiver.class); + + private ODEService _service; + + public final void invokeBusinessLogic(final MessageContext msgContext) throws AxisFault { + if (hasResponse(msgContext.getAxisOperation())) { + if (__log.isDebugEnabled()) + __log.debug("Received request message for " + msgContext.getAxisService().getName() + "." + + msgContext.getAxisOperation().getName()); + // Client is expecting a response, running in the same thread + MessageContext outMsgContext = Utils.createOutMessageContext(msgContext); + outMsgContext.getOperationContext().addMessageContext(outMsgContext); + invokeBusinessLogic(msgContext, outMsgContext); + if (__log.isDebugEnabled()) { + __log.debug("Reply for " + msgContext.getAxisService().getName() + "." + + msgContext.getAxisOperation().getName()); + __log.debug("Reply message " + outMsgContext.getEnvelope()); + } + AxisEngine.send(outMsgContext); + } else { + if (__log.isDebugEnabled()) + __log.debug("Received one-way message for " + msgContext.getAxisService().getName() + "." + + msgContext.getAxisOperation().getName()); + invokeBusinessLogic(msgContext, null); + } + } + + private void invokeBusinessLogic(MessageContext msgContext, MessageContext outMsgContext) + throws AxisFault { + _service.onAxisMessageExchange(msgContext, outMsgContext, getSOAPFactory(msgContext)); + + } + + public void setService(ODEService service) { + _service = service; + } + + private boolean hasResponse(AxisOperation op) { + switch (op.getAxisSpecificMEPConstant()) { + case WSDLConstants.MEP_CONSTANT_IN_OUT: + return true; + case WSDLConstants.MEP_CONSTANT_OUT_ONLY: + return true; + case WSDLConstants.MEP_CONSTANT_OUT_OPTIONAL_IN: + return true; + case WSDLConstants.MEP_CONSTANT_ROBUST_OUT_ONLY: + return true; + default: + return false; + } + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/SessionInHandler.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/SessionInHandler.java new file mode 100644 index 0000000..756bca4 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/SessionInHandler.java
@@ -0,0 +1,106 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import org.apache.axiom.om.OMElement; +import org.apache.axiom.soap.SOAPHeader; +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.handlers.AbstractHandler; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.utils.Namespaces; +import org.w3c.dom.Document; +import org.w3c.dom.Element; + +import javax.xml.namespace.QName; + +/** + * An incoming handler adding session id information in the message + * context. + */ +public class SessionInHandler extends AbstractHandler { + private static final long serialVersionUID = -806564877582696569L; + + private static final Log __log = LogFactory.getLog(SessionInHandler.class); + + public InvocationResponse invoke(MessageContext messageContext) throws AxisFault { + SOAPHeader header = messageContext.getEnvelope().getHeader(); + if (header != null) { + if (__log.isDebugEnabled()) + __log.debug("Found a header in incoming message, checking if there are endpoints there."); + // Checking if a session identifier has been provided for a stateful endpoint + OMElement wsaToSession = header.getFirstChildWithName(new QName(Namespaces.INTALIO_SESSION_NS, "session")); + if (wsaToSession != null) { + // Building an endpoint supposed to target the right instance + Document doc = DOMUtils.newDocument(); + Element serviceEpr = doc.createElementNS(Namespaces.WS_ADDRESSING_NS, "EndpointReference"); + Element sessionId = doc.createElementNS(Namespaces.INTALIO_SESSION_NS, "session"); + doc.appendChild(serviceEpr); + serviceEpr.appendChild(sessionId); + sessionId.setTextContent(wsaToSession.getText()); + if (__log.isDebugEnabled()) + __log.debug("A TO endpoint has been found in the header with session: " + wsaToSession.getText()); + + // Did the client provide an address too? + OMElement wsaToAddress = header.getFirstChildWithName(new QName(Namespaces.WS_ADDRESSING_NS, "To")); + if (wsaToAddress != null) { + Element addressElmt = doc.createElementNS(Namespaces.WS_ADDRESSING_NS, "Address"); + addressElmt.setTextContent(wsaToAddress.getText()); + serviceEpr.appendChild(addressElmt); + } + if (__log.isDebugEnabled()) + __log.debug("Constructed a TO endpoint: " + DOMUtils.domToString(serviceEpr)); + messageContext.setProperty("targetSessionEndpoint", serviceEpr); + } + + // Seeing if there's a callback, in case our client would be stateful as well + OMElement callback = header.getFirstChildWithName(new QName(Namespaces.INTALIO_SESSION_NS, "callback")); + if (callback != null) { + OMElement callbackSession = callback.getFirstChildWithName(new QName(Namespaces.INTALIO_SESSION_NS, "session")); + if (callbackSession != null) { + // Building an endpoint that represents our client (we're supposed to call him later on) + Document doc = DOMUtils.newDocument(); + Element serviceEpr = doc.createElementNS(Namespaces.WS_ADDRESSING_NS, "EndpointReference"); + Element sessionId = doc.createElementNS(Namespaces.INTALIO_SESSION_NS, "session"); + doc.appendChild(serviceEpr); + serviceEpr.appendChild(sessionId); + sessionId.setTextContent(callbackSession.getText()); + if (__log.isDebugEnabled()) + __log.debug("A CALLBACK endpoint has been found in the header with session: " + callbackSession.getText()); + + // Did the client give his address as well? + OMElement wsaToAddress = callback.getFirstChildWithName(new QName(Namespaces.WS_ADDRESSING_NS, "Address")); + if (wsaToAddress != null) { + Element addressElmt = doc.createElementNS(Namespaces.WS_ADDRESSING_NS, "Address"); + addressElmt.setTextContent(wsaToAddress.getText()); + serviceEpr.appendChild(addressElmt); + } + if (__log.isDebugEnabled()) + __log.debug("Constructed a CALLBACK endpoint: " + DOMUtils.domToString(serviceEpr)); + messageContext.setProperty("callbackSessionEndpoint", serviceEpr); + } + } + } + return InvocationResponse.CONTINUE; + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/SessionOutHandler.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/SessionOutHandler.java new file mode 100644 index 0000000..8c918b9 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/hooks/SessionOutHandler.java
@@ -0,0 +1,141 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.hooks; + +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMNamespace; +import org.apache.axiom.soap.SOAPFactory; +import org.apache.axiom.soap.SOAPHeader; +import org.apache.axiom.soap.SOAPHeaderBlock; +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.handlers.AbstractHandler; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.bpel.epr.EndpointFactory; +import org.apache.ode.bpel.epr.MutableEndpoint; +import org.apache.ode.bpel.epr.WSAEndpoint; +import org.apache.ode.bpel.iapi.EndpointReference; +import org.apache.ode.utils.Namespaces; +import org.apache.ode.axis2.Properties; + +/** + * An outgoing handler adding session id information in the message + * context. + */ +public class SessionOutHandler extends AbstractHandler { + + private static final long serialVersionUID = 1L; + private static final Log __log = LogFactory.getLog(SessionOutHandler.class); + + + public InvocationResponse invoke(MessageContext messageContext) throws AxisFault { + // Skip this handler if ask to do so + Boolean shouldSendWSAddrHeaders = ((Boolean)messageContext.getProperty(Properties.PROP_SEND_WS_ADDRESSING_HEADERS)); + if(shouldSendWSAddrHeaders!=null && !shouldSendWSAddrHeaders.booleanValue()){ + if(__log.isDebugEnabled()) __log.debug("WS-Adressing Headers skipped"); + return InvocationResponse.CONTINUE; + } + + EndpointReference otargetSession = (EndpointReference) messageContext.getProperty("targetSessionEndpoint"); + EndpointReference ocallbackSession = (EndpointReference) messageContext.getProperty("callbackSessionEndpoint"); + if (otargetSession == null) + otargetSession = (EndpointReference) messageContext.getOptions().getProperty("targetSessionEndpoint"); + if (ocallbackSession == null) + ocallbackSession = (EndpointReference) messageContext.getOptions().getProperty("callbackSessionEndpoint"); + + if (otargetSession != null || ocallbackSession != null) { + SOAPHeader header = messageContext.getEnvelope().getHeader(); + SOAPFactory factory = (SOAPFactory) messageContext.getEnvelope().getOMFactory(); + OMNamespace intalioSessNS = factory.createOMNamespace(Namespaces.INTALIO_SESSION_NS, "intalio"); + OMNamespace odeSessNS = factory.createOMNamespace(Namespaces.ODE_SESSION_NS, "odesession"); + OMNamespace wsAddrNS = factory.createOMNamespace(Namespaces.WS_ADDRESSING_NS, "addr"); + if (header == null) { + header = factory.createSOAPHeader(messageContext.getEnvelope()); + } + + if (otargetSession != null && otargetSession instanceof MutableEndpoint) { + + WSAEndpoint targetEpr = EndpointFactory.convertToWSA((MutableEndpoint) otargetSession); + + OMElement to = factory.createSOAPHeaderBlock("To", wsAddrNS); + header.addChild(to); + to.setText(targetEpr.getUrl()); + + String action = messageContext.getSoapAction(); + OMElement wsaAction = factory.createSOAPHeaderBlock("Action", wsAddrNS); + header.addChild(wsaAction); + wsaAction.setText(action); + + // we only set the ReplyTo and MessageID headers if doing Request-Response + org.apache.axis2.addressing.EndpointReference replyToEpr = messageContext.getReplyTo(); + if (replyToEpr != null) { + OMElement replyTo = factory.createSOAPHeaderBlock("ReplyTo", wsAddrNS); + OMElement address = factory.createOMElement("Address", wsAddrNS); + replyTo.addChild(address); + header.addChild(replyTo); + address.setText(replyToEpr.getAddress()); + + String messageId = messageContext.getMessageID(); + OMElement messageIdElem = factory.createSOAPHeaderBlock("MessageID", wsAddrNS); + header.addChild(messageIdElem); + messageIdElem.setText(messageId); + } + + if (targetEpr.getSessionId() != null) { + OMElement session = factory.createSOAPHeaderBlock("session", odeSessNS); + header.addChild(session); + session.setText(targetEpr.getSessionId()); + // same for intalio + session = factory.createSOAPHeaderBlock("session", intalioSessNS); + header.addChild(session); + session.setText(targetEpr.getSessionId()); + } + __log.debug("Sending stateful TO epr in message header using session " + targetEpr.getSessionId()); + } + + if (ocallbackSession != null && ocallbackSession instanceof MutableEndpoint) { + WSAEndpoint callbackEpr = EndpointFactory.convertToWSA((MutableEndpoint) ocallbackSession); + OMElement odeCallback = factory.createSOAPHeaderBlock("callback", odeSessNS); + OMElement intCallback = factory.createSOAPHeaderBlock("callback", intalioSessNS); + header.addChild(odeCallback); + header.addChild(intCallback); + OMElement address = factory.createOMElement("Address", wsAddrNS); + odeCallback.addChild(address); + intCallback.addChild(address.cloneOMElement()); + address.setText(callbackEpr.getUrl()); + if (callbackEpr.getSessionId() != null) { + OMElement odeSession = factory.createOMElement("session", odeSessNS); + OMElement intSession = factory.createOMElement("session", intalioSessNS); + odeSession.setText(callbackEpr.getSessionId()); + intSession.setText(callbackEpr.getSessionId()); + odeCallback.addChild(odeSession); + intCallback.addChild(intSession); + } + __log.debug("Sending stateful FROM epr in message header using session " + callbackEpr.getSessionId()); + } + + __log.debug("Sending a message containing wsa endpoints in headers for session passing."); + __log.debug(messageContext.getEnvelope().toString()); + + } + return InvocationResponse.CONTINUE; + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpBindingValidator.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpBindingValidator.java new file mode 100644 index 0000000..b58714c --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpBindingValidator.java
@@ -0,0 +1,151 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.httpbinding; + +import org.apache.commons.httpclient.methods.PostMethod; +import org.apache.commons.logging.LogFactory; +import org.apache.commons.logging.Log; +import org.apache.commons.lang.StringUtils; +import org.apache.ode.utils.wsdl.WsdlUtils; + +import javax.wsdl.Binding; +import javax.wsdl.BindingInput; +import javax.wsdl.BindingOperation; +import javax.wsdl.BindingOutput; +import javax.wsdl.extensions.http.HTTPOperation; +import javax.wsdl.extensions.mime.MIMEContent; +import java.util.Map; +import java.util.Set; +import java.util.Iterator; +import java.util.regex.Pattern; +import java.util.regex.Matcher; + +/** + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public class HttpBindingValidator { + + private static final Messages httpMsgs = Messages.getMessages(Messages.class); + private static final org.apache.ode.utils.wsdl.Messages wsdlMsgs = Messages.getMessages(org.apache.ode.utils.wsdl.Messages.class); + + protected Binding binding; + + public HttpBindingValidator(Binding binding) { + this.binding = binding; + if (!WsdlUtils.useHTTPBinding(binding)) + throw new IllegalArgumentException(httpMsgs.msgHttpBindingNotUsed(binding)); + } + + public void validate() throws IllegalArgumentException { + validatePort(); + } + + protected void validatePort() { + // Validate the given HttpBinding + for (int i = 0; i < binding.getBindingOperations().size(); i++) { + BindingOperation bindingOperation = (BindingOperation) binding.getBindingOperations().get(i); + validateOperation(bindingOperation); + } + } + + protected void validateOperation(BindingOperation bindingOperation) { + String verb = WsdlUtils.resolveVerb(binding, bindingOperation); + if (verb == null) { + throw new IllegalArgumentException(httpMsgs.msgMissingVerb(binding, bindingOperation)); + } + if (!"GET".equalsIgnoreCase(verb) + && !"DELETE".equalsIgnoreCase(verb) + && !"PUT".equalsIgnoreCase(verb) + && !"POST".equalsIgnoreCase(verb)) { + throw new IllegalArgumentException(httpMsgs.msgUnsupportedHttpMethod(binding, verb)); + } + + + BindingOutput output = bindingOperation.getBindingOutput(); + MIMEContent outputContent = WsdlUtils.getMimeContent(output.getExtensibilityElements()); + if (outputContent != null) { + if (StringUtils.isEmpty(outputContent.getType())) { + throw new IllegalArgumentException(httpMsgs.msgEmptyContentType(binding, bindingOperation)); + } + } + + BindingInput input = bindingOperation.getBindingInput(); + + // multipartRelated not supported + if (WsdlUtils.useMimeMultipartRelated(input)) { + throw new IllegalArgumentException(httpMsgs.msgMimeMultipartRelatedUnsupported(binding, bindingOperation)); + } + + // only 2 content-types supported + MIMEContent inputContent = WsdlUtils.getMimeContent(input.getExtensibilityElements()); + if (inputContent != null) { + String inputContentType = inputContent.getType(); + if (StringUtils.isEmpty(inputContentType)) { + throw new IllegalArgumentException(httpMsgs.msgEmptyContentType(binding, bindingOperation)); + } + } + + if (WsdlUtils.useUrlReplacement(input)) { + validateUrlReplacement(bindingOperation); + } + + // other specific validations + if ("GET".equalsIgnoreCase(verb) || "DELETE".equalsIgnoreCase(verb)) { + validateGetOrDelete(bindingOperation); + } + } + + protected void validateGetOrDelete(BindingOperation bindingOperation) { + BindingInput input = bindingOperation.getBindingInput(); + + if (!WsdlUtils.useUrlEncoded(input) && !WsdlUtils.useUrlReplacement(input)) { + throw new IllegalArgumentException(httpMsgs.msgOnlySupportsUrlEncodedAndUrlreplacement(binding, bindingOperation)); + } + + // another test would be to check that all parts use a simple type + } + + protected void validateUrlReplacement(BindingOperation bindingOperation) { + HTTPOperation httpOperation = (HTTPOperation) WsdlUtils.getOperationExtension(bindingOperation); + BindingInput input = bindingOperation.getBindingInput(); + Map inputParts = bindingOperation.getOperation().getInput().getMessage().getParts(); + + // validate the url pattern + if (WsdlUtils.useUrlReplacement(input)) { + String locationUri = httpOperation.getLocationURI(); + Set partNames = inputParts.keySet(); + // Must be *exactly* one search pattern for each message part. + for (Iterator it = partNames.iterator(); it.hasNext();) { + String name = (String) it.next(); + Pattern p = Pattern.compile(".*(\\(" + name + "\\)).*"); + Matcher m = p.matcher(locationUri); + // WSLD spec requires that all message parts must be exactly once in the url pattern. + // However ODE relaxes this. + // The only test is to make sure a part is not mentioned more than once + if (m.matches() && locationUri.split("(\\(" + name + "\\))", -1).length != 2) { + throw new IllegalArgumentException(httpMsgs.msgInvalidURIPattern(binding, bindingOperation, locationUri)); + } + } + } + + // another test would be to check that all parts use a simple type + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java new file mode 100644 index 0000000..2197b37 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpExternalService.java
@@ -0,0 +1,369 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.httpbinding; + +import org.apache.commons.httpclient.HttpClient; +import org.apache.commons.httpclient.HttpMethod; +import org.apache.commons.httpclient.MultiThreadedHttpConnectionManager; +import org.apache.commons.httpclient.URIException; +import org.apache.commons.httpclient.params.HttpParams; +import org.apache.commons.httpclient.params.DefaultHttpParams; +import org.apache.commons.httpclient.params.HostParams; +import org.apache.commons.httpclient.params.HttpClientParams; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.ExternalService; +import org.apache.ode.axis2.ODEService; +import org.apache.ode.axis2.Properties; +import org.apache.ode.bpel.epr.EndpointFactory; +import org.apache.ode.bpel.epr.WSAEndpoint; +import org.apache.ode.bpel.iapi.BpelServer; +import org.apache.ode.bpel.iapi.EndpointReference; +import org.apache.ode.bpel.iapi.Message; +import org.apache.ode.bpel.iapi.MessageExchange; +import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.bpel.iapi.Scheduler; +import org.apache.ode.utils.DOMUtils; +import static org.apache.ode.utils.http.StatusCode.*; +import org.apache.ode.utils.wsdl.Messages; +import org.apache.ode.utils.wsdl.WsdlUtils; +import org.w3c.dom.Element; + +import javax.wsdl.Binding; +import javax.wsdl.Definition; +import javax.wsdl.Operation; +import javax.wsdl.Port; +import javax.wsdl.Service; +import javax.xml.namespace.QName; +import java.io.IOException; +import java.io.UnsupportedEncodingException; +import java.util.Map; +import java.util.Collections; +import java.util.concurrent.Callable; +import java.util.concurrent.ExecutorService; + + +/** + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public class HttpExternalService implements ExternalService { + + private static final Log log = LogFactory.getLog(HttpExternalService.class); + private static final Messages msgs = Messages.getMessages(Messages.class); + + private MultiThreadedHttpConnectionManager connections; + + protected ExecutorService executorService; + protected Scheduler scheduler; + protected BpelServer server; + protected ProcessConf pconf; + protected QName serviceName; + protected String portName; + protected WSAEndpoint endpointReference; + + protected HttpMethodConverter httpMethodConverter; + + protected Binding portBinding; + + public HttpExternalService(ProcessConf pconf, QName serviceName, String portName, ExecutorService executorService, Scheduler scheduler, BpelServer server) { + if (log.isDebugEnabled()) + log.debug("new HTTP External service, service name=[" + serviceName + "]; port name=[" + portName + "]"); + this.portName = portName; + this.serviceName = serviceName; + this.executorService = executorService; + this.scheduler = scheduler; + this.server = server; + this.pconf = pconf; + Definition definition = pconf.getDefinitionForService(serviceName); + Service serviceDef = definition.getService(serviceName); + if (serviceDef == null) + throw new IllegalArgumentException(msgs.msgServiceDefinitionNotFound(serviceName)); + Port port = serviceDef.getPort(portName); + if (port == null) + throw new IllegalArgumentException(msgs.msgPortDefinitionNotFound(serviceName, portName)); + portBinding = port.getBinding(); + if (portBinding == null) + throw new IllegalArgumentException(msgs.msgBindingNotFound(portName)); + + // validate the http binding + if (!WsdlUtils.useHTTPBinding(port)) { + throw new IllegalArgumentException(msgs.msgNoHTTPBindingForPort(portName)); + } + // throws an IllegalArgumentException if not valid + new HttpBindingValidator(this.portBinding).validate(); + + // initial endpoint reference + Element eprElmt = ODEService.genEPRfromWSDL(definition, serviceName, portName); + if (eprElmt == null) + throw new IllegalArgumentException(msgs.msgPortDefinitionNotFound(serviceName, portName)); + endpointReference = EndpointFactory.convertToWSA(ODEService.createServiceRef(eprElmt)); + + httpMethodConverter = new HttpMethodConverter(definition, serviceName, portName); + connections = new MultiThreadedHttpConnectionManager(); + } + + public String getPortName() { + return portName; + } + + public QName getServiceName() { + return serviceName; + } + + public void close() { + connections.shutdown(); + } + + public EndpointReference getInitialEndpointReference() { + return endpointReference; + } + + public void invoke(PartnerRoleMessageExchange odeMex) { + if (log.isDebugEnabled()) log.debug("Preparing " + getClass().getSimpleName() + " invocation..."); + try { + // note: don't make this map an instance attribute, so we always get the latest version + final Map<String, String> properties = pconf.getEndpointProperties(endpointReference); + final HttpParams params = Properties.HttpClient.translate(properties); + + // build the http method + final HttpMethod method = httpMethodConverter.createHttpRequest(odeMex, params); + + // create a client + HttpClient client = new HttpClient(connections); + + + // configure the client (proxy, security, etc) + Element authenticatePart = DOMUtils.findChildByName(odeMex.getRequest().getMessage(), new QName(null, "WWW-Authenticate")); + HttpHelper.configure(client, method.getURI(), authenticatePart, params); + + // this callable encapsulates the http method execution and the process of the response + final Callable executionCallable; + + // execute it + boolean isTwoWay = odeMex.getMessageExchangePattern() == MessageExchange.MessageExchangePattern.REQUEST_RESPONSE; + if (isTwoWay) { + // two way + executionCallable = new HttpExternalService.TwoWayCallable(client, method, odeMex.getMessageExchangeId(), odeMex.getOperation()); + scheduler.registerSynchronizer(new Scheduler.Synchronizer() { + public void afterCompletion(boolean success) { + // If the TX is rolled back, then we don't send the request. + if (!success) return; + // The invocation must happen in a separate thread + executorService.submit(executionCallable); + } + + public void beforeCompletion() { + } + }); + odeMex.replyAsync(); + } else { + // one way, just execute and forget + executionCallable = new HttpExternalService.OneWayCallable(client, method, odeMex.getMessageExchangeId(), odeMex.getOperation()); + executorService.submit(executionCallable); + odeMex.replyOneWayOk(); + } + } catch (UnsupportedEncodingException e) { + String errmsg = "The returned HTTP encoding isn't supported " + odeMex; + log.error("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + odeMex.getOperationName() + "] " + errmsg, e); + odeMex.replyWithFailure(MessageExchange.FailureType.FORMAT_ERROR, errmsg, null); + } catch (URIException e) { + String errmsg = "Error sending message to " + getClass().getSimpleName() + " for ODE mex " + odeMex; + log.error("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + odeMex.getOperationName() + "] " + errmsg, e); + odeMex.replyWithFailure(MessageExchange.FailureType.FORMAT_ERROR, errmsg, null); + } catch (Exception e) { + String errmsg = "Unknown HTTP call error for ODE mex " + odeMex; + log.error("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + odeMex.getOperationName() + "] " + errmsg, e); + odeMex.replyWithFailure(MessageExchange.FailureType.OTHER, errmsg, null); + } + } + + private class OneWayCallable implements Callable<Void> { + HttpMethod method; + String mexId; + Operation operation; + HttpClient client; + + public OneWayCallable(HttpClient client, HttpMethod method, String mexId, Operation operation) { + this.method = method; + this.mexId = mexId; + this.operation = operation; + this.client = client; + } + + public Void call() throws Exception { + try { + // simply execute the http method + if (log.isDebugEnabled()) { + log.debug("Executing HTTP Request : " + method.getName() + " " + method.getURI()); + log.debug(HttpHelper.requestToString(method)); + } + + final int statusCode = client.executeMethod(method); + // invoke getResponseBody to force the loading of the body + // Actually the processResponse may happen in a separate thread and + // as a result the connection might be closed before the body processing (see the finally clause below). + byte[] responseBody = method.getResponseBody(); + // ... and process the response + if (log.isDebugEnabled()) { + log.debug("Received response for MEX " + mexId); + log.debug(HttpHelper.responseToString(method)); + } + processResponse(statusCode); + } catch (final IOException e) { + // ODE MEX needs to be invoked in a TX. + try { + scheduler.execIsolatedTransaction(new Callable<Void>() { + public Void call() throws Exception { + PartnerRoleMessageExchange odeMex = (PartnerRoleMessageExchange) server.getEngine().getMessageExchange(mexId); + String errmsg = "Unable to execute http request : " + e.getMessage(); + log.error("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] " + errmsg, e); + odeMex.replyWithFailure(MessageExchange.FailureType.COMMUNICATION_ERROR, errmsg, null); + return null; + } + }); + } catch (Exception e1) { + String errmsg = "[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] Error executing reply transaction; reply will be lost."; + log.error(errmsg, e); + } + } finally { + method.releaseConnection(); + } + return null; + } + + public void processResponse(int statusCode) { + // a one-way message does not care about the response + try { + // log the URI since the engine may have moved on while this One Way request was executing + if (statusCode >= 400) { + log.error("OneWay HTTP Request failed, Status-Line: " + method.getStatusLine() + " for " + method.getURI()); + } else { + if (log.isDebugEnabled()) + log.debug("OneWay HTTP Request, Status-Line: " + method.getStatusLine() + " for " + method.getURI()); + } + } catch (Exception e) { + String errmsg = "[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] Exception occured while processing the HTTP response of a one-way request: " + e.getMessage(); + log.error(errmsg, e); + } + } + } + + private class TwoWayCallable extends OneWayCallable { + public TwoWayCallable(org.apache.commons.httpclient.HttpClient client, HttpMethod method, String mexId, Operation operation) { + super(client, method, mexId, operation); + } + + public void processResponse(final int statusCode) { + // ODE MEX needs to be invoked in a TX. + try { + scheduler.execIsolatedTransaction(new Callable<Void>() { + public Void call() throws Exception { + try { + if (statusCode >= 200 && statusCode < 300) { + _2xx_success(); + } else if (statusCode >= 300 && statusCode < 400) { + _3xx_redirection(); + } else if (statusCode >= 400 && statusCode < 600) { + _4xx_5xx_error(); + } else { + unmanagedStatus(); + } + } catch (Exception e) { + replyWithFailure("Exception occured while processing the HTTP response of a two-way request. mexId= " + mexId, e); + } + return null; + } + }); + } catch (Exception transactionException) { + String errmsg = "[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] Error executing reply transaction; reply will be lost."; + log.error(errmsg, transactionException); + } + } + + private void unmanagedStatus() throws Exception { + replyWithFailure("Unmanaged Status Code! Status-Line: " + method.getStatusLine() + " for " + method.getURI()); + } + + private void _4xx_5xx_error() throws Exception { + int status = method.getStatusCode(); + if (HttpHelper.isFaultOrFailure(status) > 0) { + // reply with a fault, meaning the request should not be repeated + replyWithFault(); + } else { + // reply with a failure, meaning the request might be repeated later + replyWithFailure("HTTP Status-Line: " + method.getStatusLine() + " for " + method.getURI()); + } + } + + private void _3xx_redirection() throws Exception { + // redirections should be handled transparently by http-client + replyWithFailure("Redirections disabled! HTTP Status-Line: " + method.getStatusLine() + " for " + method.getURI()); + } + + private void _2xx_success() throws Exception { + PartnerRoleMessageExchange odeMex = (PartnerRoleMessageExchange) server.getEngine().getMessageExchange(mexId); + if (log.isDebugEnabled()) + log.debug("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] HTTP Status-Line: " + method.getStatusLine() + " for " + method.getURI()); + if (log.isDebugEnabled()) log.debug("Received response for MEX " + odeMex); + + Operation opDef = odeMex.getOperation(); + + // this is the message to populate and send to ODE + QName outputMsgName = odeMex.getOperation().getOutput().getMessage().getQName(); + Message odeResponse = odeMex.createMessage(outputMsgName); + + httpMethodConverter.parseHttpResponse(odeResponse, method, opDef); + + // finally send the message + try { + if (log.isInfoEnabled()) + log.info("Response: " + (odeResponse.getMessage() != null ? DOMUtils.domToString(odeResponse.getMessage()) : "empty")); + odeMex.reply(odeResponse); + } catch (Exception ex) { + replyWithFailure("Unable to process response: " + ex.getMessage(), ex); + } + } + + void replyWithFault() { + PartnerRoleMessageExchange odeMex = (PartnerRoleMessageExchange) server.getEngine().getMessageExchange(mexId); + Object[] fault = httpMethodConverter.parseFault(odeMex, method); + Message response = (Message) fault[1]; + QName faultName = (QName) fault[0]; + + // finally send the fault. We did it! + if (log.isWarnEnabled()) + log.warn("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] Fault response: faultName=" + faultName + " faultType=" + response.getType() + "\n" + DOMUtils.domToString(response.getMessage())); + + odeMex.replyWithFault(faultName, response); + } + + + void replyWithFailure(String errmsg) { + replyWithFailure(errmsg, null); + } + + void replyWithFailure(String errmsg, Throwable t) { + log.error("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + operation.getName() + "] " + errmsg, t); + PartnerRoleMessageExchange odeMex = (PartnerRoleMessageExchange) server.getEngine().getMessageExchange(mexId); + odeMex.replyWithFailure(MessageExchange.FailureType.OTHER, errmsg, HttpHelper.prepareDetailsElement(method)); + } + } +} \ No newline at end of file
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpHelper.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpHelper.java new file mode 100644 index 0000000..d648e6c --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpHelper.java
@@ -0,0 +1,374 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.httpbinding; + +import org.apache.axis2.transport.http.HttpTransportProperties; +import org.apache.commons.httpclient.HostConfiguration; +import org.apache.commons.httpclient.HttpMethod; +import org.apache.commons.httpclient.HttpState; +import org.apache.commons.httpclient.URI; +import org.apache.commons.httpclient.URIException; +import org.apache.commons.httpclient.StatusLine; +import org.apache.commons.httpclient.HttpException; +import org.apache.commons.httpclient.Header; +import org.apache.commons.httpclient.HttpClient; +import org.apache.commons.httpclient.UsernamePasswordCredentials; +import org.apache.commons.httpclient.auth.AuthScope; +import org.apache.commons.httpclient.methods.EntityEnclosingMethod; +import org.apache.commons.httpclient.methods.StringRequestEntity; +import org.apache.commons.httpclient.params.HttpParams; +import org.apache.commons.httpclient.params.HostParams; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.commons.lang.StringUtils; +import org.apache.ode.axis2.Properties; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.utils.http.HttpUtils; +import static org.apache.ode.utils.http.StatusCode.*; +import org.apache.ode.bpel.iapi.Message; +import org.w3c.dom.Element; +import org.w3c.dom.Document; + +import javax.xml.namespace.QName; +import java.io.IOException; +import java.util.regex.Matcher; +import java.util.regex.Pattern; +import java.util.Collections; + +public class HttpHelper { + + private static final Log log = LogFactory.getLog(HttpHelper.class); + + + public static void configure(HttpClient client, URI targetURI, Element authPart, HttpParams params) throws URIException { + if (log.isDebugEnabled()) log.debug("Configuring http client..."); + + /* Do not forget to wire params so that endpoint properties are passed around + Down the road, when the request will be executed, the hierarchy of parameters will be the following: + (-> means "is parent of") + default params -> params from endpoint properties -> HttpClient -> HostConfig -> Method + This wiring is done by HttpClient. + */ + client.getParams().setDefaults(params); + + // Here we make sure HttpClient will not handle the default headers. + // Actually HttpClient *appends* default headers while we want them to be ignored if the process assign them + client.getParams().setParameter(HostParams.DEFAULT_HEADERS, Collections.EMPTY_LIST); + + // proxy configuration + if (ProxyConf.isProxyEnabled(params, targetURI.getHost())) { + if (log.isDebugEnabled()) log.debug("ProxyConf"); + ProxyConf.configure(client.getHostConfiguration(), client.getState(), (HttpTransportProperties.ProxyProperties) params.getParameter(Properties.PROP_HTTP_PROXY_PREFIX)); + } + + // security + // ... + + // authentication + /* + We're expecting the following element: + <xs:complexType name="credentialType"> + <xs:attribute name="scheme" type="xs:string" default="server-decide" /> + <xs:attribute name="username" type="xs:string" /> + <xs:attribute name="password" type="xs:string" /> + </xs:complexType> + <xs:element type="rest_connector:credentialType" name="credentials" /> + */ + if (authPart != null) { + // the part must be defined with an element, so take the fist child + Element credentialsElement = DOMUtils.getFirstChildElement(authPart); + if (credentialsElement != null && credentialsElement.getAttributes().getLength() != 0) { + String scheme = DOMUtils.getAttribute(credentialsElement, "scheme"); + String username = DOMUtils.getAttribute(credentialsElement, "username"); + String password = DOMUtils.getAttribute(credentialsElement, "password"); + + if (scheme != null + && !"server-decides".equalsIgnoreCase(scheme) + && !"basic".equalsIgnoreCase(scheme) + && !"digest".equalsIgnoreCase(scheme)) { + throw new IllegalArgumentException("Unknown Authentication scheme: [" + scheme + "] Accepted values are: Basic, Digest, Server-Decides"); + } else { + if(log.isDebugEnabled()) log.debug("credentials provided"); + client.getState().setCredentials( + new AuthScope(targetURI.getHost(), targetURI.getPort(), AuthScope.ANY_REALM, scheme), + new UsernamePasswordCredentials(username, password)); + // save one round trip if basic + client.getParams().setAuthenticationPreemptive("basic".equalsIgnoreCase(scheme)); + } + } + } + } + + /** + * Parse and convert a HTTP status line into an aml element. + * + * @param statusLine + * @return + * @throws HttpException + * @see #statusLineToElement(org.w3c.dom.Document, org.apache.commons.httpclient.StatusLine) + */ + public static Element statusLineToElement + (String + statusLine) throws HttpException { + return statusLineToElement(new StatusLine(statusLine)); + } + + public static Element statusLineToElement + (StatusLine + statusLine) { + return statusLineToElement(DOMUtils.newDocument(), statusLine); + } + + /** + * Convert a <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec6.html#sec6.1">HTTP status line</a> into an xml element like this: + * <p/> + * < Status-line> + * < HTTP-Version>HTTP/1.1< /HTTP-Version> + * < Status-Code>200< /Status-Code> + * < Reason-Phrase>Success - The action was successfully received, understood, and accepted< /Reason-Phrase> + * < /Status-line></br> + * + * @param statusLine - the {@link org.apache.commons.httpclient.StatusLine} instance to be converted + * @param doc - the document to use to create new nodes + * @return an Element + */ + public static Element statusLineToElement + (Document + doc, StatusLine + statusLine) { + Element statusLineEl = doc.createElementNS(null, "Status-Line"); + Element versionEl = doc.createElementNS(null, "HTTP-Version"); + Element codeEl = doc.createElementNS(null, "Status-Code"); + Element reasonEl = doc.createElementNS(null, "Reason-Phrase"); + Element originalEl = doc.createElementNS(null, "original"); + + // wiring + doc.appendChild(statusLineEl); + statusLineEl.appendChild(versionEl); + statusLineEl.appendChild(codeEl); + statusLineEl.appendChild(reasonEl); + statusLineEl.appendChild(originalEl); + + // values + versionEl.setTextContent(statusLine.getHttpVersion()); + codeEl.setTextContent(String.valueOf(statusLine.getStatusCode())); + reasonEl.setTextContent(statusLine.getReasonPhrase()); + // the line as received, not parsed + originalEl.setTextContent(statusLine.toString()); + + return statusLineEl; + } + + /** + * Build a "details" element that looks like this: + * + * @param method + * @return + * @throws IOException + */ + public static Element prepareDetailsElement + (HttpMethod + method) { + Header h = method.getResponseHeader("Content-Type"); + String receivedType = h != null ? h.getValue() : null; + boolean bodyIsXml = receivedType != null && HttpUtils.isXml(receivedType); + + + Document doc = DOMUtils.newDocument(); + Element detailsEl = doc.createElementNS(null, "details"); + Element statusLineEl = statusLineToElement(doc, method.getStatusLine()); + detailsEl.appendChild(statusLineEl); + + // set the body if any + try { + final String body = method.getResponseBodyAsString(); + if (StringUtils.isNotEmpty(body)) { + Element bodyEl = doc.createElementNS(null, "responseBody"); + detailsEl.appendChild(bodyEl); + // first, try to parse the body as xml + // if it fails, put it as string in the body element + boolean exceptionDuringParsing = false; + if (bodyIsXml) { + try { + Element parsedBodyEl = DOMUtils.stringToDOM(body); + bodyEl.appendChild(doc.importNode(parsedBodyEl, true)); + } catch (Exception e) { + String errmsg = "Unable to parse the response body as xml. Body will be inserted as string."; + if (log.isDebugEnabled()) log.debug(errmsg, e); + exceptionDuringParsing = true; + } + } + if (!bodyIsXml || exceptionDuringParsing) { + bodyEl.setTextContent(body); + } + } + } catch (IOException e) { + if (log.isWarnEnabled()) log.warn("Exception while loading response body", e); + } + return detailsEl; + } + + private static final Pattern NON_LWS_PATTERN = Pattern.compile("\r\n([^\\s])"); + + /** + * This method ensures that a header value containing CRLF does not mess up the HTTP request. + * Actually CRLF is the end-of-line marker for headers. + * <p/> + * To do so, all CRLF followed by a non-whitespace character are replaced by CRLF HT. + * <p/> + * This is possible because the + * <a href="http://www.w3.org/Protocols/rfc2616/rfc2616-sec2.html#sec2.2">Section 2.2</a> of HTTP standard (RFC2626) states that: + * <p/> + * <quote> + * HTTP/1.1 header field values can be folded onto multiple lines if the + * continuation line begins with a space or horizontal tab. All linear + * white space, including folding, has the same semantics as SP. A + * recipient MAY replace any linear white space with a single SP before + * interpreting the field value or forwarding the message downstream. + * <p/> + * LWS = [CRLF] 1*( SP | HT ) + * <p/> + * </quote> + * <p/> + * FYI, HttpClient 3.x.x does not check this. + * + * @param header + * @return the string properly ready to be used as an HTTP header field-content + */ + public static String replaceCRLFwithLWS + (String + header) { + Matcher m = NON_LWS_PATTERN.matcher(header); + StringBuffer sb = new StringBuffer(header.length()); + while (m.find()) { + m.appendReplacement(sb, "\r\n\t"); + sb.append(m.group(1)); + } + m.appendTail(sb); + return sb.toString(); + } + + public static String requestToString + (HttpMethod + m) { + StringBuilder sb = new StringBuilder(256); + try { + sb.append("HTTP Request Details: \n").append(m.getName()).append(" ").append(m.getURI()); + } catch (URIException e) { + // not that important + if (log.isDebugEnabled()) log.debug(e); + } + sb.append("\nRequest Headers:"); + Header[] headers = m.getRequestHeaders(); + if (headers.length == 0) sb.append(" n/a"); + for (int i = 0; i < headers.length; i++) { + Header h = headers[i]; + sb.append("\n\t").append(h.getName()).append(": ").append(h.getValue()); + } + if (m instanceof EntityEnclosingMethod) { + EntityEnclosingMethod eem = (EntityEnclosingMethod) m; + if (eem.getRequestEntity() != null) { + sb.append("\nRequest Entity:"); + sb.append("\n\tContent-Type:").append(eem.getRequestEntity().getContentType()); + sb.append("\n\tContent-Length:").append(eem.getRequestEntity().getContentLength()); + if (eem.getRequestEntity() instanceof StringRequestEntity) { + StringRequestEntity sre = (StringRequestEntity) eem.getRequestEntity(); + sb.append("\n\tContent-Charset:").append(sre.getCharset()); + sb.append("\n\tRequest Entity:\n").append(sre.getContent()); + } + } + } + return sb.toString(); + } + + public static String responseToString + (HttpMethod + m) { + StringBuilder sb = new StringBuilder(256); + try { + sb.append("HTTP Response Details: \n").append(m.getName()).append(" ").append(m.getURI()); + } catch (URIException e) { + // not that important + if (log.isDebugEnabled()) log.debug(e); + } + sb.append("\nStatus-Line: ").append(m.getStatusLine()); + Header[] headers = m.getResponseHeaders(); + if (headers.length != 0) sb.append("\nResponse Headers: "); + for (int i = 0; i < headers.length; i++) { + Header h = headers[i]; + sb.append("\n\t").append(h.getName()).append(": ").append(h.getValue()); + } + try { + if (StringUtils.isNotEmpty(m.getResponseBodyAsString())) { + sb.append("\nResponse Entity:\n").append(m.getResponseBodyAsString()); + } + } catch (IOException e) { + log.error(e); + } + Header[] footers = m.getResponseFooters(); + if (footers.length != 0) sb.append("\nResponse Footers: "); + for (int i = 0; i < footers.length; i++) { + Header h = footers[i]; + sb.append("\n\t").append(h.getName()).append(": ").append(h.getValue()); + } + return sb.toString(); + } + + /** + * @param s, the status code to test, must be in [400, 600[ + * @return 1 if fault, -1 if failure, 0 if undetermined + */ + public static int isFaultOrFailure + ( + int s) { + if (s < 400 || s >= 600) { + throw new IllegalArgumentException("Status-Code must be in interval [400;600["); + } + if (s == _500_INTERNAL_SERVER_ERROR + || s == _501_NOT_IMPLEMENTED + || s == _502_BAD_GATEWAY + || s == _505_HTTP_VERSION_NOT_SUPPORTED + || s == _400_BAD_REQUEST + || s == _402_PAYMENT_REQUIRED + || s == _403_FORBIDDEN + || s == _404_NOT_FOUND + || s == _405_METHOD_NOT_ALLOWED + || s == _406_NOT_ACCEPTABLE + || s == _407_PROXY_AUTHENTICATION_REQUIRED + || s == _409_CONFLICT + || s == _410_GONE + || s == _412_PRECONDITION_FAILED + || s == _413_REQUEST_TOO_LONG + || s == _414_REQUEST_URI_TOO_LONG + || s == _415_UNSUPPORTED_MEDIA_TYPE + || s == _411_LENGTH_REQUIRED + || s == _416_REQUESTED_RANGE_NOT_SATISFIABLE + || s == _417_EXPECTATION_FAILED) { + return 1; + } else if (s == _503_SERVICE_UNAVAILABLE + || s == _504_GATEWAY_TIMEOUT + || s == _401_UNAUTHORIZED + || s == _408_REQUEST_TIMEOUT) { + return -1; + } else { + return 0; + } + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpMethodConverter.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpMethodConverter.java new file mode 100644 index 0000000..0626db2 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/HttpMethodConverter.java
@@ -0,0 +1,589 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.httpbinding; + +import org.apache.commons.httpclient.Header; +import org.apache.commons.httpclient.HttpMethod; +import org.apache.commons.httpclient.methods.DeleteMethod; +import org.apache.commons.httpclient.methods.EntityEnclosingMethod; +import org.apache.commons.httpclient.methods.GetMethod; +import org.apache.commons.httpclient.methods.PostMethod; +import org.apache.commons.httpclient.methods.PutMethod; +import org.apache.commons.httpclient.methods.RequestEntity; +import org.apache.commons.httpclient.methods.StringRequestEntity; +import org.apache.commons.httpclient.params.HostParams; +import org.apache.commons.httpclient.params.HttpParams; +import org.apache.commons.httpclient.params.HttpMethodParams; +import org.apache.commons.lang.StringUtils; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.Properties; +import org.apache.ode.axis2.util.URLEncodedTransformer; +import org.apache.ode.axis2.util.UrlReplacementTransformer; +import org.apache.ode.bpel.epr.MutableEndpoint; +import org.apache.ode.bpel.iapi.PartnerRoleMessageExchange; +import org.apache.ode.utils.DOMUtils; +import org.apache.ode.utils.Namespaces; +import org.apache.ode.utils.http.HttpUtils; +import static org.apache.ode.utils.http.HttpUtils.bodyAllowed; +import static org.apache.ode.utils.http.StatusCode._202_ACCEPTED; +import org.apache.ode.utils.wsdl.Messages; +import org.apache.ode.utils.wsdl.WsdlUtils; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.Node; +import org.xml.sax.SAXException; + +import javax.wsdl.Binding; +import javax.wsdl.BindingInput; +import javax.wsdl.BindingOperation; +import javax.wsdl.BindingOutput; +import javax.wsdl.Definition; +import javax.wsdl.Fault; +import javax.wsdl.Message; +import javax.wsdl.Operation; +import javax.wsdl.Part; +import javax.wsdl.extensions.UnknownExtensibilityElement; +import javax.wsdl.extensions.http.HTTPOperation; +import javax.wsdl.extensions.mime.MIMEContent; +import javax.xml.namespace.QName; +import java.io.IOException; +import java.io.UnsupportedEncodingException; +import java.util.Collection; +import java.util.HashMap; +import java.util.Iterator; +import java.util.Map; +import java.util.Set; +import java.util.HashSet; + +public class HttpMethodConverter { + + private static final Log log = LogFactory.getLog(HttpMethodConverter.class); + + protected static final Messages msgs = Messages.getMessages(Messages.class); + protected Definition definition; + protected Binding binding; + protected QName serviceName; + protected String portName; + + public HttpMethodConverter(Definition definition, QName serviceName, String portName) { + this.definition = definition; + this.binding = definition.getService(serviceName).getPort(portName).getBinding(); + this.serviceName = serviceName; + this.portName = portName; + } + + + public HttpMethod createHttpRequest(PartnerRoleMessageExchange odeMex, HttpParams params) throws UnsupportedEncodingException { + Operation operation = odeMex.getOperation(); + BindingOperation bindingOperation = binding.getBindingOperation(operation.getName(), operation.getInput().getName(), operation.getOutput().getName()); + + // message to be sent + Element message = odeMex.getRequest().getMessage(); + Message msgDef = operation.getInput().getMessage(); + + // base url + String url = ((MutableEndpoint) odeMex.getEndpointReference()).getUrl(); + + // extract part values into a map and check that all parts are assigned a value + Map<String, Element> partElements = extractPartElements(msgDef, message); + + // http method type + // the operation may override the verb, this is an extension for RESTful BPEL + String verb = WsdlUtils.resolveVerb(binding, bindingOperation); + + // build the http method itself + HttpMethod method = prepareHttpMethod(bindingOperation, verb, partElements, odeMex.getRequest().getHeaderParts(), url, params); + + return method; + } + + + /** + * create and initialize the http method. + * Http Headers that may been passed in the params are not set in this method. + * Headers will be automatically set by HttpClient. + * See usages of HostParams.DEFAULT_HEADERS + * See org.apache.commons.httpclient.HttpMethodDirector#executeMethod(org.apache.commons.httpclient.HttpMethod) + */ + protected HttpMethod prepareHttpMethod(BindingOperation opBinding, String verb, Map<String, Element> partValues, Map<String, Node> headers, + final String rootUri, HttpParams params) throws UnsupportedEncodingException { + if (log.isDebugEnabled()) log.debug("Preparing http request..."); + // convenience variables... + BindingInput bindingInput = opBinding.getBindingInput(); + HTTPOperation httpOperation = (HTTPOperation) WsdlUtils.getOperationExtension(opBinding); + MIMEContent content = WsdlUtils.getMimeContent(bindingInput.getExtensibilityElements()); + String contentType = content == null ? null : content.getType(); + boolean useUrlEncoded = WsdlUtils.useUrlEncoded(bindingInput) || PostMethod.FORM_URL_ENCODED_CONTENT_TYPE.equalsIgnoreCase(contentType); + boolean useUrlReplacement = WsdlUtils.useUrlReplacement(bindingInput); + + // the http method to be built and returned + HttpMethod method = null; + + // the 4 elements the http method may be made of + String relativeUri = httpOperation.getLocationURI(); + String queryPath = null; + RequestEntity requestEntity; + String encodedParams = null; + + // ODE supports uri template in both port and operation location. + // so assemble the final url *before* replacement + String completeUri = rootUri; + if (StringUtils.isNotEmpty(relativeUri)) { + completeUri = completeUri + (completeUri.endsWith("/") || relativeUri.startsWith("/") ? "" : "/") + relativeUri; + } + + if (useUrlReplacement) { + // insert part values in the url + completeUri = new UrlReplacementTransformer().transform(completeUri, partValues); + } else if (useUrlEncoded) { + // encode part values + encodedParams = new URLEncodedTransformer().transform(partValues); + } + + // http-client api is not really neat + // something similar to the following would save some if/else manipulations. + // But we have to deal with it as-is. + // + // method = new Method(verb); + // method.setRequestEnity(..) + // etc... + if ("GET".equalsIgnoreCase(verb) || "DELETE".equalsIgnoreCase(verb)) { + if ("GET".equalsIgnoreCase(verb)) { + method = new GetMethod(); + } else if ("DELETE".equalsIgnoreCase(verb)) { + method = new DeleteMethod(); + } + method.getParams().setDefaults(params); + if (useUrlEncoded) { + queryPath = encodedParams; + } + + // Let http-client manage the redirection + // see org.apache.commons.httpclient.params.HttpClientParams.MAX_REDIRECTS + // default is 100 + method.setFollowRedirects(true); + } else if ("POST".equalsIgnoreCase(verb) || "PUT".equalsIgnoreCase(verb)) { + + if ("POST".equalsIgnoreCase(verb)) { + method = new PostMethod(); + } else if ("PUT".equalsIgnoreCase(verb)) { + method = new PutMethod(); + } + method.getParams().setDefaults(params); + // some body-building... + final String contentCharset = method.getParams().getContentCharset(); + if (log.isDebugEnabled()) log.debug("Content-Type [" + contentType + "] Charset [" + contentCharset + "]"); + if (useUrlEncoded) { + requestEntity = new StringRequestEntity(encodedParams, PostMethod.FORM_URL_ENCODED_CONTENT_TYPE, contentCharset); + } else { + // get the part to be put in the body + Part part = opBinding.getOperation().getInput().getMessage().getPart(content.getPart()); + Element partValue = partValues.get(part.getName()); + + if (part.getElementName() == null) { + String errMsg = "XML Types are not supported. Parts must use elements."; + if (log.isErrorEnabled()) log.error(errMsg); + throw new RuntimeException(errMsg); + } else if (HttpUtils.isXml(contentType)) { + if (log.isDebugEnabled()) log.debug("Content-Type [" + contentType + "] equivalent to 'text/xml'"); + // stringify the first element + String xmlString = DOMUtils.domToString(DOMUtils.getFirstChildElement(partValue)); + requestEntity = new StringRequestEntity(xmlString, contentType, contentCharset); + } else { + if (log.isDebugEnabled()) + log.debug("Content-Type [" + contentType + "] NOT equivalent to 'text/xml'. The text content of part value will be sent as text"); + // encoding conversion is managed by StringRequestEntity if necessary + requestEntity = new StringRequestEntity(DOMUtils.getTextContent(partValue), contentType, contentCharset); + } + } + + // cast safely, PUT and POST are subclasses of EntityEnclosingMethod + final EntityEnclosingMethod enclosingMethod = (EntityEnclosingMethod) method; + enclosingMethod.setRequestEntity(requestEntity); + enclosingMethod.setContentChunked(params.getBooleanParameter(Properties.PROP_HTTP_REQUEST_CHUNK, false)); + + } else { + // should not happen because of HttpBindingValidator, but never say never + throw new IllegalArgumentException("Unsupported HTTP method: " + verb); + } + + method.setPath(completeUri); // assumes that the path is properly encoded (URL safe). + method.setQueryString(queryPath); + + // set headers + setHttpRequestHeaders(method, opBinding, partValues, headers, params); + return method; + } + + /** + * First go through the list of default headers set in the method params. This param is then remove to avoid interference with HttpClient. + * Actually the default headers should be overriden by any headers set from the process. + * Not to mention that, for a given header, HttpClient do not overwrite any previous values but simply append the default value.<br/> + * See {@link see org.apache.commons.httpclient.params.HostParams.DEFAULT_HEADERS} + * <p/> + * Then go through the list of message headers and set them if empty. + * <p/> + * Finally go through the list of {@linkplain Namespaces.ODE_HTTP_EXTENSION_NS}{@code :header} elements included in the input binding. + * For each of them, set the HTTP Request Header with the static value defined by the attribute {@linkplain Namespaces.ODE_HTTP_EXTENSION_NS}{@code :value}, + * or the part value mentioned in the attribute {@linkplain Namespaces.ODE_HTTP_EXTENSION_NS}{@code :part}. + * <p/> + * Finally, set the 'Accept' header if the output content type of the operation exists. + * <p/> + * Notice that the last header value overrides any values set previoulsy. Meaning that message headers might get overriden by parts bound to headers. + * + */ + public void setHttpRequestHeaders(HttpMethod method, BindingOperation opBinding, Map<String, Element> partValues, Map<String, Node> headers, HttpParams params) { + BindingInput inputBinding = opBinding.getBindingInput(); + Message inputMessage = opBinding.getOperation().getInput().getMessage(); + + // Do not let HttpClient manage the default headers + // Actually the default headers should be overriden by any headers set from the process. + // (Not to mention that, for a given header, HttpClient do not overwrite any previous values but simply append the default value) + Collection defaultHeaders = (Collection) params.getParameter(HostParams.DEFAULT_HEADERS); + if (defaultHeaders != null) { + Iterator i = defaultHeaders.iterator(); + while (i.hasNext()) { + method.setRequestHeader((Header) i.next()); + } + } + + // process message headers + for (Iterator<Map.Entry<String, Node>> iterator = headers.entrySet().iterator(); iterator.hasNext();) { + Map.Entry<String, Node> e = iterator.next(); + String headerName = e.getKey(); + Node headerNode = e.getValue(); + String headerValue = DOMUtils.domToString(headerNode); + method.setRequestHeader(headerName, HttpHelper.replaceCRLFwithLWS(headerValue)); + } + + // process parts that are bound to message parts + Collection<UnknownExtensibilityElement> headerBindings = WsdlUtils.getHttpHeaders(inputBinding.getExtensibilityElements()); + for (Iterator<UnknownExtensibilityElement> iterator = headerBindings.iterator(); iterator.hasNext();) { + Element binding = iterator.next().getElement(); + String headerName = binding.getAttribute("name"); + String partName = binding.getAttribute("part"); + String value = binding.getAttribute("value"); + + /* Header binding may use a part or a static value */ + String headerValue; + if (StringUtils.isNotEmpty(partName)) { + // 'part' attribute is used + // get the part to be put in the header + Part part = inputMessage.getPart(partName); + Element partWrapper = partValues.get(part.getName()); + if (DOMUtils.isEmptyElement(partWrapper)) { + headerValue = ""; + } else { + /* + The expected part value could be a simple type + or an element of a simple type. + So if a element is there, take its text content + else take the text content of the part element itself + */ + Element childElement = DOMUtils.getFirstChildElement(partWrapper); + if (childElement != null) { + if (DOMUtils.getFirstChildElement(childElement) != null) { + String errMsg = "Complex types are not supported. Header Parts must be simple types or elements of a simple type."; + if (log.isErrorEnabled()) log.error(errMsg); + throw new RuntimeException(errMsg); + } else { + headerValue = DOMUtils.getTextContent(childElement); + } + } else { + headerValue = DOMUtils.getTextContent(partWrapper); + } + } + } else if (StringUtils.isNotEmpty(value)) { + // 'value' attribute is used, this header is a static value + headerValue = value; + } else { + String errMsg = "Invalid binding: missing attribute! Expecting " + new QName(Namespaces.ODE_HTTP_EXTENSION_NS, "part") + " or " + new QName(Namespaces.ODE_HTTP_EXTENSION_NS, "value"); + if (log.isErrorEnabled()) log.error(errMsg); + throw new RuntimeException(errMsg); + } + // do not set the header isf the value is empty + if (StringUtils.isNotEmpty(headerValue)) + method.setRequestHeader(headerName, HttpHelper.replaceCRLFwithLWS(headerValue)); + } + + MIMEContent outputContent = WsdlUtils.getMimeContent(opBinding.getBindingOutput().getExtensibilityElements()); + // set Accept header if output content type is set + if (outputContent != null) { + method.setRequestHeader("Accept", outputContent.getType()); + } + + } + + + protected Map<String, Element> extractPartElements(Message msgDef, Element message) { + Map<String, Element> partValues = new HashMap<String, Element>(); + for (Iterator iterator = msgDef.getParts().values().iterator(); iterator.hasNext();) { + Part part = (Part) iterator.next(); + Element partEl = DOMUtils.findChildByName(message, new QName(null, part.getName())); + if (partEl == null) + throw new IllegalArgumentException(msgs.msgOdeMessageMissingRequiredPart(part.getName())); + partValues.put(part.getName(), partEl); + } + return partValues; + } + + + /** + * Create the element to be associated with this part into the {@link org.apache.ode.bpel.iapi.Message}. + * <br/>An element named with the part name will be returned. the content of this element depends on the part. + * <p/>If the part has a non-null element name, a new element will be created and named accordingly then the text value is inserted in this new element. + * <br/>else the given text content is simply set on the part element. + * + * @param part + * @param textContent + * @return an element named with the part name will be returned + */ + public Element createPartElement(Part part, String textContent) { + Document doc = DOMUtils.newDocument(); + Element partElement = doc.createElementNS(null, part.getName()); + if (part.getElementName() != null) { + Element element = doc.createElementNS(part.getElementName().getNamespaceURI(), part.getElementName().getLocalPart()); + element.setTextContent(textContent); + partElement.appendChild(element); + } else { + partElement.setTextContent(textContent); + } + return partElement; + } + + + /** + * Create the element to be associated with this part into the {@link org.apache.ode.bpel.iapi.Message}. + * <p/>If the part has a non-null element name, the bodyElement is simply appended. + * Else if the bodyElement has a text content, the value is set to the message. + * Else append all nodes of bodyElement to the returned element. Attributes are ignored. + * <p/> + * The name of the returned element is the part name. + * + * @param part + * @param receivedElement + * @return the element to insert "as is" to ODE message + */ + public Element createPartElement(Part part, Element receivedElement) { + Document doc = DOMUtils.newDocument(); + Element partElement = doc.createElementNS(null, part.getName()); + if (part.getElementName() != null) { + partElement.appendChild(doc.importNode(receivedElement, true)); + } else { + if (DOMUtils.isEmptyElement(receivedElement)) { + // Append an empty text node. + // Warning! setting an empty string with setTextContent has not effect. See javadoc. + partElement.appendChild(doc.createTextNode("")); + } else { + // No need to make the distinction between simple and complex types, importNode will handle it + // !!! Attributes are ignored + for (int m = 0; m < receivedElement.getChildNodes().getLength(); m++) { + Node child = receivedElement.getChildNodes().item(m); + partElement.appendChild(doc.importNode(child, true)); + } + } + } + return partElement; + } + + /** + * Process the HTTP Response Headers. + * <p/> + * First go through the list of {@linkplain Namespaces.ODE_HTTP_EXTENSION_NS}{@code :header} elements included in the output binding. + * For each of them, set the header value as the value of the message part. + * <p/> + * Then add all HTTP headers as header part in the message. The name of the header would be the part name. + * <p/> + * Finally, insert a header names 'Status-Line'. This header contains an element as returned by {@link HttpHelper#statusLineToElement(String)} . + * + * @param odeMessage + * @param method + * @param operationDef + */ + public void extractHttpResponseHeaders(org.apache.ode.bpel.iapi.Message odeMessage, HttpMethod method, Operation operationDef) { + Message messageDef = operationDef.getOutput().getMessage(); + + BindingOutput outputBinding = binding.getBindingOperation(operationDef.getName(), operationDef.getInput().getName(), operationDef.getOutput().getName()).getBindingOutput(); + Collection<UnknownExtensibilityElement> headerBindings = WsdlUtils.getHttpHeaders(outputBinding.getExtensibilityElements()); + + // iterate through the list of header bindings + // and set the message parts accordingly + for (Iterator<UnknownExtensibilityElement> iterator = headerBindings.iterator(); iterator.hasNext();) { + Element binding = iterator.next().getElement(); + String partName = binding.getAttribute("part"); + String headerName = binding.getAttribute("name"); + + Part part = messageDef.getPart(partName); + if (StringUtils.isNotEmpty(partName)) { + Header responseHeader = method.getResponseHeader(headerName); + // if the response header is not set, just skip it. no need to fail. + if (responseHeader != null) { + odeMessage.setPart(partName, createPartElement(part, responseHeader.getValue())); + } + } else { + String errMsg = "Invalid binding: missing required attribute! Part name: " + new QName(Namespaces.ODE_HTTP_EXTENSION_NS, "part"); + if (log.isErrorEnabled()) log.error(errMsg); + throw new RuntimeException(errMsg); + } + } + + // add all HTTP response headers (in their condensed form) into the message as header parts + Set<String> headerNames = new HashSet<String>(); + for (Header header : method.getResponseHeaders()) headerNames.add(header.getName()); + for(String hname:headerNames) odeMessage.setHeaderPart(hname, method.getResponseHeader(hname).getValue()); + + // make the status line information available as a single element + odeMessage.setHeaderPart("Status-Line", HttpHelper.statusLineToElement(method.getStatusLine())); + } + + public void parseHttpResponse(org.apache.ode.bpel.iapi.Message odeResponse, HttpMethod method, Operation opDef) throws SAXException, IOException { + BindingOperation opBinding = binding.getBindingOperation(opDef.getName(), opDef.getInput().getName(), opDef.getOutput().getName()); + /* process headers */ + extractHttpResponseHeaders(odeResponse, method, opDef); + + /* process the body if any */ + + // assumption is made that a response may have at most one body. HttpBindingValidator checks this. + MIMEContent outputContent = WsdlUtils.getMimeContent(opBinding.getBindingOutput().getExtensibilityElements()); + int status = method.getStatusCode(); + + boolean xmlExpected = outputContent != null && HttpUtils.isXml(outputContent.getType()); + // '202/Accepted' and '204/No Content' status codes explicitly state that there is no body, so we should not fail even if a part is bound to the body response + boolean isBodyExpected = outputContent != null; + boolean isBodyMandatory = isBodyExpected && bodyAllowed(status) && status != _202_ACCEPTED; + final String body; + try { + body = method.getResponseBodyAsString(); + } catch (IOException e) { + throw new RuntimeException("Unable to get the request body : " + e.getMessage()); + } + + final boolean emptyBody = StringUtils.isEmpty(body); + if (emptyBody) { + if (isBodyMandatory) { + throw new RuntimeException("Response body is mandatory but missing!"); + } + } else { + if (isBodyExpected) { + Part partDef = opDef.getOutput().getMessage().getPart(outputContent.getPart()); + Element partElement; + + if (xmlExpected) { + + Header h = method.getResponseHeader("Content-Type"); + String receivedType = h != null ? h.getValue() : null; + boolean contentTypeSet = receivedType != null; + boolean xmlReceived = contentTypeSet && HttpUtils.isXml(receivedType); + + // a few checks + if (!contentTypeSet) { + if (log.isDebugEnabled()) + log.debug("Received Response with a body but no 'Content-Type' header!"); + } else if (!xmlReceived) { + if (log.isDebugEnabled()) + log.debug("Xml type was expected but non-xml type received! Expected Content-Type=" + outputContent.getType() + " Received Content-Type=" + receivedType); + } + + // parse the body and create the message part + Element bodyElement = DOMUtils.stringToDOM(body); + partElement = createPartElement(partDef, bodyElement); + } else { + // if not xml, process it as text + partElement = createPartElement(partDef, body); + } + + // set the part + odeResponse.setPart(partDef.getName(), partElement); + + } else { + // the body was not expected but we don't know how to deal with it + if (log.isDebugEnabled()) log.debug("Body received but not mapped to any part! Body=\n" + body); + } + } + } + + public Object[] parseFault(PartnerRoleMessageExchange odeMex, HttpMethod method) { + Operation opDef = odeMex.getOperation(); + BindingOperation opBinding = binding.getBindingOperation(opDef.getName(), opDef.getInput().getName(), opDef.getOutput().getName()); + + final String body; + try { + body = method.getResponseBodyAsString(); + } catch (IOException e) { + throw new RuntimeException("Unable to get the request body : " + e.getMessage(), e); + } + Header h = method.getResponseHeader("Content-Type"); + String receivedType = h != null ? h.getValue() : null; + if (opDef.getFaults().isEmpty()) { + throw new RuntimeException("Operation [" + opDef.getName() + "] has no fault. This " + method.getStatusCode() + " error will be considered as a failure."); + } else if (opBinding.getBindingFaults().isEmpty()) { + throw new RuntimeException("No fault binding. This " + method.getStatusCode() + " error will be considered as a failure."); + } else if (StringUtils.isEmpty(body)) { + throw new RuntimeException("No body in the response. This " + method.getStatusCode() + " error will be considered as a failure."); + } else if (receivedType != null && !HttpUtils.isXml(receivedType)) { + throw new RuntimeException("Response Content-Type [" + receivedType + "] does not describe XML entities. Faults must be XML. This " + method.getStatusCode() + " error will be considered as a failure."); + } else { + + if (receivedType == null) { + if (log.isWarnEnabled()) + log.warn("[Service: " + serviceName + ", Port: " + portName + ", Operation: " + opDef.getName() + "] Received Response with a body but no 'Content-Type' header! Will try to parse nevertheless."); + } + + // try to parse body + final Element bodyElement; + try { + bodyElement = DOMUtils.stringToDOM(body); + } catch (Exception e) { + throw new RuntimeException("Unable to parse the response body as xml. This " + method.getStatusCode() + " error will be considered as a failure.", e); + } + + // Guess which fault it is + QName bodyName = new QName(bodyElement.getNamespaceURI(), bodyElement.getNodeName()); + Fault faultDef = WsdlUtils.inferFault(opDef, bodyName); + + if (faultDef == null) { + throw new RuntimeException("Unknown Fault Type [" + bodyName + "] This " + method.getStatusCode() + " error will be considered as a failure."); + } else if (!WsdlUtils.isOdeFault(opBinding.getBindingFault(faultDef.getName()))) { + // is this fault bound with ODE extension? + throw new RuntimeException("Fault [" + bodyName + "] is not bound with " + new QName(Namespaces.ODE_HTTP_EXTENSION_NS, "fault") + ". This " + method.getStatusCode() + " error will be considered as a failure."); + } else { + // a fault has only one part + Part partDef = (Part) faultDef.getMessage().getParts().values().iterator().next(); + + QName faultName = new QName(definition.getTargetNamespace(), faultDef.getName()); + QName faultType = faultDef.getMessage().getQName(); + + // create the ODE Message now that we know the fault + org.apache.ode.bpel.iapi.Message response = odeMex.createMessage(faultType); + + // build the element to be sent back + Element partElement = createPartElement(partDef, bodyElement); + response.setPart(partDef.getName(), partElement); + + // extract and set headers + extractHttpResponseHeaders(response, method, opDef); + return new Object[]{faultName, response}; + } + } + } + +} +
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/Messages.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/Messages.java new file mode 100644 index 0000000..00e5fb8 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/Messages.java
@@ -0,0 +1,78 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.httpbinding; + +import org.apache.ode.utils.msg.MessageBundle; + +import javax.xml.namespace.QName; +import javax.wsdl.Binding; +import javax.wsdl.BindingOperation; +import java.io.File; + +/** + * @author <a href="mailto:midon@intalio.com">Alexis Midon</a> + */ +public class Messages extends MessageBundle { + + public String msgMissingVerb(Binding binding, BindingOperation operation) { + return format("No verb defined for binding: {0} operation: {1}", binding.getQName(), operation.getName()); + } + + public String msgUnsupportedHttpMethod(Binding binding, String verb) { + return format("Unsupported HTTP method! binding: {0} method: {1}", binding.getQName(), verb); + } + + public String msgHttpBindingNotUsed(Binding binding) { + return format("This binding does not use http:binding: {0}" + binding.getQName()); + } + + public String msgEmptyContentType(Binding binding, BindingOperation operation) { + return format("MIME Content Type is empty! binding: {0} operation: {1}", binding.getQName(), operation.getName()); + } + + public String msgUnsupportedContentType(Binding binding, BindingOperation operation) { + return format("Unsupported content-type! binding: {0} operation: {1}", binding.getQName(), operation.getName()); + } + + public String msgInvalidURIPattern() { + return format("Invalid URI Pattern!"); + } + + public String msgInvalidURIPattern(Binding binding, BindingOperation operation, String locationUri) { + return format("Invalid URI Pattern : parts must not be mentioned more than once! binding:{0}, operation:{1}, locationUri:{2}", binding.getQName(), operation.getName(), locationUri); + } + + public String msgMimeMultipartRelatedUnsupported(Binding binding, BindingOperation operation) { + return format("MimeMultipartRelated is not supported! binding:{0}, operation:{1}", binding.getQName(), operation.getName()); + } + + public String msgInvalidContentType(Binding binding, BindingOperation operation) { + return format("Invalid content-type! binding:{0}, operation:{1}", binding.getQName(), operation.getName()); + } + + public String msgSimpleTypeExpected(String partName){ + return format("Simple type expected for {0}", partName); + } + + public String msgOnlySupportsUrlEncodedAndUrlreplacement(Binding binding, BindingOperation operation) { + return format("Only supports urlEncoded or urlReplacement! binding:{0}, operation:{1}", binding.getQName(), operation.getName()); + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/ProxyConf.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/ProxyConf.java new file mode 100644 index 0000000..e9a813f --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/httpbinding/ProxyConf.java
@@ -0,0 +1,109 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.httpbinding; + +import org.apache.axis2.transport.http.HttpTransportProperties; +import org.apache.commons.httpclient.Credentials; +import org.apache.commons.httpclient.HostConfiguration; +import org.apache.commons.httpclient.HttpState; +import org.apache.commons.httpclient.NTCredentials; +import org.apache.commons.httpclient.UsernamePasswordCredentials; +import org.apache.commons.httpclient.URIException; +import org.apache.commons.httpclient.auth.AuthScope; +import org.apache.commons.httpclient.params.HttpParams; +import org.apache.ode.axis2.Properties; + + +/** + * The purpose of this class is to configure proxy for HttpClient. + */ +public class ProxyConf { + + + // these properties are java system properties + // see http://java.sun.com/j2se/1.5.0/docs/guide/net/properties.html + public static final String HTTP_PROXY_HOST = "http.proxyHost"; + public static final String HTTP_PROXY_PORT = "http.proxyPort"; + public static final String HTTP_NON_PROXY_HOSTS = "http.nonProxyHosts"; + + public static void configure(HostConfiguration hostConfig, HttpState state, HttpTransportProperties.ProxyProperties proxyProperties) { + String proxyHost = proxyProperties.getProxyHostName(); + int proxyPort = proxyProperties.getProxyPort(); + + //Setting credentials + String userName = proxyProperties.getUserName(); + String password = proxyProperties.getPassWord(); + String domain = proxyProperties.getDomain(); + + Credentials proxyCred; + if (userName != null && password != null && domain != null) { + proxyCred = new NTCredentials(userName, password, proxyHost, domain); + } else if (userName != null) { + proxyCred = new UsernamePasswordCredentials(userName, password); + } else { + proxyCred = new UsernamePasswordCredentials("", ""); + } + + //Using Java Networking Properties + String host = System.getProperty(HTTP_PROXY_HOST); + if (host != null) { + proxyHost = host; + proxyCred = new UsernamePasswordCredentials("", ""); + } + String port = System.getProperty(HTTP_PROXY_PORT); + if (port != null) { + proxyPort = Integer.parseInt(port); + } + state.setProxyCredentials(AuthScope.ANY, proxyCred); + hostConfig.setProxy(proxyHost, proxyPort); + } + + /** + * @return true if a proxy is set in the params, or in the system property "http.proxyHost" + * and the host is not mentionnned in the system property "http.nonProxyHosts" + * @see Properties#PROP_HTTP_PROXY_PREFIX + */ + public static boolean isProxyEnabled(HttpParams params, String targetHost) throws URIException { + // from IL properties + boolean isSet = params.isParameterSet(Properties.PROP_HTTP_PROXY_PREFIX); + // from Java Networking Properties + isSet |= System.getProperty(HTTP_PROXY_HOST) != null; + + boolean isNonProxyHost = isNonProxyHost(targetHost); + return isSet && !isNonProxyHost; + } + + /** + * + * @return true if the targetHost is mentioned in the system properties "http.nonProxyHosts" + * @see http://java.sun.com/j2se/1.5.0/docs/guide/net/properties.html + */ + public static boolean isNonProxyHost(String targetHost) { + String nonProxyHosts = System.getProperty(HTTP_NON_PROXY_HOSTS); + if (nonProxyHosts != null) { + String[] splitted = nonProxyHosts.split("\\|"); + for (int i = 0; i < splitted.length; i++) { + if (targetHost.matches(splitted[i])) return true; + } + } + return false; + } +} +
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java new file mode 100644 index 0000000..50e9554 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentBrowser.java
@@ -0,0 +1,334 @@ +package org.apache.ode.axis2.service; + +import org.apache.ode.store.ProcessStoreImpl; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.utils.fs.FileUtils; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.description.AxisOperation; +import org.apache.commons.lang.StringUtils; + +import javax.xml.namespace.QName; +import javax.servlet.http.HttpServletRequest; +import javax.servlet.http.HttpServletResponse; +import javax.servlet.ServletException; +import java.io.*; +import java.util.List; +import java.util.Iterator; +import java.util.ArrayList; + +/** + * handles a set of URLs all starting with /deployment to publish all files in + * deployed bundles, services and processes. + */ +public class DeploymentBrowser { + + private ProcessStoreImpl _store; + private AxisConfiguration _config; + private File _appRoot; + + public DeploymentBrowser(ProcessStoreImpl store, AxisConfiguration config, File appRoot) { + _store = store; + _config = config; + _appRoot = appRoot; + } + + // A fake filter, directly called from the ODEAxisServlet + public boolean doFilter(final HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { + final String requestURI = request.getRequestURI(); + final int deplUri = requestURI.indexOf("/deployment"); + if (deplUri > 0) { + final String root = request.getScheme() + "://" + request.getServerName() + + ":" + request.getServerPort() + requestURI.substring(0, deplUri); + int offset = requestURI.length() > (deplUri + 11) ? 1 : 0; + final String[] segments = requestURI.substring(deplUri + 11 + offset).split("/"); + if (segments.length == 0 || segments[0].length() == 0) { + renderHtml(response, "ODE Deployment Browser", new DocBody() { + public void render(Writer out) throws IOException { + out.write("<p><a href=\"bundles/\">Deployed Bundles</a></p>"); + out.write("<p><a href=\"services/\">Process Services</a></p>"); + out.write("<p><a href=\"processes/\">Process Definitions</a></p>"); + } + }); + } else if (segments.length > 0) { + if ("services".equals(segments[0])) { + if (segments.length == 1) { + renderHtml(response, "Services Implemented by Your Processes", new DocBody() { + public void render(Writer out) throws IOException { + for (Object serviceName : _config.getServices().keySet()) + if (!"Version".equals(serviceName)) { + AxisService service = _config.getService(serviceName.toString()); + + // The service can be one of the dynamically registered ODE services, a process + // service or an unknown service deployed in the same Axis2 instance. + String url = null; + if ("DeploymentService".equals(service.getName()) + || "InstanceManagement".equals(service.getName()) + || "ProcessManagement".equals(service.getName())) + url = service.getName(); + else if (service.getFileName() != null) { + String relative = bundleUrlFor(service.getFileName().getFile()); + if (relative != null) url = root + relative; + else url = root + "/services/" + service.getName() + "?wsdl"; + } + + out.write("<p><a href=\"" + url + "\">" + serviceName + "</a></p>"); + + out.write("<ul><li>Endpoint: " + (root + "/processes/" + serviceName) + "</li>"); + Iterator iter = service.getOperations(); + ArrayList<String> ops = new ArrayList<String>(); + while (iter.hasNext()) ops.add(((AxisOperation)iter.next()).getName().getLocalPart()); + out.write("<li>Operations: " + StringUtils.join(ops, ", ") + "</li></ul>"); + } + } + }); + } else { + final String serviceName = requestURI.substring(deplUri + 12 + 9); + final AxisService axisService = _config.getService(serviceName); + if (axisService != null) { + renderXml(response, new DocBody() { + public void render(Writer out) throws IOException { + if ("InstanceManagement".equals(serviceName) || "ProcessManagement".equals(serviceName)) + write(out, new File(_appRoot, "pmapi.wsdl").getPath()); + else if (requestURI.indexOf("pmapi.xsd") > 0) + write(out, new File(_appRoot, "pmapi.xsd").getPath()); + else if ("DeploymentService".equals(serviceName)) + write(out, new File(_appRoot, "deploy.wsdl").getPath()); + else + write(out, axisService.getFileName().getFile()); + } + }); + } else { + renderHtml(response, "Service Not Found", new DocBody() { + public void render(Writer out) throws IOException { + out.write("<p>Couldn't find service " + serviceName + "</p>"); + } + }); + } + } + } else if ("processes".equals(segments[0])) { + if (segments.length == 1) { + renderHtml(response, "Deployed Processes", new DocBody() { + public void render(Writer out) throws IOException { + for (QName process :_store.getProcesses()) { + String url = root + bundleUrlFor(_store.getProcessConfiguration(process).getBpelDocument()); + String[] nameVer = process.getLocalPart().split("-"); + out.write("<p><a href=\"" + url + "\">" + nameVer[0] + "</a> (v" + nameVer[1] + ")"); + out.write(" - " + process.getNamespaceURI() + "</p>"); + } + } + }); + } + } else if ("bundles".equals(segments[0])) { + if (segments.length == 1) { + renderHtml(response, "Deployment Bundles", new DocBody() { + public void render(Writer out) throws IOException { + for (String bundle : _store.getPackages()) + out.write("<p><a href=\"" + bundle + "\">" + bundle + "</a></p>"); + } + }); + } else if (segments.length == 2) { + renderHtml(response, "Files in Bundle " + segments[1], new DocBody() { + public void render(Writer out) throws IOException { + List<QName> processes = _store.listProcesses(segments[1]); + if (processes != null) { + List<File> files = _store.getProcessConfiguration(processes.get(0)).getFiles(); + for (File file : files) { + String relativePath = file.getPath().substring(file.getPath() + .indexOf("processes")+10).replaceAll("\\\\", "/"); + out.write("<p><a href=\"" + relativePath + "\">" + relativePath + "</a></p>"); + } + } else { + out.write("<p>Couldn't find bundle " + segments[2] + "</p>"); + } + } + }); + } else if (segments.length > 2) { + List<QName> processes = _store.listProcesses(segments[1]); + if (processes != null) { + List<File> files = _store.getProcessConfiguration(processes.get(0)).getFiles(); + for (final File file : files) { + String relativePath = requestURI.substring(deplUri + 12 + 9 + segments[1].length()); + if (file.getPath().endsWith(relativePath)) { + renderXml(response, new DocBody() { + public void render(Writer out) throws IOException { + write(out, file.getPath()); + } + }); + return true; + } + } + } else { + renderHtml(response, "No Bundle Found", new DocBody() { + public void render(Writer out) throws IOException { + out.write("<p>Couldn't find bundle " + segments[2] + "</p>"); + } + }); + } + } + } else if ("getBundleDocs".equals(segments[0])) { + if (segments.length == 1) { + renderXml(response, new DocBody() { + public void render(Writer out) throws IOException { + out.write("<getBundleDocsResponse>"); + out.write("<error>Not enough args..</error>"); + out.write("</getBundleDocsResponse>"); + } + }); + } else if (segments.length == 2) { + final String bundleName = segments[1]; + final List<QName> processes = _store.listProcesses(bundleName); + if (processes != null) { + renderXml(response, new DocBody() { + public void render(Writer out) throws IOException { + out.write("<getBundleDocsResponse><name>"+ bundleName +"</name>"); + //final List<File> files = _store.getProcessConfiguration(processes.get(0)).getFiles(); + //final String pid = _store.getProcessConfiguration(processes.get(0)).getProcessId().toString(); + + for (final QName process: processes) { + List<File> files = _store.getProcessConfiguration(process).getFiles(); + String pid = _store.getProcessConfiguration(process).getProcessId().toString(); + out.write("<process><pid>"+pid+"</pid>"); + for (final File file : files) { + if (file.getPath().endsWith(".wsdl")) { + String relativePath = file.getPath().substring(_store.getDeployDir().getCanonicalPath().length() + 1); + out.write("<wsdl>"+ relativePath + "</wsdl>"); + } + if (file.getPath().endsWith(".bpel")) { + String relativePath = file.getPath().substring(_store.getDeployDir().getCanonicalPath().length() + 1); + out.write("<bpel>"+ relativePath + "</bpel>"); + } + + } + out.write("</process>"); + } + out.write("</getBundleDocsResponse>"); + } + }); + + } + } + } else if ("getProcessDefinition".equals(segments[0])) { + if (segments.length == 1) { + renderXml(response, new DocBody() { + public void render(Writer out) throws IOException{ + out.write("<getProcessDefinitionResponse>"); + out.write("<error>Not enough args..</error>"); + out.write("</getProcessDefinitionResponse>"); + } + }); + } else if (segments.length == 2) { + String processName = segments[1]; + for (QName process :_store.getProcesses()) { + String[] nameVer = process.getLocalPart().split("-"); + if(processName.equals(nameVer[0])) { + final String url = root + bundleUrlFor(_store.getProcessConfiguration(process).getBpelDocument()); + renderXml(response, new DocBody() { + public void render(Writer out) throws IOException { + out.write("<getProcessDefinition>"); + out.write("<url>"+ url +"</url>"); + out.write("</getProcessDefinition>"); + } + }); + } + } + + } + } + } + return true; + } + return false; + } + + static interface DocBody { + void render(Writer out) throws IOException; + } + private void renderHtml(HttpServletResponse response, String title, DocBody docBody) throws IOException { + response.setContentType("text/html"); + + Writer out = response.getWriter(); + out.write("<html><header><style type=\"text/css\">" + CSS + "</style></header><body>\n"); + out.write("<h2>" + title + "</h2><p/>\n"); + docBody.render(out); + out.write("</body></html>"); + } + private void renderXml(HttpServletResponse response, DocBody docBody) throws IOException { + response.setContentType("application/xml; charset=utf-8"); + //response.setContentType("application/xml"); + //response.setCharacterEncoding("UTF-8"); + + Writer out = response.getWriter(); + docBody.render(out); + } + + private void write(Writer out, String filePath) throws IOException { + BufferedReader wsdlReader = new BufferedReader(new FileReader(filePath)); + String line; + while((line = wsdlReader.readLine()) != null) out.write(line + "\n"); + wsdlReader.close(); + } + + private String bundleUrlFor(String docFile) { + if (docFile.indexOf("processes") >= 0) docFile = docFile.substring(docFile.indexOf("processes")+10); + List<File> files = FileUtils.listFilesRecursively(_store.getDeployDir(), null); + for (final File bundleFile : files) { + if (bundleFile.getPath().replaceAll("\\\\", "/").endsWith(docFile)) + return "/deployment/bundles/" + bundleFile.getPath() + .substring(_store.getDeployDir().getPath().length() + 1).replaceAll("\\\\", "/"); + } + return null; + } + + private static final String CSS = + "body {\n" + + " font: 75% Verdana, Helvetica, Arial, sans-serif;\n" + + " background: White;\n" + + " color: Black;\n" + + " margin: 1em;\n" + + " padding: 1em;\n" + + "}\n" + + "\n" + + "h1, h2, h3, h4, h5, h6 {\n" + + " color: Black;\n" + + " clear: left;\n" + + " font: 100% Verdana, Helvetica, Arial, sans-serif;\n" + + " margin: 0;\n" + + " padding-left: 0.5em;\n" + + "} \n" + + "\n" + + "h1 {\n" + + " font-size: 150%;\n" + + " border-bottom: none;\n" + + " text-align: right;\n" + + " border-bottom: 1px solid Gray;\n" + + "}\n" + + " \n" + + "h2 {\n" + + " font-size: 130%;\n" + + " border-bottom: 1px solid Gray;\n" + + "}\n" + + "\n" + + "h3 {\n" + + " font-size: 120%;\n" + + " padding-left: 1.0em;\n" + + " border-bottom: 1px solid Gray;\n" + + "}\n" + + "\n" + + "h4 {\n" + + " font-size: 110%;\n" + + " padding-left: 1.5em;\n" + + " border-bottom: 1px solid Gray;\n" + + "}\n" + + "\n" + + "p {\n" + + " text-align: justify;\n" + + " line-height: 1.5em;\n" + + " padding-left: 1.5em;\n" + + "}\n" + + "\n" + + "a {\n" + + " text-decoration: underline;\n" + + " color: Black;\n" + + "}"; +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java new file mode 100644 index 0000000..99f0b46 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/DeploymentWebService.java
@@ -0,0 +1,291 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.service; + + +import java.io.BufferedOutputStream; +import java.io.File; +import java.io.FileOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; +import java.util.Collection; +import java.util.List; +import java.util.zip.ZipEntry; +import java.util.zip.ZipInputStream; + +import javax.activation.DataHandler; +import javax.wsdl.Definition; +import javax.wsdl.WSDLException; +import javax.wsdl.factory.WSDLFactory; +import javax.wsdl.xml.WSDLReader; +import javax.xml.namespace.QName; + +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMNamespace; +import org.apache.axiom.om.OMText; +import org.apache.axiom.soap.SOAPEnvelope; +import org.apache.axiom.soap.SOAPFactory; +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.engine.AxisEngine; +import org.apache.axis2.receivers.AbstractMessageReceiver; +import org.apache.axis2.util.Utils; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.OdeFault; +import org.apache.ode.axis2.deploy.DeploymentPoller; +import org.apache.ode.axis2.hooks.ODEAxisService; +import org.apache.ode.bpel.iapi.BpelServer; +import org.apache.ode.bpel.iapi.ProcessConf; +import org.apache.ode.bpel.iapi.ProcessStore; +import org.apache.ode.il.OMUtils; +import org.apache.ode.utils.fs.FileUtils; + +/** + * Axis wrapper for process deployment. + */ +public class DeploymentWebService { + + private static final Log __log = LogFactory.getLog(DeploymentWebService.class); + + private final OMNamespace _pmapi; + + private File _deployPath; + private DeploymentPoller _poller; + private ProcessStore _store; + + + public DeploymentWebService() { + _pmapi = OMAbstractFactory.getOMFactory().createOMNamespace("http://www.apache.org/ode/pmapi","pmapi"); + } + + public void enableService(AxisConfiguration axisConfig, BpelServer server, ProcessStore store, + DeploymentPoller poller, String rootpath, String workPath) { + _deployPath = new File(workPath, "processes"); + _store = store; + + Definition def; + try { + WSDLReader wsdlReader = WSDLFactory.newInstance().newWSDLReader(); + wsdlReader.setFeature("javax.wsdl.verbose", false); + + File wsdlFile = new File(rootpath + "/deploy.wsdl"); + def = wsdlReader.readWSDL(wsdlFile.toURI().toString()); + AxisService deployService = ODEAxisService.createService( + axisConfig, new QName("http://www.apache.org/ode/deployapi", "DeploymentService"), + "DeploymentPort", "DeploymentService", def, new DeploymentMessageReceiver()); + axisConfig.addService(deployService); + _poller = poller; + } catch (WSDLException e) { + e.printStackTrace(); + } catch (IOException e) { + e.printStackTrace(); + } + } + + class DeploymentMessageReceiver extends AbstractMessageReceiver { + + public void invokeBusinessLogic(MessageContext messageContext) throws AxisFault { + String operation = messageContext.getAxisOperation().getName().getLocalPart(); + SOAPFactory factory = getSOAPFactory(messageContext); + boolean unknown = false; + + try { + if (operation.equals("deploy")) { + OMElement namePart = messageContext.getEnvelope().getBody().getFirstElement().getFirstElement(); + OMElement zipPart = (OMElement) namePart.getNextOMSibling(); + OMElement zip = (zipPart == null) ? null : zipPart.getFirstElement(); + if (zip == null || !zipPart.getQName().getLocalPart().equals("package") + || !zip.getQName().getLocalPart().equals("zip")) + throw new OdeFault("Your message should contain an element named 'package' with a 'zip' element"); + + OMText binaryNode = (OMText) zip.getFirstOMChild(); + if (binaryNode == null) { + throw new OdeFault("Empty binary node under <zip> element"); + } + binaryNode.setOptimize(true); + try { + // We're going to create a directory under the deployment root and put + // files in there. The poller shouldn't pick them up so we're asking + // it to hold on for a while. + _poller.hold(); + + File dest = new File(_deployPath, namePart.getText() + "-" + _store.getCurrentVersion()); + dest.mkdir(); + unzip(dest, (DataHandler) binaryNode.getDataHandler()); + + // Check that we have a deploy.xml + File deployXml = new File(dest, "deploy.xml"); + if (!deployXml.exists()) + throw new OdeFault("The deployment doesn't appear to contain a deployment " + + "descriptor in its root directory named deploy.xml, aborting."); + + Collection<QName> deployed = _store.deploy(dest); + + File deployedMarker = new File(_deployPath, dest.getName() + ".deployed"); + deployedMarker.createNewFile(); + + // Telling the poller what we deployed so that it doesn't try to deploy it again + _poller.markAsDeployed(dest); + __log.info("Deployment of artifact " + dest.getName() + " successful."); + + OMElement response = factory.createOMElement("response", null); + + if (__log.isDebugEnabled()) __log.debug("Deployed package: "+dest.getName()); + OMElement d = factory.createOMElement("name", null); + d.setText(dest.getName()); + response.addChild(d); + + for (QName pid : deployed) { + if (__log.isDebugEnabled()) __log.debug("Deployed PID: "+pid); + d = factory.createOMElement("id", null); + d.setText(pid); + response.addChild(d); + } + sendResponse(factory, messageContext, "deployResponse", response); + } finally { + _poller.release(); + } + } else if (operation.equals("undeploy")) { + OMElement part = messageContext.getEnvelope().getBody().getFirstElement().getFirstElement(); + + String pkg = part.getText(); + File deploymentDir = new File(_deployPath, pkg); + if (!deploymentDir.exists()) + throw new OdeFault("Couldn't find deployment package " + pkg + " in directory " + _deployPath); + + try { + // We're going to create a directory under the deployment root and put + // files in there. The poller shouldn't pick them up so we're asking + // it to hold on for a while. + _poller.hold(); + + Collection<QName> undeployed = _store.undeploy(deploymentDir); + + File deployedMarker = new File(_deployPath, pkg + ".deployed"); + deployedMarker.delete(); + FileUtils.deepDelete(new File(_deployPath, pkg)); + + OMElement response = factory.createOMElement("response", null); + response.setText("" + (undeployed.size() > 0)); + sendResponse(factory, messageContext, "undeployResponse", response); + _poller.markAsUndeployed(deploymentDir); + } finally { + _poller.release(); + } + } else if (operation.equals("listDeployedPackages")) { + Collection<String> packageNames = _store.getPackages(); + OMElement response = factory.createOMElement("deployedPackages", null); + for (String name : packageNames) { + OMElement nameElmt = factory.createOMElement("name", null); + nameElmt.setText(name); + response.addChild(nameElmt); + } + sendResponse(factory, messageContext, "listDeployedPackagesResponse", response); + } else if (operation.equals("listProcesses")) { + OMElement namePart = messageContext.getEnvelope().getBody().getFirstElement().getFirstElement(); + List<QName> processIds = _store.listProcesses(namePart.getText()); + OMElement response = factory.createOMElement("processIds", null); + for (QName qname : processIds) { + OMElement nameElmt = factory.createOMElement("id", null); + nameElmt.setText(qname); + response.addChild(nameElmt); + } + sendResponse(factory, messageContext, "listProcessResponse", response); + } else if (operation.equals("getProcessPackage")) { + OMElement qnamePart = messageContext.getEnvelope().getBody().getFirstElement().getFirstElement(); + ProcessConf process = _store.getProcessConfiguration(OMUtils.getTextAsQName(qnamePart)); + if (process == null) { + throw new OdeFault("Could not find process: " + qnamePart.getTextAsQName()); + } + String packageName = _store.getProcessConfiguration(OMUtils.getTextAsQName(qnamePart)).getPackage(); + OMElement response = factory.createOMElement("packageName", null); + response.setText(packageName); + sendResponse(factory, messageContext, "getProcessPackageResponse", response); + } else unknown = true; + } catch (Throwable t) { + // Trying to extract a meaningful message + Throwable source = t; + while (source.getCause() != null && source.getCause() != source) source = source.getCause(); + __log.warn("Invocation of operation " + operation + " failed", t); + throw new OdeFault("Invocation of operation " + operation + " failed: " + source.toString(), t); + } + if (unknown) throw new OdeFault("Unknown operation: '" + + messageContext.getAxisOperation().getName() + "'"); + } + + private File buildUnusedDir(File deployPath, String dirName) { + int v = 1; + while (new File(deployPath, dirName + "-" + v).exists()) v++; + return new File(deployPath, dirName + "-" + v); + } + + private void unzip(File dest, DataHandler dataHandler) throws AxisFault { + try { + ZipInputStream zis = new ZipInputStream(dataHandler.getDataSource().getInputStream()); + ZipEntry entry; + // Processing the package + while((entry = zis.getNextEntry()) != null) { + if(entry.isDirectory()) { + __log.debug("Extracting directory: " + entry.getName()); + new File(dest, entry.getName()).mkdir(); + continue; + } + __log.debug("Extracting file: " + entry.getName()); + File destFile = new File(dest, entry.getName()); + if (!destFile.getParentFile().exists()) destFile.getParentFile().mkdirs(); + copyInputStream(zis, new BufferedOutputStream( + new FileOutputStream(destFile))); + } + zis.close(); + } catch (IOException e) { + throw new OdeFault("An error occured on deployment.", e); + } + } + + private void sendResponse(SOAPFactory factory, MessageContext messageContext, String op, + OMElement response) throws AxisFault { + MessageContext outMsgContext = Utils.createOutMessageContext(messageContext); + outMsgContext.getOperationContext().addMessageContext(outMsgContext); + + SOAPEnvelope envelope = factory.getDefaultEnvelope(); + outMsgContext.setEnvelope(envelope); + + OMElement responseOp = factory.createOMElement(op, _pmapi); + responseOp.addChild(response); + envelope.getBody().addChild(response); + AxisEngine.send(outMsgContext); + } + } + + private static void copyInputStream(InputStream in, OutputStream out) + throws IOException { + byte[] buffer = new byte[1024]; + int len; + while((len = in.read(buffer)) >= 0) + out.write(buffer, 0, len); + out.close(); + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/ManagementService.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/ManagementService.java new file mode 100644 index 0000000..90a74b6 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/ManagementService.java
@@ -0,0 +1,156 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.service; + +import java.io.File; +import java.io.IOException; +import java.io.PrintWriter; +import java.io.StringWriter; + +import javax.wsdl.Definition; +import javax.wsdl.WSDLException; +import javax.wsdl.factory.WSDLFactory; +import javax.wsdl.xml.WSDLReader; +import javax.xml.namespace.QName; + +import org.apache.axiom.om.OMElement; +import org.apache.axiom.soap.SOAPEnvelope; +import org.apache.axiom.soap.SOAPFactory; +import org.apache.axiom.soap.SOAPFault; +import org.apache.axiom.soap.SOAPFaultCode; +import org.apache.axiom.soap.SOAPFaultDetail; +import org.apache.axiom.soap.SOAPFaultReason; +import org.apache.axis2.AxisFault; +import org.apache.axis2.context.MessageContext; +import org.apache.axis2.description.AxisService; +import org.apache.axis2.engine.AxisConfiguration; +import org.apache.axis2.engine.AxisEngine; +import org.apache.axis2.receivers.AbstractMessageReceiver; +import org.apache.axis2.util.Utils; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.hooks.ODEAxisService; +import org.apache.ode.bpel.engine.ProcessAndInstanceManagementImpl; +import org.apache.ode.bpel.iapi.BpelServer; +import org.apache.ode.bpel.iapi.ProcessStore; +import org.apache.ode.bpel.pmapi.InstanceManagement; +import org.apache.ode.bpel.pmapi.ProcessManagement; +import org.apache.ode.il.DynamicService; +import org.apache.ode.utils.Namespaces; + +/** + * Axis2 wrapper for process and instance management interfaces. + */ +public class ManagementService { + + private static final Log __log = LogFactory.getLog(ManagementService.class); + + public static final QName PM_SERVICE_NAME = new QName("http://www.apache.org/ode/pmapi", "ProcessManagementService"); + public static final String PM_PORT_NAME = "ProcessManagementPort"; + public static final String PM_AXIS2_NAME = "ProcessManagement"; + + public static final QName IM_SERVICE_NAME = new QName("http://www.apache.org/ode/pmapi", "InstanceManagementService"); + public static final String IM_PORT_NAME = "InstanceManagementPort"; + public static final String IM_AXIS2_NAME = "InstanceManagement"; + + private ProcessManagement _processMgmt; + private InstanceManagement _instanceMgmt; + + public void enableService(AxisConfiguration axisConfig, BpelServer server, ProcessStore _store, String rootpath) { + ProcessAndInstanceManagementImpl pm = new ProcessAndInstanceManagementImpl(server, _store); + _processMgmt = pm; + _instanceMgmt = pm; + + Definition def; + try { + WSDLReader wsdlReader = WSDLFactory.newInstance().newWSDLReader(); + wsdlReader.setFeature("javax.wsdl.verbose", false); + + File wsdlFile = new File(rootpath + "/pmapi.wsdl"); + def = wsdlReader.readWSDL(wsdlFile.toURI().toString()); + AxisService processService = ODEAxisService.createService(axisConfig, PM_SERVICE_NAME, PM_PORT_NAME, + PM_AXIS2_NAME, def, new DynamicMessageReceiver<ProcessManagement>(_processMgmt)); + AxisService instanceService = ODEAxisService.createService(axisConfig, IM_SERVICE_NAME, IM_PORT_NAME, + IM_AXIS2_NAME, def, new DynamicMessageReceiver<InstanceManagement>(_instanceMgmt)); + axisConfig.addService(processService); + axisConfig.addService(instanceService); + } catch (WSDLException e) { + __log.error("Couldn't start-up management services!", e); + } catch (IOException e) { + __log.error("Couldn't start-up management services!", e); + } + } + + public ProcessManagement getProcessMgmt() { + return _processMgmt; + } + + public InstanceManagement getInstanceMgmt() { + return _instanceMgmt; + } + + class DynamicMessageReceiver<T> extends AbstractMessageReceiver { + T _service; + + public DynamicMessageReceiver(T service) { + _service = service; + } + + public void invokeBusinessLogic(MessageContext messageContext) throws AxisFault { + DynamicService<T> service = new DynamicService<T>(_service); + MessageContext outMsgContext = Utils.createOutMessageContext(messageContext); + outMsgContext.getOperationContext().addMessageContext(outMsgContext); + SOAPFactory soapFactory = getSOAPFactory(messageContext); + SOAPEnvelope envelope = soapFactory.getDefaultEnvelope(); + outMsgContext.setEnvelope(envelope); + + OMElement response; + try { + response = service.invoke(messageContext.getAxisOperation().getName().getLocalPart(), + messageContext.getEnvelope().getBody().getFirstElement()); + if (response != null) { + envelope.getBody().addChild(response); + } + } catch (Exception e) { + // Building a nicely formatted fault + envelope.getBody().addFault(toSoapFault(e, soapFactory)); + } + AxisEngine.send(outMsgContext); + } + + private SOAPFault toSoapFault(Exception e, SOAPFactory soapFactory) { + SOAPFault fault = soapFactory.createSOAPFault(); + SOAPFaultCode code = soapFactory.createSOAPFaultCode(fault); + code.setText(new QName(Namespaces.SOAP_ENV_NS, "Server")); + SOAPFaultReason reason = soapFactory.createSOAPFaultReason(fault); + reason.setText(e.toString()); + + OMElement detail = soapFactory + .createOMElement(new QName(Namespaces.ODE_PMAPI, e.getClass().getSimpleName())); + StringWriter stack = new StringWriter(); + e.printStackTrace(new PrintWriter(stack)); + detail.setText(stack.toString()); + SOAPFaultDetail soapDetail = soapFactory.createSOAPFaultDetail(fault); + soapDetail.addDetailEntry(detail); + return fault; + } + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/ServiceClientUtil.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/ServiceClientUtil.java new file mode 100644 index 0000000..63a9045 --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/service/ServiceClientUtil.java
@@ -0,0 +1,114 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ + +package org.apache.ode.axis2.service; + +import org.apache.axiom.om.OMAbstractFactory; +import org.apache.axiom.om.OMElement; +import org.apache.axiom.om.OMFactory; +import org.apache.axiom.om.OMNamespace; +import org.apache.axis2.AxisFault; +import org.apache.axis2.addressing.EndpointReference; +import org.apache.axis2.client.Options; +import org.apache.axis2.client.ServiceClient; +import org.apache.ode.utils.Namespaces; + +import javax.xml.namespace.QName; + +/** + * Client utilities that can be used to invoke easily the deployment + * and management services with Axis2. + */ +public class ServiceClientUtil { + + /** + * Sends the provided message to an Axis2 deployed service. + * @param msg the message OMElement that will be included in the body + * @param url to send the message to + * @return the response message + * @throws AxisFault when a problem occured during the call + */ + public OMElement send(OMElement msg, String url) throws AxisFault { + return send(msg, url, Options.DEFAULT_TIMEOUT_MILLISECONDS); + } + + /** + * Sends the provided message to an Axis2 deployed service allowing to set a + * specific timeout (in ms). + * @param msg the message OMElement that will be included in the body + * @param url to send the message to + * @param timeout in milliseconds + * @return the response message + * @throws AxisFault when a problem occured during the call + */ + public OMElement send(OMElement msg, String url, long timeout) throws AxisFault { + Options options = new Options(); + EndpointReference target = new EndpointReference(url); + options.setTo(target); + options.setTimeOutInMilliSeconds(timeout); + + ServiceClient serviceClient = new ServiceClient(); + serviceClient.setOptions(options); + + return serviceClient.sendReceive(msg); + } + + /** + * Builds a message for the deployment and management API using simple parameter + * passing. Example: <br/> + * <code> + * buildMessage("listProcesses", new String[] {"filter", "orderKeys"}, + * new String[] {"name=DynPartnerResponder namespace=http://ode/bpel/responder " + + * "deployed>=" + notSoLongAgoStr, ""}); + * </code> + * @param operation to call + * @param params list of the parameters for the operation as defined in the WSDL document + * @param values of the parameters + * @return the message to send + */ + public OMElement buildMessage(String operation, String[] params, Object[] values) { + OMFactory _factory = OMAbstractFactory.getOMFactory(); + OMNamespace pmns = _factory.createOMNamespace(Namespaces.ODE_PMAPI, "pmapi"); + OMElement root = _factory.createOMElement(operation, pmns); + for (int m = 0; m < params.length; m++) { + OMElement omelmt = _factory.createOMElement(params[m], null); + if (values[m] == null) + omelmt.setText(""); + else if (values[m] instanceof String) + omelmt.setText((String) values[m]); + else if (values[m] instanceof QName) + omelmt.setText((QName) values[m]); + else if (values[m] instanceof OMElement) + omelmt.addChild((OMElement) values[m]); + else if (values[m] instanceof Object[]) { + Object[] subarr = (Object[]) values[m]; + String elmtName = (String) subarr[0]; + for (int p = 1; p < subarr.length; p++) { + OMElement omarrelmt = _factory.createOMElement(elmtName, null); + omarrelmt.setText(subarr[p].toString()); + omelmt.addChild(omarrelmt); + } + } else throw new UnsupportedOperationException("Type " + values[m].getClass() + "isn't supported as " + + "a parameter type (only String and QName are)."); + root.addChild(omelmt); + } + return root; + } + +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/util/Axis2UriResolver.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/util/Axis2UriResolver.java new file mode 100644 index 0000000..3ba02db --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/util/Axis2UriResolver.java
@@ -0,0 +1,55 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.apache.ode.axis2.util; + +import java.io.InputStream; +import java.net.URI; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.apache.ode.axis2.hooks.ODEAxisService; +import org.xml.sax.InputSource; + +public class Axis2UriResolver implements org.apache.ws.commons.schema.resolver.URIResolver { + private static final Log LOG = LogFactory.getLog(ODEAxisService.class); + + public InputSource resolveEntity(String targetNamespace, String schemaLocation, String baseUri) { + if (LOG.isDebugEnabled()) { + LOG.debug("resolveEntity: targetNamespace=" + targetNamespace + " schemaLocation=" + schemaLocation + + " baseUri=" + baseUri); + } + InputStream is; + try { + URI base = new URI(baseUri); + URI uri = base.resolve(schemaLocation); + is = uri.toURL().openStream(); + if (is == null) { + LOG.error("Exception resolving entity: schemaLocation=" + schemaLocation + " baseUri=" + baseUri); + return null; + } + InputSource source = new InputSource(is); + source.setSystemId(uri.toString()); + source.setPublicId(schemaLocation); + return new InputSource(is); + } catch (Exception e) { + LOG.error("Exception resolving entity: schemaLocation=" + schemaLocation + " baseUri=" + baseUri, e); + return null; + } + } +}
diff --git a/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/util/Axis2WSDLLocator.java b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/util/Axis2WSDLLocator.java new file mode 100644 index 0000000..00ace7e --- /dev/null +++ b/_br-ode-1.X.svn/axis2/src/main/java/org/apache/ode/axis2/util/Axis2WSDLLocator.java
@@ -0,0 +1,115 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.apache.ode.axis2.util; + +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.io.InputStream; +import java.net.URI; +import java.net.URISyntaxException; + +import javax.wsdl.xml.WSDLLocator; + +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; +import org.xml.sax.InputSource; + +public class Axis2WSDLLocator implements WSDLLocator { + private static final Log LOG = LogFactory.getLog(Axis2WSDLLocator.class); + private URI _baseUri; + private String _latest; + + public Axis2WSDLLocator(URI baseUri) throws URISyntaxException { + _baseUri = baseUri; + } + + public InputSource getBaseInputSource() { + try { + InputSource is = new InputSource(); + is.setByteStream(openResource(_baseUri)); + is.setSystemId(_baseUri.toString()); + return is; + } catch (IOException e) { + LOG.error("Unable to create InputSource for " + _baseUri, e); + return null; + } + } + + public InputSource getImportInputSource(String parent, String imprt) { + URI uri; + try { + uri = parent == null ? _baseUri.resolve(imprt) : new URI(parent).resolve(imprt); + } catch (URISyntaxException e1) { + LOG.error("URI syntax error: parent="+parent+" error="+e1); + return null;