[Haskell-cafe] Re: Lambada and connecting Haskell to a Weblogic server

2007-02-15 Thread Adam Megacz

[EMAIL PROTECTED] (Mark T.B. Carroll) writes:
> Is it easy to create Haskell stubs (in the IO monad, presumably) for
> standard Java libraries so that your compiled-to-JVM Haskell code can
> easily use the usual Java APIs like Swing? One source of vexation for us
> is mapping between Java types and Haskell types.

Unbelievably easy -- check out his source code.  It works just like the
C FFI.

...
foreign import jvm safe "getHead" getHead :: JTree -> IO (Object a)
foreign import jvm safe "child" getChild :: JTree -> Int32 -> IO JTree
foreign import jvm safe "size" size :: JTree -> IO Int32
foreign import jvm safe "toString" jtoString :: (Object a) -> IO JString
...

  - a

-- 
PGP/GPG: 5C9F F366 C9CF 2145 E770  B1B8 EFB1 462D A146 C380

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: Lambada and connecting Haskell to a Weblogic server

2007-02-15 Thread Brian Alliet
On Thu, Feb 15, 2007 at 11:24:31AM -0800, Adam Megacz wrote:
> You should check out Brian Alliet's LambdaVM:
> 
>   http://www.cs.rit.edu/~bja8464/lambdavm/

I think what is in darcs is actually broken right now (the base repo is
out of sync with the ghc repo), but thanks for giving me a big
incentive to fix it. If anyone is interested in playing with it drop me
an email and I'll let you know when it works again.

-Brian
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: Lambada and connecting Haskell to a Weblogic server

2007-02-15 Thread Mark T.B. Carroll
Adam Megacz <[EMAIL PROTECTED]> writes:

> You should check out Brian Alliet's LambdaVM:
>
>   http://www.cs.rit.edu/~bja8464/lambdavm/

That looks very interesting. We'd been wondering if there was some route
from GHC core to Scheme through Bigloo or Kawa to the JVM, but something
more direct is nicer.

Is it easy to create Haskell stubs (in the IO monad, presumably) for
standard Java libraries so that your compiled-to-JVM Haskell code can
easily use the usual Java APIs like Swing? One source of vexation for us
is mapping between Java types and Haskell types.

-- Mark

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: Lambada and connecting Haskell to a Weblogic server

2007-02-15 Thread Adam Megacz

You should check out Brian Alliet's LambdaVM:

  http://www.cs.rit.edu/~bja8464/lambdavm/

  - a

Joel Reymont <[EMAIL PROTECTED]> writes:
> Folks,
>
> Where can I find Lambada these days and would it be of any use to me
> in trying to connect to a Weblogic server?
>
> To make the long story short, my broker's Java software connects to a
> remote Weblogic server and I would like to do the same. I suppose
> this would require me to implement Java RMI in Haskell which is non-
> trivial.
>
> I wonder if it would be easier for me to implement a Java server that
> talks to Weblogic and then connect to that server. What do you think?
>
>   Thanks, Joel
>
> --
> http://wagerlabs.com/

-- 
PGP/GPG: 5C9F F366 C9CF 2145 E770  B1B8 EFB1 462D A146 C380

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe