R4R
Right Place For Right Person TM

What is a native method?

previous previous previous
Question:
What is a native method?

Question:What is a native method?


Answer
A native method is the Java interface to non-Java code. It is Java's link to the "outside world". A native method is a Java method whose implementation is provided by non-java code. A native method is one for which the body of the method is defined elsewhere, entirely outside the Java Virtual Machine, in a library. Only methods can be declared as native. A native code is written in a non-Java language, typically C or C++, and compiled for a single target machine type. Syntax : native public void Native1( ) ;

By:Jalees
Date:

What is a native method?

Post Your Answers


User Name:
Answers:

Related Links

  1. What is the difference between a continue statement and a break statement?
  2. What must a class do to implement an interface?
  3. What is the difference between notifyand notifyAll method ?
  4. What does wait method do ?
  5. What are the different states of a thread ?
  6. What is the difference between static and non static inner class ?
  7. What is the difference between readers and streams?
  8. Why we cannot override static methods?
  9. When does a compiler supplies a default constructor for a class?
  10. What will happen if an exception is not caught ?
  11. What are the different ways in which a thread can enter into waiting state?
  12. What is a ResourceBundle class?
  13. What is numeric promotion?
  14. What is the difference between the prefix and postfix forms of the ++ operator?
  15. What is the difference between a switch statement and an if statement?
  16. What is hashCode?
  17. What is the difference between RandomAccessFile and File?
  18. What is the difference among JVM Spec, JVM Implementation, JVM Runtime ?
  19. What is the difference between Hashtable and HashMap ?
  20. Why java is said to be pass-by-value ?
  21. What do you mean by immutable ? How to create an immutable object ?
  22. What is a weak reference ?
  23. What is object cloning?
  24. What is object pooling?
  25. What is the disadvantage of garbage collection?
  26. What are tag interfaces?
  27. What are the restrictions placed on static method ?
  28. What is JIT?
  29. What is the Locale class?
  30. What is the difference between URL and URLConnection?
  31. What are the two important TCP Socket classes?
  32. Strings are immutable. But String s="Hello"; String s1=s+"World" returns HelloWorld how ?
  33. What is classpath?
  34. What is path?
  35. What is java collections?
  36. Can we compile a java program without main?
  37. What is static initializer block? What is its use?
  38. How does a try statement determine which catch clause should be used to handle an exception?
  39. If a class doesn't have any constructors, what will happen?
  40. What will happen if a thread cannot acquire a lock on an object?
  41. What will happen if you are invoking a thread's interrupt method while the thread is waiting or sleeping?
  42. What is coupling?
  43. How will you define an interface?
  44. How will you define an abstract class?
  45. What is a JVM heap?
  46. What is daemon thread?
  47. What is a green thread?
  48. What is volatile variable?
  49. What is diamond problem?
  50. How many JVM's we can run in a system?

Question:What is a native method?

Back Home Next

New Updates

Topics

Topics

R4R
R4R
R4R
R4R
R4R
R4R
R4R
R4R