Delen via


RouteData.PushState Method

Definition

Creates a snapshot of the current state of the RouteData before appending router to Routers, merging values into Values, and merging dataTokens into DataTokens.

Call Restore() to restore the state of this RouteData to the state at the time of calling PushState(IRouter, RouteValueDictionary, RouteValueDictionary).

public:
 Microsoft::AspNetCore::Routing::RouteData::RouteDataSnapshot PushState(Microsoft::AspNetCore::Routing::IRouter ^ router, Microsoft::AspNetCore::Routing::RouteValueDictionary ^ values, Microsoft::AspNetCore::Routing::RouteValueDictionary ^ dataTokens);
public Microsoft.AspNetCore.Routing.RouteData.RouteDataSnapshot PushState (Microsoft.AspNetCore.Routing.IRouter router, Microsoft.AspNetCore.Routing.RouteValueDictionary values, Microsoft.AspNetCore.Routing.RouteValueDictionary dataTokens);
public Microsoft.AspNetCore.Routing.RouteData.RouteDataSnapshot PushState (Microsoft.AspNetCore.Routing.IRouter? router, Microsoft.AspNetCore.Routing.RouteValueDictionary? values, Microsoft.AspNetCore.Routing.RouteValueDictionary? dataTokens);
member this.PushState : Microsoft.AspNetCore.Routing.IRouter * Microsoft.AspNetCore.Routing.RouteValueDictionary * Microsoft.AspNetCore.Routing.RouteValueDictionary -> Microsoft.AspNetCore.Routing.RouteData.RouteDataSnapshot
Public Function PushState (router As IRouter, values As RouteValueDictionary, dataTokens As RouteValueDictionary) As RouteData.RouteDataSnapshot

Parameters

router
IRouter

An IRouter to append to Routers. If null, then Routers will not be changed.

values
RouteValueDictionary

A RouteValueDictionary to merge into Values. If null, then Values will not be changed.

dataTokens
RouteValueDictionary

A RouteValueDictionary to merge into DataTokens. If null, then DataTokens will not be changed.

Returns

A RouteData.RouteDataSnapshot that captures the current state.

Applies to