WebSphere Enterprise Service Bus for z/OS バージョン 6.2.0 オペレーティング・システム: z/OS


どのようにして混合内容を処理するか

混合内容の場合、Sequence にはテキストを追加するための固有の API である addText(...) があります。

それ以外のすべての API は、テキストに対して Property の場合と同じように機能します。getProperty(int) API は、混合内容テキスト・データについて、ヌルを返します。以下の混合内容コードの例は、DataObject からのすべての混合内容テキストを印刷するために使用できます。

	DataObject mixedContent = ...
	Sequence seq = mixedContent.getSequence();

	for (int i=0; i < seq.size(); i++)
	{
	    Property prop = seq.getProperty(i);
	    Object value = seq.getValue(i);

	    if (prop == null)
	    {
	        System.out.println("Found mixed content text: "+value);
	    }
	    else
	    {
	        System.out.println("Found Property "+prop.getName()+": "+value);
	    }
	}

concept 概念トピック

ご利用条件 | フィードバック


タイムスタンプ・アイコン 最終更新: 2010/07/05


http://publib.boulder.ibm.com/infocenter/dmndhelp/v6r2mx/topic//com.ibm.websphere.wesb620.zseries.doc/doc/cbo_howmixedcontent.html
Copyright IBM Corporation 2005, 2010. All Rights Reserved.
このインフォメーション・センターでは Eclipse テクノロジーが採用されています (http://www.eclipse.org)。