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

Definition

Namespace:Kendo.Mvc.UI

Assembly:Kendo.Mvc.dll

Syntax:

C#
public static class NavigatableExtensions

Inheritance: objectNavigatableExtensions

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

Methods

Sets the action, controller name and route values of INavigatable object.

C#
public static void Action(this INavigatable navigatable, RouteValueDictionary routeValues)
Parameters:navigatableINavigatable

The INavigatable object.

routeValuesRouteValueDictionary

The route values of the Action method.

Sets the action and controller name, along with Route values of INavigatable object.

C#
public static void Action(this INavigatable navigatable, string actionName, string controllerName, object routeValues)
Parameters:navigatableINavigatable

The INavigatable object.

actionNamestring

Action name.

controllerNamestring

Controller name.

routeValuesobject

Route values as an object

Sets the action, controller name and route values of INavigatable object.

C#
public static void Action(this INavigatable navigatable, string actionName, string controllerName, RouteValueDictionary routeValues)
Parameters:navigatableINavigatable

The INavigatable object.

actionNamestring

Action name.

controllerNamestring

Controller name.

routeValuesRouteValueDictionary

Route values as RouteValueDictionary

Sets the action and route values of INavigatable object.

C#
public static void Action<TController>(this INavigatable item, Expression<Action<TController>> controllerAction) where TController : Controller
Parameters:itemINavigatable

The INavigatable object.

controllerActionExpression<Action<TController>>

The controller action.

Generating url depending on the ViewContext and the IUrlGenerator generator.

C#
public static string GenerateUrl(this INavigatable navigatable, ViewContext viewContext, IUrlGenerator urlGenerator, RouteValueDictionary routeValues)
Parameters:navigatableINavigatable

The INavigatable object.

viewContextViewContext

The ViewContext object

urlGeneratorIUrlGenerator

The IUrlGenerator generator.

routeValuesRouteValueDictionary

Route values as RouteValueDictionary.

Returns:

string

Generating url depending on the ViewContext and the IUrlGenerator generator.

C#
public static string GenerateUrl(this INavigatable navigatable, ViewContext viewContext, IUrlGenerator urlGenerator)
Parameters:navigatableINavigatable

The INavigatable object.

viewContextViewContext

The ViewContext object

urlGeneratorIUrlGenerator

The IUrlGenerator generator.

Returns:

string

Determines whether this instance has value.

C#
public static bool HasValue(this INavigatable navigatable)
Parameters:navigatableINavigatableReturns:

bool

true if either ActionName and ControllerName, RouteName or Url are set; false otherwise

Verify whether the INavigatable object is accessible.

C#
public static bool IsAccessible(this INavigatable item, INavigationItemAuthorization authorization, ViewContext viewContext)
Parameters:itemINavigatable

The INavigatable object.

authorizationINavigationItemAuthorization

The INavigationItemAuthorization object.

viewContextViewContext

The ViewContext object

Returns:

bool

Verifies whether collection of INavigatable objects is accessible.

C#
public static bool IsAccessible<T>(this IEnumerable<T> items, INavigationItemAuthorization authorization, ViewContext viewContext)
Parameters:itemsIEnumerable<T>

The INavigatable object.

authorizationINavigationItemAuthorization

The INavigationItemAuthorization object.

viewContextViewContext

The ViewContext object

Returns:

bool

Determines whether the specified navigatable matches the current request URL.

C#
public static bool IsCurrent(this INavigatable navigatable, ViewContext viewContext, IUrlGenerator urlGenerator)
Parameters:navigatableINavigatable

The INavigatable object.

viewContextViewContext

The ViewContext object.

urlGeneratorIUrlGenerator

The IUrlGenerator generator.

Returns:

bool

Sets the route name and route values of INavigatable object.

C#
public static void Route(this INavigatable navigatable, string routeName, object routeValues)
Parameters:navigatableINavigatable

The INavigatable object.

routeNamestring

Route name.

routeValuesobject

Route values as an object.

Sets the route name and route values of INavigatable object.

C#
public static void Route(this INavigatable navigatable, string routeName, RouteValueDictionary routeValues)
Parameters:navigatableINavigatable

The INavigatable object.

routeNamestring

Route name.

routeValuesRouteValueDictionary

Route values as RouteValueDictionary.

Sets the url property of INavigatable object.

C#
public static void Url(this INavigatable navigatable, string value)
Parameters:navigatableINavigatable

The INavigatable object.

valuestring

The Url.