阅读背景:

JavaFX:如果ObservableList的元素发生更改,则更新ListView

来源:互联网 

I would like to display a list of persons (coded in POJOS, and containing a name and surname property) using a JavaFX ListView control. I created the ListView and added the list of persons as an ObservableList. Everything works fine if I delete or add a new person to the ObservableList, but changes in the POJO do not trigger an update of the ListView. I have to remove and add the modified POJO from the ObservableList to trigger the update of the ListView. Is there any possibility to display changes in POJOS without the workaround described above?I would like to display a list of persons (code




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: