Share via


TaxonomyNavigation.GetTermSetForWeb method

Returns efficiently from the taxonomy navigation cache a read-only instance of a NavigationTermSet object for the specified Web object.

Namespace:  Microsoft.SharePoint.Client.Publishing.Navigation
Assembly:  Microsoft.SharePoint.Client.Publishing (in Microsoft.SharePoint.Client.Publishing.dll)

Syntax

'Declaration
Public Shared Function GetTermSetForWeb ( _
    context As ClientRuntimeContext, _
    web As Web, _
    siteMapProviderName As String, _
    includeInheritedSettings As Boolean _
) As NavigationTermSet
'Usage
Dim context As ClientRuntimeContext
Dim web As Web
Dim siteMapProviderName As String
Dim includeInheritedSettings As Boolean
Dim returnValue As NavigationTermSet

returnValue = TaxonomyNavigation.GetTermSetForWeb(context, _
    web, siteMapProviderName, includeInheritedSettings)
public static NavigationTermSet GetTermSetForWeb(
    ClientRuntimeContext context,
    Web web,
    string siteMapProviderName,
    bool includeInheritedSettings
)

Parameters

  • includeInheritedSettings
    Type: System.Boolean

    Specifies whether the parent Web objects should be considered if the SiteMapProvider is configured to inherit its settings via the StandardNavigationSource.InheritFromParentWeb enumeration; otherwise, a null reference (Nothing in Visual Basic) is returned when these configurations are encountered.

Return value

Type: Microsoft.SharePoint.Client.Publishing.Navigation.NavigationTermSet
A NavigationTermSet object for the specified SPWeb object if managed navigation is configured for the site; otherwise, a null reference (Nothing in Visual Basic).

Remarks

If the NavigationTermSet object is not already in the cache, returning it may involve loading the WebNavigationSettings object from Properties and then loading the TermSet.object.

See also

Reference

TaxonomyNavigation class

TaxonomyNavigation members

Microsoft.SharePoint.Client.Publishing.Navigation namespace