Breyta

Deila með


StaticSiteMapProvider Class

Definition

Serves as a partial implementation of the abstract SiteMapProvider class and serves as a base class for the XmlSiteMapProvider class, which is the default site map provider in ASP.NET.

public ref class StaticSiteMapProvider abstract : System::Web::SiteMapProvider
public abstract class StaticSiteMapProvider : System.Web.SiteMapProvider
type StaticSiteMapProvider = class
    inherit SiteMapProvider
Public MustInherit Class StaticSiteMapProvider
Inherits SiteMapProvider
Inheritance
StaticSiteMapProvider
Derived

Examples

The following code example demonstrates how you to extend the StaticSiteMapProvider class to use Microsoft Access as a site map provider. The AccessSiteMapProvider class is a site map provider that supports only a simple, one-level-deep hierarchy. The table that the site map data is stored in has the following structure:

NODEID URL            NAME       PARENTNODEID  
 ---------------------------------------------  
 1      default.aspx   Default    <NULL>  
 2      catalog.aspx   Catalog    1  
 3      aboutus.aspx   Contact Us 1  
...  

The AccessSiteMapProvider class is derived from the StaticSiteMapProvider class and retrieves its information from a Microsoft Access database using basic SQL queries and the OleDbCommand and OleDbDataReader objects.

#using <System.Data.dll>
#using <System.Transactions.dll>
#using <System.EnterpriseServices.dll>
#using <System.dll>
#using <System.Web.dll>
#using <System.Configuration.dll>

using namespace System;
using namespace System::Collections;
using namespace System::Collections::Specialized;
using namespace System::Configuration;
using namespace System::Data;
using namespace System::Data::OleDb;
using namespace System::Security::Permissions;
using namespace System::Web;

/// An extremely simple AccessSiteMapProvider that only supports a
/// site map node hierarchy 1 level deep.

