title: How do you create a table cell factory in JavaFX to display a ChoiceBox?
body: <p>I am trying to display a ChoiceBox inside of a TableView in JavaFX. Right now I am just trying to test if I can get this working, so I am generating fake data within the cell factory, but I can't even get this to work. </p>
  
  <p>My IDE is giving me the error that</p>
  
  <pre><code>forTableColumn (javafx.collections.ObservableList&lt;T&gt;) in ChoiceBoxTableCell cannot be applied
  to             (javafx.collections.ObservableList&lt;java.lang.String&gt;)
  </code></pre>
  
  <p>Here is my code.</p>
  
  <pre><code>private ListView&lt;RequirementsProperty&gt; guiPropertyList;
  private TableColumn&lt;RequirementsProperty, String&gt; guiSpecifierColumn;
  
  guiSpecifierColumn.setCellFactory(
                  new Callback&lt;TableColumn&lt;RequirementsProperty, String&gt;, TableCell&lt;RequirementsProperty, String&gt;&gt;() {
                      @Override
                      public TableCell&lt;RequirementsProperty, String&gt; call(TableColumn&lt;RequirementsProperty, String&gt; param) {
                          ObservableList&lt;String&gt; testlist = FXCollections.observableArrayList("A", "B", "C");
                          return ChoiceBoxTableCell.forTableColumn(testlist);
                      }
                  });
  </code></pre>
  
  <p>Does anyone know what I am doing wrong? I just want to display the list containing A, B, and C right now, and then I can move on to displaying my own data.</p>