Re: Mirrored observable collections

2014-10-10 Thread Mike Hearn
Someone got in touch with me today and pointed out a bug in this code, but it was already fixed by me some time ago. I've refreshed the gist with the latest versions of these classes, but the upstream project is now fully open source. You can get the latest code here: https://github.com/vinumeris/

Re: Mirrored observable collections

2014-07-24 Thread Werner Lehmann
Hi Mike, well seems as if you can create such a method using StringBinding with 4-5 lines of code. Personally I wished that StringConverter was a SAM interface so that I can just provide a lambda for it. In many cases - like yours - it is sufficient to implement the toString method... Werner

Re: Mirrored observable collections

2014-07-23 Thread Mike Hearn
Yes createStringBinding helps but is verbose and repetitive. format() requires the formatting to be specifiable with format codes, not Java. What I want is basically bindBidirectional(Property stringProperty, Property otherProperty, StringConverter converter) but with a signature of bind(Propert

Re: Mirrored observable collections

2014-07-23 Thread Werner Lehmann
Hi, take a look at Bindings.format and Bindings.createStringBinding for that. I use it all the time. Werner On 23.07.2014 13:16, Mike Hearn wrote: Incidentally the lack of a uni-directional string binding utility in JavaFX is really annoying: converting a read only observable value into a st

Re: Mirrored observable collections

2014-07-23 Thread Tomas Mikula
On Wed, Jul 23, 2014 at 1:16 PM, Mike Hearn wrote: > Thanks Tomas! I'm a big fan of your work and blog. > > I learned about ReactFX after I started writing my current project, seems > like a very useful abstraction indeed, although so far I've found the basic > JFX stuff to be nearly sufficient (a

Re: Mirrored observable collections

2014-07-23 Thread Mike Hearn
Thanks Tomas! I'm a big fan of your work and blog. I learned about ReactFX after I started writing my current project, seems like a very useful abstraction indeed, although so far I've found the basic JFX stuff to be nearly sufficient (a few more transformers and mirrored observables were so far a

Re: Mirrored observable collections

2014-07-22 Thread Tomas Mikula
Nice! On Tue, Jul 22, 2014 at 6:09 PM, Mike Hearn wrote: > I have what I imagine is a fairly typical JavaFX application (once it's > released I'll post more about it). It has a GUI, some mostly asynchronous > state management, and interactions with various servers that can change the > apps state

Mirrored observable collections

2014-07-22 Thread Mike Hearn
I have what I imagine is a fairly typical JavaFX application (once it's released I'll post more about it). It has a GUI, some mostly asynchronous state management, and interactions with various servers that can change the apps state. At first I tried the simple and obvious approach in which the ba