• 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
Ref counting/garbage collection in a obj-c/java bridge
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Ref counting/garbage collection in a obj-c/java bridge


  • Subject: Ref counting/garbage collection in a obj-c/java bridge
  • From: Christoffer Lerno <email@hidden>
  • Date: Thu, 18 Mar 2004 14:30:40 +0800

I'm just starting to try out obj-c/java bridging.

I just want to make sure that I handle memory right. As far as I can tell:

id someclass=[[NSClassFromString(@"SomeClass") alloc] init];

would require an explicit

[someclass release]

However, if my java class has a method like this:

public static SomeClass create()
{
return new SomeClass();
}

And I instead get my object this way:

id someclass=[NSClassFromString(@"SomeClass") create];

It would be autoreleased?

What about objects created with newWithSignature? Do I need to release those?


/Christoffer
_______________________________________________
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: Cocoa equivelant of NMInstall()?
  • Next by Date: substring return a new string?
  • Previous by thread: NSDate conversion
  • Next by thread: substring return a new string?
  • Index(es):
    • Date
    • Thread