Do Not Expose More Than You Want

From APIDesign

(Difference between revisions)
Jump to: navigation, search
(New page: Repeating basic advices present in every design book.)
Current revision (16:41, 25 May 2009) (edit) (undo)
 
(4 intermediate revisions not shown.)
Line 1: Line 1:
-
Repeating basic advices present in every design book.
+
== Have You Ever Wondered...? ==
 +
 
 +
Do you want to know some simple trick that will help you design better APIs? The [[Do Not Expose More Than You Want|chapter 5]] gives you one. It is very elementary, but very powerful. It also shows that the object oriented languages of today are not really optimized for API development and that there are many gotchas one needs to be aware of.
 +
 
 +
=== Friend Packages ===
 +
 
 +
Among others, [[Do_Not_Expose_More_Than_You_Want|this chapter]] introduces a [[Java]] [[APIDesignPatterns|API Design Pattern]] to join two packages into [[APIDesignPatterns:FriendPackages|friend relationship]].
 +
 
 +
=== [[Privileged API]] ===
 +
 
 +
One way to do not expose everything to everyone is to designed [[Privileged API|API]] that can be used only by [[Privileged API]] clients.

Current revision

Have You Ever Wondered...?

Do you want to know some simple trick that will help you design better APIs? The chapter 5 gives you one. It is very elementary, but very powerful. It also shows that the object oriented languages of today are not really optimized for API development and that there are many gotchas one needs to be aware of.

Friend Packages

Among others, this chapter introduces a Java API Design Pattern to join two packages into friend relationship.

Privileged API

One way to do not expose everything to everyone is to designed API that can be used only by Privileged API clients.

Personal tools
buy