[AspNetHostingPermission(SecurityAction::Demand,Level=AspNetHostingPermissionLevel::Minimal)]
public ref class AccessSiteMapProvider: public StaticSiteMapProvider
{
private:
   SiteMapNode ^ rootNode;
   OleDbConnection^ accessConnection;

   // This string is case sensitive.
   String^ AccessConnectionStringName;

public:
   // Implement a default constructor.
   AccessSiteMapProvider()
   {
      initialized = false;
      AccessConnectionStringName = "accessSiteMapConnectionString";
   }


private:

   // Some basic state to help track the initialization state of the provider.
   bool initialized;

public:

   property bool IsInitialized 
   {
      virtual bool get()
      {
         return initialized;
      }

   }

   property SiteMapNode ^ RootNode 
   {

      // Return the root node of the current site map.
      virtual SiteMapNode ^ get() override
      {
         SiteMapNode ^ temp = nullptr;
         temp = BuildSiteMap();
         return temp;
      }

   }

protected:

   virtual SiteMapNode ^ GetRootNodeCore() override
   {
      return RootNode;
   }


public:

   // Initialize is used to initialize the properties and any state that the
   // AccessProvider holds, but is not used to build the site map.
   // The site map is built when the BuildSiteMap method is called.
   virtual void Initialize( String^ name, NameValueCollection^ attributes ) override
   {
      if ( IsInitialized )
            return;

      StaticSiteMapProvider::Initialize( name, attributes );
      
      // Create and test the connection to the Microsoft Access database.
      // Retrieve the Value of the Access connection string from the
      // attributes NameValueCollection.
      String^ connectionString = attributes[ AccessConnectionStringName ];
      if ( nullptr == connectionString || connectionString->Length == 0 )
            throw gcnew Exception( "The connection string was not found." );
      else
            accessConnection = gcnew OleDbConnection( connectionString );

      initialized = true;
   }


protected:

   ///
   /// SiteMapProvider and StaticSiteMapProvider methods that this derived class must override.
   ///
   // Clean up any collections or other state that an instance of this may hold.
   virtual void Clear() override
   {
      System::Threading::Monitor::Enter( this );
      try
      {
         rootNode = nullptr;
         StaticSiteMapProvider::Clear();
      }
      finally
      {
         System::Threading::Monitor::Exit( this );
      }

   }


public:

   // Build an in-memory representation from persistent
   // storage, and return the root node of the site map.
   virtual SiteMapNode ^ BuildSiteMap() override
   {
      // Since the SiteMap class is static, make sure that it is
      // not modified while the site map is built.
      System::Threading::Monitor::Enter( this );
      try
      {
         
         // If there is no initialization, this method is being
         // called out of order.
         if (  !IsInitialized )
         {
            throw gcnew Exception( "BuildSiteMap called incorrectly." );
         }
         
         // If there is no root node, then there is no site map.
         if ( nullptr == rootNode )
         {
            
            // Start with a clean slate
            Clear();
            
            // Select the root node of the site map from Microsoft Access.
            int rootNodeId = -1;
            if ( accessConnection->State == ConnectionState::Closed )
               accessConnection->Open();
            
            OleDbCommand^ rootNodeCommand = gcnew OleDbCommand
               ("SELECT nodeid, url, name FROM SiteMap WHERE parentnodeid IS NULL", accessConnection);
            OleDbDataReader^ rootNodeReader = rootNodeCommand->ExecuteReader();
            if ( rootNodeReader->HasRows )
            {
               rootNodeReader->Read();
               rootNodeId = rootNodeReader->GetInt32( 0 );
               
               // Create a SiteMapNode that references the current StaticSiteMapProvider.
               rootNode = gcnew SiteMapNode(this, rootNodeId.ToString(), 
                  rootNodeReader->GetString( 1 ),rootNodeReader->GetString( 2 ));
            }
            else
               return nullptr;
            rootNodeReader->Close();
            
            // Select the child nodes of the root node.
            OleDbCommand^ childNodesCommand = gcnew OleDbCommand
               ("SELECT nodeid, url, name FROM SiteMap WHERE parentnodeid = ?", accessConnection);
            OleDbParameter^ rootParam = gcnew OleDbParameter( "parentid", OleDbType::Integer);
            rootParam->Value = rootNodeId;
            childNodesCommand->Parameters->Add( rootParam );
            OleDbDataReader^ childNodesReader = childNodesCommand->ExecuteReader();
            if ( childNodesReader->HasRows )
            {
               SiteMapNode ^ childNode = nullptr;
               while ( childNodesReader->Read() )
               {
                  childNode = gcnew SiteMapNode( this, 
                      System::Convert::ToString(childNodesReader->GetInt32( 0 )),
                     childNodesReader->GetString( 1 ),
                     childNodesReader->GetString( 2 ) 
                  );
                  // Use the SiteMapNode AddNode method to add
                  // the SiteMapNode to the ChildNodes collection.
                  AddNode( childNode, rootNode );
               }
            }
            childNodesReader->Close();
            accessConnection->Close();
         }
         return rootNode;
      }
      finally
      {
         System::Threading::Monitor::Exit( this );
      }

   }

};
namespace Samples.AspNet.CS.Controls {

    using System;
    using System.Collections;
    using System.Collections.Specialized;
    using System.Data;
    using System.Data.OleDb;
    using System.Security.Permissions;
    using System.Web;

    /// An extremely simple AccessSiteMapProvider that only supports a
    /// site map node hierarchy 1 level deep.
    [AspNetHostingPermission(SecurityAction.Demand, Level=AspNetHostingPermissionLevel.Minimal)]
    public class AccessSiteMapProvider : StaticSiteMapProvider
    {
        private SiteMapNode rootNode =  null;
        private OleDbConnection accessConnection = null;

        // This string is case sensitive.
        private string AccessConnectionStringName = "accessSiteMapConnectionString";

        // Implement a default constructor.
        public AccessSiteMapProvider () { }

        // Some basic state to help track the initialization state of the provider.
        private bool initialized = false;
        public virtual bool IsInitialized {
            get {
                return initialized;
            }
        }
        // Return the root node of the current site map.
        public override SiteMapNode RootNode {
            get {
                SiteMapNode temp = null;
                temp = BuildSiteMap();
                return temp;
            }
        }
        protected override SiteMapNode GetRootNodeCore() {
            return RootNode;
        }
        // Initialize is used to initialize the properties and any state that the
        // AccessProvider holds, but is not used to build the site map.
        // The site map is built when the BuildSiteMap method is called.
        public override void Initialize(string name, NameValueCollection attributes) {
            if (IsInitialized)
                return;

            base.Initialize(name, attributes);

            // Create and test the connection to the Microsoft Access database.

            // Retrieve the Value of the Access connection string from the
            // attributes NameValueCollection.
            string connectionString = attributes[AccessConnectionStringName];

            if (null == connectionString || connectionString.Length == 0)
                throw new Exception ("The connection string was not found.");
            else
                accessConnection = new OleDbConnection(connectionString);

            initialized = true;
        }

