├── .gitignore ├── .vscode └── settings.json ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── chapter01_strategy ├── duck.py └── readme.md ├── chapter02_observer ├── readme.md └── weather.py ├── chapter03_decorator ├── coffee.py └── readme.md ├── chapter04_factory ├── pizza_abstract_factory.py └── readme.md ├── chapter05_singleton ├── chocolate.py └── readme.md ├── chapter06_command ├── readme.md └── remote_undo.py ├── chapter07_adapter_facade ├── __init__.py ├── duck.py ├── duck_adapter.py ├── facade │ ├── __init__.py │ └── home_theatre_facade.py ├── home_theatre.py ├── readme.md └── subcomponents │ ├── __init__.py │ └── separates.py ├── chapter08_template ├── barista.py └── readme.md ├── chapter09_iterator_composite ├── composite.py ├── menus.py └── readme.md ├── chapter10_state ├── gumballstate.py └── readme.md ├── chapter12_compound ├── clap.wav └── djview.py ├── chapter14_leftover └── readme.md ├── extra_result ├── broken_config.json ├── company_config.json ├── filereader.py ├── readme.md └── user_config.json ├── images └── learning.oreilly.jpg └── requirements.txt /.gitignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/.gitignore -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "python.formatting.provider": "black" 3 | } -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/CONTRIBUTING.md -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/LICENSE -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/README.md -------------------------------------------------------------------------------- /chapter01_strategy/duck.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter01_strategy/duck.py -------------------------------------------------------------------------------- /chapter01_strategy/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter01_strategy/readme.md -------------------------------------------------------------------------------- /chapter02_observer/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter02_observer/readme.md -------------------------------------------------------------------------------- /chapter02_observer/weather.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter02_observer/weather.py -------------------------------------------------------------------------------- /chapter03_decorator/coffee.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter03_decorator/coffee.py -------------------------------------------------------------------------------- /chapter03_decorator/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter03_decorator/readme.md -------------------------------------------------------------------------------- /chapter04_factory/pizza_abstract_factory.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter04_factory/pizza_abstract_factory.py -------------------------------------------------------------------------------- /chapter04_factory/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter04_factory/readme.md -------------------------------------------------------------------------------- /chapter05_singleton/chocolate.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter05_singleton/chocolate.py -------------------------------------------------------------------------------- /chapter05_singleton/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter05_singleton/readme.md -------------------------------------------------------------------------------- /chapter06_command/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter06_command/readme.md -------------------------------------------------------------------------------- /chapter06_command/remote_undo.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter06_command/remote_undo.py -------------------------------------------------------------------------------- /chapter07_adapter_facade/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /chapter07_adapter_facade/duck.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter07_adapter_facade/duck.py -------------------------------------------------------------------------------- /chapter07_adapter_facade/duck_adapter.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter07_adapter_facade/duck_adapter.py -------------------------------------------------------------------------------- /chapter07_adapter_facade/facade/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /chapter07_adapter_facade/facade/home_theatre_facade.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter07_adapter_facade/facade/home_theatre_facade.py -------------------------------------------------------------------------------- /chapter07_adapter_facade/home_theatre.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter07_adapter_facade/home_theatre.py -------------------------------------------------------------------------------- /chapter07_adapter_facade/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter07_adapter_facade/readme.md -------------------------------------------------------------------------------- /chapter07_adapter_facade/subcomponents/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /chapter07_adapter_facade/subcomponents/separates.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter07_adapter_facade/subcomponents/separates.py -------------------------------------------------------------------------------- /chapter08_template/barista.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter08_template/barista.py -------------------------------------------------------------------------------- /chapter08_template/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter08_template/readme.md -------------------------------------------------------------------------------- /chapter09_iterator_composite/composite.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter09_iterator_composite/composite.py -------------------------------------------------------------------------------- /chapter09_iterator_composite/menus.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter09_iterator_composite/menus.py -------------------------------------------------------------------------------- /chapter09_iterator_composite/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter09_iterator_composite/readme.md -------------------------------------------------------------------------------- /chapter10_state/gumballstate.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter10_state/gumballstate.py -------------------------------------------------------------------------------- /chapter10_state/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter10_state/readme.md -------------------------------------------------------------------------------- /chapter12_compound/clap.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter12_compound/clap.wav -------------------------------------------------------------------------------- /chapter12_compound/djview.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter12_compound/djview.py -------------------------------------------------------------------------------- /chapter14_leftover/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/chapter14_leftover/readme.md -------------------------------------------------------------------------------- /extra_result/broken_config.json: -------------------------------------------------------------------------------- 1 | { 2 | "broken file" 3 | -------------------------------------------------------------------------------- /extra_result/company_config.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/extra_result/company_config.json -------------------------------------------------------------------------------- /extra_result/filereader.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/extra_result/filereader.py -------------------------------------------------------------------------------- /extra_result/readme.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/extra_result/readme.md -------------------------------------------------------------------------------- /extra_result/user_config.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/extra_result/user_config.json -------------------------------------------------------------------------------- /images/learning.oreilly.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/dancergraham/HeadFirstDesignPatterns_python/HEAD/images/learning.oreilly.jpg -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | playsound == 1.2.2 --------------------------------------------------------------------------------