Brain Oriented Programming
This is a nice story, but the reality is that popular languages and libraries tend to expose API surfaces that are broad and shallow, not ones that are narrow and deep.<p>For example, a Python string object has something like 40 methods. I counted about 85 instance methods on org.joda.time.DateTime from Java.[1] Turning to JavaScript, every method in Underscore.js lives in a single gigantic namespace.[2]<p>Experience suggests two related factors that favor the proliferation of big, shallow APIs.<p>Modern IDEs offer rich auto-completion with pop-up docs. This makes it much easier to look at the available list of fields and methods and choose the one that&#x27;s appropriate.<p>A second, related reason is that IDEs generally <i>don&#x27;t</i> have tooling that is nearly as rich to help you identify the chain of calls you need to make to obtain an instance of some type that has the method you want. Do you get a Connection from a ConnectionContext, a ConnectionContextManager, or a ConnectionContextManagerCache? And how do you get one of those?<p>Shallow APIs and big namespaces tend to favor easy lookup. Deep APIs where every type only has a handful of methods make you memorize them.<p>[1] <a href="http:&#x2F;&#x2F;joda-time.sourceforge.net&#x2F;apidocs&#x2F;org&#x2F;joda&#x2F;time&#x2F;DateTime.html" rel="nofollow">http:&#x2F;&#x2F;joda-time.sourceforge.net&#x2F;apidocs&#x2F;org&#x2F;joda&#x2F;time&#x2F;DateT...</a><p>[2] <a href="https:&#x2F;&#x2F;underscorejs.org&#x2F;" rel="nofollow">https:&#x2F;&#x2F;underscorejs.org&#x2F;</a>