        ///
        /// SiteMapProvider and StaticSiteMapProvider methods that this derived class must override.
        ///
        // Clean up any collections or other state that an instance of this may hold.
        protected override void Clear() {
            lock (this) {
                rootNode = null;
                base.Clear();
            }
        }

        // Build an in-memory representation from persistent
        // storage, and return the root node of the site map.
        public override SiteMapNode BuildSiteMap() {

            // Since the SiteMap class is static, make sure that it is
            // not modified while the site map is built.
            lock(this) {

                // If there is no initialization, this method is being
                // called out of order.
                if (! IsInitialized) {
                    throw new Exception("BuildSiteMap called incorrectly.");
                }

                // If there is no root node, then there is no site map.
                if (null == rootNode) {
                    // Start with a clean slate
                    Clear();

                    // Select the root node of the site map from Microsoft Access.
                    int rootNodeId = -1;

                    if (accessConnection.State == ConnectionState.Closed)
                        accessConnection.Open();
                    OleDbCommand rootNodeCommand =
                        new OleDbCommand("SELECT nodeid, url, name FROM SiteMap WHERE parentnodeid IS NULL",
                                         accessConnection);
                    OleDbDataReader rootNodeReader = rootNodeCommand.ExecuteReader();

                    if(rootNodeReader.HasRows) {
                        rootNodeReader.Read();
                        rootNodeId = rootNodeReader.GetInt32(0);
                        // Create a SiteMapNode that references the current StaticSiteMapProvider.
                        rootNode   = new SiteMapNode(this,
                                                     rootNodeId.ToString(),
                                                     rootNodeReader.GetString(1),
                                                     rootNodeReader.GetString(2));
                    }
                    else
                    {
                        return null;
                    }

                    rootNodeReader.Close();
                    // Select the child nodes of the root node.
                    OleDbCommand childNodesCommand =
                        new OleDbCommand("SELECT nodeid, url, name FROM SiteMap WHERE parentnodeid = ?",
                                         accessConnection);
                    OleDbParameter rootParam = new OleDbParameter("parentid", OleDbType.Integer);
                    rootParam.Value = rootNodeId;
                    childNodesCommand.Parameters.Add(rootParam);

                    OleDbDataReader childNodesReader = childNodesCommand.ExecuteReader();

                    if (childNodesReader.HasRows) {

                        SiteMapNode childNode = null;
                        while(childNodesReader.Read()) {
                            childNode =  new SiteMapNode(this,
                                                         childNodesReader.GetInt32(0).ToString(),
                                                         childNodesReader.GetString(1),
                                                         childNodesReader.GetString(2));

                            // Use the SiteMapNode AddNode method to add
                            // the SiteMapNode to the ChildNodes collection.
                            AddNode(childNode, rootNode);
                        }
                    }

                    childNodesReader.Close();
                    accessConnection.Close();
                }
                return rootNode;
            }
        }
    }
}
Imports System.Collections
Imports System.Collections.Specialized
Imports System.Data
Imports System.Data.OleDb
Imports System.Security.Permissions
Imports System.Web

