• 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
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Practical API Design chapter 3 Determining what makes a good API

 
Bartender
Posts: 3648
16
Android Mac OS X Firefox Browser Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In this chapter, Jaroslav (the author) listed some traits in checking the quality of an API, namely:
* Comprehensibility = ease of understanding (purpose, documentation, objective/goal etc)
* Consistency = somewhat along the lines of backward compatible, future release doesn't break existing code
* Discoverability = ability for the user/programmer to "use" the API
* Simple tasks should be easy = somewhat along the lines of having a cohesive class/interface, separate into different package when needed
* Preservation of investment = treating users well, build a community, increase user adoption

Given the above, I would also add testability (ability to function as expected) and interoperability (ability to interact/cooperate with other classes/interfaces).

Actually the author has a chapter on each of these areas in the book.

What other traits do you see when checking the quality of an API?
 
Sheriff
Posts: 16910
283
Mac Android IntelliJ IDE Eclipse IDE Spring Debian Java Ubuntu Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The only other thing that comes to mind is safety/security. An API should lead you towards doing the right things; it should lead you into writing code that is unlikely to come back and bite you in the behind. But you could also see this quality as a result of being simple, intuitive, and flexible.
 
Lasagna is spaghetti flvored cake. Just like this tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic