Category Archives: Tips

Tip #3: Never Write ‘new Thread()’ Again

As you probably know JRebirth has a powerful thread engine that kick away all coding complexity that could lead to User Interface corruptions, lags or the worst one a totally frozen interface.

It’s really difficult to create dynamically a lot of threads without adding some bugs to the application. JRebirth provides a powerful way to simplify your developments.

With the advent of Java 8 (with Method References) and JRebirth 8,  it’s now possible to chain and combine Tasks running into specific Thread in a very convenient way.

Continue reading

Tip #2: How to runAndWait with JRebirth Thread Engine

Last week I saw an interesting blog entry from Kynosarges that deal with the missing feature Platform.runAndWait(…) that was available into Swing.

While I was reading it, I figure that JRebirth Thread Engine already does the job !!!

As a remember JRebirth Application framework provides 4 kinds of threads:

  • JAT ==> JavaFX Application Thread to perform all graphical updates
  • JIT ==> JRebirth Internal Thread (perform JRebirth wave registration and other custom internal stuff)
  • JTP ==> First Thread Pool (perform long task)
  • HPTP ==> Second Thread Pool to perform higher priority task

Let’s see how to do run a UI task and wait before doing something else, we will play with some JRebirth Commands, the threading engine is totally hidden from developer sight.

Continue reading

Tip #1: FXML Model Simplification

Today I open a new category of posts, I will try to publish periodically some tips about JRebirth Application Framework.

I begin with a FXML model simplification inspired by @Jerady adm4ee application, I discussed with him about reasons that drive him to use his own small application framework to develop his tool (more info about his tool on bitbucket).

He replies to me that he wants to try coding a whole application without using other external libraries to reduce the number of external dependencies (but the main advantage to use JRebirth is to solve all common threading issues… , by the way I suspect his application to freeze during long task performed into JavaFX Application Thread -[JAT])

Continue reading