flectSoap
インデックスに戻る
概要
シンプルなSOAP Clientです。
AxisやApacheSOAPを利用しないフルスクラッチ実装となっています。
サンプル
以下はSalesforceにログインする処理のサンプルです。
※Salesforceに接続する場合はflectSalesforceを使用する方が簡単です。
SoapClient client = new SoapClient(new File("partner.wsdl")); //Input parameters are set in java.util.Map. //Its structure is same as SOAP body. //You can set values in the deep position by using ExtendedMap. ExtendedMap input = new ExtendedMap(true); input.putDeep("login.username", SALESFORCE_USERNAME); input.putDeep("login.password", SALESFORCE_PASSWORD + SALESFORCE_SECRET); /* //Above code is same as this. Mapinput = new HashMap //Invoke method SoapResponse res = client.invoke("login", null, input); ExtendedMap output = res.getAsMap(); String sessionId = (String)output.getDeep("loginResponse.result.sessionId"); String endpont = (String)output.getDeep("loginResponse.result.serverUrl"); client.setEndpoint(endpoint);(); Map loginEl = new HashMap (); loginEl.put("username", SALESFORCE_USERNAME); loginEl.put("password", SALESFORCE_PASSWORD + SALESFORCE_SECRET); input.put("login", loginEl); */
最新版
ダウンロード - 1.2.1
Maven
<repositories> <repository> <id>jp.co.flect</id> <name>FLECT maven repository</name> <url>http://flect.github.io/maven-repo/</url> </repository> </repositories> <dependencies> <dependency> <groupId>jp.co.flect</groupId> <artifactId>flectSoap</artifactId> <version>1.2.1</version> </dependency> </dependencies>
ライセンス
MIT
商用利用を公式サポートする有償版のご用意があります。
詳細は info@flect.co.jp にお問い合わせください。