• Post Reply Bookmark Topic Watch Topic
  • New Topic

JNI - difference between refrence and pointer

 
Abbu Rahman
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
someOne answer me please
whats the difference between refrence and a pointer ??
and what is opaque refrence ??
trying to demistify "JNI Programmer's Guide"
someOne answer me please
 
Ernest Friedman-Hill
author and iconoclast
Sheriff
Posts: 24213
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A "pointer" generally means a C-type pointer, which is (or is convertible to) the actual machine address of something. In Java-related context, a "reference" means a more abstract kind of pointer, like a variable of object type in the Java language itself. It refers to an object, and has semantics like a pointer, but you can't convert it into an address.
An "opaque" pointer or reference means a pointer or reference that you can't dereference, because you don't know what it actually points to -- i.e., it points to some undocumented data structure. All you're allowed to do is pass it to some function that understands this same undocumented structure.
 
Abbu Rahman
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks so much
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!