Search code examples
javaextjscomboboxgxt

Sencha GXT Combo Box without Data Type


I'm using Sencha GXT 3.0.0 + Hibernate.

I have static values to insert into a ComboBox, for example: names of states from USA, and I DONT want to create a (base) class a.k.a. data type (I have my reasons...)

I have something like this in mind:

String vector=["Alabama","California","Wyoming"];
private ComboBox<String> comboBox1;

On Sencha GXT Web Site we can see an example

But I dont want to create the "State" class.

Is it possible?


Solution

  • SimpleComboBox should do you. It actually still creates a base class of type SimpleComboValue, but it does all that behind the scenes.