DataSet

Introduction

The Dataset is a control to represent collections of items. Traditionally, this would have been covered by the table or hierarchy. However, tabular or hierarchical views of collections are nothing but views on the actual data.
To allow more flexibility to the user, data sets allow switching the view (layout) on the data at runtime. This behavior is most likely already known from today's operating systems' file explorers. There views for files as list, detailed list, icons, thumbnails, etc. can be choosen.

The Dataset provides a toolbar on top where the the user finds the view switches in the leftmost position. Next to the view switches additional toolbar items can be added. On the rightmost end there a filter field can be displayed.

DataSetSimpleView Layout

The DataSetSimpleView control is a basic layout for the DataSet control. Depending how the attributes of the DataSetSimpleView are set different target layouts can be achieved:

If the attribute floating is set to false each item of the Dataset is rendered into a separate row.
Setting the attribute floating to true and the attribute responsive to false results in a floating layout where as many items as fit (based on their actual width) are rendered within a row.
If both attributes floating and responsive are set to true also a floating layout is created. In this case as many items as fit (based on a specified minimum width (attribute itemMinWidth)) are rendered within a row. The items are stretched to fill the available space of each row.

Dataset Example

The following example gives an overview how the Dataset and the DataSetSimpleView layout can be used. In the example a custom control is used as template for the Dataset items, but also other controls or SAPUI5 views are possible. The CSS declarations used for the custom control can be found here.



API Documentation

DataSet API documentation
DataSetSimpleView API documentation