Skip to content

Latest commit

 

History

History
123 lines (79 loc) · 6.58 KB

nf-structuredquery-iconditionfactory-resolve.md

File metadata and controls

123 lines (79 loc) · 6.58 KB
UID title description helpviewer_keywords old-location tech.root ms.assetid ms.date ms.keywords req.header req.include-header req.target-type req.target-min-winverclnt req.target-min-winversvr req.kmdf-ver req.umdf-ver req.ddi-compliance req.unicode-ansi req.idl req.max-support req.namespace req.assembly req.type-library req.lib req.dll req.irql targetos req.typenames req.redist ms.custom f1_keywords dev_langs topic_type api_type api_location api_name
NF:structuredquery.IConditionFactory.Resolve
IConditionFactory::Resolve (structuredquery.h)
Performs a variety of transformations on a condition tree, including the following:\_resolves conditions with relative date/time expressions to conditions with absolute date/time (as a VT_FILETIME); turns other recognized named entities into condition trees with actual values; simplifies condition trees; replaces virtual or compound properties with OR trees of other properties; removes condition trees resulting from queries with property keywords that had no condition applied.
IConditionFactory interface [search]
Resolve method
IConditionFactory.Resolve
IConditionFactory::Resolve
Resolve
Resolve method [search]
Resolve method [search]
IConditionFactory interface
_search_IConditionFactory_Resolve
search._search_IConditionFactory_Resolve
structuredquery/IConditionFactory::Resolve
search\_search_IConditionFactory_Resolve.htm
search
VS|search|~\search\wds3x\reference\ifaces\querying\iconditionfactory\resolve.htm
12/05/2018
IConditionFactory interface [search],Resolve method, IConditionFactory.Resolve, IConditionFactory::Resolve, Resolve, Resolve method [search], Resolve method [search],IConditionFactory interface, _search_IConditionFactory_Resolve, search._search_IConditionFactory_Resolve, structuredquery/IConditionFactory::Resolve
structuredquery.h
Windows
Windows XP with SP2, Windows Vista [desktop apps only]
Windows Server 2003 with SP1 [desktop apps only]
Structuredquery.idl
Windows
Windows Desktop Search (WDS) 3.0
19H1
IConditionFactory::Resolve
structuredquery/IConditionFactory::Resolve
c++
APIRef
kbSyntax
COM
Structuredquery.h
IConditionFactory.Resolve

IConditionFactory::Resolve

-description

Performs a variety of transformations on a condition tree, including the following: resolves conditions with relative date/time expressions to conditions with absolute date/time (as a VT_FILETIME); turns other recognized named entities into condition trees with actual values; simplifies condition trees; replaces virtual or compound properties with OR trees of other properties; removes condition trees resulting from queries with property keywords that had no condition applied.

-parameters

-param pc [in]

Type: ICondition*

A pointer to an ICondition object to be resolved.

-param sqro [in]

Type: STRUCTURED_QUERY_RESOLVE_OPTION

Specifies zero or more of the STRUCTURED_QUERY_RESOLVE_OPTION flags. For Windows 7 and later, the SQRO_ADD_VALUE_TYPE_FOR_PLAIN_VALUES flag is automatically added to sqro.

-param pstReferenceTime [in]

Type: SYSTEMTIME const*

A pointer to a SYSTEMTIME value to use as the reference date and time. A null pointer can be passed if sqro is set to SQRO_DONT_RESOLVE_DATETIME.

-param ppcResolved [out, retval]

Type: ICondition**

Receives a pointer to the new ICondition in which all time fields have been resolved to have values of type VT_FILETIME. This new condition tree is the resolved version of pc.

-returns

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

-remarks

In a condition tree produced by the Parse method and returned by GetQuery, the leaves pair up properties with restrictions on these properties, and result in a condition tree that is partially finished. The IConditionFactory::Resolve method finishes such a condition tree by a process known as resolution. The input condition tree is not modified in any way. The output condition tree may share parts of the input condition that contained no leaf nodes with unresolved date/time values.

Note  Resolving a leaf node often produces a non-leaf node.
 
For example, Structured Query supports relative date/time expressions, which remain unresolved until they are applied to some reference time. In a leaf node with semantic type System.StructuredQueryType.DateTime, the value can be either a VT_FILETIME or a VT_LPWSTR. VT_FILETIME is an absolute date/time so it is already resolved. VT_LPWSTR is a string representation of a relative date/time expression. The specified reference time should be a local time, but the resolved times in the resulting query expression will be in Coordinated Universal Time (UTC).

The StructuredQuerySample demonstrates how to read lines from the console, parse them using the system schema, and display the resulting condition trees.

-see-also

CONDITION_OPERATION

CONDITION_TYPE

ICondition

ICondition2

IConditionFactory

IConditionFactory2

Reference