What's Model"
From Documentation
Maya001122 (talk | contribs) m (Created page with '{{ZKDevelopersGuidePageHeader}} To assign data to a component (e.g. <tt>grid</tt> or <tt>listbox</tt>), you have to prepare the data in certain data model. For example, <tt>list…') |
m (correct highlight (via JWB)) |
||
Line 1: | Line 1: | ||
{{ZKDevelopersGuidePageHeader}} | {{ZKDevelopersGuidePageHeader}} | ||
− | To assign data to a component (e.g. < | + | To assign data to a component (e.g. <code>grid</code> or <code>listbox</code>), you have to prepare the data in certain data model. For example, <code>listbox</code> and <code>grid</code> accept interfaces <code>ListModel</code> and <code>GroupsModel</code>, while <code>tree</code> only accepts <code>TreeModel</code>. See the <code>setModel</code> method of each component for the kind of model it accepts. Using the wrong type of data model will throw a cast error and is a common beginner mistake. |
ZK has implemented following Models: | ZK has implemented following Models: |
Latest revision as of 10:40, 19 January 2022
This documentation is for an older version of ZK. For the latest one, please click here.
To assign data to a component (e.g. grid
or listbox
), you have to prepare the data in certain data model. For example, listbox
and grid
accept interfaces ListModel
and GroupsModel
, while tree
only accepts TreeModel
. See the setModel
method of each component for the kind of model it accepts. Using the wrong type of data model will throw a cast error and is a common beginner mistake.
ZK has implemented following Models:
- SimpleCategoryModel
- SimpleGroupsModel
- SimpleListModel
- SimplePieModel
- SimpleTreeModel
- SimpleXYModel
- SimpleXYZModel
- SimpleHiLoModel