Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

What is hot code replacement?

 
Bruce Jin
Ranch Hand
Posts: 672
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I heard that JDK 1.4 supports hot code replacement feature. What is it? Can someone give a simple explanation/example?
Thanks
 
Steve Chernyak
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think its for debugging purposes.
If while you are debugging an application you want to change code in the current method the debugger is able to reexecute that method with out having to restart the application.
 
Bruce Jin
Ranch Hand
Posts: 672
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Steve.
This is interesting.
I use Eclipse IDE I will try this. You mean this is not an IDE feature but built in JDK?
 
Steve Chernyak
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yeah its cool.
Eclipse is what I tried it with too.
For somereason you can't do it in the main method.
Im not sure if its because its static or not
 
Dirk Schreckmann
Sheriff
Posts: 7023
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sun is calling it HotSwap. It allows a class to be updated while under the control of a debugger. More informaion on HowSwap can be found in The JPDA Enhancements Document.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic