Is there a way to modularize a JavaFX application?

前提是你 提交于 2019-12-03 15:43:50
Sergey Grinev

From FXML perspective there are two approaches:

  1. Simply use fx:include directive to split application into logical parts in different fxml files.

  2. More advanced way would be to implement parts of your application as separate "controls". Which will have their own (can be very simple) API to provide data and can be used in FXML or FX API like built-in controls. See next question for details how to implement that using FXML: How to pass object created in FXML Controller1 to Controller2 of inner FXML control

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!