IConditionFactory::MakeLeaf Method

Creates a leaf condition node.

Syntax

HRESULT MakeLeaf(      
    LPCWSTR pszPropertyName,
    CONDITION_OPERATION op,
    LPCWSTR pszValueType,
    PROPVARIANT const *pValue,
    IRichChunk *pPropertyNameTerm,
    IRichChunk *pOperationTerm,
    IRichChunk *pValueTerm,
    BOOL expand,
    ICondition **ppResultQuery
);

Parameters

  • pszPropertyName
    [in, unique]  The name of a property to be compared or NULL for an unspecified property.
  • op
    [in]  A CONDITION_OPERATION value.
  • pszValueType
    [in, unique]  The name of a semantic type or NULL for a plain string.
  • pValue
    [in]  A pointer to the constant to which the property is compared.
  • pPropertyNameTerm
    [in]  A pointer to an IRichChunk. May be NULL.
  • pOperationTerm
    [in]  A pointer to an IRichChunk. May be NULL.
  • pValueTerm
    [in]  A pointer to an IRichChunk. May be NULL.
  • expand
    [in]  If TRUE and pszPropertyName identifies a virtual property, then the result is a disjunction of leaf conditions, each of which corresponds to one expansion of the virtual property.
  • ppResultQuery
    [out, retval]  Returns a pointer to the new ICondition node.

Return Value

Returns S_OK if successful, or an error value otherwise.

Remarks

Each of pPropertyNameTerm, pOperationTerm and pValueTerm is either NULL or identifies the part of the query string that specified the property name, the operation, and the constant value, respectively. For more information, see ICondition::GetInputTerms.

A virtual property has one or more metadata where the key is "MapsToRelation" and the value is a property name (which is one expansion of the property). For more information about metadata, see IRelationship::MetaData. See also STRUCTURED_QUERY_RESOLVE_OPTION.