kms

Interfaces and Layers

March 2, 2014

I’ve become much more interface-oriented than I used to be. Descriptions of the inputs and actions and outputs of methods with no code. I love writing that stuff. I also enjoy writing the code that implements it, but I do less of that nowadays than I used to. And of course it’s important to have had an experience doing that so you don’t design impossible specifications. You should have an idea what the implementation is going to look like as you design the interface. You should have an idea for the implementation. Then if someone comes along with a better one, that’s fine.

Guy Steele, Coders at Work, p. 343

[…] it seems like when you’re just building layer on top of another layer on top of another layer, you don’t really get the benefit of writing, say, a DFA. I think by necessity algorithms–new algorithms are just getting more complex over time. A new algorithm to do something is based on 50 other little algorithms. Back when I was a kid you were doing these little algorithms and they were fun. You could understand them without it being an accounting job where you divide it up into cases and this case is solved by this algorithm that you read about but you don’t really know and on and on. So it’s different. I really believe it’s different and most of it is because the whole thing is layered over time and we’re dealing with layers. It might be that I’m too much of a curmudgeon to understand layers.

Ken Thompson, Coders at Work, p. 483