JLink`
JLink`
KeepJavaObject
KeepJavaObject[object]
causes the specified object or objects not to be released when the current JavaBlock ends.
KeepJavaObject[object,Manual]
causes the specified object to escape from all enclosing JavaBlock blocks, meaning that the object will only be released if you manually call ReleaseJavaObject.
更多信息和选项
- To use KeepJavaObject, you first need to load J/Link using Needs["JLink`"].
- KeepJavaObject allows an object to "escape" from the current JavaBlock.
- KeepJavaObject only has an effect if the object was in fact slated to be released by the current block.
- KeepJavaObject causes the object to be promoted to the "release" list of the next enclosing JavaBlock, if there is one, so it will be released when that block ends (unless you call KeepJavaObject again in the outer block).
Wolfram Research (2007),KeepJavaObject,Wolfram 语言函数,https://reference.wolfram.com/language/JLink/ref/KeepJavaObject.html.
文本
Wolfram Research (2007),KeepJavaObject,Wolfram 语言函数,https://reference.wolfram.com/language/JLink/ref/KeepJavaObject.html.
CMS
Wolfram 语言. 2007. "KeepJavaObject." Wolfram 语言与系统参考资料中心. Wolfram Research. https://reference.wolfram.com/language/JLink/ref/KeepJavaObject.html.
APA
Wolfram 语言. (2007). KeepJavaObject. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/JLink/ref/KeepJavaObject.html 年