searchInfo

指定如何在给定属性定义中配置 Windows 搜索引擎。 如果未提供 searchInfo 元素,则该属性不包含在 Windows 搜索引擎中。 对于 Windows 7,此元素已更改。

Windows 7 的语法

<!-- searchInfo for Windows 7-->
<xs:element name="searchInfo">
    <xs:complexType>
        <xs:attribute name="inInvertedIndex"    type="xs:boolean" default="false"/>
        <xs:attribute name="isColumn"           type="xs:boolean" default="false"/>
        <xs:attribute name="isColumnSparse"     type="xs:boolean" default="true">
            <xs:annotation>
                <xs:documentation>
                    isColumnSparse: Default is true. If the property is multi-valued, this is always true.
                </xs:documentation>
            </xs:annotation>
        </xs:attribute>
        
        <xs:attribute name="columnIndexType" default="OnDemand">
            <xs:simpleType>
                <xs:restriction base="xs:string">
                    <xs:enumeration value="NotIndexed"/>
                    <xs:enumeration value="OnDisk"/>
                    <xs:enumeration value="OnDiskAll"/>
                    <xs:enumeration value="OnDiskVector"/>
                    <xs:enumeration value="OnDemand"/>
                </xs:restriction>
            </xs:simpleType>
        </xs:attribute>
        <xs:attribute name="maxSize" type="xs:nonNegativeInteger" default="512"/>
        <xs:attribute name="mnemonics" type="xs:string"/>                            
    </xs:complexType>
</xs:element>

Windows Vista 的语法

<!-- searchInfo for Windows Vista-->
<xs:element name="searchInfo">
    <xs:complexType>
        <xs:attribute name="inInvertedIndex"    type="xs:boolean" default="false"/>
        <xs:attribute name="isColumn"           type="xs:boolean" default="false"/>
        <xs:attribute name="isColumnSparse"     type="xs:boolean" default="true">
            <xs:annotation>
                <xs:documentation>
                    isColumnSparse: Default is true. If the property is multi-valued, this is always true.
                </xs:documentation>
            </xs:annotation>
        </xs:attribute>
        
        <xs:attribute name="columnIndexType" default="OnDemand">
            <xs:simpleType>
                <xs:restriction base="xs:string">
                    <xs:enumeration value="NotIndexed"/>
                    <xs:enumeration value="OnDisk"/>
                </xs:restriction>
            </xs:simpleType>
        </xs:attribute>
        <xs:attribute name="maxSize" type="xs:nonNegativeInteger" default="128"/>
    </xs:complexType>
</xs:element>

元素信息

Parent 元素 子元素
propertyDescription 没有

 

属性

属性 描述
inInvertedIndex 公共。 自选。 指示属性值是否应存储在倒排索引中。 这样,最终用户就可以对此属性的值执行全文查询。 默认值为“false”。
isColumn 公共。 自选。 指示属性是否还应作为列存储在 Windows 搜索数据库中,以便独立软件供应商(ISV)可以创建基于谓词的查询(例如,选择 * Where “System.Title”='qqq')。 如果架构创建者希望使最终用户(或开发人员)能够基于属性创建谓词,则需要将其设置为“true”。 默认值为“false”。
isColumnSparse 公共。 自选。 默认值为“true”。 如果该属性是多值,则此属性始终为“true”。
columnIndexType 公共。 自选。 为了优化排序和分组,Windows 搜索引擎可以为具有 isColumn=“true”的属性创建辅助索引。 仅当 Windows Vista 中的 inInvertedIndex 为“true”或 Windows 7 中的 isColumn 为“true”时,此属性才有用。 如果属性往往由用户频繁排序,则应指定此属性。 Windows Vista 中的默认值为“NotIndexed”。 Windows 7 中的默认值为“OnDemand”。 以下值有效。
  • NotIndexed:从不生成值索引。
  • OnDisk:默认情况下,为此属性生成值索引。
  • OnDiskAll(仅 Windows 7 及更高版本):默认情况下,为此属性生成值索引,如果它是向量属性,则也是所有串联向量值的值索引。
  • OnDiskVector(仅限 Windows 7 及更高版本):默认为串联矢量值生成值索引。
  • OnDemand(仅限 Windows 7 及更高版本):仅按需生成值索引,即仅首次用于查询。
maxSize 公共。 自选。 允许存储在 Windows 搜索数据库中的特定属性的最大大小(以字节为单位)。 默认值为:
  • Windows Vista:128 字节
  • Windows 7 及更高版本:512 字节
请注意,此最大大小以字节而不是字符为单位。 最大字符数取决于其编码。
记忆术 Windows 7 及更高版本。 公共。 自选。 可用于引用搜索查询中的属性的助记值列表。 该列表以“|”字符分隔。