ListViewBuilder<T>
Defines the fluent interface for configuring the ListView<T>.
Definition
Namespace:Kendo.Mvc.UI.Fluent
Assembly:Kendo.Mvc.dll
Type Parameters:
T
Syntax:
public class ListViewBuilder<T> : WidgetBuilderBase<ListView<T>, ListViewBuilder<T>>, IHtmlString where T : class
Inheritance: objectWidgetBuilderBase<ListView<T>, ListViewBuilder<T>>ListViewBuilder<T>
Implements:
Inherited Members
Constructors
Methods
Sets an aria-label attribute on the ListView content element (the element with role listbox or list).
public ListViewBuilder<T> AriaLabel(string value)
The value for AriaLabel
Returns:Specifies if the ListView should be automatically bound on initial load. This is only possible if AJAX binding is used, and widget is not initialy populated on the server.
public ListViewBuilder<T> AutoBind(bool value)
If true ListView will be automatically data bound, otherwise false
Returns:Binds the ListView to a list of objects
public ListViewBuilder<T> BindTo(IEnumerable dataSource)
The IEnumerable list of objects.
Returns:Binds the ListView to a list of objects
public ListViewBuilder<T> BindTo(IEnumerable<T> dataSource)
The data source.
Returns:Renders border around the listview element.
public ListViewBuilder<T> Bordered(bool value)
The value for Bordered
Returns:Renders border around the listview items. Valid values are: all: renders borders around listview items.; horizontal: renders top border of listview items. Useful when setting layout: "flex" and flex.direction: column. or vertical: renders top border of listview items. Useful when setting layout: "flex" and flex.direction: row..
public ListViewBuilder<T> Borders(string value)
The value for Borders
Returns:Specifies ListView alternating item template.
public ListViewBuilder<T> ClientAltTemplate<TModel>(TemplateBuilder<TModel> template)
The template component which contains the template.
Returns:Specifies ListView alternating item template.
public ListViewBuilder<T> ClientAltTemplateHandler(string template)
Specifies ListView alternating item template.
public ListViewBuilder<T> ClientAltTemplateId(string templateId)
The Id of the script element which contains the template.
Returns:Specifies ListView alternating item template.
public ListViewBuilder<T> ClientAltTemplateView(MvcHtmlString template)
The view which contains the template.
Returns:Specifies ListView item template.
public ListViewBuilder<T> ClientTemplate<TModel>(TemplateBuilder<TModel> template)
The template component which contains the template.
Returns:Specifies ListView item template.
public ListViewBuilder<T> ClientTemplateHandler(string template)
Specifies ListView item template.
public ListViewBuilder<T> ClientTemplateId(string templateId)
The Id of the script element which contains the template.
Returns:Specifies ListView item template.
public ListViewBuilder<T> ClientTemplateView(MvcHtmlString template)
The view which contains the template.
Returns:Defines the type of element that holds the listview content. The default value is "div".
public ListViewBuilder<T> ContentElement(string value)
The value for ContentElement
Returns:Binds the ListView to a DataSource.
public ListViewBuilder<T> DataSource(Action<ListViewAjaxDataSourceBuilder<T>> configurator)
The DataSourceBuilder<TModel> configurator.
Returns:Binds the ListView to an existing DataSource instance.
public ListViewBuilder<T> DataSource(string dataSourceId)
The name of the client DataSource instance.
Returns:Enables ListView editing.
Configures the ListView editing settings.
public ListViewBuilder<T> Editable(Action<ListViewEditingSettingsBuilder<T>> configurator)
The editing settings configurator.
Returns:Configures the client-side events.
public ListViewBuilder<T> Events(Action<ListViewEventBuilder> configurator)
The client events action.
Returns:Flex layout settings
public ListViewBuilder<T> Flex(Action<ListViewFlexSettingsBuilder> configurator)
The configurator for the flex setting.
Returns:Grid layout settings.
public ListViewBuilder<T> Grid(Action<ListViewGridSettingsBuilder> configurator)
The configurator for the grid setting.
Returns:Specify the layout of listview content. Valid options are: flex: This is equivalent to display: flex. It defines a flex container and enables a flex context for all its direct children. Think of flex items as primarily laying out either in horizontal rows or vertical columns. or grid: This is equivalent to display: grid. It defines the element as a grid container and establishes a new grid formatting context for its contents..
public ListViewBuilder<T> Layout(string value)
The value for Layout
Returns:Enables keyboard navigation.
Allows paging of the data.
Allows paging of the data.
public ListViewBuilder<T> Pageable(Action<ListViewPageableBuilder> pagerAction)
Use builder to define paging settings.
Returns:If set, the ListView will display a scrollbar when the content exceeds the ListView's height. By default, scrolling is disabled.
In endless scrolling mode the listview should be configured to display a scrollbar. Scrolling to the end of the scrollbar will load more items (equal to the pageSize number) and append them to the listview DOM element utill all items are loaded and displayed.
public ListViewBuilder<T> Scrollable(ListViewScrollableMode mode)
The value for Scrollable
Returns:Enables single item selection.
Enables selection in the specified selection mode.
public ListViewBuilder<T> Selectable(Action<ListViewSelectionSettingsBuilder> selectionAction)
Use builder to define the selection mode.
Returns:Specifies ListView wrapper element tag name.