SearchQueryLinguisticDetails 类

定义

提供有关用户通过输入法编辑器输入的查询文本的信息, (IME) 。

public ref class SearchQueryLinguisticDetails sealed
/// [Windows.Foundation.Metadata.Activatable(Windows.ApplicationModel.Search.ISearchQueryLinguisticDetailsFactory, 65536, Windows.Foundation.UniversalApiContract)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
class SearchQueryLinguisticDetails final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Activatable(Windows.ApplicationModel.Search.ISearchQueryLinguisticDetailsFactory, 65536, "Windows.Foundation.UniversalApiContract")]
class SearchQueryLinguisticDetails final
[Windows.Foundation.Metadata.Activatable(typeof(Windows.ApplicationModel.Search.ISearchQueryLinguisticDetailsFactory), 65536, typeof(Windows.Foundation.UniversalApiContract))]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
public sealed class SearchQueryLinguisticDetails
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Activatable(typeof(Windows.ApplicationModel.Search.ISearchQueryLinguisticDetailsFactory), 65536, "Windows.Foundation.UniversalApiContract")]
public sealed class SearchQueryLinguisticDetails
function SearchQueryLinguisticDetails(queryTextAlternatives, queryTextCompositionStart, queryTextCompositionLength)
Public NotInheritable Class SearchQueryLinguisticDetails
继承
Object IInspectable SearchQueryLinguisticDetails
属性

Windows 要求

设备系列
Windows 10 (在 10.0.10240.0 中引入)
API contract
Windows.Foundation.UniversalApiContract (在 v1.0 中引入)

注解

重要

若要在应用中实现Windows 10搜索,请使用 AutoSuggestBox。 有关详细信息 ,请参阅“自动建议”框

不应在适用于 Windows 10 的应用中使用 Windows.ApplicationModel.Search API (SearchPaneSearchContract) 或 SearchBox (Windows.UI.Xaml.Controls.SearchBox/WinJS.UI.SearchBox) API。

处理 QueryChanged 事件或处理 SuggestionsRequested 事件时,通过 LinguisticDetails 属性获取此对象。

构造函数

SearchQueryLinguisticDetails(IIterable<String>, UInt32, UInt32)

初始化 SearchQueryLinguisticDetails 类的新实例。

属性

QueryTextAlternatives

获取当前查询文本的文本替代项的列表。 这些替代项用于用户正在输入 IME 的未编译文本。

QueryTextCompositionLength

获取用户使用输入法编辑器 (IME) 撰写的查询文本部分的长度。

QueryTextCompositionStart

获取用户使用输入法编辑器 (IME) 撰写的文本的起始位置。

适用于