HostDistributionRuleCollection.AddRule Method (String, CrawlStore)
Adds a new HostDistributionRule to the Search service application and caches it to the HostDistributionRuleCollection object.
Namespace: Microsoft.Office.Server.Search.Administration
Assembly: Microsoft.Office.Server.Search (in Microsoft.Office.Server.Search.dll)
Syntax
'Declaration
Public Sub AddRule ( _
hostName As String, _
cs As CrawlStore _
)
'Usage
Dim instance As HostDistributionRuleCollection
Dim hostName As String
Dim cs As CrawlStore
instance.AddRule(hostName, cs)
public void AddRule(
string hostName,
CrawlStore cs
)
Parameters
hostName
Type: System.StringThe host name of the HostDistributionRule to add.
cs
Type: Microsoft.Office.Server.Search.Administration.CrawlStoreThe crawl store for the HostDistributionRule to add.
Remarks
This method calls the AddRule(String, Guid) method with the Id property of cs to add a new HostDistributionRule.
See Also
Reference
HostDistributionRuleCollection Class