-
20 Feb 2012 5:16 AM #1
Unanswered: Difference between a list and a nested list
Unanswered: Difference between a list and a nested list
Hi,
I wanna know the differences between a list and a nested list ?
Acoording to me, a list is a basic enumaration of item(s) and a nested list is like a tree.
List :
- A
- B
- C
Nested list:
-------- A1
- A -- |
-------- A2
- B
-------- C1
- C -- |
-------- C2
|
-------- C3
Thanks you for validating my view.
Regards.
-
20 Feb 2012 5:26 AM #2
Nested List
Nested List
Yes the nested list allows you to separate the data and use the search bar so is useful for longer pieces of data like contacts list check out
http://docs.sencha.com/touch/2-0/#!/...iew.NestedList
-
20 Feb 2012 5:42 AM #3
Yep.
A list is just a simple list of element.
A nested list is a tree of element.
If I have a good understanding of how these components work in sencha - if I'm wrong, please correct me -, the nested list is a navigation view containing lists created from the data source.
It needs to load all data at once. (the whole tree)
A list is just a list...
But you can embed it into a navigation view and customized the navigation to browse your data.
For example :
- the first view displays the root level of your data,
- select an item in this list, push another list in the navigation view which displays the second level of your data,
...
This solution will be better if you have a lot of data to display since you only load a part of the tree when you browse it.
Otherwise a nested list is easier to use.
-
20 Feb 2012 5:48 AM #4
Is it possible to load sub-items step by step using a recursive jsonRpc call ?
Each node that is not a leaf can call for a listing of the subtree or is it really mandatory to load the whole tree in one time ?
-
20 Feb 2012 6:21 AM #5
I think there is also a difference in the store type. Nestedlist takes a treestore. I don't think list does.
-
20 Feb 2012 7:14 AM #6
Hi,
First thanks for all the reply.
So now i think i will used a nestedlist linked with treestore / proxy / jsonp (json rpc call).
I have checked on the example and inside the documentation, but i didn't find any good example.Code:Ext.define('FileSystemModel', { extend: 'Ext.data.Model', fields: [ { name: 'item', type: 'string' }, { name: 'type', type: 'int' } ] }); var FileSystemStore = Ext.create('Ext.data.TreeStore', { model : 'FileSystemModel', defaultRootProperty: 'items', root : data });
Is there a good skeleton/example that can help me to work efficiently and quicky ?
Thanks in advance of your reply.
Regards
-
20 Feb 2012 1:11 PM #7Sencha Premium Member
- Join Date
- Oct 2011
- Location
- San Antonio, TX
- Posts
- 93
- Vote Rating
- 0
- Answers
- 4


Reply With Quote