• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
(no subject)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

(no subject)


  • Subject: (no subject)
  • From: DevReseune <email@hidden>
  • Date: Sat, 19 Jul 2003 16:33:32 +0200

Hi,

I want to call methods of Java class from my Objective C code.
The old Apple's documentation had a document about Java Bridge, and now, this document isn't in the site. So, how to find documentation?
I saw:
- file:///Developer/Documentation/Cocoa/Legacy/JavaBridge/ JavaBridge.3.html
- http://cocoa.mamasam.com/MACOSXDEV/2003/05/1/63268.php -> to correct a error message
- the bridget tool


After many tests, I can't call my method. This is an example;

My Java Class

public class MyJavaObject {
public String methodWithStringAndValue(String message, int value) {
return message+" - "+value;
}
}

I want now, in a ObjC code, use this code:

Class MyJavaObjectClass = NSClassFromString(@"MyJavaObject"); // it's ok
MyJavaObject object = [[MyJavaObjectClass alloc] init];
NSString *message = [object methodWithString: @"hello" andValue: 10];

Thanks for your help

Fridiric
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: Songs at WWDC 2003
  • Next by Date: Re: Anybody get Distributed Build to work?
  • Previous by thread: (no subject)
  • Next by thread: (no subject)
  • Index(es):
    • Date
    • Thread