StaticSiteMapProvider クラス

定義

SiteMapProvider 抽象クラスの部分実装として機能します。また、ASP.NET の既定のサイト マップ プロバイダーである XmlSiteMapProvider クラスの基本クラスとして機能します。

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
継承
StaticSiteMapProvider
派生

次のコード例では、Microsoft Access をサイト マップ プロバイダーとして使用するように クラスを拡張 StaticSiteMapProvider する方法を示します。 クラスは AccessSiteMapProvider 、単純な 1 レベルの深い階層のみをサポートするサイト マップ プロバイダーです。 サイト マップ データが格納されているテーブルの構造は次のとおりです。

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

クラスは AccessSiteMapProvider クラスからStaticSiteMapProvider派生し、基本的な SQL クエリと オブジェクトと OleDbDataReader オブジェクトを使用して、Microsoft Access データベースからその情報をOleDbCommand取得します。

#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

最後に、 AccessSiteMapProvider は、次のWeb.config ファイルの既定のプロバイダーとして構成されます。

<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>  

注釈

クラスは StaticSiteMapProvider 抽象 SiteMapProvider クラスの部分的な実装であり、2 つの追加メソッド AddNodeRemoveNode、抽象 BuildSiteMap メソッドと保護された Clear メソッドを提供します。

クラスは StaticSiteMapProvider 、永続ストレージに格納されているサイト マップを XmlSiteMapProviderメモリに格納されているサイト マップに変換するサイト マップ プロバイダー (例: ) の作成をサポートします。 クラスは StaticSiteMapProvider 、オブジェクトを格納および取得するための基本的な実装を SiteMapNode 提供します。

クラスと StaticSiteMapProvider クラスではSiteMapProvider、サイト マップ プロバイダー階層の概念がサポートされています。サイト マップ プロバイダーは、他のサイト マップ プロバイダーと階層的な関係を持つことができます。 このパターンは、 プロパティと ParentProvider プロパティを使用してRootProvider実装されます。

クラスは StaticSiteMapProvider 、そのオブジェクトを SiteMapNode ハッシュ テーブルに格納し、サイト マップ ノードによって表されるページの プロパティをキーとして内部的に使用 SiteMapNode.Url します。 (サイト マップ ノードで URL が指定されていない場合は、自動的に生成された一意キーを使用して追跡されます)。その結果、同じ URL を持つサイト マップ ノードが複数回使用されるサイト マップ ノードを持つことはできません。 たとえば、次のコード例に示すサイト マップ ノードをクラスと共に読み込もうと XmlSiteMapProvider すると、既定の ASP.NET サイト マップ プロバイダーであるか、AboutUs.aspx ページが複数回使用されるため、クラスから StaticSiteMapProvider 派生したサイト マップ プロバイダーは機能しません。

<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>  

クラスを拡張するStaticSiteMapProvider場合、最も重要な 3 つのメソッドは、GetRootNodeCoreInitializeおよび BuildSiteMap メソッドです。 Clearメソッドと FindSiteMapNode メソッドには、ほとんどのカスタム サイト マップ プロバイダーの実装に十分な既定の実装があります。

メソッドは Initialize 、サイト マップ データの読み込みに必要なすべてのリソースを含む、派生サイト マップ プロバイダーを初期化するために呼び出されますが、メモリ内にサイト マップ ノードを構築しようとします。 派生クラスがファイルを使用してサイト マップ データを格納している場合は、ここでファイルの初期化を実行できます。 サイト マップ ノードでリレーショナル データベースなどの他の種類のデータ ストアを使用している場合は、ここで接続の初期化が実行される可能性があります。 構成内のサイト マップ プロバイダー要素に配置されるファイル名や接続文字列などの追加の属性は、ASP.NET 構成システムによって処理され、 パラメーターを使用attributesして メソッドにInitialize渡されます。

