Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Generate getters and setters

 
Gnanavelan Ganeshan
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
how to generate getters and setters at runtime using java code with out any tool

is this possible ?

 
Dave Meyers
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I know of no way to do this. What are you trying to accomplish?
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I suppose you could do it at load time, but personally I'd want to be *really* sure that's what I wanted to do before embarking down that path: there be dragons.
 
Campbell Ritchie
Sheriff
Posts: 48917
58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
At runtime? That doesn't sound at all easy. Maybe impossible. And I agree with David Newton's "there be dragons."
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64827
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is your motivation for this rather bizarre requirement?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic