1

Most of the source codes I find on the web about JavaFX show codes with the View and Control layers in one source. So the code that creates the visual components are attached to the methods corresponding to events, ie, layers View and Controller are together. That's not bad, since it is better to develop using MVC architecture?

Why do not prefer web examples separate layers View and Control, ie, use files ".fxml" and controllers in Java classes?

I really liked JavaFX Scene Builder, but there are few examples of web that implement this separation of layers using files ".fxml".

I am Brazilian, sorry the possible english errors. Thank you!

Sandro TC
  • 11
  • 3
  • Good question. +1. I'm also wondering what level of support does JavaFX have for MVVM, since it seems to be a (poor) copy of WPF. – Federico Berasategui Jul 18 '13 at 17:30
  • In the older example there is no FXML support so it's normal, but now there is no reasons to not separate your controller and your view on fxml, I think if you see recent examples without FXML it's not a good practice and maybe it's just to go faster for small example. You can do everything in FXML. You just have to import what you want from FXML to your controller, just easy to do – agonist_ Jul 19 '13 at 09:57

0 Answers0