ScopesManager.GetRulesInfo Method
Gets a key/value pair of Search scope rules from the specified rule information collection.
Namespace: Microsoft.Office.Server.Search.Administration
Assembly: Microsoft.Office.Server.Search (in Microsoft.Office.Server.Search.dll)
Syntax
'Declaration
Protected Function GetRulesInfo ( _
scope As Scope, _
ruleInfos As List(Of RuleInfo), _
statusCode As Integer _
) As IDictionary(Of Integer, ScopeRule)
'Usage
Dim scope As Scope
Dim ruleInfos As List(Of RuleInfo)
Dim statusCode As Integer
Dim returnValue As IDictionary(Of Integer, ScopeRule)
returnValue = Me.GetRulesInfo(scope, _
ruleInfos, statusCode)
protected IDictionary<int, ScopeRule> GetRulesInfo(
Scope scope,
List<RuleInfo> ruleInfos,
int statusCode
)
Parameters
scope
Type: Microsoft.Office.Server.Search.Administration.ScopeThe Search scope of the rules.
ruleInfos
Type: System.Collections.Generic.List<RuleInfo>A collection of information about the Search scope rules.
statusCode
Type: System.Int32The status code that indicates whether the scope exists. ‘0’ means the scope exists.
Return Value
Type: System.Collections.Generic.IDictionary<Int32, ScopeRule>
A key/value pair of Search scope rules.
Exceptions
Exception | Condition |
---|---|
DeletedConcurrencyException | The value of the statusCode parameter is not equal to 0. |
ArgumentOutOfRangeException | The RuleType property of a RuleInfo object in ruleInfos is not AllContent or Url or PropertyQuery. |
Remarks
This method creates different types of scope rules based on the value of the RuleType property of the RuleInfo objects in ruleInfos.