CS257 Software Design Wednesday, 26 October 2022 + Thinking about your data & features - Animals Who's the user? * 10-year-old who's into animals - evolutionary biologist - parent looking for pets - college students - middle school students trying to find a topic for their report - 10 minutes: - What features would the user want? - Your feature ideas - (??) pictures (eye-catching) - (!!) search feature: text input, ("bear" --> list of bear types that you can click on, thumbnails) - some way to search by ecosystem (savannah, taiga, rainforest...) - (!!) some way to search by map - glossary (alphabetical list of stuff) - mobile-friendly, especially tablets - (I don't know the UI yet) table linking predators to prey - pronunciation of the name, scientific name - animal sounds - table/something linking similar species click click click to EXPLORE the space of species - picture recognition - monetization (merch!) - quiz, games, achievements, etc. - search by attributes - user profile; save favorite animals, cultivate a giant squid as a pet... + IMPORTANT OBSERVATION - You don't actually know what your target audience wants so you should ask them - They kinda don't know either + Next - Get your vision of your web app ready - Learn how to render a web page using HTML/CSS - Design an API that provides service to your web application Implement that with Flask - Design a database to serve the API Implement that like we did for Olympics data - Put it all together + The word "interface" Your definitions - the window that you use to get data - the design -- multiple ways to get there e.g. you can search these things, but there might be multiple ... - a mediator for retrieval or interaction - an abstract interaction with the system e.g. code for accessing data without caring about the underlying details Two categories - User interface - the widgets, layout, appearance, "affordances", etc. that enable a person to interact with the software, its data, and its features - Software interface - "functional interface" -- the mechanism by which one of the code invokes a function elsewhere in the code def print_author(author): ''' Prints the author's name and dates to standard output ''' - "network interface" / usually involves a "protocol" client software wants to request a service from server software what language does the client use to articulate the request? what language does the server use to respond? "protocol" HTTP provides a protocol, and an API publishes an interface that uses HTTP as the request/response language GET /actor?name=adams HTTP/1.1 etc. + Architecture - Shaun, me, and our colleagues' code - "Design patterns" - Question: interface -