AvailableSearchKeys複合タイプによって、データ・ドメイン内で使用できる検索可能属性および検索インタフェースのリストを取得できます。
<complexType name="AvailableSearchKey"> <annotation> <documentation> A key used to identify searchable properties and search interfaces. </documentation> </annotation> <sequence> <element name="Key" type="string"/> <element name="DisplayName" type="string" /> </sequence> <attribute name="Interface" type="boolean" use="required" /> </complexType>
Interface属性は、検索キーが検索可能属性と検索インタフェースのどちらであるかを識別します。検索キーが検索インタフェースである場合、属性はtrueに設定されます。検索キーが検索インタフェースではなく、検索可能属性である場合、属性はfalseに設定されます。
<Request xmlns="http://www.endeca.com/MDEX/conversation/2/0"> <State/> <ContentElementConfig xsi:type="AvailableSearchKeysConfig" HandlerFunction="AvailableSearchKeysHandler" HandlerNamespace="http://www.endeca.com/MDEX/conversation/2/0" Id="MySearchKeys" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" /> </Request>
Id属性は、構成の識別子です。
<cs:Results xmlns:cs="http://www.endeca.com/MDEX/conversation/2/0" xmlns:mdex="http://www.endeca.com/MDEX/XQuery/2009/09"> <cs:Request> <State xmlns="http://www.endeca.com/MDEX/conversation/2/0" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"/> <ContentElementConfig xsi:type="AvailableSearchKeysConfig" HandlerFunction="AvailableSearchKeysHandler" HandlerNamespace="http://www.endeca.com/MDEX/conversation/2/0" Id="MySearchKeys" xmlns="http://www.endeca.com/MDEX/conversation/2/0" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"/> </cs:Request> <cs:ContentElement xsi:type="cs:AvailableSearchKeys" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <cs:AvailableSearchKey Interface="true"> <cs:Key>AllWineSearch</cs:Key> <cs:DisplayName>AllWineSearch</cs:DisplayName> </cs:AvailableSearchKey> <cs:AvailableSearchKey Interface="false"> <cs:Key>Description</cs:Key> <cs:DisplayName>Wine Description</cs:DisplayName> </cs:AvailableSearchKey> <cs:AvailableSearchKey Interface="false"> <cs:Key>WineType</cs:Key> <cs:DisplayName>Wine Type</cs:DisplayName> </cs:AvailableSearchKey> </cs:ContentElement> </cs:Results>
各AvailableSearchKey要素は、検索可能属性または検索インタフェース(Keyサブ要素)の名前、およびNCName以外の書式を持つことができる表示名をリストします。検索キーが検索インタフェースである場合、Interface属性はtrueに設定されます。
このサンプル・レスポンスでは、1つの検索インタフェースAllWineSearch、および2つの属性DescriptionとWineTypeが、使用可能な検索キーとしてリストされます。