Wolfram ResearchPRODUCTSPURCHASEFOR USERSCOMPANYOUR SITES
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.

Documentation / Mathematica / Add-ons & Links / J/Link / Part 1. Installable Java: Calling Java from Mathematica / ...Reference Counts and Memory Management /

PeekObjects and PeekClasses

PeekObjects[] returns a list of all Java objects that are currently referenced in Mathematica. This includes all objects explicitly created with JavaNew and all those that were returned to Mathematica as the result of a Java method call or field access. It does not include objects that have been released with ReleaseJavaObject or through JavaBlock. PeekObjects is intended mainly for debugging. It is very useful to call it before and after some function you are working on. If the list grows, your function leaks references, and you need to examine its use of JavaBlock and/or ReleaseJavaObject.

PeekClasses[] returns a list of JavaClass expressions representing all classes loaded into Mathematica. Like PeekObjects, PeekClasses is intended mainly for debugging. Note that you do not have to determine if a class has already been loaded before you call LoadJavaClass. If the class has been loaded, LoadJavaClass does nothing but return the appropriate JavaClass expression.



Any questions about topics on this page? Click here to get an individual response.Buy NowMore Information


 © 2008 Wolfram Research, Inc.  Terms of Use  Privacy Policy | [ja] |
Sign up for our newsletter: