StateBag Methods

StateBag Methods

The StateBag type exposes the following members.

  NameDescription
Public method Add Adds a new StateItem object to the StateBag object. If the item already exists in the StateBag object, this method updates the value of the item.
Public method Clear Removes all items from the current StateBag object.
Public method Equals Determines whether the specified Object is equal to the current Object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetEnumerator Returns an enumerator that iterates over all the key/value pairs of the StateItem objects stored in the StateBag object.
Public method GetHashCode Serves as a hash function for a particular type. (Inherited from Object.)
Public method GetType Gets the type of the current instance. (Inherited from Object.)
Public method IsItemDirty Checks a StateItem object stored in the StateBag object to evaluate whether it has been modified since the call to Control.TrackViewState.
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method Remove Removes the specified key/value pair from the StateBag object.
Public method SetDirty Sets the state of the StateBag object as well as the Dirty property of each of the StateItem objects contained by it.
Public method SetItemDirty Sets the Dirty property for the specified StateItem object in the StateBag object.
Public method ToString Returns a string that represents the current object. (Inherited from Object.)
Top

  NameDescription
Public Extension Method AsQueryable Converts an IEnumerable to an IQueryable. (Defined by Queryable.)
Public Extension Method Cast Converts the elements of an IEnumerable to the specified type. (Defined by Enumerable.)
Public Extension Method OfType Filters the elements of an IEnumerable based on a specified type. (Defined by Enumerable.)
Top

  NameDescription
Explicit interface implemetation Private method IDictionary.Add For a description of this member, see IDictionary.Add.
Explicit interface implemetation Private method IDictionary.Contains For a description of this member, see IDictionary.Contains.
Explicit interface implemetation Private method ICollection.CopyTo For a description of this member, see ICollection.CopyTo.
Explicit interface implemetation Private method IEnumerable.GetEnumerator For a description of this member, see IEnumerable.GetEnumerator.
Explicit interface implemetation Private method IStateManager.LoadViewState Restores the previously saved view state of the StateBag object.
Explicit interface implemetation Private method IDictionary.Remove For a description of this member, see Remove.
Explicit interface implemetation Private method IStateManager.SaveViewState Saves the changes to the StateBag object since the time the page was posted back to the server.
Explicit interface implemetation Private method IStateManager.TrackViewState Causes the StateBag object to track changes to its state so that it can be persisted across requests.
Top

Community Additions

ADD
Show:
© 2016 Microsoft