メソッドは BuildSiteMap 、 クラスから StaticSiteMapProvider 派生したすべてのクラスによってオーバーライドする必要があり、永続的ストレージからサイト マップ ノードを読み込み、内部表現に変換するために呼び出されます。 メソッドはBuildSiteMap、 クラスと XmlSiteMapProvider クラスの既定のメンバー実装の多くで内部的にStaticSiteMapProvider呼び出されます。 独自のサイト マップ プロバイダーを実装する場合は、サイト マップのデータ処理が 1 回行われ、サイト マップ情報が既に読み込まれている場合は、 メソッドの BuildSiteMap 後続の呼び出しが直ちに返されるようにします。 メソッドを実装するときは、複数の BuildSiteMap 同時ページ要求によってサイト マップ情報を読み込むための複数の呼び出しが間接的に発生する可能性があるため、スレッド セーフであることを確認します。 サイト マップ インフラストラクチャでは、ユーザーの役割に基づくサイト マップ情報の表示がサポートされています。 個々SiteMapNodeRolesオブジェクトでサポートされているプロパティによっては、ユーザーごとに異なるナビゲーション構造が存在する可能性があります。 クラスのサイト マップ ノード取得メンバーの既定の実装では、 メソッドを StaticSiteMapProvider 呼び出してセキュリティ トリミングが IsAccessibleToUser 自動的に実行されます。

Clearメソッド、および RemoveNode メソッドはAddNode、スレッド セーフな方法でサイト マップ ノードを追跡するために使用される内部コレクションを操作します。

注意 (実装者)

クラスから継承する場合は、次のStaticSiteMapProviderメンバーをオーバーライドする必要があります。 BuildSiteMap()

コンストラクター

StaticSiteMapProvider()

StaticSiteMapProvider クラスの新しいインスタンスを初期化します。

プロパティ

CurrentNode

現在要求されているページを表す SiteMapNode オブジェクトを取得します。

(継承元 SiteMapProvider)
Description

管理ツールまたは他のユーザー インターフェイス (UI) での表示に適した、簡単でわかりやすい説明を取得します。

(継承元 ProviderBase)
EnableLocalization

SiteMapNode 属性のローカライズされた値が返されるかどうかを示すブール値を取得または設定します。

(継承元 SiteMapProvider)
Name

構成時にプロバイダーを参照するために使用される表示名を取得します。

(継承元 ProviderBase)
ParentProvider

現在のプロバイダーの親 SiteMapProvider オブジェクトを取得または設定します。

(継承元 SiteMapProvider)
ResourceKey

SiteMapNode 属性のローカライズに使用するリソース キーを取得または設定します。

(継承元 SiteMapProvider)
RootNode

現在のプロバイダーが示すサイト マップ データのルート SiteMapNode オブジェクトを取得します。

(継承元 SiteMapProvider)
RootProvider

現在のプロバイダー階層のルート SiteMapProvider オブジェクトを取得します。

(継承元 SiteMapProvider)
SecurityTrimmingEnabled

サイト マップ プロバイダーがユーザーのロールに基づいてサイト マップ ノードをフィルター処理するかどうかを示すブール値を取得します。

(継承元 SiteMapProvider)

メソッド

AddNode(SiteMapNode)

サイト マップ プロバイダーが管理するノード コレクションに SiteMapNode オブジェクトを追加します。

(継承元 SiteMapProvider)
AddNode(SiteMapNode, SiteMapNode)

SiteMapNode を、サイト マップ プロバイダーが管理するコレクションに追加し、SiteMapNode オブジェクト間の親子関係を確立します。

BuildSiteMap()

派生クラスでオーバーライドされた場合は、サイト マップ情報を永続ストレージから読み込み、メモリ内で構築します。

Clear()

StaticSiteMapProvider が状態の一部として追跡する子および親サイト マップ ノードのコレクションに含まれているすべての要素を削除します。

Equals(Object)

指定されたオブジェクトが現在のオブジェクトと等しいかどうかを判断します。

