• 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
NSAutoreleasePool with java questions
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSAutoreleasePool with java questions


  • Subject: NSAutoreleasePool with java questions
  • From: Chris Kelly <email@hidden>
  • Date: Tue, 06 Aug 2002 23:55:16 -0700

I've got working code to read an app's info.plist using CocoaJava, except I
kept getting the messages "_NSAutoreleaseNoPool(): Object XXX of class
NSCFString autoreleased with no pool in place - just leaking"

So, I added this in main():
int pool = NSAutoreleasePool.push();
// my code
NSAutoreleasePool.pop( pool );

Now, I'm getting an UnsatisfiedLinkError for the push() method. What
library is that in?

I'm not exactly clear on when I need to use the NSAutoreleasePool frame. Is
it only in this case, where my main method is used for testing? After
testing, this code will be put into a library which will be called from
someone's application. In that case, will I need to surround my code with
the pool frame? Can I install pool frames willy-nilly just in case, or is
there a size/memory leak/speed downside?

-------------------
Send Sun a Message! Vote for JConfig here:

http://www.sys-con.com/java/readerschoice2002/nominationform.cfm

See the 'Best Class Library', 'Best Component', and 'Most Innovative
Product' categories. Thanks!

Get JConfig here: http://www.jconfig.com

Use JConfig to: enumerate the user's hard drives,
launch processes, get the file type of a file,
launch the user's default web browser, and much more.
-------------------
_______________________________________________
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: enough of accessors - how about private method naming conventions in the real world?
  • Next by Date: Re: enough of accessors - how about private method naming conventions in the real world?
  • Previous by thread: Re: enough of accessors - how about private method naming conventions in the real world?
  • Next by thread: NSComboBox vs NSComboBoxCell
  • Index(es):
    • Date
    • Thread