Open
Conversation
|
해당 의견에 동의합니다. 의존성 역전에서의 나쁜 예시라면 해당 링크를 참고했습니다: 링크 |
|
저도 의견 주신 내용들처럼 예시가 DIP보다는 캡슐화에 가까워서 적절한 예시와는 거리가 있는 것 같습니다. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What I did
의존성 역전 원칙 (DIP)에 대한 번역을 진행했습니다.
Problem
번역 자체는 큰 문제는 없어 보이지만, 이 예제가 과정 의존성 역전을 이해하기에 명확한 예시인지 모르겠습니다.
제가 생각하는 의존성 역전이란, 클래스를 상속할 때 최대한 추상화의 단계가 높은 (상위 클래스) 클래스를 의존해야 한다는 것 입니다.
하지만, 예제는 그것과는 거리가 좀 있어 보입니다.