boundaries dan sugalski [email protected] november 8, 2003
TRANSCRIPT
BoundariesBoundaries
November 8, 2003
BoundaryBoundary
Pronunciation: 'baun-d(&-)rEFunction: nounInflected Form(s): plural -ariesDate: 1626: something (as a line,
point, or plane) that indicates or fixes a limit or extent
Boundaries are everywhereBoundaries are everywhere
• Functions• Source Modules• CPU modes• Programs• Languages• People• Concepts
Boundaries provideBoundaries provide
• Categorization• Isolation• Inflection points• Constraint• Safety• Domain separation
BoundariesBoundaries
• Used properly, they provide structure and framework
• Used improperly, they’ll strangle the life out of a project
• Which is which is always up for argument
Reality CheckReality Check
• The problem’s just too big to fit in your brain all at once
• Unless it’s a very small problem• Or a scary-sized brain
The landscape isn’t mobileThe landscape isn’t mobile
• “Problem points” are linked• They can be moved (some)• They exist whether you want to
consider them or not
Division of LaborDivision of Labor
• Who does what• Who doesn’t do what• Who provides what to whom• Who has to understand what
API segregationAPI segregation
• What you have to know to use a library
• What data belongs to whom• How to cross the boundary• For code, defines part of the
boundary
ParadigmsParadigms
• Different languages act differently• Drawing boundaries keeps things
separate• Beats having to think in Forth, C,
Scheme, Prolog, APL, and Smalltalk simultaneously
Poor definition can be harmful
Poor definition can be harmful
• Sloppy APIs• Limits on forward changes• Confusion amongst users• Confusion amongst developers• Force extra work
Use them to your advantageUse them to your advantage
• Partition problem spaces to fit your brain
• …And other people’s brains• Install inflection points• Provide guarantees• Hide cheating