Namespace Samples.AspNet.VB.Controls
 
    ' An extremely simple AccessSiteMapProvider that only supports a
    ' site map node hierarchy one level deep.
    <AspNetHostingPermission(SecurityAction.Demand, Level:=AspNetHostingPermissionLevel.Minimal)> _
    Public Class AccessSiteMapProvider
        Inherits StaticSiteMapProvider

        Private aRootNode As SiteMapNode = Nothing
        Private accessConnection As OleDbConnection = Nothing

        ' This string is case sensitive.
        Private AccessConnectionStringName As String = "accessSiteMapConnectionString"

        ' Implement a default constructor.
        Public Sub New()
        End Sub

        ' Some basic state to help track the initialization state of the provider.
        Private initialized As Boolean = False

        Public Overridable ReadOnly Property IsInitialized() As Boolean
            Get
                Return initialized
            End Get
        End Property

        ' Return the root node of the current site map.
        Public Overrides ReadOnly Property RootNode() As SiteMapNode
            Get
                Return BuildSiteMap()
            End Get
        End Property

        Protected Overrides Function GetRootNodeCore() As SiteMapNode
            Return RootNode
        End Function

        ' Initialize is used to initialize the properties and any state that the
        ' AccessProvider holds, but is not used to build the site map.
        ' The site map is built when the BuildSiteMap method is called.
        Public Overrides Sub Initialize(ByVal name As String, ByVal attributes As NameValueCollection)
            If IsInitialized Then
                Return
            End If
            MyBase.Initialize(name, attributes)

            ' Create and test the connection to the Microsoft Access database.
            ' Retrieve the Value of the Access connection string from the
            ' attributes NameValueCollection.
            Dim connectionString As String = attributes(AccessConnectionStringName)

            If Nothing = connectionString OrElse connectionString.Length = 0 Then
                Throw New Exception("The connection string was not found.")
            Else
                accessConnection = New OleDbConnection(connectionString)
            End If
            initialized = True
        End Sub

        ' SiteMapProvider and StaticSiteMapProvider methods that this derived class must override.
        '
        ' Clean up any collections or other state that an instance of this may hold.
        Protected Overrides Sub Clear()
            SyncLock Me
                aRootNode = Nothing
                MyBase.Clear()
            End SyncLock
        End Sub

        ' Build an in-memory representation from persistent
        ' storage, and return the root node of the site map.
        Public Overrides Function BuildSiteMap() As SiteMapNode

            ' Since the SiteMap class is static, make sure that it is
            ' not modified while the site map is built.
            SyncLock Me

                ' If there is no initialization, this method is being
                ' called out of order.
                If Not IsInitialized Then
                    Throw New Exception("BuildSiteMap called incorrectly.")
                End If

                ' If there is no root node, then there is no site map.
                If aRootNode Is Nothing Then
                    ' Start with a clean slate
                    Clear()

                    ' Select the root node of the site map from Microsoft Access.
                    Dim rootNodeId As Integer = -1

                    If accessConnection.State = ConnectionState.Closed Then
                        accessConnection.Open()
                    End If
                    Dim rootNodeCommand As New OleDbCommand("SELECT nodeid, url, name FROM SiteMap WHERE parentnodeid IS NULL", accessConnection)
                    Dim rootNodeReader As OleDbDataReader = rootNodeCommand.ExecuteReader()

                    If rootNodeReader.HasRows Then
                        rootNodeReader.Read()
                        rootNodeId = rootNodeReader.GetInt32(0)
                        ' Create a SiteMapNode that references the current StaticSiteMapProvider.
                        aRootNode = New SiteMapNode(Me, rootNodeId.ToString(), rootNodeReader.GetString(1), rootNodeReader.GetString(2))
                    Else
                        Return Nothing
                    End If
                    rootNodeReader.Close()
                    ' Select the child nodes of the root node.
                    Dim childNodesCommand As New OleDbCommand("SELECT nodeid, url, name FROM SiteMap WHERE parentnodeid = ?", accessConnection)
                    Dim rootParam As New OleDbParameter("parentid", OleDbType.Integer)
                    rootParam.Value = rootNodeId
                    childNodesCommand.Parameters.Add(rootParam)

                    Dim childNodesReader As OleDbDataReader = childNodesCommand.ExecuteReader()

                    If childNodesReader.HasRows Then

                        Dim childNode As SiteMapNode = Nothing
                        While childNodesReader.Read()
                            childNode = New SiteMapNode(Me, _
                            childNodesReader.GetInt32(0).ToString(), _
                            childNodesReader.GetString(1), _
                            childNodesReader.GetString(2))

                            ' Use the SiteMapNode AddNode method to add
                            ' the SiteMapNode to the ChildNodes collection.
                            AddNode(childNode, aRootNode)
                        End While
                    End If

                    childNodesReader.Close()
                    accessConnection.Close()
                End If
                Return aRootNode
            End SyncLock

        End Function 'BuildSiteMap

    End Class

End Namespace

Finally, the AccessSiteMapProvider is configured as the default provider in the following Web.config file.

<configuration>  
  <system.web>  
    <siteMap defaultProvider="AccessSiteMapProvider">  
     <providers>  
       <add   
         name="AccessSiteMapProvider"  
         type="Samples.AspNet.AccessSiteMapProvider,Samples.AspNet "  
         accessSiteMapConnectionString="PROVIDER=MICROSOFT.JET.OLEDB.4.0;DATA SOURCE=sitemap.mdb "/>  
     </providers>   
    </siteMap>  
  </system.web>  
