WebSphere Product Center: ポータル機能
バージョン 5.2
注! 本書および本書で紹介する製品をご使用になる前に、 特記事項に記載されている情報をお読みください。
21 March2005
本書は、WebSphere Product Center バージョン 5.2 (5724-I68) および新しい版で明記されていない限り、 以降のすべてのリリースおよびモディフィケーションに適用されます。
(C) Copyright International Business
Machines Corporations 2005. All rights reserved.
第 2 章 ポータル統合フレームワークのアーキテクチャー
Product Center の統合フレームワーク
WebSphere Portal Server の Web サービス機能
データ
Product Center の要求データと応答データ
アイテム仕様
コンポーネント
Product Center Mediator
Web サービスのインターフェース
データ・コンバーター
データ・タイプ
データ Bean
ユーザー・インターフェース・コンポーネント
データ交換サービス
サービス
国際化対応/ローカリゼーションのサポート
セキュリティー・サポート
参考資料
LDAP を使用した Portal Server セキュリティーの構成
LDAP 用データベースの構成
LDAP 用データベースの構成
サフィックスの追加
ポータル・ユーザーの作成
ポータルの構成
ポータル管理ユーザーの作成
サプライヤー・ポータルのログイン・サービスのカスタマイズ
Product Center の構成
結論
参考資料
第 4 章 WebSphere Product Center ポートレットの作成
サンプル・ポートレット - WorkWithItem
XML メッセージ
アイテムを表すデータ・オブジェクト
XML 生成プログラムおよび XML パーサー
Product Center Mediator へのメソッドの追加
ポートレットの作成
WebSphere Product Center Web サービスの指定
第 5 章 サプライヤー・ポータルのデプロイメントと UI カスタマイズ
サプライヤー・ポータルのデプロイ
サプライヤー・ポータルの UI のカスタマイズ
ナビゲーション・メニューの作成
テーマおよびスキンのインストール
タブにポートレットをレイアウトする
タブに対するアクセス権の提供
構成ファイルの更新
構成ファイル
結論
第 6 章 ユーザー・インターフェース・フレームワーク
ポートレットの構造
ポートレットの品目
第 7 章 メッセージ形式の概要
呼び出されるスクリプトと Web サービスの概要
さまざまなメッセージ形式
WebSphere Product Center のポータル機能は、お客様が取引先ポータルを構築するための基盤となります。ポータルを使用すると、多数のユーザーが貴重なアイテム・データにアクセスすることが可能になり、WebSphere Product Center を実装する価値が大いに増します。
ポータル機能がサポートするビジネス・プロセスの例は、以下のとおりです。アイテムの作成または変更、同期されたアイテム情報の変更、アイテムの一括アップロード、ユーザー特有の選択、および提案や使用条件データの入力。
WebSphere Portal Server と WebSphere Product Center の統合を容易に行うことができます。Portal Server の統合により、Portal Server から以下の操作を実行できます。
WebSphere Product Center へのアイテムの追加
WebSphere Product Center のアイテムの変更
WebSphere Product Center のアイテムの削除
GTIN (Global Trade Identification Number)、SKU (Stock Keeping Unit)、GLN (Global Location Number) に基づくアイテムの検索
サポートの選択
CSV (コンマ区切り値) のアップロードとダウンロード
一括更新
本書では、WebSphere Product Center 環境において以下のコンポーネントが使用されているものと想定しています。
現在、WebSphere Product Center に商品情報管理ポートレットはありません。ただし、WebSphere Product Center には、ポートレットとサプライヤー・ポータル・ユーザー・インターフェースの開発をサポートするのに必要な API とメタデータが備わっています。
この章では、IBM WebSphere Product Center (以後、Product Center とします) 用のポートレット作成方法について取り上げます。また、Product Center にユーザー・インターフェースを提供するためのアーキテクチャーについて説明します。
統合フレームワークは、ポートレットと Product Center との連動をサポートします。それによってユーザーは Product Center の情報を表示したり、その情報を扱う仕事をしたりすることができます。ユーザー・インターフェース・フレームワークと Product Center との統合は、Product Center の Web サービス・サポートに基づいています。
このアーキテクチャーは、Product Center が提供する Web サービス・インターフェースを介して Product Center と通信するポートレットで構成されています (図 1 を参照してください)。Product Center には、API レイヤーとして使用できるスクリプト・レイヤーがあります。こうしたスクリプトは、後ほど Web サービスとして公開できます。Product Center で公開する必要のあるすべてのビジネス機能に対して、Web サービスを作成します。この Web サービスと対話するために、対応するポートレットを作成します。Web サービスは 1 つ以上のスクリプトを Product Center で実行し、所要のビジネス機能を提供するため他の Web サービスと連動します。Web サービスは、スクリプトおよび他の Web サービスとの間で必要な振り付けを実行することにより、以下の事柄を可能にします。
図 1
ポータル統合の場合、XML 文書がデータ転送のモードとなります。受け取る要求メッセージのモードに応じて、応答が即時に送られたり、後で送られたりします。下の図 2 は、アーキテクチャー全体について説明しています。
図 2
Product Center と WebSphere Portal Server との間の通信は、必ずドキュメント/リテラル・ベースの XML 文書変換になります。ASYNC / SYNC トランザクションの維持は Product Center の Web サービス・フレームワークに依存し、インプリメンテーション・スクリプト・レベルには依存しません。この機能により、スクリプトに変更を加えることなく、どの操作をどの時点においてでも ASYNC / SYNC にすることができます。
データ交換形式は XML であり、データ・モデルは単一のエンベロープ (トランザクションの処理に必要な情報を定義したコンテナー) に基づいています。エンベロープは、以下を定義します。
要求 XML 構造のサンプルを、以下の表 1 に示します。
表 1: 要求 XML
<wpc:envelope xmlns:wpc="http://ibm.com/wpc/" communicationVersion="5.2">
<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>
<wpc:wpcHeader>
<wpc:companyName>TSS</wpc:companyName>
<wpc:userID>Scott</wpc:userID>
<wpc:password>null</wpc:password>
<wpc:messageIdentifier> 905EF150-8F05-11D9-B150-B7A43B4A833E </wpc:messageIdentifier>
<wpc:timestamp>2005-03-07</wpc:timestamp>
<wpc:supplierId>1234567890123</wpc:supplierId>
</wpc:wpcHeader>
<wpc:wpcBody>
<wpc:wpcCommand type="ITEMDETAIL" mode="SYNC">
<wpc:wpcParentCategory />
<wpc:wpcCatalogName>CTG_PORTAL_MASTER </wpc:wpcCatalogName>
<wpc:wpcTradeItem ID="C139" />
</wpc:wpcCommand>
</wpc:wpcBody>
</wpc:envelope>
対応する応答 XML のサンプルを、表 2 に示します。
表 2: 応答 XML
<wpc:envelope communicationVersion="5.2" xmlns:wpc="http://ibm.com/wpc/">
<wpc:wpcHeader>
<wpc:companyName>TSS</wpc:companyName>
<wpc:userID>wpsadmin</wpc:userID>
<wpc:password>null</wpc:password>
<wpc:messageIdentifier>1110199602</wpc:messageIdentifier>
<wpc:timestamp>2005-03-07</wpc:timestamp>
</wpc:wpcHeader>
<wpc:wpcBody>
<wpc:wpcResponse>
<wpc:wpcEntityIdentifier>
<wpc:wpcMessageIdentifier>8CD1DD80-8F06-11D9-9D80-A9B52946044C</wpc:wpcMessageIdentifier>
</wpc:wpcEntityIdentifier>
<wpc:wpcNotification type="SUCCESS">
<wpc:notificationInfo>
<wpc:notificationCode>000</wpc:notificationCode>
<wpc:notificationMessage>SUCCESS</wpc:notificationMessage>
</wpc:notificationInfo>
</wpc:wpcNotification>
<wpc:wpcTradeItem ID="C144">
...
...
</wpc:wpcTradeItem>
</wpc:wpcResponse>
</wpc:wpcBody>
</wpc:envelope>
アイテム仕様は、アイテムとその属性コレクションの Product Center 固有の定義です。この定義は、XML 文書の形式で収集できます。このアイテム仕様は、アイテムとその属性を定義するために使用する多様なデータ・タイプを参照する際に使用します。アイテム仕様をビューの定義と組み合わせて使用すると、ポートレットの画面をレンダリングするのに役立ちます。これは自動レンダリング・モードの場合も、開発者が JSP をハンド・コーディングしなければならない場合も同じです。
フレームワークは、Product Center との対話の実行やデータ形式変更に役立つコンポーネントのセットで構成されています。
Mediator は、ポートレットや Product Center Web サービスとの対話を支援します。これは、これらのレイヤーの単一の接点となるとともに、必要なデータ形式変更を行ってこれらのレイヤーがそれを使用できるようにします。Mediator は、一緒に働くポートレットのためのインターフェースとして公開されています。
Web サービスのインターフェースは、AXIS Web Services Invocation Framework を使用して実現されます。Web サービス・レイヤーが AXIS クライアントと対話して、対応する Web サービス呼び出しを Product Center に対して開始します。Web サービスの呼び出しはドキュメント/リテラル・タイプです。通信プロトコルとしては SOAP が使用され、現在のところ HTTP トランスポート上で実行されています。現行の Web サービス・レイヤーは XML データを交換するため、および添付ファイルをアップロードやダウンロードするために使用されています。AXIS の SwA (SOAP-with-Attachment) のインプリメンテーションは、この目的で使用されます。AXIS フレームワークの詳細については、この章の『参考資料』というセクションを参照してください。
構成ファイルには、ユーザー・インターフェースからのアクションに応じて呼び出さなければならない Web サービスのリストが保持されます。アクションから Web サービスへのこのマッピングは、以下の形式で含められます。
表 3: アクションから Web サービスへのマッピング
<soap-url action="<action name>">http://<server name>:<server port>/services/<service name></soap-url>
<soap-url action="ADD">http://ibm.com:9557/webservices/addAction</soap-url>
Mediator レイヤーは、Product Center からの XML コンテンツを解析したり、生成された XML コンテンツを Product Center で使用できるように変換したりするために、パーサーや生成プログラムのセットを使用します。こうしたコンバーターは、XML 形式のデータを事前定義された Java オブジェクトに変換したり、その逆方向に変換したりします。Java オブジェクトに変換するには、データ・タイプとデータ・オブジェクトの定義されたセットのサポートが必要です。こうした点について、以下のセクションで説明します。
Product Center は、アイテム定義の属性のセットを定義します。こうした属性には、ストリングや数値などからグループ属性に至るまで、多様なタイプがあります。ユーザー・インターフェース・フレームワーク側の属性タイプとその振る舞いは、属性クラスおよび属性タイプ・クラスのセットに取り込まれます。
図 3 に、サポートされる属性すべてをリストします。こうした属性は、検証、フォーマット、およびレンダリング機能を付加するための基礎となります。
データ Bean は、ポートレットに表示されるコンテンツのサポートを提供するとともに、ポートレットの現在の状態またはモードを保管するためのユーザー・インターフェースのフローを制御します。
ユーザー・インターフェース・コンポーネントは主に、ユーザー・インターフェースのレンダリングやユーザーの対話の処理に関与します。また、Mediator レイヤーに対して特定の呼び出しを行って、Product Center からデータを取り出したり、Product Center にデータを保管したりします。主要なユーザー・インターフェース・コンポーネントは、ポートレットとタグ・ライブラリー (ポートレットのユーザー・インターフェースのレンダリングに役立つ) です。
図 3
Portal Server にデプロイされたポートレット同士には、情報を交換するための簡単な方法がありません。異なるページ上のポートレット同士の場合は特にそうです。ポートレット同士の通信が有効なのは、それらがともに同じページにある場合に限られます。データ交換サービスはすべてのポートレットのために単一の接点を提供します。このサービスは情報を保持する能力を備えており、ポートレットはこのサービスを使用してデータを交換します。現在のところ、このサービスは singleton であり、単純な Java メソッドの起動の形で呼び出されます。将来、このサービスは、より広範囲に渡るオブジェクト交換のセットまたはタイプを提供するように拡張を施され、パフォーマンス調整面を改善するために別個のアプリケーションとしてデプロイされる予定です。
ユーザー・インターフェース・フレームワークは、Portal Server が備えている基本的なインフラストラクチャーを使用して、国際化対応サポートとセキュリティーを提供します。
Portal Server には、テーマやスキンなど、ポータル・フレームワークによって表示されるコンテンツをローカライズするためのカスタム・タグやリソース・バンドルのセットが備わっています。ポートレット内のコンテンツのローカライズは、リソース・バンドル (ラベル、ボタン、および表示メッセージの内容を提供する) のセットを使用して行います。Product Center から取り出した内容のローカライズは、そのアプリケーションのレベルで使用可能なロケール・サポートを基にして行います。
ポータル・ベースのユーザー・インターフェース・フレームワークと Product Center は、ユーザー・レジストリーを保持する手段として LDAP を使用します。Product Center とユーザー・インターフェース・フレームワークは、ユーザー情報を保持するために別々のユーザー・スキーマのセットを使用します。これは主に、ポータル・レベルで登録されたユーザーは、サプライヤー・ポータルやベンダー・ポータルとの対話を実行するために、ポータル・レベルのスキーマを使用するからです。一方で、Product Center に登録されるユーザーは主に、システムのパワー・ユーザーまたは管理ユーザーです。ユーザー・レジストリーの領域における次のステップは、フレームワークが使用するスキーマと Product Center が使用するスキーマを統合することです。これにより、ユーザー・レジストリーや、ユーザーとその役割の定義の共通化ももたらされることになります。
ユーザーの認証
ベンダー・ポータルのシナリオでは、サプライヤーおよび一般ユーザーはポータルを使用して登録し、ポータルを介してログインします。ユーザー管理とその後のユーザー認証は、ポータルの LDAP レベルで実行されます。ポータルと基礎を成す Product Center レイヤーとが共有している重要な情報に、サプライヤーの ID 情報があります。この情報は、ユーザーが作成または処理したデータをフィルター操作するために使用されます。
ユーザーの許可
ログインしているユーザーに応じてデータに対する許可を与えるのは、主に Product Center の機能です。現在の状態のシステムにおいて、許可とは、基本的に言って、サプライヤー ID に基づいてデータをフィルター処理することです。ポータルにはポータル・アクセス許可の度合いが規定されていて、ユーザーが管理者であるか一般ユーザーであるかに応じて、表示やアクションの実行が許可されます。
以下の記事は、Product Center のポータル統合フレームワークのアーキテクチャーについて説明しています。
以下のセクションでは、組織内にサプライヤー・ポータルをデプロイメントできるようにするために必要な環境のセットアップについて詳述します。
この章では、WebSphere Product Center 環境の一部として以下のソフトウェアがインストールされているものと想定します。
使用するオペレーティング・システムの選択によって、インストールするソフトウェアの組み合わせが決まります。サプライヤー・ポータルが作動する基本プラットフォームは、Portal Server バージョン 5.0.2.2 です。
Websphere Product Center のポータル統合のインストールには、2 つの圧縮ファイルが含まれています。1 つは Portal Server 上にデプロイされ、もう 1 つはポータル統合用の Product Center サーバーにデプロイされます。
サプライヤー・ポータルのセットアップの第一歩として、LDAP により Portal Server のセキュリティーを構成します。このステップでは、IBM DB2、Directory Server、Directory Server Web 管理ツールがインストール済みであることを前提としています。
このステップでは、LDAP 用に DB2 インスタンスを構成します。
1. 次のようにナビゲートして Directory Server の構成ツールを開きます。「スタート」 -> 「プログラム」 -> 「IBM Tivoli Directory Server」 -> 「ディレクトリー構成 (Directory Configuration)」。
2. 構成ツールの左側で「管理者 DN/パスワード (Administrator DN/password)」を選択します。
3. 以下のフィールドに値を入力します。
4. 「OK」をクリックします。
5. 構成ツールの左側で「データベースの構成 (Configure database)」を選択します。
6. 「新しいデータベースの作成 (Create a new database)」オプションを選択してから、「次へ」をクリックします。
7. DB2 の admin ユーザーのユーザー ID とパスワードを入力します。(通常は、db2admin と password)「次へ」をクリックします。
8. 次の画面でデータベース名として DB2 インスタンス名を入力します。「完了 (Finish)」をクリックします。
このステップでは、LDAP 階層にサフィックスを追加します。
1. 次のようにナビゲートして Directory Server の構成ツールを開きます。「スタート」 -> 「プログラム」 -> 「IBM Tivoli Directory Server」 -> 「ディレクトリー構成 (Directory Configuration)」。
2. 構成ツールの左側で「サフィックスの管理 (Manage Suffixes)」を選択します。
3. 「サフィックス DN (Suffix DN)」フィールドに「dc=wps,dc=com」というストリングを入力します。
4. 「追加」をクリックします。その後、「OK」をクリックします。
このステップでは、ポータルへのアクセスを許可されたユーザーのリストを定義します。
1. 次のようにナビゲートして Directory Server の構成ツールを開きます。「スタート」 -> 「プログラム」 -> 「IBM Tivoli Directory Server」 -> 「ディレクトリー構成 (Directory Configuration)」。
2. 構成ツールの左側で「LDIF データのインポート (Import LDIF data)」を選択します。LDIF ファイルをブラウズしたり、ユーザー・データをインポートしたりするためのオプションがある画面が開きます。
3. サプライヤー・ポータルに必要な LDIF ファイルを選択して、インポートを実行します。インポートの状況が、タスク・メッセージ領域に反映されます。
このステップでは、ポータルのセキュリティーを構成します。
1. Directory Server がインストール済みで、WebSphere Portal に必要なすべてのセットアップが実行されていることを確認します。
2. <PortalServer_root>/config/wpconfig.properties ファイルを見つけて、値を変更する前にバックアップ・コピーを作成しておきます。
3. テキスト・エディターを使用して、<wp_root>/config/wpconfig.properties ファイルを開きます。
4. 末尾にサフィックス DN「dc=yourco,dc=com」が付いた項目すべてを、「dc=wps,dc=com」で終わるように置換します。
5. 「LDAP プロパティー構成 (LDAP Properties Configuration)」セクションの以下のプロパティーを、ご使用の環境に合わせて編集します。
WasUserid=uid=wpsbind,cn=users,dc=wps,dc=com
WasPassword=wpsbind
PortalAdminId=uid=wpsadmin,cn=users,dc=wps,dc=com
PortalAdminIdShort=wpsadmin
PortalAdminPwd=wpsadmin
LDAPHostName=localhost(IP Address of the LDAP Host machine)
LDAPPort=389
LDAPAdminUId=cn=root
LDAPAdminPwd=password
LDAPServerType=IBM_DIRECTORY_SERVER
LDAPBindID=uid=wpsbind,cn=users,dc=wps,dc=com
LDAPBindPassword=wpsbind
LDAPSuffix=dc=wps,dc=com
6. ファイルを保管します。
7. コマンド・プロンプトを開き、ディレクトリーを <AppServer_root>/bin に変更します。
8. 以下のコマンドを入力します。
startServer server1
stopServer WebSphere_Portal
9. ディレクトリーを <PortalServer_root>/config に変更します。
10. 以下のコマンドを入力して、適切な構成タスクを実行します。
WPSconfig.bat validate-ldap
注: 構成タスクが失敗した場合は、wpconfig.properties ファイルの値を検証してください。
11. 以下のコマンドを入力して、LDAP セキュリティーを使用可能にするための適切な構成タスクを実行します。
WPSconfig.bat enable-security-ldap
12. ディレクトリーを <AppServer_root>/bin に変更して、以下のコマンドを入力します。
(a) stopServer server1
(b) startServer server1
(c) startServer WebSphere_PortalWebSphere Application Server でセキュリティーを使用可能にして実行する場合は、以下のコマンドを入力する際にセキュリティー認証のためにユーザー ID とパスワードを指定する必要があります。
(d) stopServer server1 -user was_admin_userid -password was_admin_password
(e) startServer server1
(f) startServer WebSphere_Portal注: インストール・タイプおよびオペレーティング環境によっては、Infocenter にあるさらにいくつかのステップを実行する必要があります。要件によっては、こうしたステップを除外できます。
このステップでは、管理特権を持つポータル・ユーザーを作成します。
1. Directory Server Web 管理ツールにログインします。
2. 「スキーマ管理 (Schema management)」>「属性の追加 (Add an attribute)」を選択して、以下の属性を追加します。
WPCRole{Syntax - Directory String Syntax, Attribute Length - 50}
userStatus{Syntax - Boolean}
userGLN{Syntax - Directory String Syntax, Attribute Length - 50}
company{Syntax - Directory String Syntax, Attribute Length - 50}
3. 「スキーマ管理 (Schema management)」>「オブジェクト・クラスの追加 (Add an object class)」を選択して、以下を追加します。
オブジェクト・クラス: wpcUserClass
必須属性 - abstract、company、UserStatus、WPCRole
オプション属性 - userGLN
4. 変更すべてを保管します。
5. 構成ツールから portalAdmin.ldif ファイルをインポートします。参照用に Admin LDIF ファイルのサンプルが添付されます。
6. ポータル用の admin/admin/ibm でログインします。
ポータルは Product Center 用のインターフェースとなります。ポータルにログインするとき、ユーザーはユーザー ID、パスワード、および会社情報を入力することが必要です。したがって、Portal Server に用意されている標準のログイン・ページに変更を加える必要があります。
1. ログイン・ページをカスタマイズする前に、サプライヤー・ポータルの管理特権を持つユーザーを構成する必要があります。
(a) ポータル管理者のユーザー ID とパスワードでログインします。
(b) 上部バーの管理リンクをクリックして、左側にある「アクセス (Access)」>「ユーザーとグループ (Users and Group) 」を選択します。
(c)「グループ (Groups)」が表示されたら、wpsadmins を選択します。
(d) portalAdmin.ldif で作成したユーザー「admin」を追加して、変更を保管します。その結果、「admin」ユーザーはサプライヤー・ポータルに対する管理特権を持つようになります。
2. ポータル・ユーザーがポータルにログインまたはログアウトするとき、WP はログイン/ログアウト・コマンドを実行します。これらのコマンドのクラス名はプロパティー・ファイル PortalServer_root>/shared/app/config/services/ConfigService.properties に指定されています。デフォルト設定は次のとおりです。command.login = LoginUserAuth and command.logout = LogoutUserAuth
これらのコマンドのパッケージ検索パスはプロパティー・ファイル <PortalServer_root>/shared/app/config/services/LoaderService.properties にコンマ区切りリストの形で指定されます。デフォルト設定は次のとおりです。
command.path = com.ibm.wps.engine.commands
3. LDAP に関連するユーティリティーが必要とする customlogin.jar を、<PortalServer_Root>/shared/app フォルダーに配置します。
4. LDAP に関連するユーティリティーが必要とする ibmjndi.jar を、<PortalServer_root>/shared/app フォルダーに配置します。
5. 次に、新規クラスがポータル・クラスパスにあることを確認してから、LoaderService.properties の command.path の最初の項目としてコマンドのパッケージを追加します。
例: command.path=com.ibm.ccd.ui.services.user, com.ibm.wps.engine.commands
6. <AppServer_root>/installedApps/<hostname>/wps.ear/wps.war/screens/html フォルダー内の「Login.jsp」を編集して、必要なフィールドを追加します。たとえば、次のコード・フラグメントは、ログイン画面にフィールド「Company」を追加します。キャンセル・ボタンのコード・フラグメントは不要なのでコメント化します。
<tr>
<td> </td>
<td align="<%= bidiAlignLeft %>" class="wpsEditText">
<label for="company">
<wps:text key="company" bundle="nls.field"/>
</label>
</td>
</tr>
<tr>
<td> </td>
<td> <input dir="ltr" class="wpsFieldText" size="16" value="" id="company" name="company" type="text"></td>
</tr>
7. Login.jsp の nls 関連項目を <PortalServer_root>/shared/app/nls/field.properties にあるプロパティー・ファイルに追加します。
例: company = Company
8. Login.jsp に関連するエラー・メッセージを、<PortalServer_root>/shared/app/nls/problem.properties にあるプロパティー・ファイルに追加します。
9. サプライヤー・ポータルに関する以下の項目を追加します。
(a) login.invalid.userStatus = このユーザーは非アクティブです。システム管理者と連絡を取ってください。
(b) login.invalid.company = このユーザーはこの会社に属していません。確認してください。
(c) ldap.not.configured = LDAP 認証サービスに障害が発生しています。システム管理者と連絡を取ってください。
Portal Server と統合できるよう Product Center を正しく構成するには、以下のステップを使用します。
1. common.properties 内の soap_company、soap_user、および trigo_web_url の値を設定します。
a) soap_company は、Product Center を使用している会社の名前です。
b) soap_user は、必ず Admin になります。
c) trigo_web_url は、http://<ipaddress>:<port> になります。
2. public_html ディレクトリーをマウントします。
3. common.properties で mountmgr デーモンの頻度を 1000 に増やします。
4. Portal_Config ルックアップ・テーブルの FTP 詳細情報を変更します。サンプル値が用意されています。
5. (Portal_Config 内の) ftpDir は、FTP サーバーのルート・ディレクトリーの下でなければなりません。
6. /public_html/WEB-INF/server-config.wsdd に位置しているファイルを書き込み可能にします。
7. 最初に PORTAL_LKP.ZIP をインポートします。
8. 次に PORTAL_NON_LKP.ZIP をインポートします。
9. 上記のステップの後に、サーバーを再始動します。
10. Web Logic の場合、以下のブロックを変更してから Web サービスを保管してください。
<xs:element name="wpcSearchElementOperator">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="="/>
<xs:enumeration value=">="/>
<xs:enumeration value="<="/>
<xs:enumeration value=">"/>
<xs:enumeration value="<"/>
<xs:enumeration value="!="/>
<xs:enumeration value="BEGINSWITH"/>
<xs:enumeration value="CONTAINS"/>
<xs:enumeration value="ENDSWITH"/>
<xs:enumeration value="ISEMPTY"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
上記のブロックを以下のように変更します。
<xs:element name="wpcSearchElementOperator">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="="/>
<xs:enumeration value=">="/>
<xs:enumeration value="<="/>
<xs:enumeration value=">"/>
<xs:enumeration value="<"/>
<xs:enumeration value="!="/>
<xs:enumeration value="BEGINSWITH"/>
<xs:enumeration value="CONTAINS"/>
<xs:enumeration value="ENDSWITH"/>
<xs:enumeration value="ISEMPTY"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
この章の終わりまでに、以下のタスクが完了したことになります。
この章では、Product Center 用のポートレットを作成するステップについて説明します。WorkWithItem ポートレットという既存の Product Center ポートレットを例として用います。
この章の目的上、IBM WebSphere Portal Server におけるポートレットの開発とテストに関する実際的な知識と、IBM WebSphere Studio Application Developer 機能に関する実地の経験があることが前提となっています。この章では、Product Center 側でポートレットの要求を満たすのに必要な Product Center スクリプトの作成方法の詳細については取り上げていません。このようなスクリプトを作成して Web サービスとしてホスティングすることについての詳細は、この章の範囲外です。
フレームワーク・インフラストラクチャー、およびそれを使用するポートレットについては、後のセクションで説明します。このインフラストラクチャーでは、データ交換のための XML の形式と、その XML を表すデータ・オブジェクトを参照します。これにはまた、XML から Java、および Java から XML に変換を行うクラスも必要です。メソッドのセットを Product Center Mediator に付加して、ポートレットがこれを使用できるようにすることが必要です。
Product Center の中のアイテムは、Product Center カタログの下に存在します。こうしたアイテムは、アイテム仕様を使用して記述されます。この仕様は、属性のコレクションです。アイテムは、さらにカテゴリー、およびサブカテゴリーにグループ化されます。カテゴリーを表すこのツリーは、階層とも呼ばれます。
WorkWithItem ポートレットはユーザーがアイテムを扱う仕事をするのを支援します。また、このポートレットは次のタスクを行うためにも必要です。
(a) アイテムの表示
(b) アイテムの作成
(c) アイテムの変更
(d) アイテムのクローン
(e) アイテムの削除
WorkwithItem ポートレットの基本機能は、カタログ内のアイテムを表示、作成、変更、クローン、および削除することです。これらのアクションを実行するために、ポートレットは Web サービスを介して Product Center と XML 形式でデータ交換する必要があります。つまり、ポートレットでどのアクションを実行する場合でも、XML 形式の要求が Product Center に送られ、処理が行われた後に Product Center から XML 形式の応答が戻されるということです。
たとえば、アイテム詳細情報を取得する場合、要求 XML は以下のようになります。
表 1: Product Center の要求 XML
<wpc:wpcCommand type="ITEMDETAIL" mode="SYNC" >
<wpc:wpcParentCategory>1/5</wpc:wpcParentCategory>
<wpc:wpcCatalogName>CTG_PORTAL_MASTER</wpc:wpcCatalogName>
<wpc:wpcTradeItem ID="1732"></wpc:wpcTradeItem>
</wpc:wpcCommand>
このアクション・コマンドはアイテムの詳細情報を取得するためのものであり、呼び出しのモードは SYNC/ASYNC です。これらのモードは、Product Center で呼び出される Web サービス API が同期モードと非同期モードのどちらで機能するかを決定します。この特定の要求で、アイテムの詳細情報を取得するには、ItemID、CatalogName、および ParentCategory が必須フィールドになります。
アイテムの詳細情報に関する応答 XML は、そのアイテムの属性のコレクションであり、以下のようになります。
表 2: Product Center の応答 XML
<wpc:attribute-list>
<wpc:attribute name="Master Item Spec/GTIN" type="STRING">
<wpc:values>
<wpc:value occurrence="0">1087383</wpc:value>
</wpc:values>
</wpc:attribute>
<wpc:attribute name="Master Item Spec/Effective Start Date" type="DATE">
<wpc:values>
<wpc:value occurrence="0">2005-01-06 00:00:00</wpc:value>
</wpc:values>
</wpc:attribute>
<wpc:attribute name="Master Item Spec/Product Content/Web Image" type="IMAGE">
<wpc:values>
<wpc:value occurrence="0">1109678022009_id-w3-sitemark-simple.gif</wpc:value>
</wpc:values>
</wpc:attribute>
...
</wpc:attribute-list>
要求 XML および応答 XML の構造に基づき、Product Center Mediator からのデータを表すデータ・オブジェクトが定義されます。データ・オブジェクトから XML ストリングへ (およびその逆) の変換は、Product Center Mediator レイヤーで行われます。
たとえば、「WorkWithItem」ポートレットの場合、Product Center アイテムは「CatalogItem」クラスに含められています。このクラスは属性のコレクションを有しています。
XML 生成プログラムとパーサーは、Product Center アイテムの Java 表現を XML 表現に (またはその逆に) 変換するのを支援します。CatalogItemGenerator は、Product Center 要求 XML を作成します。各コマンドに対して固有の XML が生成されます。この場合のコマンドは、アイテムの詳細情報を取り出すというものです。ユーザーが指定する入力値がこの XML に読み込まれます。それらの値は、ポートレットの要求オブジェクトから収集されたものです。
以下のコードの断片は、アイテム詳細情報の検索操作のために生成された XML の一例に過ぎません。
public class CatalogItemGenerator {
public static String prepareItemDetailsRequestXML(
String parentCtgyID,
String catalogID,
String itemID) {
StringBuffer requestXML = new StringBuffer();
requestXML
.append(XMLHelper.WPC_NS_REF_BEG)
.append(ISoapMessageKeys.PARENT_CATEGORY)
.append(">")
.append(parentCtgyID)
.append(XMLHelper.WPC_NS_REF_END)
.append(ISoapMessageKeys.PARENT_CATEGORY)
.append(">")
.append(XMLHelper.WPC_NS_REF_BEG)
.append(ISoapMessageKeys.CATALOG_NAME)
.append("> ")
.append(catalogID)
.append(XMLHelper.WPC_NS_REF_END)
.append(ISoapMessageKeys.CATALOG_NAME)
.append(">")
.append(XMLHelper.WPC_NS_REF_BEG)
.append(ISoapMessageKeys.TRADE_ITEM)
.append(" ")
.append(ISoapMessageKeys.ID)
.append("=¥"")
.append(itemID)
.append("¥">")
.append(XMLHelper.WPC_NS_REF_END)
.append(ISoapMessageKeys.TRADE_ITEM)
.append(">");
return requestXML.toString();
}
}
}
CatalogItemParser は、Product Center 応答 XML コンテンツを解析して、これをカタログ・アイテム・データ・オブジェクトにします。
public class CatalogItemParser {
public static ICatalogItem prepareItem(
Element specElement,
Element tradeItemElement) {
// 仕様を作成
ICatalogItem item = getCatalogSpecItem(specElement);
// アイテムに属性値を設定する
prepareItem(item, tradeItemElement);
return item;
}
}
}
ポートレットは、どんな種類のデータ交換を Product Center と行うにせよ、Mediator レイヤーとだけ対話するべきです。Mediator の側は、Product Center Web サービスの呼び出しに関連した必要な操作を実行するためにポートレット・クラスが必要とする、すべてのメソッドを備えていなければなりません。ポートレットは、機能面での要件と、ユーザー対話関連の操作を表します。WorkwithItemPortlet の例の場合、ポートレットは以下を行う必要があります。
(a) アイテムの表示
(b) アイテムの作成
(c) アイテムの変更
(d) アイテムのクローン
(e) アイテムの削除
そのため、Mediator レイヤーにメソッドを追加する必要があります。こうしたメソッドは、以下の事柄を行うものと期待されます。
(1) Web サービス呼び出しに適した SOAP URL をロードする。
(2) そのメソッド呼び出しのための要求 XML を作成する。
(3) SOAP URL を起動し、SYNC/ASYNC 呼び出しを開始する。
(4) 応答 XML を受け取って解釈する。
(5) 成功した場合には、応答 XML を適切なデータ・オブジェクトに変換する。
(6) 成功しなかった場合には、障害の情報を通知 Bean の形でポートレットに渡す。これにより WPCMediator 例外がスローされる。
たとえば、Mediator の中で CatalogItem を取り出すメソッドは、以下のようになります。
public ICatalogItem getCatalogItem(
String parentCgyID,
String catalogID,
String itemID,
WPSContext context)
throws WPCMediatorException {
try {
// アイテム仕様を取得する
item = getCatalogItem(parentCgyID, catalogID, context);
//データを取り出すためのアイテム要求 XML を作成する
String itemReqXML =
CatalogItemGenerator.prepareItemDetailsRequestXML(
parentCgyID,
catalogID,
itemID);
// soapHelper を呼び出す
Element itemElement = wsHelper.getCatalogItemXML(itemReqXML, user);
// 結果を解析して、アイテムを準備する
CatalogItemParser.prepareItem(item, itemElement);
return item;
} catch (WPCMediatorException wpce) {
if (DEBUG) wpce.printStackTrace();
throw wpce;
}
}
さらに Mediator は呼び出しを WSHelper クラスに委任します。このクラスは要求 XML を作成し、SOAP URL を呼び出します。
public Element getCatalogItemXML(String itemReqXML, WPCUser user)
throws WPCMediatorException {
String requestXML = XMLHelper.prepareWPCRequest(
itemReqXML,
"ITEMDETAIL",
"SYNC",
user);
SoapResponse soapResponse = invokeSOAP(getSoapURL("ITEMDETAIL"),requestXML);
String responseXML = soapResponse.getDataXML();
}
上に示されているように、メソッド getCatalogItem() は応答 XML を受け取り、それを CatalogItemParser に渡します。ここで応答 XML が CatalogItem オブジェクトに変換されます。
XMLHelper は、こうした呼び出しすべてのために完全な XML を生成します。
要約すると、Mediator のあらゆる操作にあてはまる汎用的なステップは、次のようなものです。
ポートレット > WPCMediator > WSHelper > SoapInvoker >Axis API
WebSphere Portal Server でのポートレットの開発およびデプロイの詳細については、以下を参照してください。
<PortalServer_root>¥doc¥en¥InfoCenter¥index.html
Product Center ポートレットは適切な Product Center Mediator 呼び出しを起動し、その呼び出しの結果としてエンド・ユーザーに表示する必要のあるメッセージを判別します。これらのメッセージはメッセージ・コレクションに追加しておく必要があります。これは、その目的で用意されている API を使って行います。
現在のポートレットのさまざまな画面は JSP で表現しますが、JSP には、これらのユーザー・メッセージの内容を表示するのに役立つカスタム・タグを組み込む必要があります。
<wpctags:uimessages/>
soapactionurls.xml などの構成ファイルを変更し、適切な SOAP URL を指すようにします。構成ファイルのサンプルを以下に示します。
<soap-url action="<action name>">http://<server name>:<server port>/services/<service name></soap-url>
<soap-url action="ADD">http://9.184.114.58:9999/services/wpc_portal_integrated_dev
</soap-url>
この章では、Product Center にサプライヤー・ポータルをインストールして構成する方法の詳細なステップについて取り上げます。
ご使用の環境の一部として、以下のソフトウェアをインストールしてください。
このステップでは、サプライヤー・ポータルのデプロイ方法について説明します。
1. コマンド・プロンプトを開き、<AppServer-Root>¥bin に移動して、以下のコマンドを利用してサーバーを停止します。
stopServer WebSphere_Portal -username wpsbind -password wpsbind
2. URL http://localhost:9080/IDSWebApp/IDSjsp/Login.jsp で Directory Server Web 管理ツールを開き、以下の証明書でログインします。
LDAP ホスト名 : localhost
ユーザー名 : cn=root
パスワード : password
3. Web 管理ツールを停止します。
4. コマンド・プロンプトで DirectoryServer_Root¥appsrv¥bin に移動し、以下のコマンドを使用して LDAP サーバーを停止します。
stopServer server1 -username wpsbind -password wpsbind
5. アプリケーション ZIP ファイルをダウンロードして、内容を解凍します。JAR ファイル customlogin.jar[I2] が含まれているはずです。これらのファイルは Product Center インストール CD でも入手可能です。
6. customlogin.jar および ibmjndi.jar を <PortalServer_Root>¥shared¥app フォルダーに追加します。
7. コマンド・プロンプトで DirectoryServer_Root¥appsrv¥bin に移動し、以下のコマンドを使用して LDAP サーバーを開始します。
startServer server1 -username wpsbind -password wpsbind
8. URL http://localhost:9080/IDSWebApp/IDSjsp/Login.jsp で Directory Server Web 管理ツールを開き、以下の証明書でログインします。
LDAP ホスト名 : localhost
ユーザー名 : cn=root
パスワード : password
9. Web 管理ツールを開始します。
10. コマンド・プロンプトを開き AppServer_Root¥bin に移動し、以下のコマンドを使用して Portal Server を開始します。
startServer WebSphere_Portal -username wpsbind -password wpsbind
11. admin/admin/ibm でログインします。
12. 「管理 (Administration)」->「ポートレット (Portlets)」->「アプリケーションの管理 (Manage Applications)」の順に移動します。
13. アプリケーションの以前のインスタンスが存在する場合には、アンインストールします。
14. アプリケーションの新たなインスタンスをインストールし、ポートレットを必要なページに追加します。
15. 必要に応じてポートレットにユーザー許可を割り当てます。
このステップでは、サプライヤー・ポータルの UI をカスタマイズします。このステップでは、ポータルのデフォルトのレイアウトとルック・アンド・フィールを準備します。
ポータルのカスタマイズの一環として、図 1 に示されている、以下のラベルをポータルに作成します。
図 1
アプリケーションのテーマおよびスキンをインストールします。
1. ファイル「themes.zip」を、フォルダー <AppServer_Root>¥installedApps¥<AppServer_HOST_NAME>¥wps.ear¥wps.war¥themes¥html に解凍します。
2. ファイル「skins.zip」を、フォルダー <AppServer_Root>¥installedApps¥<AppServer_HOST_NAME>¥wps.ear¥wps.war¥skins¥html に解凍します。
3. Portal Server に管理者としてログインします。
4. 右上にある「管理者 (Administrator)」リンクをクリックします。
5. 「ポータル・ユーザー・インターフェース (Portal User Interface)」->「テーマとスキン (Themes and Skins)」の順に移動します。
6. 「新しいテーマの追加 (Add new theme)」リンクをクリックします。
7. 新しいテーマの名前とディレクトリーとして「WPC_Default_theme」を入力します。「OK」をクリックします。
8. 「新しいスキンの追加 (Add New skin)」リンクをクリックします。
9. 新しいスキンの名前とディレクトリーとして「WPC_Default_skin」を入力します。「OK」をクリックします。
ポートレットを以下のさまざまなタブの下にまとめます。
「Home (ホーム)」タブ |
|
「Search (検索)」タブ |
|
「Create/Edit Item (アイテムの作成/編集)」タブ |
|
「Mass Edit (一括編集)」タブ |
|
「Upload (アップロード)」タブ |
|
「Registration (登録)」タブ |
|
以下のステップに従い、タブにポートレットを追加します。
1. Portal Server に管理者としてログインします。
2. 右上にある「管理者 (Administrator)」リンクをクリックします。
3. 「ポータル・ユーザー・インターフェース (Portal User Interface)」>「ページの管理 (Manage Pages)」の順に移動します。
4. 右側の画面で必要なページの「ページ・レイアウトの編集 (Edit Page Layout)」ボタンを選択します。
5. 必要なポートレットを検索して、ページに追加します。
6. 前述のすべてのタブに関して、ステップ (4) と (5) を繰り返します。
1. Portal Server に管理者としてログインします。
2. 右上にある「管理者 (Administrator)」リンクをクリックします。
3. 「アクセス (Access)」->「リソース許可 (Resource Permissions)」の順に移動します。
4. 「マイ・ポータル (My Portal)」リンクの「アクセスの割り当て (Assign Access)」ボタンを選択します。「役割の編集 (Edit Role)」画面で「すべての認証済みユーザー (All Authenticated Users)」にアクセスを許可し、「OK」をクリックします。
5. ステップ (4) の説明と同様に、登録ページへのアクセスを「匿名ユーザー (Anonymous User)」 に許可します。
1. 以下の構成ファイルに対し、ログアウトに関連した以下の変更を加えます。
<PortalServer_Root>/shared/app/config/services/ConfigService.properties
# Logout redirect parameters
redirect.logout = true
redirect.logout.url = /wps/myportal
上記の変更により、「ログアウト (Logout)」リンクをクリックすると、ポータルがログイン・ページに転送されるようになります。
2. 以下の構成ファイルに対し、ログアウトに関連した以下の変更を加えます。
<PortalServer_Root>/shared/app/nls/engine_en.properties
<PortalServer_Root>/shared/app/nls/engine.properties
以下の項目を編集して、リンク名を「Register」、「Login」、および「Logout」に変更します。
link.enrollment = Register
link.login = Sign in
link.logout = Sign out
カスタマイズしたウェルカム・メッセージが表示されるように、以下の 2 つの項目を追加します。
default_welcome = Welcome!
login_welcome = Welcome, {0}
3. 以下の構成ファイルに対し、「ログイン (Login)」ボタンに関連した以下の変更を加えます。
<PortalServer_Root>/shared/app/nls/button_en.properties
<PortalServer_Root>/shared/app/nls/button.properties
以下の項目を編集して、リンク名「Login」を変更します。
login = Sign in
サプライヤー・ポータルのインストールおよび構成中には、Portal Server 固有のいくつかの構成ファイルと、サプライヤー・ポータル・アプリケーション固有のいくつかの構成ファイルに変更が加えられます。以下に、こうしたファイルについて簡単に説明します。
<PortalServer_root>/config/wpconfig.properties
<PortalServer_root>/wmm/wmmLDAPServerAttributes.xml
<PortalServer_root>/shared/app/config/services/ConfigService.properties
<PortalServer_root>/shared/app/config/services/LoaderService.properties
<PortalServer_root>/shared/app/nls/field.properties
<PortalServer_root>/shared/app/nls/problem.properties
<PortalServer_root>/shared/app/nls/engine.properties
<PortalServer_root>/shared/app/nls/button.properties
サプライヤー・ポータル・アプリケーション固有の構成ファイル
<application_root>/WebContent/WEB-INF/config/soapactionurls.xml
<Application_root>/WebContent/WEB-INF/config/timezonevalues.xml
<Application_root>/WebContent/WEB-INF/config/catalog_configuration.xml
<Application_root>/WebContent/WEB-INF/config/portletActions2pages.xml
この章の終わりまでに、以下のタスクを実行したことになります。
この章では、以下について説明します。
一般的なポートレットの構造は、以下の図に示すとおりです。 トランザクションの状況は、メッセージ領域でユーザーに通知されます。ユーザーは、アクティブ領域およびアクション・ボタン領域を使用して対話します。
使用可能なユーザー・シナリオ用のポートレットを以下にリストします。
ユーザー登録
a. ログイン・ページで、「登録 (Register)」リンクをクリックします。
b. ユーザー登録ポートレットが表示されます。
c. ユーザー登録ポートレットには、サプライヤー GLN および E メール・アドレスが表示されます。ユーザーが、この情報を入力します。
d. 「次へ (Next)」ボタンをクリックして、GLN および E メール・アドレスを検証します。
e. これがシステムで認識されると、パスワード・フィールドが表示されます。
f. システムがパスワードを検査して、一致していることを確認します。
g. 登録承認情報がユーザーに送信されることを通知する画面が表示され、その後ユーザーがポータルにログインできるようになります。
ユーザー登録承認 - 手動
a. これはオフラインで処理されます。WebSphere Product Center 管理者は、登録されたユーザーを承認する必要があります。これによって、ユーザーはポータルにログインし、WebSphere Product Center に関連したポートレットを使って仕事ができるようになります。
b. WebSphere Product Center 管理者は、登録されたユーザーに役割を割り当てる必要があります。このアクションは、ポータル・サーバーと WebSphere Product Center とが共用する LDAP ストアで、手動で実行する必要があります。これによって、WebSphere Product Center に関連したトランザクションを実行する許可がユーザーに与えられます。
アイテム・カタログの表示
a. このポートレットは、ツリー構造形式でアイテム・カタログをリストします。アイテムは、カタログ・ツリーのリーフです。
b. ユーザーがカタログを選択すると、「アイテムの追加」を選択できるようになります。このオプションは、アクション・ボタン領域にボタンとして表示されます。
c. ユーザーがアイテムを選択すると、アイテムの表示、編集、クローン、または削除を選択できるようになります。これらのオプションは、アクション・ボタン領域にボタンとして表示されます。
d. これらのボタンは、アイテムに対する操作にのみ有効です。
e. 第 1 レベルのカタログが、WebSphere Product Center から検索されます。下位ノード (サブカタログおよびアイテム) は、ユーザー対話に基づいて検索されます。ユーザーがノードを拡張表示すると、その下の内容が表示されます。これによって、任意の時点でロードする必要があるデータ量を減らすことは可能ですが、この情報を検索するために WebSphere Product Center に対して行われる呼び出しの回数は増えます。
既存のアイテムの表示
a. アイテム・カタログ・ポートレットからアイテムを選択して、「アイテムの表示」ボタンをクリックします。アイテムの詳細情報が「アイテム処理」ポートレットにレンダリングされます。内容は読み取り専用モードで表示されます。
新規アイテムの追加
a. 「アイテム・カタログ」ポートレットからカタログを選択して、「アイテムの追加」ボタンをクリックします。アイテムの内容が「アイテム処理」ポートレットにレンダリングされ、ユーザーがアイテム情報を入力できるようになります。「追加」操作によって、入力されたアイテムが選択したカタログに追加されます。
b. このアイテムの作成処理は、「アイテム処理」ポートレットの「アイテムの追加」ボタンをクリックして開始することもできます。これによって、未割り当てのカタログにアイテムが作成されます。
c. アイテム・エントリーに関連した検証が送信時に実行されます。第 1 レベルの検証が、WebSphere Product Center から受信される属性メタ情報に基づいて実行されます。通常、これらの検証は型検査および範囲検査です。検証は、JavaScript レベル検査の一部として実行されるわけではありません。
d. ユーザーは、操作をキャンセルすることもできます。この場合、ポートレットは初期状態に戻ります。
既存のアイテムの更新
a. 「アイテム・カタログ」ポートレットからアイテムを選択して、「アイテムの更新 (Update Item)」ボタンをクリックします。アイテムの内容が「アイテム処理」ポートレットにレンダリングされ、ユーザーがアイテム更新情報を入力できるようになります。
b. このアイテムの更新処理は、アイテムの検索を実行し、アイテムを選択して検索結果の「アイテムの処理」ボタンをクリックして開始することもできます。これによって、「アイテム処理」ポートレットにアイテム情報が取り込まれます。次いで、ユーザーが「アイテムの更新 (Update Item)」ボタンをクリックすると、アイテムの処理を開始できるようになります。
c. このアイテムの更新処理は、「アイテム・カタログ」ポートレットでアイテムを選択して、「アイテムの表示」をクリックして開始することもできます。これによって、「アイテム処理」ポートレットにデータが取り込まれます。次いで、ユーザーが「更新」ボタンをクリックすると、内容が編集可能モードでレンダリングされます。
d. アイテム・エントリーに関連した検証が送信時に実行されます。第 1 レベルの検証が、WebSphere Product Center から受信される属性メタ情報に基づいて実行されます。通常、これらの検証は型検査および範囲検査です。検証は、JavaScript レベル検査の一部として実行されるわけではありません。
e. ユーザーは、操作をキャンセルすることもできます。この場合、ポートレットは初期状態に戻ります。
アイテムのクローン
a. 「アイテム・カタログ」ポートレットからアイテムを選択して、「アイテムのクローン (Clone Item)」ボタンをクリックします。アイテムの内容のコピーが「アイテム処理」ポートレットにレンダリングされ、ユーザーがアイテムのコピー操作を実行できるようになります。
b. このアイテムのクローン処理は、アイテムの検索を実行し、アイテムを選択して検索結果の「アイテムの処理」ボタンをクリックして開始することもできます。これによって、「アイテム処理」ポートレットにアイテム情報が取り込まれます。ユーザーは「クローン」ボタンをクリックして、アイテムを処理できます。
c. このアイテムのクローン処理は、「アイテム・カタログ」ポートレットでアイテムを選択して、「アイテムの表示」をクリックして開始することもできます。これによって、「アイテム処理」ポートレットにデータが取り込まれます。次いで、ユーザーが「クローン」ボタンをクリックすると、内容が編集可能モードでレンダリングされます。
d. アイテム・エントリーに関連した検証が送信時に実行されます。第 1 レベルの検証が、WebSphere Product Center から受信される属性メタ情報に基づいて実行されます。通常、これらの検証は型検査および範囲検査です。検証は、JavaScript レベル検査の一部として実行されるわけではありません。
e. ユーザーは、操作をキャンセルすることもできます。この場合、ポートレットは初期状態に戻ります。
既存のアイテムの除去
a. 「アイテム・カタログ」ポートレットからアイテムを選択して、「アイテムの削除」ボタンをクリックします。アイテムの内容が「アイテム処理」ポートレットにレンダリングされ、ユーザーがアイテムの削除操作を実行できるようになります。アイテムの内容が読み取り可能モードで表示されます。
b. このアイテムの削除処理は、アイテムの検索を実行し、アイテムを選択して検索結果の「アイテムの処理」ボタンをクリックして開始することもできます。これによって、「アイテム処理」ポートレットにアイテム情報が取り込まれます。次いで、ユーザーが「削除」ボタンをクリックすると、アイテムが削除されます。
c. このアイテムの削除処理は、「アイテム・カタログ」ポートレットでアイテムを選択して、「アイテムの表示」をクリックして開始することもできます。これによって、「アイテム処理」ポートレットにデータが取り込まれます。次いで、ユーザーが「削除」ボタンをクリックできます。
d. ユーザーは、操作をキャンセルすることもできます。この場合、ポートレットは初期状態に戻ります。
アイテムの検索
a. 検索ポートレットには、次の検索条件値が初期表示されています。すなわち、GTIN、GLN、Target Market、商品状況 (承認、拒否、ドラフトなど)、SKU#、価格、単一アイテムと階層のどちらを戻すかです。ユーザーは、ワイルドカード検索を実行できます。
b. 検索条件では、タイプが日付または数値である基準に関して範囲オプションを指定できます。例えば、価格基準に $100 より大きく、$500 より小さい価格を指定できます。
c. 検索条件では、ユーザーが使用した最新の 10 個の検索条件が保管され、これらの条件がリストされます。このリンクをクリックすると、これらの検索条件で検索が実行されます。
d. 検索結果は、同じポートレットの検索条件の下に表示されます。戻される検索結果は、ユーザー固有のスクロール・サイズに合わせて表示されます。この値は、ポートレットの編集オプションを使用して設定できます。検索結果のサイズは WebSphere Product Center によって制御されます。これは検索パフォーマンスとの関連が大きい事項です。検索結果の表示はポートレットによって制御されます。これはユーザー・エクスペリエンスとの関連が大きい事項です。
e. ユーザーは、検索結果から単一アイテムを選択して、「アイテムの処理 (work with item)」ボタンをクリックできます。これによって、アイテム情報が「アイテム処理」ポートレットに移動します。
f. ユーザーは、検索結果から複数のアイテムを選択して、「アイテムの処理 (work with item)」ボタンをクリックできます。これによって、アイテムが「アイテム一括更新」ポートレットに移動します。
一括アップロード
a. 「一括アップロード」ポートレットには、CSV (comma-separated-value) ファイルをユーザーのマシンから WebSphere Product Center にアップロードするファイル・ブラウザー・インターフェースがあります。
b. これは、WebSphere Product Center の観点から見て長いトランザクションであるため、この対話は非同期になります。CSV ファイルが WebSphere Product Center にアップロードされ、トランザクションの結果がポータルのメッセージとして、または E メールによって、ユーザーに報告されます。
一括更新
a. ユーザーが「検索」ポートレットを使用してアイテムの検索を実行します。検索結果に表示されるアイテムを選択して、「アイテムの処理 (Work with Item)」ボタンをクリックします。
b. これによって、選択されたアイテムの内容が「アイテム一括更新」ポートレットに転送されます。これで、ユーザーが、選択された属性セットについて、アイテムの一括更新を実行できるようになります。
メッセージ形式は、UCCNet メッセージ形式と同様です。エンベロープにはヘッダーと本文が含まれます。ヘッダーには、送信側 / 受信側の詳細を識別する情報と、固有のメッセージ ID が含まれます。本文には、要求メッセージの場合は実行されるコマンドおよび関連情報、応答メッセージの場合には応答詳細が含まれます。
ポータルと Product Center の間のメッセージ・トランザクションを処理する方法には、同期 (SYNC) と非同期 (ASYNC) の 2 つがあります。
文書構成
<envelope>
<wpcHeader>
<!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< companyName></ companyName>
<!- ユーザー ID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< userID></ userID>
<!-- messageIdentifier は各メッセージを固有に識別します -->
< messageIdentifier></
messageIdentifier>
<!- メッセージが送信されたタイム・スタンプ -- >
<timestamp></timestamp>
<!- WPS ユーザーのサプライヤー ID -- >
<supplierId></supplierId>
</wpcHeader>
<wpcBody>
< wpcCommand type=ADD mode=SYNC
>
………...
</wpcCommand>
</wpcBody>
</envelope>
wpcCommand エレメントの「type」属性には、ADD、MODIFY、DELETE、SEARCH、QUERY_TRANSACTION などの値を指定できます。このフィールドは、実行する必要のある操作を決定します。wpcCommand の「mode」属性は、どちらのモードで操作を実行するかを決定します。これは SYNC (同期) または ASYNC (非同期) のいずれかです。
SYNC モードの場合、要求 XML 文書が処理されると、対応する応答 XML 文書が生成されてただちに返送されます。
ASYNC モードの場合、XML 要求が受信されると、特定の文書が妥当 (有効) かつ整形式であるかどうかただちに確認され、1 つのトランザクション ID が呼び出し側に返送されます。それ以降は、トランザクション ID を提示することにより、要求されたトランザクションの状況を呼び出し側がいつでもポーリングし続けることができます。
Product Center のカタログ・アイテムを追加するには、ポータルは適切なデータを入力して以下のようなメッセージ・スケルトンを送る必要があります。ただちに応答を受け取りたい場合はモード・フラグを「SYNC」に、そうでない場合は「ASYNC」にします。
<envelope>
<wpcHeader>
<!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< companyName></ companyName>
<!- ユーザー ID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< userID></ userID>
<!-- messageIdentifier は各メッセージを固有に識別します -->
< messageIdentifier></
messageIdentifier>
</wpcHeader>
<wpcBody>
< wpcCommand type=ADD mode=SYNC
>
<wpcCatalogItem>
………...
</wpcCatalogItem>
</wpcCommand>
</wpcBody>
</envelope>
Product Center からの対応する応答は、次のようになります。
<envelope> <wpcHeader> <!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。 --> < companyName></ companyName> <!— UserID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。 --> < userID></ userID> <!-- messageIdentifier は各メッセージを固有に識別します --> < messageIdentifier></ messageIdentifier> </wpcHeader> <wpcBody> < wpcResponse> < wpcEntityIdentifier> <!— 要求メッセージの messageidentifier 値 --!> < wpcMessageIdentifier > </ wpcMessageIdentifier > <!— 要求メッセージに関する、作成された WPC トランザクション ID --!> < wpcTransactionID ></ wpcTransactionID > </ wpcEntityIdentifier> < wpcNotification > < notificationInfo type=”SUCCESS” > < notificationCode >000</ notificationCode > <notificationMessage>SUCCESS</notificationMessage> </ wpcResponse> </wpcBody> </envelope>
何らかのエラーが検出された場合、notificationInfo の「type」属性の値が「ERROR」または「WARNING」になり、通知コード (notificationCode) にはエラー・コード、notificaitonMessage には対応するエラー・メッセージが入ります。これは、ポータルから送られるすべてのメッセージに適用されます。SEARCH または SELECTION 要求の場合、SYNC モード要求の検索/選択結果である wpcCatalogueItem ブロックが wpcResponse 応答に含まれます。
ASYNC モード要求の場合、以下のようなメッセージ要求を送信する必要があります。
<envelope>
<wpcHeader>
<!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< companyName></ companyName>
<!- ユーザー ID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< userID></ userID>
<!-- messageIdentifier は各メッセージを固有に識別します -->
< messageIdentifier></ messageIdentifier>
</wpcHeader>
<wpcBody>
< wpcCommand type=ADD mode=”ASYNC”>
<!— アイテムの一括操作の場合、以下のブロックを使用します --!>
<!— 現在サポートされているファイル・タイプは CSV だけです --!>
<wpcDataContainer fileType=”CSV”>
<serverName></serverName>
<userName></userName>
<password></password>
<dataDir></dataDir>
<fileName></filename>
</wpcCommand>
</wpcBody>
</envelope>
これに対する応答は次のようになります。
<envelope>
<wpcHeader>
<!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< companyName></ companyName>
<!- ユーザー ID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< userID></ userID>
<!-- messageIdentifier は各メッセージを固有に識別します -->
< messageIdentifier></ messageIdentifier>
</wpcHeader>
<wpcBody>
< wpcResponse>
< wpcEntityIdentifier>
<!— 要求メッセージの messageidentifier 値 --!>
< wpcMessageIdentifier > </ wpcMessageIdentifier >
<!— 要求メッセージに関する、作成された WPC トランザクション ID --!>
< wpcTransactionID ></ wpcTransactionID >
</ wpcEntityIdentifier>
< wpcNotification >
< notificationInfo type=”PROCESSING” >
< notificationCode >999</ notificationCode >
<notificationMessage>PROCESSING</notificationMessage>
</ wpcResponse>
</wpcBody>
</envelope>
次に、特定のトランザクションの完了を確認するために、ポータルは Product Center に対してポーリングし続ける必要があります。以下のメッセージを使用します。
<envelope>
<wpcHeader>
<!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< companyName></ companyName>
<!- ユーザー ID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< userID></ userID>
<!-- messageIdentifier は各メッセージを固有に識別します -->
< messageIdentifier></ messageIdentifier>
</wpcHeader>
<wpcBody>
< wpcCommand type=”QUERY_TRANSACTION” mode=”ASYNC”>
< wpcEntityIdentifier>
<!— 要求メッセージの messageidentifier 値 --!>
< wpcMessageIdentifier > </ wpcMessageIdentifier >
<!— 要求メッセージに関する、作成された WPC トランザクション ID --!>
< wpcTransactionID ></ wpcTransactionID >
</ wpcEntityIdentifier>
</wpcCommand>
</wpcBody>
</envelope>
操作が正常終了した場合、Product Center から対応する次のような応答が送られます。
<envelope>
<wpcHeader>
<!— companyName。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< companyName></ companyName>
<!- ユーザー ID。デフォルトでは、WPC のユーザー ID と企業名がそれぞれスクリプト・コンテキストから取得されます。今のところ、これは FYI のようなフィールドだけです。-->
< userID></ userID>
<!-- messageIdentifier は各メッセージを固有に識別します -->
< messageIdentifier></ messageIdentifier>
</wpcHeader>
<wpcBody>
< wpcResponse>
< wpcEntityIdentifier>
<!— 要求メッセージの messageidentifier 値 --!>
< wpcMessageIdentifier > </ wpcMessageIdentifier >
<!— 要求メッセージに関する、作成された WPC トランザクション ID --!>
< wpcTransactionID ></ wpcTransactionID >
</ wpcEntityIdentifier>
< wpcNotification >
< notificationInfo type=”SUCCESS” >
< notificationCode >000</ notificationCode >
<notificationMessage>SUCCESS</notificationMessage>
</ wpcResponse>
</wpcBody>
</envelope>
要求がまだ処理中の場合の応答は、Product Center が ASYNC 要求を受け取った直後に送る応答と同じです。
このセクションでは、ポータル統合で呼び出されるスクリプトと Web サービスについて示します。
wpc_portal_integrated_dev
Web サービス・インプリメンテーション・スクリプト (/scripts/wbs/wpc_portal_integrated_dev0)
/scripts/triggers/WPC-Portal-RequestUtil.wpcs
/scripts/triggers/WPC-Portal-ResponseUtil.wpcs
/scripts/triggers/WPC-Portal-ItemHelper.wpcs
/scripts/triggers/WPC-Portal-CSVHelper.wpcs
/scripts/triggers/WPC-Portal-ViewHelper.wpcs
以下のセクションでは、サンプル XML メッセージ、および特定のコマンドを呼び出す対応するスクリプトをいくつか示します。
この要求はアイテムを追加して、成功または失敗の応答を返送させます。
// アイテム追加メッセージを呼び出す
<?xml version="1.0" encoding="UTF-8"?>
<envelope xmlns="http://ibm.com/wpc/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://ibm.com/wpc/
C:¥wpc¥portal¥webservice_dev.xsd" communicationVersion="5.2">
<WPCResponseType>synchronous</WPCResponseType>
<wpcHeader>
<companyName>null</companyName>
<userID>administrator</userID>
<password>null</password>
<messageIdentifier>D5D92CE0-97A8-11D9-B84B-A068E33E0476</messageIdentifier>
<timestamp>2005-03-18</timestamp>
<supplierId>null</supplierId>
</wpcHeader>
<wpcBody>
<wpcCommand type="ADD" mode="SYNC">
<wpcParentCategory>1/5</wpcParentCategory>
<wpcCatalogName> CTG_PORTAL_MASTER</wpcCatalogName>
<wpcTradeItem>
<attribute-list>
<attribute name="Master Item Hier Sec Spec1/name"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Hier Sec Spec1/ID"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/GTIN" type="STRING">
<values>
<value occurrence="0">393939</value>
</values>
</attribute>
<attribute name="Master Item Spec/Internal ID"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Short Description"
type="STRING">
<values>
<value occurrence="0">short description</value>
</values>
</attribute>
<attribute name="Master Item Spec/Long Description"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Thumbnail Preview" type="THUMBNAIL_IMAGE_URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Type" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Regulation" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Source" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Perishable Type" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content"
type="GROUPING">
<values>
<groupvalue>
<attribute name="Master Item Spec/Product Content/Thumbnail Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Small Thumbnail
Image" type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Print Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Web Image"
type="IMAGE">
<values>
<file type="" occurrence="0">
<name/>
<dir/>
<server-name/>
<userID/>
<password/>
</file>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/POS Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Hi-Res Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Product
Documents"
type="GROUPING">
<values>
<groupvalue>
<attribute name="Master Item Spec/Product Content/Product
Documents/Document" type="URL">
<values>
<value occurrence="0"/>
</values>
</attribute>
</groupvalue>
</values>
</attribute>
</groupvalue>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet"
type="GROUPING">
<values>
<groupvalue>
<attribute name="Master Item Spec/UCCnet/Product Type"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Brand"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Category"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Color"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Consumer Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Coupon Family Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Dated Product - Days"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Detailed Description"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/D-U-N-S"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/EANUCC Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/EANUCC Type"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Effective Date"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/First Arrival"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/First Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/First Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Flash Point Temp"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Flash Point Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/GLN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Gross Weight"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/GTIN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Class Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Code Qualifier"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Description"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Sequence"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Height"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/HI"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/InnerPack"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Item Description"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Item Status"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Last Arrival"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Last Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Last Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Length"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Linear"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Maximum Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Maximum Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Minimum Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Minimum Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Name"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Net Weight"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Order Increment"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Order Sizing Factor"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Orderable Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Order Increment Units"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Pack"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Page"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Phone"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/POS Desc 1"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/POS Desc 2"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Pre Priced Amount"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Private"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Replaced by GTIN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Replaces GTIN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Size"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Size Units"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Special Handling Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Suggested Retail Price"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/TI"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Version"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Version Status"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Volume"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Volume Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Weight"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Width"
type="STRING">
<values>
<value/>
</values>
</attribute>
</groupvalue>
</values>
</attribute>
<attribute name="Master Item Spec/Supplier_ID"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/ItemStatus"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Effective Start Date"
type="DATE">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Effective End Date"
type="DATE">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Last Updated By"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Update on"
type="DATE">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 1"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 2"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 3"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 4"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 5"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/AddedVia" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/ModifiedVia" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Price"
type="NUMBER">
<values>
<value occurrence="0">0.0</value>
</values>
</attribute>
<attribute name="Master Item Spec/Item Unit Size"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/testImage"
type="IMAGE">
<values>
<file>
<name/>
</file>
</values>
</attribute>
</attribute-list>
</wpcTradeItem>
</wpcCommand>
</wpcBody>
</envelope>
次の要求は、特定の基本キーを使ってアイテムを変更します
// MODIFY メッセージを呼び出す
<?xml version="1.0" encoding="UTF-8"?>
<envelope xmlns="http://ibm.com/wpc/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://ibm.com/wpc/
C:¥wpc¥portal¥webservice_dev.xsd" communicationVersion="5.2">
<WPCResponseType>synchronous</WPCResponseType>
<wpcHeader>
<companyName>null</companyName>
<userID>administrator</userID>
<password>null</password>
<messageIdentifier>253667D0-97A9-11D9-B84B-CFE00DAB579A</messageIdentifier>
<timestamp>2005-03-18</timestamp>
<supplierId>null</supplierId>
</wpcHeader>
<wpcBody>
<wpcCommand type="MODIFY" mode="SYNC">
<wpcParentCategory>1/5</wpcParentCategory>
<wpcCatalogName> CTG_PORTAL_MASTER</wpcCatalogName>
<wpcTradeItem ID="393939">
<attribute-list>
<attribute name="Master Item Hier Sec Spec1/name"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Hier Sec Spec1/ID"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/GTIN" type="STRING">
<values>
<value occurrence="0">393939</value>
</values>
</attribute>
<attribute name="Master Item Spec/Internal ID"
type="STRING">
<values>
<value occurrence="0">23</value>
</values>
</attribute>
<attribute name="Master Item Spec/Short Description"
type="STRING">
<values>
<value occurrence="0">short description</value>
</values>
</attribute>
<attribute name="Master Item Spec/Long Description"
type="STRING">
<values>
<value occurrence="0">23</value>
</values>
</attribute>
<attribute name="Master Item Spec/Thumbnail Preview" type="THUMBNAIL_IMAGE_URL">
<values>
<value occurrence="0">http://23</value>
</values>
</attribute>
<attribute name="Master Item Spec/Item Type" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Regulation" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Source" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Perishable Type" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content"
type="GROUPING">
<values>
<groupvalue>
<attribute name="Master Item Spec/Product Content/Thumbnail Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Small Thumbnail
Image" type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Print Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Web Image"
type="IMAGE">
<values>
<file type="" occurrence="0">
<name/>
<dir/>
<server-name/>
<userID/>
<password/>
</file>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/POS Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Hi-Res Image"
type="URL">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Product Content/Product
Documents" type="GROUPING">
<values>
<groupvalue>
<attribute name="Master Item Spec/Product Content/Product
Documents/Document" type="URL">
<values>
<value occurrence="0"/>
</values>
</attribute>
</groupvalue>
</values>
</attribute>
</groupvalue>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet"
type="GROUPING">
<values>
<groupvalue>
<attribute name="Master Item Spec/UCCnet/Product Type"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Brand"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Category"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Color"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Consumer Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Coupon Family Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Dated Product - Days"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Detailed Description"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/D-U-N-S"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/EANUCC Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/EANUCC Type"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Effective Date"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/First Arrival"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/First Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/First Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Flash Point Temp"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Flash Point Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/GLN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Gross Weight"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/GTIN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Class Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Code Qualifier"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Description"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Hazmat Sequence"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Height"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/HI"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/InnerPack"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Item Description"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Item Status"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Last Arrival"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Last Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Last Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Length"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Linear"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Maximum Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Maximum Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Minimum Order"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Minimum Ship"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Name"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Net Weight"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Order Increment"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Order Sizing Factor"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Orderable Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Order Increment Units"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Pack"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Page"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Phone"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/POS Desc 1"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/POS Desc 2"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Pre Priced Amount"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Private"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Replaced by GTIN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Replaces GTIN"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Size"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Size Units"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Special Handling Code"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Suggested Retail Price"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/TI"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Version"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Version Status"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Volume"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Volume Unit"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Weight"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/UCCnet/Width"
type="STRING">
<values>
<value/>
</values>
</attribute>
</groupvalue>
</values>
</attribute>
<attribute name="Master Item Spec/Supplier_ID"
type="STRING">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/ItemStatus"
type="STRING">
<values>
<value occurrence="0">232</value>
</values>
</attribute>
<attribute name="Master Item Spec/Effective Start Date"
type="DATE">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Effective End Date"
type="DATE">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Last Updated By"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Update on"
type="DATE">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 1"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 2"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 3"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 4"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/Comment 5"
type="STRING">
<values>
<value occurrence="0"/>
</values>
</attribute>
<attribute name="Master Item Spec/AddedVia" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/ModifiedVia" type="STRING_ENUMERATION">
<values>
<value/>
</values>
</attribute>
<attribute name="Master Item Spec/Item Price"
type="NUMBER">
<values>
<value occurrence="0">0.0</value>
</values>
</attribute>
<attribute name="Master Item Spec/Item Unit Size"
type="STRING">
<values>
<value occurrence="0">23</value>
</values>
</attribute>
<attribute name="Master Item Spec/testImage"
type="IMAGE">
<values>
<file>
<name/>
</file>
</values>
</attribute>
</attribute-list>
</wpcTradeItem>
</wpcCommand>
</wpcBody>
</envelope>
特定の基本キーを使って特定のアイテムを削除するには、次のようにします
// DELETE メッセージを呼び出す
var strXML = "<?xml version=¥"1.0¥"
encoding=¥"UTF-8¥"?>" +
"<wpc:envelope xmlns:wpc=¥"http://ibm.com/wpc/¥" xmlns:xsi=¥"http://www.w3.org/2001/XMLSchema-instance¥"
xsi:schemaLocation=¥"http://ibm.com/wpc/
C:¥vrprabu¥5.2¥xsd¥portalschema¥wpc¥5.2_siva¥envelop_portal.xsd¥"
communicationVersion=¥"5.2¥"> " +
" <wpc:WPCResponseType>synchronous</wpc:WPCResponseType>"
+
" <wpc:wpcHeader>" +
" <wpc:companyName>IBM</wpc:companyName>" +
" <wpc:userID>Admin</wpc:userID>" +
" <wpc:password>trinitron</wpc:password>" +
" <wpc:messageIdentifier>12344</wpc:messageIdentifier>" +
" <wpc:timestamp>2004-10-10</wpc:timestamp>" +
" </wpc:wpcHeader>" +
" <wpc:wpcBody>" +
" <wpc:wpcCommand type=¥"DELETE¥"
mode=¥"SYNC¥">" +
" <wpc:wpcParentCategory>Hierarchy1/Category1</wpc:wpcParentCategory>"
+
" <wpc:wpcCatalogName>CTG_PORTAL</wpc:wpcCatalogName>" +
" <wpc:wpcTradeItem ID=¥"173¥">" +
" </wpc:wpcTradeItem>" +
" </wpc:wpcCommand>" +
" </wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
この検索メッセージでは拡張選択で使用可能なすべての種類の検索パラメーターを使用できます。それぞれの検索条件のメッセージ形式の詳細については、WSDL を確認してください。
var
strXML = "<wpc:envelope xmlns:wpc='http://ibm.com/wpc/'
communicationVersion='5.2'>" +
"<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>" +
" <wpc:wpcHeader>" +
" <wpc:companyName>ibm</wpc:companyName>" +
" <wpc:userID>admin</wpc:userID>" +
" <wpc:password>admin</wpc:password>" +
" <wpc:messageIdentifier>C815A530-9077-11D9-A530-E0AE7B025BD4</wpc:messageIdentifier>"
+
" <wpc:timestamp>2005-03-09</wpc:timestamp>" +
" <wpc:supplierId>1236868684668</wpc:supplierId>" +
" </wpc:wpcHeader>" +
" <wpc:wpcBody>" +
" <wpc:wpcCommand type=¥"SEARCH¥" mode=¥"SYNC¥"
>" +
" <wpc:wpcCatalogName>CTG_PORTAL_MASTER</wpc:wpcCatalogName>"
+
" <wpc:wpcResultCount>2</wpc:wpcResultCount>" +
" <wpc:wpcSearchCriteria>" +
" <wpc:wpcSearchOperator name=¥"AND¥">" +
" <wpc:wpcSearchOperator name=¥"AND¥">" +
" <wpc:wpcSearchElement>" +
" <wpc:wpcAttributePath>Master Item Spec/GTIN</wpc:wpcAttributePath>"
+
" <wpc:wpcAttributeValue></wpc:wpcAttributeValue>" +
" <wpc:wpcAttributeNotPredicate>1</wpc:wpcAttributeNotPredicate>"
+
" <wpc:wpcSearchElementOperator>ISEMPTY</wpc:wpcSearchElementOperator>"
+
" </wpc:wpcSearchElement>" +
" </wpc:wpcSearchOperator>" +
" </wpc:wpcSearchOperator>" +
" </wpc:wpcSearchCriteria>" +
" </wpc:wpcCommand>" +
" </wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
このメッセージは特定のカタログの基本仕様を戻します。もしカテゴリー情報が存在しており、そのカテゴリーに何らかのアイテム・カテゴリー仕様が付加されている場合は、その情報が応答として戻されます。
// ITEMSKELETON メッセージを呼び出す
var strXML = "<wpc:envelope xmlns:wpc=¥"http://ibm.com/wpc/¥"
communicationVersion=¥"5.2¥">" +
" <wpc:WPCResponseType>synchronous</wpc:WPCResponseType>"
+
" <wpc:wpcHeader>"+
" <wpc:companyName>carmel</wpc:companyName>" +
" <wpc:userID>Admin</wpc:userID>" +
" <wpc:password>trinitron</wpc:password>" +
" <wpc:messageIdentifier>12345</wpc:messageIdentifier>" +
" <wpc:timestamp>2004-12-13</wpc:timestamp>" +
" </wpc:wpcHeader> " +
" <wpc:wpcBody> " +
" <wpc:wpcCommand type=¥"ITEMSKELETON¥"
mode=¥"SYNC¥"> " +
" <wpc:wpcCatalogName>CTG_PORTAL_MASTER</wpc:wpcCatalogName>"
+
" </wpc:wpcCommand>" +
" </wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
このコマンドは WPC の Web サービス・フレームワーク自体によって処理されます。対応するスクリプト・インプリメンテーションによっては処理されません。Web サービス・フレームワークはそれぞれの ASYNC 要求に対して固有のトランザクション ID を割り当てます。特定のトランザクション ID を使って WPS がトランザクション詳細のクエリー・メッセージを送ると、フレームワークはインプリメンテーション・スクリプトによって生成される応答を返送します。
// QUERY_TRANSACTION_DETAILS メッセージを呼び出す
<ibm:envelope xmlns:ibm="http://ibm.com/wpc/"
communicationVersion="5.2">
<ibm:WPCResponseType>synchronous</ibm:WPCResponseType>
<ibm:wpcHeader>
<ibm:companyName>String</ibm:companyName>
<ibm:userID>String</ibm:userID>
<ibm:password>String</ibm:password>
<ibm:messageIdentifier>1242432</ibm:messageIdentifier>
<ibm:timestamp>1967-08-13</ibm:timestamp>
</ibm:wpcHeader>
<ibm:wpcBody>
<ibm:wpcCommand type="QUERY_TRANSACTION_DETAILS"
mode="SYNC">
<ibm:wpcTransactionID>99</ibm:wpcTransactionID>
</ibm:wpcCommand>
</ibm:wpcBody>
</ibm:envelope>
これは、特定のトランザクション ID (ASYNC メッセージ) が完了したかどうかを確認するために定期的な間隔でユーザーによって送信されるポーリング・メッセージです。このメッセージもまた、インプリメンテーション・スクリプトではなく Web サービス・フレームワークによって処理されます。
// QUERY_TRANSACTION_STATUS メッセージを呼び出す
<ibm:envelope xmlns:ibm="http://ibm.com/wpc/"
communicationVersion="5.2">
<ibm:WPCResponseType>synchronous</ibm:WPCResponseType>
<ibm:wpcHeader>
<ibm:companyName>String</ibm:companyName>
<ibm:userID>String</ibm:userID>
<ibm:password>String</ibm:password>
<ibm:messageIdentifier>1242432</ibm:messageIdentifier>
<ibm:timestamp>1967-08-13</ibm:timestamp>
</ibm:wpcHeader>
<ibm:wpcBody>
<ibm:wpcCommand type="QUERY_TRANSACTION_STATUS"
mode="SYNC">
<ibm:wpcTransactionID>99</ibm:wpcTransactionID>
</ibm:wpcCommand>
</ibm:wpcBody>
</ibm:envelope>
ファイルのアップロード
Web サービスの添付ファイルとして送られるファイルをアップロードするために、応答インプリメンテーション・スクリプトはアップロードされるファイルを文書ストア内の対応する supplier/ctg_files フォルダーにコピーし、現在の文書ストアのパスを返送します。
// 添付ファイルなしで UPLOAD_FILE メッセージを呼び出す
var strXML = "<wpc:envelope xmlns:wpc=¥"http://ibm.com/wpc/¥"
communicationVersion=¥"5.2¥">" +
"<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>" +
" <wpc:wpcHeader>" +
" <wpc:companyName>null</wpc:companyName>" +
" <wpc:userID>wpsadmin</wpc:userID>" +
" <wpc:password>null</wpc:password>" +
" <wpc:messageIdentifier>C71125E0-8002-11D9-BDC3-93DA3F31311D</wpc:messageIdentifier>"
+
" <wpc:timestamp>2005-02-16</wpc:timestamp>" +
" <wpc:supplierId>null</wpc:supplierId>" +
" </wpc:wpcHeader>" +
"<wpc:wpcBody>" +
" <wpc:wpcCommand type=¥"UPLOAD_FILE¥"
mode=¥"SYNC¥">" +
" <wpc:wpcDataContainer>" +
" <wpc:wpcAttachmentsDataContainer>" +
" <wpc:FileName>xyz.jpg</wpc:FileName>" +
" </wpc:wpcAttachmentsDataContainer>" +
" </wpc:wpcDataContainer>" +
" </wpc:wpcCommand>" +
"</wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
このコマンドを呼び出す前に、ファイル・アップロード・コマンドを使って、必要なデータの入った CSV ファイルをアップロードします。その後、アップロードされたファイルの文書ストア・パスと一緒にインポート・メッセージが送られ、その同じ情報がインプリメンテーション・スクリプトによって処理されて、対応するレコードが追加または更新されます。
// 添付ファイルなしで IMPORT メッセージを呼び出す
var strXML = "<wpc:envelope xmlns:wpc=¥"http://ibm.com/wpc/¥"
communicationVersion=¥"5.2¥">" +
"<wpc:WPCResponseType>asynchronous</wpc:WPCResponseType>"
+
" <wpc:wpcHeader>" +
" <wpc:companyName>null</wpc:companyName>" +
" <wpc:userID>wpsadmin</wpc:userID>" +
" <wpc:password>null</wpc:password>" +
" <wpc:messageIdentifier>C71125E0-8002-11D9-BDC3-93DA3F31311D</wpc:messageIdentifier>"
+
" <wpc:timestamp>2005-02-16</wpc:timestamp>" +
" <wpc:supplierId>null</wpc:supplierId>" +
" </wpc:wpcHeader>" +
"<wpc:wpcBody>" +
" <wpc:wpcCommand type=¥"IMPORT¥" mode=¥"ASYNC¥">"
+
"<wpc:wpcFileDocStorePath>public_html/ctg_files/1108730965078_15.3KB.1.csv</wpc:wpcFileDocStorePath>"
+
" </wpc:wpcCommand>" +
"</wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
カテゴリー固有属性 (該当する場合) を含む、すべてのアイテム属性を取得します。
// アイテムの詳細を取得する
<wpc:envelope xmlns:wpc="http://ibm.com/wpc/" communicationVersion="5.2">
<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>
<wpc:wpcHeader>
<wpc:companyName>IBM</wpc:companyName>
<wpc:userID>Admin</wpc:userID>
<wpc:password>trinitron</wpc:password>
<wpc:messageIdentifier>12343</wpc:messageIdentifier>
<wpc:timestamp>2004-12-10</wpc:timestamp>
<wpc:supplierId>2348623864826</wpc:supplierId>
</wpc:wpcHeader>
<wpc:wpcBody>
<wpc:wpcCommand type="ITEMDETAIL" mode="ASYNC">
<wpc:wpcParentCategory>1/5</wpc:wpcParentCategory>
<wpc:wpcCatalogName>CTG_PORTAL_MASTER</wpc:wpcCatalogName>
<wpc:wpcTradeItem ID="111225868"></wpc:wpcTradeItem>
</wpc:wpcCommand>
</wpc:wpcBody>
</wpc:envelope>
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
このメッセージは、基本キーの値なしでアイテム詳細の応答を戻します。
// アイテム・クローン・メッセージを呼び出す
// アイテム詳細を取得する
<wpc:envelope xmlns:wpc="http://ibm.com/wpc/" communicationVersion="5.2">
<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>
<wpc:wpcHeader>
<wpc:companyName>IBM</wpc:companyName>
<wpc:userID>Admin</wpc:userID>
<wpc:password>trinitron</wpc:password>
<wpc:messageIdentifier>12343</wpc:messageIdentifier>
<wpc:timestamp>2004-12-10</wpc:timestamp>
<wpc:supplierId>2348623864826</wpc:supplierId>
</wpc:wpcHeader>
<wpc:wpcBody>
<wpc:wpcCommand type="CLONEITEM" mode="ASYNC">
<wpc:wpcParentCategory>1/5</wpc:wpcParentCategory>
<wpc:wpcCatalogName>CTG_PORTAL_MASTER</wpc:wpcCatalogName>
<wpc:wpcTradeItem ID="111225868"></wpc:wpcTradeItem>
</wpc:wpcCommand>
</wpc:wpcBody>
</wpc:envelope>
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
このコマンドは応答として、特定のカタログの現在のカテゴリー内 (および、カテゴリー・ツリー情報が要求メッセージに含まれない場合には基本カテゴリー・ツリー内) のすべての子カテゴリーおよび子アイテムを戻します。
// QUERY_CATALOG_CHILDREN メッセージを呼び出す
var strXML = "<?xml version=¥"1.0¥"
encoding=¥"UTF-8¥"?>" +
"<wpc:envelope xmlns:wpc=¥"http://ibm.com/wpc/¥"
communicationVersion=¥"5.2¥"> " +
"<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>"
+
"<wpc:wpcHeader>" +
"<wpc:companyName>ibm</wpc:companyName>" +
"<wpc:userID>portaluser</wpc:userID>" +
"<wpc:password>password</wpc:password>" +
"<wpc:messageIdentifier>A2473730-5D85-11D9-BF8A-BC1A417CAB44</wpc:messageIdentifier>"
+
"<wpc:timestamp>2005-01-03</wpc:timestamp>" +
"</wpc:wpcHeader>" +
"<wpc:wpcBody>" +
"<wpc:wpcCommand type=¥"QUERY_CATALOG_CHILDREN¥"
mode=¥"SYNC¥">" +
"<wpc:wpcParentCategory>1/5</wpc:wpcParentCategory>" +
"<wpc:wpcCatalogName>CTG_PORTAL</wpc:wpcCatalogName>" +
"<wpc:wpcHierarchyName name=¥"Hier_Portal¥"
type=¥"PRIMARY¥"/>" +
"</wpc:wpcCommand>" +
"</wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
このメッセージは現在 WPC 内で使用可能なすべてのカタログを取得し、同じものを応答として送信します。
// GET_CATALOGS メッセージ・タイプを呼び出す
var strXML = "<?xml version=¥"1.0¥"
encoding=¥"UTF-8¥"?>" +
"<wpc:envelope xmlns:wpc=¥"http://ibm.com/wpc/¥"
communicationVersion=¥"5.2¥"> " +
"<wpc:WPCResponseType>synchronous</wpc:WPCResponseType>"
+
"<wpc:wpcHeader>" +
"<wpc:companyName>ibm</wpc:companyName>" +
"<wpc:userID>portaluser</wpc:userID>" +
"<wpc:password>password</wpc:password>" +
"<wpc:messageIdentifier>A2473730-5D85-11D9-BF8A-BC1A417CAB44</wpc:messageIdentifier>"
+
"<wpc:timestamp>2005-01-03</wpc:timestamp>" +
"</wpc:wpcHeader>" +
"<wpc:wpcBody>" +
"<wpc:wpcCommand type=¥"GET_CATALOGS¥"
mode=¥"SYNC¥"/>" +
"</wpc:wpcBody>" +
"</wpc:envelope>";
var resp = invokeSoapServerForDocLit("<respective
webservice URL>",strXML);
var respLog = createOtherOut("Response.xml"); // これはトランザクション ID を使用します。実際の応答については /scripts/soap/messages/response/<TXN_ID> を参照してください。
respLog.writeln(resp);
respLog.save("Response.xml");
指定されたビューを XML 応答で戻します。このメッセージは、現在 Product Center で使用されていません。
これは、対応する要求された応答を応答ファイルとして戻します。
// GET_RESOURCE メッセージを呼び出す
<?xml version="1.0" encoding="UTF-8"?>
<envelope xmlns="http://ibm.com/wpc/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://ibm.com/wpc/
C:¥wpc¥portal¥webservice_dev.xsd" communicationVersion="5.2">
<WPCResponseType>synchronous</WPCResponseType>
<wpcHeader>
<companyName>null</companyName>
<userID>administrator</userID>
<password>null</password>
<messageIdentifier>1D3589B0-97AB-11D9-B84B-AED0CDB181F1</messageIdentifier>
<timestamp>2005-03-18</timestamp>
<supplierId>null</supplierId>
</wpcHeader>
<wpcBody>
<wpcCommand type="GET_RESOURCE" mode="SYNC">
<wpcParentCategory>9/11</wpcParentCategory>
<wpcCatalogName>CTG_PORTAL_MASTER</wpcCatalogName>
<wpcHierarchyName type="PRIMARY" name="null"/>
<wpcTradeItem ID="1732">
<attribute-list>
<attribute name="Master Item Spec/Product Content/Web Image"
type="IMAGE"/>
</attribute-list>
</wpcTradeItem>
</wpcCommand>
</wpcBody>
</envelope>
本書に記載の製品、サービス、または機能が日本においては提供されていない場合があります。 日本で利用可能な製品、サービス、および機能については、日本 IBM の営業担当員にお尋ねください。 本書で IBM 製品、プログラム、またはサービスに言及していても、その IBM 製品、プログラム、または サービスのみが使用可能であることを意味するものではありません。これらに代えて、IBM の知的所有権を侵害することのない、機能的に同等の 製品、プログラム、またはサービスを使用することができます。 ただし、IBM 以外の製品とプログラムの操作またはサービスの評価および検証は、お客様の責任で行っていただきます。
IBM は、本書に記載されている内容に関して特許権 (特許出願中のものを含む) を保有している場合があります。 本書の提供は、お客様にこれらの特許権について 実施権を許諾することを意味するものではありません。 実施権についてのお問い合わせは、書面にて下記宛先にお送りください。
〒106-0032
東京都港区六本木3-2-31
IBM World Trade Asia Corporation
Licensing
以下の保証は、国または地域の法律に沿わない場合は、適用されません。
IBM およびその直接または間接の子会社は、本書を特定物として現存するままの状態で提供し、商品性の保証、特定目的適合性の保証および法律上の瑕疵担保責任を含むすべての明示もしくは黙示の保証責任を負わないものとします。国または地域によっては、法律の強行規定により、保証責任の制限が禁じられる場合、強行規定の制限を受けるものとします。
この情報には、技術的に不適切な記述や誤植を含む場合があります。 本書は定期的に見直され、必要な変更は本書の次版に組み込まれます。 IBM は予告なしに、随時、この文書に記載されている製品またはプログラムに対して、改良または変更を行うことがあります。
本書において IBM 以外の Web サイトに言及している場合がありますが、 便宜のため記載しただけであり、決してそれらの Web サイトを推奨するものでは ありません。それらの Web サイトにある資料は、この IBM 製品の資料の一部ではありません。それらの Web サイトは、お客様の責任でご使用ください。
IBM は、お客様が提供するいかなる情報も、お客様に対してなんら義務も負うことのない、自ら適切と信ずる方法で、使用もしくは配布することができるものとします。
本プログラムのライセンス保持者で、(i) 独自に作成したプログラムとその他のプログラム(本プログラムを含む)との間での情報交換、および (ii) 交換された情報の相互利用を可能にすることを目的として、本プログラムに関する情報を必要とする方は、下記に連絡してください。
IBM Burlingame Laboratory
Director IBM Burlingame Laboratory
577 Airport Blvd., Suite 800
Burlingame, CA 94010
U.S.A
本プログラムに関する上記の情報は、適切な使用条件の下で使用することができますが、有償の場合もあります。
本書で説明されているライセンス・プログラムまたはその他のライセンス資料は、IBM 所定のプログラム契約の契約条項、IBM プログラムのご使用条件、またはそれと同等の条項に基づいて、IBM より提供されます。
この文書に含まれるいかなるパフォーマンス・データも、管理環境下で 決定されたものです。 そのため、他の操作環境で得られた結果は、異なる可能性があります。 一部の測定が、開発レベルのシステムで行われた可能性がありますが、 その測定値が、一般に利用可能なシステムのものと同じである保証はありません。 さらに、一部の測定値が、推定値である可能性があります。 実際の結果は、異なる可能性があります。お客様は、お客様の特定の環境に適したデータを確かめる必要があります。
IBM 以外の製品に関する情報は、その製品の供給者、出版物、 もしくはその他の公に利用可能なソースから入手したものです。IBM は、それらの製品のテストは行っておりません。したがって、 他社製品に関する実行性、互換性、またはその他の要求については確証できません。 IBM 以外の製品の性能に関する質問は、それらの製品の供給者にお願いします。
本書には、日常の業務処理で用いられるデータや報告書の例が含まれています。 より具体性を与えるために、それらの例には、個人、企業、ブランド、あるいは製品などの名前が含まれている場合があります。 これらの名称はすべて架空のものであり、名称や住所が類似する企業が実在しているとしても、それは偶然にすぎません。
IBM の将来の方向または意向に関する記述については、予告なしに変更または撤回される場合があり、単に目標を示しているものです。
プログラミング・インターフェース情報が記載されている場合、その情報はプログラムを使用してアプリケーション・ソフトウェアを作成する際に役立ちます。
一般使用プログラミング・インターフェースにより、このプログラム・ツール・サービスを含むアプリケーション・ソフトウェアを書くことができます。
ただし、この情報には、診断、修正、および調整情報が含まれている場合が あります。診断、修正、調整情報は、お客様のアプリケーション・ソフトウェアの デバッグ支援のために提供されています。
警告: 診断、修正、調整情報は、変更される場合がありますので、 プログラミング・インターフェースとしては使用しないでください。
以下は、IBM Corporation の商標です。
IBM
IBM ロゴ
AIX
CrossWorlds
DB2
DB2 Universal Database
Domino
Lotus
Lotus Notes
MQIntegrator
MQSeries
Tivoli
WebSphere
Microsoft、Windows、Windows NT および Windows ロゴは、Microsoft Corporation の米国およびその他の国における商標です。
MMX、Pentium および ProShare は、Intel Corporation の米国およびその他の国における商標です。
Java およびすべての Java 関連の商標およびロゴは、Sun Microsystems, Inc. の米国およびその他の国における商標または登録商標です。
他の会社名、製品名、およびサービス名等はそれぞれ各社の商標です。
IBM WebSphere Product Center にはいくつかの「適用除外コンポーネント」(関係する「ライセンス情報」文書の定義に従う) が含まれており、これには以下に挙げる追加の条件が適用されます。このソフトウェアは、「プログラムのご使用条件」の使用条件の下でお客様に使用許諾されており、「適用除外コンポーネント」の条件に従います。IBM には、このソフトウェアに関連して、お客様に以下の通知を行う義務があります。
i.) IBM WebSphere Product Center には、Apache 2.0 ライセンスの使用条件に従って Apache Software Foundation から IBM によって使用許諾された、以下のソフトウェアが含まれています。
- Apache Regular Expression v1.2
- Apache Axis v1.1
- Apache XML4J v3.0.1
- Apache Log4j v1.1.1
- Apache Jakarta Commons DBCP Package v1.1
- Apache Jakarta Commons Pool Package v1.1
- Apache Jakarta Commons Collections Package v3.0
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 ther
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
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following boilerplate
notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include the brackets!)
The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a file or class name
and description of purpose be included on the same "printed page" as
the copyright notice for easier identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
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.
ii.) IBM WebSphere Product Center には、以下の使用条件に従って IBM が Scott Hudson、Frank Flannery、および C. Scott Ananian より使用許諾を得た以下のソフトウェアが含まれています。
- Cup Parser Generator v0.10k
CUP Parser Generator Copyright Notice, License, and Disclaimer
Copyright 1996-1999 by Scott Hudson, Frank Flannery, C. Scott Ananian
Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted, provided that
the above copyright notice appear in all copies and that both the copyright
notice and this permission notice and warranty disclaimer appear in supporting
documentation, and that the names of the authors or their employers not be used
in advertising or publicity pertaining to distribution of the software without
specific, written prior permission. The authors and their employers disclaim all
warranties with regard to this software, including all implied warranties of
merchantability and fitness. In no event shall the authors or their employers be
liable for any special, indirect or consequential damages or any damages
whatsoever resulting from loss of use, data or profits, whether in an action of
contract, negligence or other tortious action, arising out of or in connection
with the use or performance of this software.
iii.) IBM WebSphere Product Center には、以下の使用条件に従って IBM が Elliot Joel Berk および C. Scott Ananian より使用許諾を得た以下のソフトウェアが含まれています。
- JLex v1.2.6
JLEX COPYRIGHT NOTICE, LICENSE AND DISCLAIMER.
Copyright 1996-2003 by Elliot Joel Berk and C. Scott Ananian
Permission to use, copy, modify, and distribute this software and its
documentation for any purpose and without fee is hereby granted, provided that
the above copyright notice appear in all copies and that both the copyright
notice and this permission notice and warranty disclaimer appear in supporting
documentation, and that the name of the authors or their employers not be used
in advertising or publicity pertaining to distribution of the software without
specific, written prior permission. The authors and their employers disclaim all
warranties with regard to this software, including all implied warranties of
merchantability and fitness. In no event shall the authors or their employers be
liable for any special, indirect or consequential damages or any damages
whatsoever resulting from loss of use, data or profits, whether in an action of
contract, negligence or other tortious action, arising out of or in connection
with the use or performance of this software. Java is a trademark of Sun
Microsystems, Inc. References to the Java programming language in relation to
JLex are not meant to imply that Sun endorses this product.
iv.) IBM WebSphere Product Center には、以下の使用条件に従って IBM が International Business Machines Corporation およびその他の者より使用許諾を得た以下のソフトウェアが含まれています。
- ICU4J v2.8
ICU License - ICU 1.8.1 and later
COPYRIGHT AND PERMISSION NOTICE
Copyright (c) 1995-2003 International Business Machines Corporation and others
All rights reserved.
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
provided that the above copyright notice(s) and this permission notice appear in
all copies of the Software and that both the above copyright notice(s) and this
permission notice appear in supporting documentation.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD
PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR HOLDERS INCLUDED IN THIS
NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL INDIRECT OR CONSEQUENTIAL
DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
Except as contained in this notice, the name of a copyright holder shall not be
used in advertising or otherwise to promote the sale, use or other dealings in
this Software without prior written authorization of the copyright holder.
-----------------------------------------------------------------------------
All trademarks and registered trademarks mentioned herein are the property of
their respective owners.