(継承元 Object)
FindSiteMapNode(HttpContext)

現在要求されているページを表す SiteMapNode オブジェクトを、指定した HttpContext オブジェクトを使用して取得します。

(継承元 SiteMapProvider)
FindSiteMapNode(String)

指定した URL のページを表す SiteMapNode オブジェクトを取得します。

FindSiteMapNodeFromKey(String)

指定したキーに基づいて SiteMapNode オブジェクトを取得します。

GetChildNodes(SiteMapNode)

特定の SiteMapNode オブジェクトの子サイト マップ ノードを取得します。

GetCurrentNodeAndHintAncestorNodes(Int32)

現在要求されているページのノードを取得し、現在のページの親および先祖のサイト マップ ノードをフェッチする際、サイト マップ プロバイダーに最適化された検索メソッドを提供します。

(継承元 SiteMapProvider)
GetCurrentNodeAndHintNeighborhoodNodes(Int32, Int32)

現在要求されているページのノードを検索し、現在のノードの近くのサイト マップ ノードをフェッチする際、サイト マップ プロバイダーに最適化された検索メソッドを提供します。

(継承元 SiteMapProvider)
GetHashCode()

既定のハッシュ関数として機能します。

(継承元 Object)
GetParentNode(SiteMapNode)

特定の SiteMapNode オブジェクトの親サイト マップ ノードを取得します。

GetParentNodeRelativeToCurrentNodeAndHintDownFromParent(Int32, Int32)

現在要求されているページの先祖ノードを取得し、その先祖の子孫ノードをフェッチする際、サイト マップ プロバイダーに最適化された検索メソッドを提供します。

(継承元 SiteMapProvider)
GetParentNodeRelativeToNodeAndHintDownFromParent(SiteMapNode, Int32, Int32)

指定した SiteMapNode オブジェクトの先祖ノードを取得して、その子ノードをフェッチする際に、サイト マップ プロバイダーに最適化された検索メソッドを提供します。

(継承元 SiteMapProvider)
GetRootNodeCore()

派生クラスでオーバーライドされた場合は、現在のプロバイダーによって現在管理されている全ノードのルート ノードを取得します。

(継承元 SiteMapProvider)
GetType()

現在のインスタンスの Type を取得します。

(継承元 Object)
HintAncestorNodes(SiteMapNode, Int32)

サイト マップ プロバイダーがオーバーライドして、指定した SiteMapNode オブジェクトの相対として 1 つ以上のレベルの親ノードと先祖ノードの最適化された取得を実行できるメソッドを提供します。

(継承元 SiteMapProvider)
HintNeighborhoodNodes(SiteMapNode, Int32, Int32)

サイト マップ プロバイダーがオーバーライドして、指定したノードの近くで見つかったノードの最適化された取得を実行できるメソッドを提供します。

(継承元 SiteMapProvider)
Initialize(String, NameValueCollection)

SiteMapProvider 実装を初期化します。対象には、サイト マップ データを永続ストレージから読み込むために必要なリソースがすべて含まれます。

(継承元 SiteMapProvider)
IsAccessibleToUser(HttpContext, SiteMapNode)

指定した SiteMapNode オブジェクトを、指定したコンテキストでユーザーが表示できるかどうかを示すブール値を取得します。

(継承元 SiteMapProvider)
MemberwiseClone()

現在の Object の簡易コピーを作成します。

(継承元 Object)
RemoveNode(SiteMapNode)

指定された SiteMapNode オブジェクトを、サイト マップ プロバイダーによる追跡対象のすべてのサイト マップ ノード コレクションから削除します。

ResolveSiteMapNode(HttpContext)

SiteMapResolve イベントを発生させます。

(継承元 SiteMapProvider)
ToString()

現在のオブジェクトを表す文字列を返します。

(継承元 Object)

イベント

SiteMapResolve

CurrentNode プロパティが呼び出されると発生します。

(継承元 SiteMapProvider)

適用対象

こちらもご覧ください