</configuration>  

Remarks

The StaticSiteMapProvider class is a partial implementation of the abstract SiteMapProvider class and supplies two additional methods: AddNode and RemoveNode, as well as the abstract BuildSiteMap and protected Clear methods.

The StaticSiteMapProvider class supports writing a site map provider (for example, an XmlSiteMapProvider) that translates a site map that is stored in persistent storage to one that is stored in memory. The StaticSiteMapProvider class provides basic implementations for storing and retrieving SiteMapNode objects.

The SiteMapProvider and StaticSiteMapProvider classes support the concept of a site map provider hierarchy, where a site map provider can have a hierarchical relationship with other site map providers. This pattern is implemented with the RootProvider and ParentProvider properties.

The StaticSiteMapProvider class stores its SiteMapNode objects in hash tables and internally uses the SiteMapNode.Url property of the pages, represented by site map nodes, as keys. (If a site map node does not specify a URL, it is tracked using an automatically generated unique key.) As a result, you cannot have site map nodes wherein a site map node with the same URL is used more than once. For example, attempting to load the site map node illustrated in the following code example with the XmlSiteMapProvider class, which is the default ASP.NET site map provider, or any site map provider that is derived from the StaticSiteMapProvider class will not work because the AboutUs.aspx page is used more than once.

<sitemap>  
  <sitemapnode title="Home" description="Home" url="default.aspx" >  
    <sitemapnode title="Catalog" description="Our catalog" url="catalog.aspx"/>  
    <sitemapnode title="About Us" description="All about our company" url="aboutus.aspx"/>  
    <sitemapnode title="Driving Directions" description="Directions to our store" url="aboutus.aspx"/>  
  </sitemapnode>  
</sitemap>  

If you are extending the StaticSiteMapProvider class, the three most important methods are the GetRootNodeCore, Initialize, and BuildSiteMap methods. The Clear and FindSiteMapNode methods have default implementations that are sufficient for most custom site map provider implementations.

The Initialize method is called to initialize derived site map providers, including any resources that are required to load site map data, but it does attempt to build the site map node in memory. If your derived class is using files to store site map data, any file initialization can be performed here. If the site map node uses some other type of data store, such as a relational database, initializing a connection might be performed here. Additional attributes, such as file names or connection strings that are placed on the site map provider element in the configuration are processed by the ASP.NET configuration system and passed to the Initialize method with the attributes parameter.

The BuildSiteMap method must be overridden by all classes that are derived from the StaticSiteMapProvider class and is called to load the site map node from persistent storage and convert it to an internal representation. The BuildSiteMap method is called internally in many of the default member implementations of the StaticSiteMapProvider and XmlSiteMapProvider classes. If you implement your own site map provider, ensure that site map data processing occurs once and subsequent calls to the BuildSiteMap method return immediately, if site map information has already been loaded. When you implement the BuildSiteMap method, ensure it is thread safe, as multiple concurrent page requests can result indirectly in multiple calls to load site map information. The site map infrastructure supports displaying site map information based on the user's role. Depending on the Roles property that are supported by the individual SiteMapNode objects, a different navigation structure can exist for different users. The default implementations of the site map node retrieval members of the StaticSiteMapProvider class perform security trimming automatically by calling the IsAccessibleToUser method.

The AddNode, Clear and RemoveNode methods manipulate the internal collections that are used to track site map nodes in a thread-safe manner.

Notes to Implementers

When you inherit from the StaticSiteMapProvider class, you must override the following member: BuildSiteMap().

Constructors

StaticSiteMapProvider()

Initializes a new instance of the StaticSiteMapProvider class.

Properties

CurrentNode

Gets the SiteMapNode object that represents the currently requested page.

(Inherited from SiteMapProvider)
Description

Gets a brief, friendly description suitable for display in administrative tools or other user interfaces (UIs).

(Inherited from ProviderBase)
EnableLocalization

Gets or sets a Boolean value indicating whether localized values of SiteMapNode attributes are returned.

(Inherited from SiteMapProvider)
Name

Gets the friendly name used to refer to the provider during configuration.

(Inherited from ProviderBase)
ParentProvider

Gets or sets the parent SiteMapProvider object of the current provider.

(Inherited from SiteMapProvider)
ResourceKey

Get or sets the resource key that is used for localizing SiteMapNode attributes.

(Inherited from SiteMapProvider)
RootNode

