• Post Reply Bookmark Topic Watch Topic
  • New Topic

Story within the javadoc of "TransformerFactoryImpl" from rt.jar  RSS feed

 
Manu Somasekhar
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was going through the source of TransformerFactoryImpl.java from rt.jar . I found java doc of the variable as "DEFAULT_TRANSLET_NAME" as "As Gregor Samsa awoke one morning from uneasy dreams he found himself transformed in his bed into a gigantic insect". Jumping into the class browser within eclipse I found more kind of a story. Check this link. Anybody know what is this mystery all about ?
 
Ulf Dittmer
Rancher
Posts: 42972
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you search for "Gregor Samsa" you'll find that he is the protagonist of a story called "The Metamorphosis" written by Franz Kafka. Transformation is another word for metamorphosis, so it seems to fit with the purpose of the class. Interesting discovery :-)
 
Campbell Ritchie
Marshal
Posts: 55793
164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
They obviously let people write Javadoc comments on 1st April at Apache
 
Mike Simmons
Ranch Hand
Posts: 3090
14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's not just the JavaDoc - the value of DEFAULT_TRANSLET_NAME is "GregorSamsa". This means that by default, the transformer factory generates a translet class named GregorSamsa.java. You may see references to this in stack traces.
 
Rob Spoor
Sheriff
Posts: 21095
85
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf Dittmer wrote:a story called "The Metamorphosis" written by Franz Kafka.

Die Verwandlung, for purists (like me). Quite a good book, I've read it in high school.
 
Mike Simmons
Ranch Hand
Posts: 3090
14
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm guessing Ulf knows that.
 
Manu Somasekhar
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So it was an Easter egg in jdk .
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!