๐ Object Oriented Programming, ํ๋ก๊ทธ๋จ์ Object ์ค์ฌ์ผ๋ก ๊ตฌ์ฑํ๋ ๊ฒ
- Program = Object์ ์ํธ์์ฉ
- Object = ๊ด๋ จ ์๋ ํจ์(์ฐ์ฐ)์ ๋ฐ์ดํฐ์ Set, Program์ ๊ตฌ์ฑํ๊ธฐ ์ํ ๋ถํ
- ๋ฉค๋ฒ ๋ณ์ โก๏ธ Good Independence (๋
๋ฆฝ์ฑ)
- Readability (๊ฐ๋ ์ฑ): ํ ๋ชจ๋์ ์ดํดํ๊ธฐ ์ํด ๋ค๋ฅธ ๋ชจ๋๋ค์ ์ดํดํ ํ์ ์์
- Safety (์์ ์ฑ): ๋ชจ๋ ์์ ๋ฐ์ดํฐ์ ๋ค๋ฅธ ๋ชจ๋๋ค์ด ์ ๊ทผํ์ง ์์์์ ๋ณด์ฅํ ์ ์์
- ์ค๊ณ๋ Top-down, ๊ตฌํ์ Bottom-up
โ Procedural (์ ์ฐจ ์งํฅ)
๋ฐ์ ์์
- Unstructured
- ์ ์ญ ๋ณ์ โก๏ธ Dependency (์์กด์ฑ)
gotoโก๏ธ SW Complexity (SW Crisis)- ์ฝ๋ ๋ฐ๋ณต โก๏ธ Bad Reusability (์ฌ์ฌ์ฉ์ฑ)
- Procedural
- Program = ๋ฐ์ดํฐ + ํจ์ ํธ์ถ์ Sequence
- ๋ฐ๋ณต๋๋ ์ฝ๋๋ฅผ ํจ์๋ก ๋ง๋ค์ด Reusability (์ฌ์ฌ์ฉ์ฑ)๋ฅผ ๋์
- Modular (Structured)
- Module = ๊ด๋ จ ์๋ ํจ์์ Set
- ํ๋ก๊ทธ๋จ์ Interface๋ฅผ ํตํด ํจ์ ์ฌ์ฉ
- Top-down, Divide & Conquer, Decomposition (๋ถํด)
- Module = ๊ด๋ จ ์๋ ํจ์์ Set
- OOP
๋ชฉ์
๋ฐฐ๊ฒฝ๊ณผ ๋์ผ
- ๊ธ๊ฒฉํ ๋์์ง SW Complexity (SW Crisis)์ ๋์ํ๊ธฐ ์ํจ
๊ฐ๋
- Abstraction (์ถ์ํ), Data Abstraction, Encapsulation (์บก์ํ), Information Hiding (์ ๋ณด ์๋)
- Maximize Cohesion (์์ง๋), Minimize Coupling (๊ฒฐํฉ๋)
- ๋์จํ๊ฒ ๊ฒฐํฉ๋ ๊ฐ์ฒด๋ค์ ์ํธ์์ฉ์ ํตํด ์์คํ ์กฐ์ง
- Inheritance (์์)
- Polymorphism (๋คํ์ฑ)