Gets the root SiteMapNode object of the site map data that the current provider represents.

(Inherited from SiteMapProvider)
RootProvider

Gets the root SiteMapProvider object in the current provider hierarchy.

(Inherited from SiteMapProvider)
SecurityTrimmingEnabled

Gets a Boolean value indicating whether a site map provider filters site map nodes based on a user's role.

(Inherited from SiteMapProvider)

Methods

AddNode(SiteMapNode, SiteMapNode)

Adds a SiteMapNode to the collections that are maintained by the site map provider and establishes a parent/child relationship between the SiteMapNode objects.

AddNode(SiteMapNode)

Adds a SiteMapNode object to the node collection that is maintained by the site map provider.

(Inherited from SiteMapProvider)
BuildSiteMap()

When overridden in a derived class, loads the site map information from persistent storage and builds it in memory.

Clear()

Removes all elements in the collections of child and parent site map nodes that the StaticSiteMapProvider tracks as part of its state.

Equals(Object)

Determines whether the specified object is equal to the current object.

(Inherited from Object)
FindSiteMapNode(HttpContext)

Retrieves a SiteMapNode object that represents the currently requested page using the specified HttpContext object.

(Inherited from SiteMapProvider)
FindSiteMapNode(String)

Retrieves a SiteMapNode object that represents the page at the specified URL.

FindSiteMapNodeFromKey(String)

Retrieves a SiteMapNode object based on a specified key.

GetChildNodes(SiteMapNode)

Retrieves the child site map nodes of a specific SiteMapNode object.

GetCurrentNodeAndHintAncestorNodes(Int32)

Provides an optimized lookup method for site map providers when retrieving the node for the currently requested page and fetching the parent and ancestor site map nodes for the current page.

(Inherited from SiteMapProvider)
GetCurrentNodeAndHintNeighborhoodNodes(Int32, Int32)

Provides an optimized lookup method for site map providers when retrieving the node for the currently requested page and fetching the site map nodes in the proximity of the current node.

(Inherited from SiteMapProvider)
GetHashCode()

Serves as the default hash function.

(Inherited from Object)
GetParentNode(SiteMapNode)

Retrieves the parent site map node of a specific SiteMapNode object.

GetParentNodeRelativeToCurrentNodeAndHintDownFromParent(Int32, Int32)

Provides an optimized lookup method for site map providers when retrieving an ancestor node for the currently requested page and fetching the descendant nodes for the ancestor.

(Inherited from SiteMapProvider)
GetParentNodeRelativeToNodeAndHintDownFromParent(SiteMapNode, Int32, Int32)

Provides an optimized lookup method for site map providers when retrieving an ancestor node for the specified SiteMapNode object and fetching its child nodes.

(Inherited from SiteMapProvider)
GetRootNodeCore()

When overridden in a derived class, retrieves the root node of all the nodes that are currently managed by the current provider.

(Inherited from SiteMapProvider)
GetType()

Gets the Type of the current instance.

(Inherited from Object)
HintAncestorNodes(SiteMapNode, Int32)

Provides a method that site map providers can override to perform an optimized retrieval of one or more levels of parent and ancestor nodes, relative to the specified SiteMapNode object.

(Inherited from SiteMapProvider)
HintNeighborhoodNodes(SiteMapNode, Int32, Int32)

Provides a method that site map providers can override to perform an optimized retrieval of nodes found in the proximity of the specified node.

(Inherited from SiteMapProvider)
Initialize(String, NameValueCollection)

Initializes the SiteMapProvider implementation, including any resources that are needed to load site map data from persistent storage.

(Inherited from SiteMapProvider)
IsAccessibleToUser(HttpContext, SiteMapNode)

Retrieves a Boolean value indicating whether the specified SiteMapNode object can be viewed by the user in the specified context.

(Inherited from SiteMapProvider)
MemberwiseClone()

Creates a shallow copy of the current Object.

(Inherited from Object)
RemoveNode(SiteMapNode)

Removes the specified SiteMapNode object from all site map node collections that are tracked by the site map provider.

ResolveSiteMapNode(HttpContext)

Raises the SiteMapResolve event.

(Inherited from SiteMapProvider)
ToString()

Returns a string that represents the current object.

(Inherited from Object)

Events

SiteMapResolve

Occurs when the CurrentNode property is called.

(Inherited from SiteMapProvider)

Applies to

See also