Wednesday, November 18, 2015

Re: CellTree with different types at same level

Make sure that all your classes extend the same base class and you will be fine as John already said.

On Wednesday, November 18, 2015 at 9:58:56 AM UTC+1, wrote:
Hi john

I have a query, what if we want the level one too have different type and same with sub level.

On Wednesday, November 17, 2010 at 8:18:36 AM UTC-5, John LaBanca wrote:
By "at the same level", we mean that if A and B are siblings, their children can be different types even if there are at the same depth in the tree.  CellTree doesn't support difference types within the same child list.  You'll have to use a common super type or interface and cast as needed.

The following is supported.  The children of A and B are different types (Bar and Baz) but are both one level deep:
A (Foo)
- AA (Bar)
- AB (Bar)
- AA (Bar)
B (Foo)
- BA (Baz)
- BB (Baz)
- BC (Baz)

The following is not supported.  The children of A cannot be of multiple types.
A (Foo)
- AA (Bar)
- AB (Baz)
- AA (Biz)

John LaBanca

On Tue, Nov 16, 2010 at 8:41 PM, David Pinn <> wrote:
I think type checking and casting within the cell is necessary in that

On Nov 17, 10:47 am, decitrig <> wrote:
> The docs for CellTree say that nodes at the same level "usually" share
> a common type, but that it isn't necessary. However, since the data
> providers & node info are parameterized, nodes seem to *have* to have
> a common type at a given level. What am I missing? are there examples
> anywhere of having types with nothing in common at the same level? Is
> it just returning a raw NodeInfo and then doing the type checking/
> casting in the cell?

You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To post to this group, send email to
Visit this group at
For more options, visit

No comments:

Post a Comment