Say lots of data from db records need to be "loaded" into objects and then these objects are "put" into a java.util.Vector object. The size of the "data" that would occupy memory space can be estimated. But howabout each of the objects' reference addresses that were put into the vector, do these also occupy memory space, or, for some reason (i don't know), are copies of these addresses made by the jvm and placed in memory space? If they are, would they grow to be significant for estimating memory requirements...big/small devices? Thanks. I learn from any comment.
posted 14 years ago
References take up four bytes (this is from memory - YMMV)