Share via


TaxonomyNavigation.GetWebNavigationSettings method

Returns the navigation settings for the specified Web object as a read-only instance of the WebNavigationSettings class that is efficiently obtained from the taxonomy navigation cache.

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

Syntax

'Declaration
Public Shared Function GetWebNavigationSettings ( _
    context As ClientRuntimeContext, _
    web As Web _
) As WebNavigationSettings
'Usage
Dim context As ClientRuntimeContext
Dim web As Web
Dim returnValue As WebNavigationSettings

returnValue = TaxonomyNavigation.GetWebNavigationSettings(context, _
    web)
public static WebNavigationSettings GetWebNavigationSettings(
    ClientRuntimeContext context,
    Web web
)

Parameters

Return value

Type: Microsoft.SharePoint.Client.Publishing.Navigation.WebNavigationSettings
A read-only, cached WebNavigationSettings object.

Remarks

Since this object is fetched from the cache, the GetWebNavigationSettings(Web) method is more efficient than calling the constructor for the WebNavigationSettings object. If the WebNavigationSettings object is not already in the cache, the system adds it. However, if the settings were recently changed during the same HTTP request, the returned settings may be out of data until the cache has been refreshed.

The GetWebNavigationSettings(Microsoft.SharePoint.Client.Web) method returns a null reference (Nothing in Visual Basic) if there are no settings defined in the Web object, or if the settings are invalid.

See also

Reference

TaxonomyNavigation class

TaxonomyNavigation members

Microsoft.SharePoint.Client.Publishing.Navigation namespace