New to Telerik UI for ASP.NET MVC? Start a free 30-day trial

Definition

Namespace:Kendo.Mvc

Assembly:Kendo.Mvc.dll

Syntax:

C#
public class SiteMapDictionary : IDictionary<string, SiteMapBase>, ICollection<KeyValuePair<string, SiteMapBase>>, IEnumerable<KeyValuePair<string, SiteMapBase>>, IEnumerable

Inheritance: objectSiteMapDictionary

Implements: ICollection<KeyValuePair<string, SiteMapBase>>IDictionary<string, SiteMapBase>IEnumerableIEnumerable<KeyValuePair<string, SiteMapBase>>

Inherited Members object.GetType()object.MemberwiseClone()object.ToString()object.Equals(object)object.Equals(object, object)object.ReferenceEquals(object, object)object.GetHashCode()...

Constructors

C#
public SiteMapDictionary()

Properties

Gets the number of elements contained in the ICollection<T>.

C#
public int Count { get; }

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.Count

Gets or sets the default site map.

C#
public SiteMapBase DefaultSiteMap { get; set; }
Property Value:

The default site map.

Gets or sets the default site map factory.

C#
public static Func<SiteMapBase> DefaultSiteMapFactory { get; set; }
Property Value:

The default site map factory.

Gets a value indicating whether the ICollection<T> is read-only.

C#
public bool IsReadOnly { get; }

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.IsReadOnly

Gets an ICollection<T> containing the keys of the IDictionary<TKey, TValue>.

C#
public ICollection<string> Keys { get; }

Implements: IDictionary<string, SiteMapBase>.Keys

Gets or sets the SiteMapBase with the specified key.

C#
public SiteMapBase this[string key] { get; set; }
Parameters:keystring

Implements: IDictionary<string, SiteMapBase>.this[string]

Gets an ICollection<T> containing the values in the IDictionary<TKey, TValue>.

C#
public ICollection<SiteMapBase> Values { get; }

Implements: IDictionary<string, SiteMapBase>.Values

Methods

Adds an item to the ICollection<T>.

C#
public void Add(KeyValuePair<string, SiteMapBase> item)
Parameters:itemKeyValuePair<string, SiteMapBase>

The object to add to the ICollection<T>.

Exceptions: NotSupportedException

The ICollection<T> is read-only.

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.Add(KeyValuePair<string, SiteMapBase>)

Adds an element with the provided key and value to the IDictionary<TKey, TValue>.

C#
public void Add(string key, SiteMapBase value)
Parameters:keystring

The object to use as the key of the element to add.

valueSiteMapBase

The object to use as the value of the element to add.

Exceptions: ArgumentNullException

key is null.

ArgumentException

An element with the same key already exists in the IDictionary<TKey, TValue>.

NotSupportedException

The IDictionary<TKey, TValue> is read-only.

Implements: IDictionary<string, SiteMapBase>.Add(string, SiteMapBase)

Removes all items from the ICollection<T>.

C#
public void Clear()
Exceptions: NotSupportedException

The ICollection<T> is read-only.

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.Clear()

Determines whether the ICollection<T> contains a specific value.

C#
public bool Contains(KeyValuePair<string, SiteMapBase> item)
Parameters:itemKeyValuePair<string, SiteMapBase>

The object to locate in the ICollection<T>.

Returns:

bool

true if item is found in the ICollection<T>; otherwise, false.

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.Contains(KeyValuePair<string, SiteMapBase>)

Determines whether the IDictionary<TKey, TValue> contains an element with the specified key.

C#
public bool ContainsKey(string key)
Parameters:keystring

The key to locate in the IDictionary<TKey, TValue>.

Returns:

bool

true if the IDictionary<TKey, TValue> contains an element with the key; otherwise, false.

Exceptions: ArgumentNullException

key is null.

Implements: IDictionary<string, SiteMapBase>.ContainsKey(string)

Copies the elements of the ICollection<T> to an Array, starting at a particular Array index.

C#
public void CopyTo(KeyValuePair<string, SiteMapBase>[] array, int arrayIndex)
Parameters:arrayKeyValuePair<string, SiteMapBase>[]

The one-dimensional Array that is the destination of the elements copied from ICollection<T>. The Array must have zero-based indexing.

arrayIndexint

The zero-based index in array at which copying begins.

Exceptions: ArgumentNullException

array is null.

ArgumentOutOfRangeException

arrayIndex is less than 0.

ArgumentException

array is multidimensional. -or- arrayIndex is equal to or greater than the length of array. -or- The number of elements in the source ICollection<T> is greater than the available space from arrayIndex to the end of the destination array. -or- Type cannot be cast automatically to the type of the destination array

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.CopyTo(KeyValuePair<string, SiteMapBase>[], int)

Returns an enumerator that iterates through the collection.

C#
public IEnumerator<KeyValuePair<string, SiteMapBase>> GetEnumerator()
Returns:

IEnumerator<KeyValuePair<string, SiteMapBase>>

A IEnumerator<T> that can be used to iterate through the collection.

Implements: IEnumerable<KeyValuePair<string, SiteMapBase>>.GetEnumerator()

Registers the specified name.

C#
public SiteMapDictionary Register<TSiteMap>(string name, Action<TSiteMap> configure) where TSiteMap : SiteMapBase, new()
Parameters:namestring

The name.

configureAction<TSiteMap>

The configure.

Returns:

SiteMapDictionary

Removes the first occurrence of a specific object from the ICollection<T>.

C#
public bool Remove(KeyValuePair<string, SiteMapBase> item)
Parameters:itemKeyValuePair<string, SiteMapBase>

The object to remove from the ICollection<T>.

Returns:

bool

true if item was successfully removed from the ICollection<T>; otherwise, false. This method also returns false if item is not found in the original ICollection<T>.

Exceptions: NotSupportedException

The ICollection<T> is read-only.

Implements: ICollection<KeyValuePair<string, SiteMapBase>>.Remove(KeyValuePair<string, SiteMapBase>)

Removes the element with the specified key from the IDictionary<TKey, TValue>.

C#
public bool Remove(string key)
Parameters:keystring

The key of the element to remove.

Returns:

bool

true if the element is successfully removed; otherwise, false. This method also returns false if key was not found in the original IDictionary<TKey, TValue>.

Exceptions: ArgumentNullException

key is null.

NotSupportedException

The IDictionary<TKey, TValue> is read-only.

Implements: IDictionary<string, SiteMapBase>.Remove(string)

Gets the value associated with the specified key.

C#
public bool TryGetValue(string key, out SiteMapBase value)
Parameters:keystring

The key whose value to get.

valueSiteMapBase

When this method returns, the value associated with the specified key, if the key is found; otherwise, the default value for the type of the value parameter. This parameter is passed uninitialized.

Returns:

bool

true if the object that implements IDictionary<TKey, TValue> contains an element with the specified key; otherwise, false.

Exceptions: ArgumentNullException

key is null.

Implements: IDictionary<string, SiteMapBase>.TryGetValue(string, out SiteMapBase)