Size of Objects in Java Heap w/ Regards to Methods
- by Eric
I know about primitives and objects living on the heap, but how does the number of methods effect heap size of the object?
For example:
public class A {
int x;
public getX() { return x; }
}
public class B {
int x;
public getX() { return x; }
public getXString() { return String.valueOf(x); }
public…