- the big picture -- what is proj 1 all about? - helpful to map it to a more real-world experience - humans are better at thinking about interactions w/ & relationships to other humans/the real world, than they are thinking about abstract stuff (web pages, classes, sets, etc.) - Design principle #1: principle of mimesis: try to structure software so as to reflect/correspond to the domain that you're modeling. (This is what object orientation was designed to support in the first place.) - in this case: think about a real-world scenario that mirrors the task at hand, then build objects to reflect that - example task: buying specialty items from a collectables store - store offers all sorts of collectables -- model trains, dolls, baseball cards, old music, etc. - customer wants to buy an original copy of the 1965 British release of the Beatles LP "Help". - goes to store front and makes the request to the salesperson - salesperson goes back to warehouse to see if they have that in stock - asks warehouse clerk for "Beatles AND LP AND Help AND Britain AND 1965" - warehouse clerk looks up - all bins marked "Beatles" - all bins marked "LP" - all bins marked "Help" - all bins marked "Britain" - all bins marked "1965" - takes the intersection of all of those bins to find the one that is the target - looks in that bin and finds, say, 5 items - reports back to sales clerk: "we have these 5 items matching your description" - sales clerk returns to customer: "we have these 5 items, and here's the order in which I suggest you examine them" - this gives us a view of two of the parts of the task: the UI (store front/salesperson) and the WEB DATABASE (warehouse/clerk). - more importantly, gives you a view of what the _interactions_ between these two modules are - in OO programming, you more-or-less think of an object as a "noun" and a method as a "verb" - when designing, think about what the nouns are in the problem ==> objects/classes, and what the verbs/actions are ==> methods - these interactions can be mapped almost directly into method calls - ** sequence diagram ** - illustrates the role of the Map in all of this - allows rapid "get" queries: words -> URLMap - so... Why do we want to use the java.util.Map version of a map?