ViewModelType
- the type of the viewModel.public interface JavaView<ViewModelType extends ViewModel>
extends de.saxsys.mvvmfx.internal.viewloader.View<ViewModelType>
A view that is implemented with with pure Java.
The implementing class will typically extend from one of JavaFX`s controls or containers etc. For Example:
public class MyCoolView extends VBox implements JavaView <MyCoolViewModel>
{
...
public MyCoolView(){
getChildren().add(new Label("Hello World"));
}
}
It is recommended to implement views with FXML and therefore use FxmlView
instead of this interface. But
there may be use-cases where FXML isn't suitable or not supported (i.e. the "Compact-1" profile introduced in Java 8
doesn't support FXML) or the developer doesn't like FXML. For this cases this interface provides a way to implement
the view without FXML in pure Java.
Copyright © 2015 Saxonia Systems AG. All rights reserved.