Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8770989
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T17:40:33+00:00 2026-06-13T17:40:33+00:00

I have a custom JavaFX-2 component written in the fxml language (Which I’ll referrer

  • 0

I have a custom JavaFX-2 component written in the fxml language (Which I’ll referrer as child or children), which I used the JavaFX Scene Builder to create it. One of my view classes need to display several (~100) of those components and communicate with them. With the MVC architecture in mind, what’s the best approach for communication?

  1. (Container) Model -> (Children) Model
  2. (Container) Controller -> (Children) Controller
  3. (Container) Controller -> (Children) Model

Basically I need at least to be able to monitor 2 case of events happening in the children UI and or in the container object.

Case 1: The user clicked a button (or interacted with another object) which exists inside my custom component (child), the container must be communicate about the change.

Case 2: The user triggered an event on the container, filtering the components based on a specific query for example, I need to communicate the children about this change.

Thanks in advance for all the help. Cheers

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T17:40:34+00:00Added an answer on June 13, 2026 at 5:40 pm

    I always tend to keep communication between the controllers, while my models are POJOs although they use javafx properties to store data. This seems to map to option #2.

    It is fairly easy for the parent controller to call the child controller, all it has to do is load them and keep them in a list. The child calling the parent is a little more ugly since it might require a reference to the parent. I try and avoid this by having an event handler property on the child controller which the parent adds a listener to. This has made my child controls quite reusable.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have written a custom component for jsf. The renderer extends com.sun.faces.renderkit.html_basic.ListboxRenderer. My component
I have custom component that I can place in my layout file (XML) for
I have a custom InjectionProvider which retrieves a User object from the SecurityContext and
I have a Jtable which uses custom renderer and editor, which use JTextPane as
We have a custom javax.security.auth.spi.LoginModule used for web services as well as some web
I have an custom annotation called @Pojo which I use for automatic wiki documentation
I have custom UITableViewCell . It contains UITextLabel . When I press this cell
I have custom validation rule: public function customRule($check) { } Inside this rule I
I have custom classes that I currently instantiate within App.xaml as resources. I want
i have custom cell with 2 buttons(the function of these buttons is just to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.