Well, the Scala sample created by Rickard simply used standard Qi4j features to create the "bridge" with "TraitMixin" to be applied when you have traits.
Likewise; libraries/scripting contains simplistic support for implementing Mixins in javascript, jruby, beanshell or groovy. (These libs needs some more care though) So, a lot can already be done without additional hooks and I am not totally sure what you have in mind. Without it, I have a bit hard time commenting on it. -- Niclas On Fri, Jun 29, 2012 at 2:37 PM, Dag Blakstad <[email protected]> wrote: > Would it be possible to create a delegate residing in the Scala Support > module? > > By introducing a delegate interface more languages could be introduced > without adding concrete dependencies into Qi4J core module(s). > > I guess a similar situation has been resolved by the the Play Framework, > that supports both plain Java and Scala. Take a sneak peek? > > Regards, > Dag > > 2012/6/28 Paul Merlin <[email protected]> > >> Niclas Hedhman a écrit : >> >> Are we Ok with a Scala dependency on Qi4j Core?? >>> >> It depends on what it really means. >> >> If I use Qi4j in a Java only project, having the scala jars coming in is >> not an option. >> >> >> At this very moment on my local copy, I do >>> >>> private boolean isScalaTrait( Class<?> declaringClass ) >>> { >>> return ScalaObject.class.**isAssignableFrom( declaringClass ); >>> } >>> >>> but, I could modify that to walk the parents and see if any (top one) >>> is named "scala.ScalaObject" instead. >>> At the moment, this is the only Scala dependency in here, but I am >>> pretty sure that soon we should add Scala collection support and >>> possibly other useful types for serialization. So, shall I delay the >>> introduction of the Scala dependency, or Ok to put it in right away >>> and give people some time to get the IDEs to work with Scala (was not >>> trivial for me)? >>> >> Couldn't it be in qi4j-runtime-scala and/or qi4j-scala-support module? >> >> Cheers >> >> /Paul >> >> >> >> ______________________________**_________________ >> qi4j-dev mailing list >> [email protected] >> http://lists.ops4j.org/**mailman/listinfo/qi4j-dev<http://lists.ops4j.org/mailman/listinfo/qi4j-dev> >> > _______________________________________________ > qi4j-dev mailing list > [email protected] > http://lists.ops4j.org/mailman/listinfo/qi4j-dev -- Niclas Hedhman, Software Developer http://www.qi4j.org - New Energy for Java I live here; http://tinyurl.com/3xugrbk I work here; http://tinyurl.com/6a2pl4j I relax here; http://tinyurl.com/2cgsug _______________________________________________ qi4j-dev mailing list [email protected] http://lists.ops4j.org/mailman/listinfo/qi4j-dev

