• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

java classes and references

 
chandra sekhar
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I just want to know where java class objects will be created and
where their reference will be stored.
As I know
ex:MyClass m1=new MyClass();
The actual object is created on heap and object reference m1 is kept on stack pointing to actual object.Is it correct?
Help me...
how exactly and where exactly they will be created
chandu
 
Frank Carver
Sheriff
Posts: 6920
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Note really a servlets question, so I moved it to Java (Beginner)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic