Reputation: 93
How the static methods and normal methods are stored in memory? If its a heap structure how the methods are associated with the classes and objects?
Upvotes: 0
Views: 58
Reputation: 1
Read much more about the JVM, its bytecode, and its class loaders.
You could download and read the JVM specification.
In practice, JVMs are using JIT compilation techniques on the bytecode.
In principle, JVMs load classes (e.g. in .class
files) containing bytecode (and other data).
A Java class is represented by some structure containing something similar to a vtable which (in theory) associate function bytecode to method names.
Upvotes: 1