Share via


ISpSREngineSite::GetRuleInfo

Other versions of this page are also available for the following:

Windows Mobile Not SupportedWindows Embedded CE Supported

8/28/2008

This method gets information about a CFG rule. The method can be called after the engine has been informed of a rule with a call to the ISpSREngine::RuleNotify method.

Syntax

HRESULT GetRuleInfo(
  SPRULEENTRY* pRuleEntry,
  SPRULEINFOOPT Options
);

Parameters

  • pRuleEntry
    [in, out] Pointer to an SPRULEENTRY structure that contains the grammar rule entry information. The engine only needs to fill in the hRule member of the structure when calling this method. If the engine wants to use the pvClientRuleContext member in the structure, it can set it by calling ISpSREngineSite::SetRuleClientContext. The engine can also set the hInitialState member of the structure. Information on the initial and subsequent states can be obtained by calling the ISpSREngineSite::GetStateInfo method.
  • Options
    [in] A grammar rule option. Possible values are defined for the SPRULEINFOOPT enumeration. For this parameter, the option must always be SPRIO_NONE.

Return Value

The following table shows the possible return values.

Value Description

S_OK

Function completed successfully.

E_POINTER

pRuleEntry points to invalid memory.

E_INVALIDARG

Either invalid hRule rule handle specified for pRuleEntry or Options contains invalid flags.

FAILED(hr)

Appropriate error message.

Requirements

Header sapiddk.h, sapiddk.idl
Library sapilib.lib
Windows Embedded CE Windows CE .NET 4.1 and later

See Also

Reference

ISpSREngineSite
SAPI Interfaces