< prev index next >

src/java.base/share/native/include/jvm.h

Print this page




  46  *
  47  * Second, this file contains the functions and constant definitions
  48  * needed by the byte code verifier and class file format checker.
  49  * These functions allow the verifier and format checker to be written
  50  * in a VM-independent way.
  51  *
  52  * Third, this file contains various I/O and nerwork operations needed
  53  * by the standard Java I/O and network APIs.
  54  */
  55 
  56 /*
  57  * Bump the version number when either of the following happens:
  58  *
  59  * 1. There is a change in JVM_* functions.
  60  *
  61  * 2. There is a change in the contract between VM and Java classes.
  62  *    For example, if the VM relies on a new private field in Thread
  63  *    class.
  64  */
  65 
  66 #define JVM_INTERFACE_VERSION 4
  67 
  68 JNIEXPORT jint JNICALL
  69 JVM_GetInterfaceVersion(void);
  70 
  71 /*************************************************************************
  72  PART 1: Functions for Native Libraries
  73  ************************************************************************/
  74 /*
  75  * java.lang.Object
  76  */
  77 JNIEXPORT jint JNICALL
  78 JVM_IHashCode(JNIEnv *env, jobject obj);
  79 
  80 JNIEXPORT void JNICALL
  81 JVM_MonitorWait(JNIEnv *env, jobject obj, jlong ms);
  82 
  83 JNIEXPORT void JNICALL
  84 JVM_MonitorNotify(JNIEnv *env, jobject obj);
  85 
  86 JNIEXPORT void JNICALL


 482  */
 483 JNIEXPORT jobject JNICALL
 484 JVM_NewInstanceFromConstructor(JNIEnv *env, jobject c, jobjectArray args0);
 485 
 486 /*
 487  * Constant pool access; currently used to implement reflective access to annotations (JDK 1.5)
 488  */
 489 
 490 JNIEXPORT jobject JNICALL
 491 JVM_GetClassConstantPool(JNIEnv *env, jclass cls);
 492 
 493 JNIEXPORT jint JNICALL JVM_ConstantPoolGetSize
 494 (JNIEnv *env, jobject unused, jobject jcpool);
 495 
 496 JNIEXPORT jclass JNICALL JVM_ConstantPoolGetClassAt
 497 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 498 
 499 JNIEXPORT jclass JNICALL JVM_ConstantPoolGetClassAtIfLoaded
 500 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 501 



 502 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetMethodAt
 503 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 504 
 505 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetMethodAtIfLoaded
 506 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 507 
 508 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetFieldAt
 509 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 510 
 511 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetFieldAtIfLoaded
 512 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 513 
 514 JNIEXPORT jobjectArray JNICALL JVM_ConstantPoolGetMemberRefInfoAt
 515 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 516 






 517 JNIEXPORT jint JNICALL JVM_ConstantPoolGetIntAt
 518 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 519 
 520 JNIEXPORT jlong JNICALL JVM_ConstantPoolGetLongAt
 521 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 522 
 523 JNIEXPORT jfloat JNICALL JVM_ConstantPoolGetFloatAt
 524 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 525 
 526 JNIEXPORT jdouble JNICALL JVM_ConstantPoolGetDoubleAt
 527 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 528 
 529 JNIEXPORT jstring JNICALL JVM_ConstantPoolGetStringAt
 530 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 531 
 532 JNIEXPORT jstring JNICALL JVM_ConstantPoolGetUTF8At



 533 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 534 
 535 /*
 536  * Parameter reflection
 537  */
 538 
 539 JNIEXPORT jobjectArray JNICALL
 540 JVM_GetMethodParameters(JNIEnv *env, jobject method);
 541 
 542 /*
 543  * java.security.*
 544  */
 545 
 546 JNIEXPORT jobject JNICALL
 547 JVM_DoPrivileged(JNIEnv *env, jclass cls,
 548                  jobject action, jobject context, jboolean wrapException);
 549 
 550 JNIEXPORT jobject JNICALL
 551 JVM_GetInheritedAccessControlContext(JNIEnv *env, jclass cls);
 552 




  46  *
  47  * Second, this file contains the functions and constant definitions
  48  * needed by the byte code verifier and class file format checker.
  49  * These functions allow the verifier and format checker to be written
  50  * in a VM-independent way.
  51  *
  52  * Third, this file contains various I/O and nerwork operations needed
  53  * by the standard Java I/O and network APIs.
  54  */
  55 
  56 /*
  57  * Bump the version number when either of the following happens:
  58  *
  59  * 1. There is a change in JVM_* functions.
  60  *
  61  * 2. There is a change in the contract between VM and Java classes.
  62  *    For example, if the VM relies on a new private field in Thread
  63  *    class.
  64  */
  65 
  66 #define JVM_INTERFACE_VERSION 5
  67 
  68 JNIEXPORT jint JNICALL
  69 JVM_GetInterfaceVersion(void);
  70 
  71 /*************************************************************************
  72  PART 1: Functions for Native Libraries
  73  ************************************************************************/
  74 /*
  75  * java.lang.Object
  76  */
  77 JNIEXPORT jint JNICALL
  78 JVM_IHashCode(JNIEnv *env, jobject obj);
  79 
  80 JNIEXPORT void JNICALL
  81 JVM_MonitorWait(JNIEnv *env, jobject obj, jlong ms);
  82 
  83 JNIEXPORT void JNICALL
  84 JVM_MonitorNotify(JNIEnv *env, jobject obj);
  85 
  86 JNIEXPORT void JNICALL


 482  */
 483 JNIEXPORT jobject JNICALL
 484 JVM_NewInstanceFromConstructor(JNIEnv *env, jobject c, jobjectArray args0);
 485 
 486 /*
 487  * Constant pool access; currently used to implement reflective access to annotations (JDK 1.5)
 488  */
 489 
 490 JNIEXPORT jobject JNICALL
 491 JVM_GetClassConstantPool(JNIEnv *env, jclass cls);
 492 
 493 JNIEXPORT jint JNICALL JVM_ConstantPoolGetSize
 494 (JNIEnv *env, jobject unused, jobject jcpool);
 495 
 496 JNIEXPORT jclass JNICALL JVM_ConstantPoolGetClassAt
 497 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 498 
 499 JNIEXPORT jclass JNICALL JVM_ConstantPoolGetClassAtIfLoaded
 500 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 501 
 502 JNIEXPORT jint JNICALL JVM_ConstantPoolGetClassRefIndexAt
 503 (JNIEnv *env, jobject obj, jobject unused, jint index);
 504 
 505 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetMethodAt
 506 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 507 
 508 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetMethodAtIfLoaded
 509 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 510 
 511 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetFieldAt
 512 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 513 
 514 JNIEXPORT jobject JNICALL JVM_ConstantPoolGetFieldAtIfLoaded
 515 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 516 
 517 JNIEXPORT jobjectArray JNICALL JVM_ConstantPoolGetMemberRefInfoAt
 518 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 519 
 520 JNIEXPORT jint JNICALL JVM_ConstantPoolGetNameAndTypeRefIndexAt
 521 (JNIEnv *env, jobject obj, jobject unused, jint index);
 522 
 523 JNIEXPORT jobjectArray JNICALL JVM_ConstantPoolGetNameAndTypeRefInfoAt
 524 (JNIEnv *env, jobject obj, jobject unused, jint index);
 525 
 526 JNIEXPORT jint JNICALL JVM_ConstantPoolGetIntAt
 527 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 528 
 529 JNIEXPORT jlong JNICALL JVM_ConstantPoolGetLongAt
 530 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 531 
 532 JNIEXPORT jfloat JNICALL JVM_ConstantPoolGetFloatAt
 533 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 534 
 535 JNIEXPORT jdouble JNICALL JVM_ConstantPoolGetDoubleAt
 536 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 537 
 538 JNIEXPORT jstring JNICALL JVM_ConstantPoolGetStringAt
 539 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 540 
 541 JNIEXPORT jstring JNICALL JVM_ConstantPoolGetUTF8At
 542 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 543 
 544 JNIEXPORT jbyte JNICALL JVM_ConstantPoolGetTagAt
 545 (JNIEnv *env, jobject unused, jobject jcpool, jint index);
 546 
 547 /*
 548  * Parameter reflection
 549  */
 550 
 551 JNIEXPORT jobjectArray JNICALL
 552 JVM_GetMethodParameters(JNIEnv *env, jobject method);
 553 
 554 /*
 555  * java.security.*
 556  */
 557 
 558 JNIEXPORT jobject JNICALL
 559 JVM_DoPrivileged(JNIEnv *env, jclass cls,
 560                  jobject action, jobject context, jboolean wrapException);
 561 
 562 JNIEXPORT jobject JNICALL
 563 JVM_GetInheritedAccessControlContext(JNIEnv *env, jclass cls);
 564 


< prev index next >