Click or drag to resize

VirtualFileBaseCollection Class

A strongly typed KeyedCollectionTKey, TItem where each element is a VirtualFileBase and is keyed off of the VirtualPath property.
Inheritance Hierarchy

Namespace: GSF.Web.Hosting
Assembly: GSF.Web (in GSF.Web.dll) Version: 2.4.218-beta
Syntax
public class VirtualFileBaseCollection : KeyedCollection<string, VirtualFileBase>
View Source

The VirtualFileBaseCollection type exposes the following members.

Constructors
 NameDescription
Public methodVirtualFileBaseCollection Initializes a new instance of the VirtualFileBaseCollection class that uses a case-insensitive comparer.
Public methodVirtualFileBaseCollection(IEqualityComparerString) Initializes a new instance of the VirtualFileBaseCollection class that uses the specified equality comparer.
Public methodVirtualFileBaseCollection(IEqualityComparerString, Int32) Initializes a new instance of the VirtualFileBaseCollection class that uses the specified equality comparer.
Top
Properties
 NameDescription
Public propertyComparerGets the generic equality comparer that is used to determine equality of keys in the collection.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public propertyCountGets the number of elements actually contained in the CollectionT.
(Inherited from CollectionVirtualFileBase)
Protected propertyDictionaryGets the lookup dictionary of the KeyedCollectionTKey, TItem.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public propertyItemInt32Gets or sets the element at the specified index.
(Inherited from CollectionVirtualFileBase)
Public propertyItemTKeyGets the element with the specified key.
(Inherited from KeyedCollectionString, VirtualFileBase)
Protected propertyItemsGets a IListT wrapper around the CollectionT.
(Inherited from CollectionVirtualFileBase)
Top
Methods
 NameDescription
Public methodAddAdds an object to the end of the CollectionT.
(Inherited from CollectionVirtualFileBase)
Protected methodChangeItemKeyChanges the key associated with the specified element in the lookup dictionary.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public methodClearRemoves all elements from the CollectionT.
(Inherited from CollectionVirtualFileBase)
Protected methodClearItemsRemoves all elements from the KeyedCollectionTKey, TItem.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public methodContains(TKey)Determines whether the collection contains an element with the specified key.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public methodContains(T)Determines whether an element is in the CollectionT.
(Inherited from CollectionVirtualFileBase)
Public methodCopyToCopies the entire CollectionT to a compatible one-dimensional Array, starting at the specified index of the target array.
(Inherited from CollectionVirtualFileBase)
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodGetEnumeratorReturns an enumerator that iterates through the CollectionT.
(Inherited from CollectionVirtualFileBase)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Protected methodGetKeyForItem Extracts the key from the specified element.
(Overrides KeyedCollectionTKey, TItemGetKeyForItem(TItem))
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Public methodIndexOfSearches for the specified object and returns the zero-based index of the first occurrence within the entire CollectionT.
(Inherited from CollectionVirtualFileBase)
Public methodInsertInserts an element into the CollectionT at the specified index.
(Inherited from CollectionVirtualFileBase)
Protected methodInsertItemInserts an element into the KeyedCollectionTKey, TItem at the specified index.
(Inherited from KeyedCollectionString, VirtualFileBase)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodRemove(TKey)Removes the element with the specified key from the KeyedCollectionTKey, TItem.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public methodRemove(T)Removes the first occurrence of a specific object from the CollectionT.
(Inherited from CollectionVirtualFileBase)
Public methodRemoveAtRemoves the element at the specified index of the CollectionT.
(Inherited from CollectionVirtualFileBase)
Protected methodRemoveItemRemoves the element at the specified index of the KeyedCollectionTKey, TItem.
(Inherited from KeyedCollectionString, VirtualFileBase)
Protected methodSetItemReplaces the item at the specified index with the specified item.
(Inherited from KeyedCollectionString, VirtualFileBase)
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Extension Methods
 NameDescription
Public Extension MethodGetEnumValueOrDefault Gets the enumeration constant for value, if defined in the enumeration, or a default value.
(Defined by EnumExtensions)
Public Extension MethodGetEnumValueOrDefaultT Gets the enumeration constant for this value, if defined in the enumeration, or a default value.
(Defined by EnumExtensions)
Top
Remarks

The default constructor for this collection does a culture-invariant case-insensitive comparison on the keys. This allows for proper case-insensitive web-oriented behavior that is generally expected.

See Also