Possible duplicate:static allocation in java - heaps, stacks and constant generation
its a little confusion ... the definition of static for a class, methods, and variables. In these three cases, when memory is allocated in this way.? My boss is familiar with C, he says that only variables are in heap memory, and the rest (static classes and static methods) remain in main memory. what's this? any explanation.?
another one in android using static class and static methods is best practice?
Try it,
static members are stored in Method Area.
. . , .
Non-heap Memory
‘Method Area’ , . , " ".
‘Method Area’
Method Area
, ( ). , . static fields.
static fields
( , ) , JVM.
, ( ..). 1). ( ) , , , . :
.