• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

name of class and interface

 
Ranch Hand
Posts: 594
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I read an article; it says that class name is always noun only.

Is it correct?

Then how a interface cane be named with noun?, interface contains only operations ,which is ,similar to verb ,then how a noun suit for verb??
 
Ranch Hand
Posts: 1936
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Interface name can be adjective like Runnable, Iterable.
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
@Jacob: Do you believe classes don't contain any verbs?
 
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If comments or questions are specifically addressing a particular participant, then please indicated this by including the participant's screen name in the post. This well help reduce the amount of confusion that somtimes arises in text/email communications.

Either way, interface class names can be anything, e.g. TDS34. Preferrably, the names should be descriptive but there is no compiler rule that mandates this.

However, the names of the methods declared in an interface class are usually "verb-like" and the name of the class itself is "noun-like."
reply
    Bookmark Topic Watch Topic
  • New Topic