From: Sascha H. <sa...@xm...> - 2011-02-15 22:53:35
|
Hi, On Fri, Feb 11, 2011 at 3:05 PM, <yo....@ho...> wrote: > Hello > > I have watched the Google Talk about XMLVM and would like to ask some > questions. > > - Can I use Jython with XMLVM or must I use Java? > As XMLVM is using bytecode, you should be able to use Jython, although I don't know if anybody ever tried. > > - Since XMLVM cross compiles the byte code doesn't that mean that the > resulting Objective-C code can't be modified? For instance, if I want to > make any changes I would have to go back to the original Java (or Jython) > code, make the changes and then cross compile again? > Well, nothing is stopping you from making changes to the generated code, but if you make changed to the original code, or we introduce optimizations in XMLVM, then you would need to re-generate your code and merging would become necessary. > - Can I write Objective-C code that will use variables from the XMLVM > resulting code? For example, I write the Java code to communicate with a > server sending login information (i.e. login and password) and then write > ObjC that sets those variables from user input. > First of all, will soon deprecate the ObjC backend and switch over to the much better C-Backend. However the answer is the same: Why would you not write the code that sets those variables in Java as well? > - If the Java code that I write doesn't do any GUI and I want to do all the > UI using Interface Builder is this possible or will I have trouble linking > the XMLVM code with Interface Builder? > So the Interface Builder spits out Objective-C Code, I imagine? You would need to do some manual work to combine that code with the one XMLVM generates. So far we don't have very smooth support for combining manually writte application code with cross-compiled code. > > - If I have a .jar which contains a Java API is it possible to cross > compile this library and then use the API with native ObjC? > If your JAR contains compiled classes, then you can cross-compile this with XMLVM. Using this API from within ObjC is possible, but you would need to know how to create and use cross-compiled XMLVM classes. Again, we don't have easy support for merging hand-written code with cross-compiled code. Hope that helps a bit. // Sascha |