Re: WebObjects IDE
Re: WebObjects IDE
- Subject: Re: WebObjects IDE
- From: Mike Schrag <email@hidden>
- Date: Mon, 11 Feb 2013 16:11:16 -0500
(cc'ing the mailing list) It doesn't work that way. WebObjects is Java now. You would need to go through a much more complicated process to use Objective-C in your Java app. You need to read up on the JNA framework. Again, I highly recommend not starting out doing this. You will spin your wheels just fighting this.
ms On Feb 11, 2013, at 4:09 PM, Zachary Igielman < email@hidden> wrote: How do I import the objective c class into an eclipse project?Here is the class:
/* Here is an example .h file, "CircularList.h". All behavior is inherited from List, which defines a List of objects. Nowadays we can use NSArray which is more complex than List.* /
#include <objc/List.h> /* Superclass interface */ @interface CircularList: List /* List is superclass */ { int currentLocation; } - (NSString *) next; /* Returns next object in List or nil if none. */ @end
/* Here is the corresponding .m file: */ #include "CircularList.h" @implementation CircularList - (NSString *) next { int numObjects = [self count]; if (currentLocation >= numObjects) currentLocation = 0; return [self objectAt:currentLocation++]; } + (NSString *) webScriptNameForSelector:(SEL)sel { if (sel == @selector(nameAtIndex:)) name = [self next]; return name; } + (BOOL)isSelectorExcludedFromWebScript:(S… { if (sel == @selector(nameAtIndex:)) return NO; return YES; } @end
How do I connect the objective c with the _javascript_ file or eclipse project? Where does the objective c class go (eg same folder as js)? What is the _javascript_ to call my function 'next'? What does the following code do?: + (BOOL)isSelectorExcludedFromWebScript:(S… { if (sel == @selector(nameAtIndex:)) return NO; return YES; } Sent from my iPad 2 What IDE can I use for WebObjects development? Can you send me installation instructions for mountain lion and a link to a hello world webobjects WEBSITE tutorial? When making a WebObjects WEBSITE, can I call objective-c classes and functions, if so, how?
You will need to wrap it with a JNI. Check http://jenkins.wocommunity.org/job/Wonder/javadoc/er/attachment/thumbnail/ImageIOImageProcessor.html for an example.
I would use JNA over JNI these days. However, I would also say that you don't want to do it. It would have to be a very compelling reason to do it in my book. You make everything about your deployment significantly more complicated, and you become platform-bound as well.
ms
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden