I\'m looking an efficient way of executing Haskell functions from within a Java program. I\'ve considered the use of exec() to interact with GHC, but it seems like there sho
I assume you know how to call C from Java? If so, then you can follow the FFI guide to call Haskell from C, and C from Java, creating a bridge. This is a native call, and may require some fiddling with linkers.
Details on calling Haskell from C are here: http://www.haskell.org/haskellwiki/Calling_Haskell_from_C
Alternatively, you might consider an RPC server.