IConditionFactory2::CreateStringLeaf method (structuredquery.h)

Creates a leaf condition node for a string value that represents a comparison of property value and constant value. The returned object supports ICondition and ICondition2.

Syntax

HRESULT CreateStringLeaf(
  [in]  REFPROPERTYKEY             propkey,
  [in]  CONDITION_OPERATION        cop,
  [in]  LPCWSTR                    pszValue,
  [in]  LPCWSTR                    pszLocaleName,
  [in]  CONDITION_CREATION_OPTIONS cco,
  [in]  REFIID                     riid,
  [out] void                       **ppv
);

Parameters

[in] propkey

Type: REFPROPERTYKEY

The name of the property of the leaf condition as a REFPROPERTYKEY. If the leaf has no particular property, use PKEY_Null.

[in] cop

Type: CONDITION_OPERATION

A CONDITION_OPERATION enumeration. If the leaf has no particular operation, then use COP_IMPLICIT.

[in] pszValue

Type: LPCWSTR

The value to be compared, or NULL for an unspecified property. The locale name of the leaf node is LOCALE_NAME_USER_DEFAULT.

[in] pszLocaleName

Type: LPCWSTR

The name of the locale of the lead condition, or NULL for a plain string. The locale name of the leaf node is LOCALE_NAME_USER_DEFAULT.

[in] cco

Type: CONDITION_CREATION_OPTIONS

The condition creation operation of the leaf condition as the CONDITION_CREATION_OPTIONS enumeration.

[in] riid

Type: REFIID

The desired IID of the enumerating interface: either IEnumUnknown, IID_IEnumVARIANT, or (for a negation condition) IID_ICondition.

[out] ppv

Type: void**

Receives a pointer to zero or more ICondition and ICondition2 objects.

Return value

Type: HRESULT

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

Remarks

For default options, use the CONDITION_CREATION_DEFAULT flag.

Requirements

Requirement Value
Minimum supported client Windows 7 [desktop apps only]
Minimum supported server Windows Server 2008 R2 [desktop apps only]
Target Platform Windows
Header structuredquery.h

See also

CONDITION_CREATION_OPTIONS

CONDITION_OPERATION

CONDITION_TYPE

ICondition

ICondition2

IConditionFactory

IConditionFactory2

Reference