/// <summary>
        /// Sets the route name and route values of <see cref="INavigatable"/> object.
        /// </summary>
        /// <param name="navigatable">The <see cref="INavigatable"/> object.</param>
        /// <param name="routeName">Route name.</param>
        /// <param name="routeValues">Route values as <see cref="RouteValueDictionary"/>.</param>
        public static void Route(this INavigatable navigatable, string routeName, RouteValueDictionary routeValues)
        {
            Guard.IsNotNullOrEmpty(routeName, "routeName");

            navigatable.RouteName = routeName;
            navigatable.SetRouteValues(routeValues);
        }
 public static void Action(this INavigatable navigatable, string actionName, string controllerName, object routeValues)
 {
     navigatable.ControllerName = controllerName;
     navigatable.ActionName     = actionName;
     navigatable.SetRouteValues(routeValues);
 }
 private static void SetAction(INavigatable navigatable, string actionName, string controllerName, RouteValueDictionary routeValues)
 {
     navigatable.ActionName     = actionName;
     navigatable.ControllerName = controllerName;
     navigatable.SetRouteValues((IDictionary <string, object>)routeValues);
 }
 public static void Route(this INavigatable navigatable, string routeName, RouteValueDictionary routeValues)
 {
     navigatable.RouteName = routeName;
     navigatable.SetRouteValues((IDictionary <string, object>)routeValues);
 }
 public static void Route(this INavigatable navigatable, string routeName, object routeValues)
 {
     navigatable.RouteName = routeName;
     navigatable.SetRouteValues(routeValues);
 }
 private static void SetAction(INavigatable navigatable, string actionName, string controllerName, RouteValueDictionary routeValues)
 {
     navigatable.ActionName = actionName;
     navigatable.ControllerName = controllerName;
     navigatable.SetRouteValues((IDictionary<string, object>)routeValues);
 }
示例#7
0
 private static void ApplyRoute(INavigatable navigatable,string controllerName,string actionName,RouteValueDictionary routeValues)
 {
     navigatable.ControllerName = controllerName;
     navigatable.ActionName = actionName;
     navigatable.SetRouteValues(routeValues);
 }