• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Tim Cooke
  • Paul Clapham
  • Jeanne Boyarsky
Sheriffs:
  • Ron McLeod
  • Frank Carver
  • Junilu Lacar
Saloon Keepers:
  • Stephan van Hulst
  • Tim Moores
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Frits Walraven
  • fred rosenberger

Inner interfaces

 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Ranchers,

I just found a code-bit in which an inner interface is used in a class and it's implemented within a method, as below:




I am just curious to know what extra functionality do we achieve by using this syntax? We could have provided the same functionality by either:

a)Creating another private method and calling it from other methods within the same class, OR,
b)If the code is used at just one place then directly code it as part of "getCall()" method above.

So any thoughts on this might help me to understand the design approach.

Thanks,
Kamal Arora
[ July 27, 2007: Message edited by: Kamal Arora ]
 
It's fun to be me, and still legal in 9 states! Wanna see my tiny ad?
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic