Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

anonymous inner class - Andrew's book

 
Harish Yerneni
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ranchers:

I am not able to understand the anonymous inner class arguments, third argument to log.entering. Can somebody explain me the argument part..how come they are between flower braces.

public DVD(String upc, String name, String composer, String director,
String leadActor, String supportActor, String year,
int copies) {
log.entering("DVD", "DVD",
new Object[]{upc, name, composer, director, leadActor,
supportingActor, year, copies}
);
this.upc = upc;
this.name = name;
this.composer = composer;
this.director = director;
this.leadActor = leadActor;
this.supportingActor = supportActor;
this.year = year;
this.copy = copies;
log.exiting("DVD", "DVD");
}

Thanks,

Harish
 
John Stone
Ranch Hand
Posts: 332
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's not anonymous class, that is array.

You can do the same thing by:
 
Harish Yerneni
Ranch Hand
Posts: 94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, John.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic