Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make it possible to register custom BuilderFactories #131

Closed
manuel-mauky opened this issue Sep 5, 2014 · 3 comments
Closed

Make it possible to register custom BuilderFactories #131

manuel-mauky opened this issue Sep 5, 2014 · 3 comments
Labels
Milestone

Comments

@manuel-mauky
Copy link
Collaborator

In some use cases you need a custom BuilderFactory for your own components.
We should provide a way to add such factories to our framework so that thay are set in the internal FXMLLoader.

We could create our own BuilderFactory that first iterates over the provided custom BuilderFactories when a builder is requested and after that (if no suitable builder was found) and then forward the request to the default [JavaFXBuilderFactory].

@manuel-mauky manuel-mauky added this to the 0.5.0 milestone Oct 16, 2014
@manuel-mauky manuel-mauky modified the milestones: 1.1.0, 1.0.0, 1.2.0 Nov 28, 2014
@manuel-mauky manuel-mauky modified the milestones: 1.4.0 - future ideas, 1.3.0 Apr 30, 2015
@sideisra
Copy link
Contributor

I have a related problem. I need to give View and ViewModel some further information based on the loaded fxml file. Therefore i would need lifecycle methods that give me access to FXML, View and ViewModel when creating these instances. Like a Builder from a custom BuilderFactory but I need to know from what fxml the view has been created.

Example: I have a generic view and a generic view model which serve as code behind for different fxml files. But there is some fxml specific logic so I need to know the fxml file name in view and/or view model. With the name of the fxml file I load other files which are equally names (e.g. main.fxml > main.xml).

Would it be possible to implement this addition here or should it be a separate feature request?

@manuel-mauky
Copy link
Collaborator Author

This should be a separate feature request. Could you please open a new ticket for this? Can you provide some more details of your example? Especially how do you use your "generic view"/"generic viewmodel"? Are you using sub-classing or do you bypass the naming conventions when you load the view?

@sialcasa
Copy link
Owner

@dennyisrael @lestard #215 is related to this topic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants