Anyone using ...?

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Anyone using ...?

Roger Whitcomb-2

Hi,

                I’m curious about anyone using Pivot with either Java 8 Lambdas, or using Pivot with Scala or Groovy.  If you are could you let us know with a few comments about your experiences (good or bad)?

                Basically thinking about changes / extensions to Pivot that we could work on for future versions to more easily / compactly support these newer languages.

 

Thanks,

~Roger Whitcomb

 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Anyone using ...?

Jamal BERRICH

2015-01-16 0:21 GMT+01:00 Roger Whitcomb <[hidden email]>:

Hi,

                I’m curious about anyone using Pivot with either Java 8 Lambdas, or using Pivot with Scala or Groovy.  If you are could you let us know with a few comments about your experiences (good or bad)?

                Basically thinking about changes / extensions to Pivot that we could work on for future versions to more easily / compactly support these newer languages.

 

Thanks,

~Roger Whitcomb

 


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: Anyone using ...?

Karel Hübl
In reply to this post by Roger Whitcomb-2

Hi Roger,

 

We plan to use Pivot with Groovy in our next project. Expected use cases:

-        Use closures instead of annonymous inner classes adapting common Pivot interfaces – typically component listeners, asynchronous actions

-        Use groovy beans for property bindable models. Now we use POJO’s, so we need to implement model POJO, model property listener and property change notification in POJO. We expect, we could intercept property changes in Groovy using GroovyInterceptable.setProperty() and implement org.apache.pivot.collections.Map on groovy bean parent / trait. The goal is to be able to declare strictly properties on groovy model classes and do not implement (boilerplate) support for Pivot property change notifications.

 

May be, the first use case could be somehow supported in future Pivot versions. I mean Pivot developers could have option to handle events of Pivot components by setting Lambda (Closure) handlers instead of implementing and registering custom listeners.

 

Regards Karel

From: Roger Whitcomb [mailto:[hidden email]]
Sent: Friday, January 16, 2015 12:21 AM
To: Pivot Users; '[hidden email]'
Subject: Anyone using ...?

 

Hi,

                I’m curious about anyone using Pivot with either Java 8 Lambdas, or using Pivot with Scala or Groovy.  If you are could you let us know with a few comments about your experiences (good or bad)?

                Basically thinking about changes / extensions to Pivot that we could work on for future versions to more easily / compactly support these newer languages.

 

Thanks,

~Roger Whitcomb

 

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Anyone using ...?

Roger and Beth Whitcomb
Hi Karel,
    Definitely that is one thing I've been looking at with our application -- lots and lots of boilerplate code for listeners and registering listeners, and tons of POJOs just to hold values for the GUI, which are then transferred to the "real" objects.... I'd like to have some automatic ways to register listeners, and then be able to use Lambdas or closures for handling events (property change notifications).

    So, sounds like we're pretty much on the same page with this (or am I off base still?)....  Feel free to share other thoughts as you see things.

Thanks,
~Roger

On 1/20/15 6:27 AM, Karel Hübl wrote:

Hi Roger,

 

We plan to use Pivot with Groovy in our next project. Expected use cases:

-        Use closures instead of annonymous inner classes adapting common Pivot interfaces – typically component listeners, asynchronous actions

-        Use groovy beans for property bindable models. Now we use POJO’s, so we need to implement model POJO, model property listener and property change notification in POJO. We expect, we could intercept property changes in Groovy using GroovyInterceptable.setProperty() and implement org.apache.pivot.collections.Map on groovy bean parent / trait. The goal is to be able to declare strictly properties on groovy model classes and do not implement (boilerplate) support for Pivot property change notifications.

 

May be, the first use case could be somehow supported in future Pivot versions. I mean Pivot developers could have option to handle events of Pivot components by setting Lambda (Closure) handlers instead of implementing and registering custom listeners.

 

Regards Karel

From: Roger Whitcomb [[hidden email]]
Sent: Friday, January 16, 2015 12:21 AM
To: Pivot Users; '[hidden email]'
Subject: Anyone using ...?

 

Hi,

                I’m curious about anyone using Pivot with either Java 8 Lambdas, or using Pivot with Scala or Groovy.  If you are could you let us know with a few comments about your experiences (good or bad)?

                Basically thinking about changes / extensions to Pivot that we could work on for future versions to more easily / compactly support these newer languages.

 

Thanks,

~Roger Whitcomb

 


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Anyone using ...?

Sandro Martini
Hi all,
sorry for the delay but I was in bed with flu ...

my toy projects with Groovy and Scala didn't have specific problems.
Just for info, I tried even to use Scala as scripting language inside
bxml files and in this case problems are due to Scala not using
default Java Beans conventions.

In trunk there are some small features that could be useful with
Groovy/Scala, for example:
- the ability to set a Classloader from an outside environment (like
from a Groovy script) ... there should be a sample for this if I
remember well
- some work (only started) with immutable containers, and support for
SAM-like methods (good even for Java 8) ...

I'm starting to prototipe a simple DSL for building Pivot UI (instead
of bxml) and checked at compile time, on this Groovy and Scala are
great !!
This could even open the way for another skin where the output is HTML
5, and a running app using that skin could serve its GUI opening
default browser (if any) on that port (and of course making it
available even to others) ...

What do you think ?

Bye,
Sandro
Loading...