-
Notifications
You must be signed in to change notification settings - Fork 412
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[3, 4 단계 - 체스] 져니(이지원) 미션 제출합니다. #604
Merged
Merged
Changes from all commits
Commits
Show all changes
76 commits
Select commit
Hold shift + click to select a range
b63b1e3
feat: service layer를 제거하고 dto에 대한 static mapper 클래스를 생성한다
Cl8D 4427291
fix: 아군 기물인지 검증하는 기능에 대해 불필요한 예외 발생 로직을 제거한다
Cl8D fb8682f
feat: 점수에 대해 관리하는 클래스를 생성한다
Cl8D 9e0f5dd
feat: 체스말이 킹인지 확인하는 기능을 추가한다
Cl8D 107aaad
feat: 현재 체스판에 살아있는 킹을 조회한다
Cl8D e6476e8
feat: 현재 체스 게임에서 킹이 살아있는지 판단한다
Cl8D 2bbad93
feat: 각 기물의 점수에 대해 더하고, 빼고, 곱하는 기능을 추가한다
Cl8D 93ea4b9
feat: 체스말이 폰인지 판단한다
Cl8D 2920874
feat: 흑진영, 백진영의 체스판을 반환한다
Cl8D 04e9920
feat: 폰이 이동이나 공격할 때 앞으로 이동하는지 검증한다
Cl8D bb61e76
feat: 현재 체스판의 각 진영에 대한 점수를 계산한다
Cl8D a15f708
feat: status에 대한 명령어와 테스트를 추가한다
Cl8D c183445
feat: 각 진영의 점수와 이긴 진영에 대해서 출력한다
Cl8D 54ff520
feat: 킹이 사망하였다면 게임의 진행 상태를 false로 만든다
Cl8D 47be1dc
feat: 게임이 시작 상태일 때 사용자가 입력한 명령어가 status면 예외가 발생한다
Cl8D 75079e7
feat: EndController의 생성자에 대해 접근 제어자를 변경한다
Cl8D 62a1df9
feat: 킹이 모두 살아있는 경우 게임의 결과에 대해 출력하는 기능을 추가한다
Cl8D ca5389e
feat: 게임이 움직임 상태일 때 status를 입력하면 게임 결과를 출력하도록 제어한다
Cl8D 3575b90
docs: 기물에 대한 기능 명세서를 수정한다
Cl8D 9f2ba13
refactor: 명령어를 입력받는 기능의 네이밍을 변경한다
Cl8D 23d07fe
docs: 기능 명세서를 수정한다
Cl8D 8eee586
build: mysql, snakeyaml dependency를 추가한다
Cl8D f886775
feat: DB 연결에 필요한 프로퍼티 정보를 관리한다
Cl8D 74cfdd1
feat: 사용자의 이름 길이에 대한 검증 기능을 추가한다
Cl8D ec032ea
feat: 쿼리에 따라 1개의 결과를 조회하는 기능을 추가한다
Cl8D 265e0d2
feat: 사용자의 이름을 기준으로 사용자 엔티티를 조회한다
Cl8D 737f81d
feat: 사용자의 정보를 삽입하는 기능을 추가한다
Cl8D 832eba9
feat: 사용자가 입력한 이름이 이미 존재하는지 검증한다
Cl8D 0661b08
feat: 사용자의 이름을 바탕으로 사용자의 정보를 삽입한다
Cl8D 618bd08
fix: 자동으로 생성된 키를 반환하도록 옵션을 추가한다
Cl8D a0fba3c
feat: 사용자의 정보가 이미 존재할 경우 존재하는 아이디를 반환하도록 수정한다
Cl8D 113b388
refactor: 패키지 이동을 진행한다
Cl8D 3f5eb19
feat: 사용자의 아이디를 기준으로 체스 게임을 조회한다
Cl8D d5a4334
feat: final 키워드를 붙인다
Cl8D beb6363
feat: 체스 게임 아이디를 기준으로 체스말 리스트의 정보를 조회한다
Cl8D cb34b70
feat: pieceEntity에서 체스판을 생성하는 mapper class를 추가한다
Cl8D 9d2914b
feat: 체스 게임 아이디를 기준으로 체스판 정보를 조회한다
Cl8D 22d66a8
feat: 체스판 조회 시 ChessBoard를 반환하도록 변경한다
Cl8D 9707f95
feat: 사용자의 아이디에 해당하는 체스 게임이 존재하면 해당 게임을 반환하고, 아니라면 새 게임을 반환한다
Cl8D e394f37
refactor: 메서드 이름을 변경한다
Cl8D 0eb3004
feat: 입력으로 들어온 체스 게임에 대한 체스말의 정보를 저장한다
Cl8D 9f08e21
feat: 사용자가 현재 진행 중인 체스 게임을 저장한다
Cl8D eca3a55
test: 사용자 정보에 대한 테스트 로직을 변경한다
Cl8D 33a1f83
test: 체스 게임에 대한 테스트 로직을 변경한다
Cl8D 4649903
feat: 입력으로 들어온 체스 게임에 대해 특정 위치에 존재하는 체스말의 정보를 제거한다
Cl8D 36dfe42
feat: 체스 게임 아이디에 해당하는 체스말 정보를 제거한다
Cl8D 0a6c3f2
feat: 체스 게임 아이디에 해당하는 게임의 현재 진영을 업데이트한다
Cl8D 2e98cfa
test: mapper 테스트에 대한 코드를 수정한다
Cl8D 04fb202
feat: 사용자의 아이디에 해당하는 체스 게임을 제거한다
Cl8D a56e8ab
feat: chessGame의 생성자에서 진영을 받아올 수 있도록 수정한다
Cl8D 6f01133
fix: delete 연산 시 key를 받아오지 않는 것을 수정하기 위해 예외 발생 로직을 변경한다
Cl8D 7ad0aa6
feat: 사용자의 아이디를 기준으로 체스 게임을 조회한다
Cl8D 121bc27
feat: 체스말 정보를 바탕으로 체스말을 저장한다
Cl8D c623a30
feat: 입력받은 위치에 해당하는 체스말을 제거한다
Cl8D 7df4018
feat: 체스판의 모든 기물을 저장한다
Cl8D ec1db9c
feat: 체스 게임 아이디에 해당하는 모든 기물을 제거한다
Cl8D 06bf99d
feat: 체스말 정보를 바탕으로 체스말을 저장한다
Cl8D 1c461e7
feat: 체스 게임 아이디에 해당하는 진영 정보를 업데이트한다
Cl8D 6593a07
feat: 입력받은 위치에 해당하는 체스말을 제거한다
Cl8D cb18d5d
feat: 사용자의 아이디에 해당하는 체스 기물과 체스판 정보를 제거한다
Cl8D e8390b5
feat: 서비스의 생성을 관리하는 클래스를 생성한다
Cl8D d4aeaea
feat: 사용자에게 이름을 입력받는 기능을 추가한다
Cl8D 89913cd
feat: ServiceManager에 대한 mock 객체를 생성한다
Cl8D 165e847
feat: 이동 시 게임에 대한 정보를 저장한다
Cl8D 1d433e8
feat: 체스판 출력 기능을 추가한다
Cl8D 7129d4a
refactor: ScoreVO와 Service 인터페이스의 네이밍을 변경한다
Cl8D 4c2ccfb
feat: 체스판의 출력 기능을 핸들러에게 위임한다
Cl8D a35e743
feat: chessGame을 인자로 관리하지 않도록 변경한다
Cl8D 8745349
refactor: 메서드에 대한 네이밍을 변경한다
Cl8D 69d4c58
test: assertAll로 리팩터링을 진행한다
Cl8D a44da58
feat: @BeforeAll을 @BeforeEach로 변경한다
Cl8D e58e270
feat: entity의 equals, hashcode를 제거한다
Cl8D c2a1f45
refactor: long에 대한 불필요한 wrapper 형을 제거한다
Cl8D becd15d
refactor: save에 대한 네이밍을 insert로 변경한다
Cl8D e0bc4d9
fix: ChessGame에 대한 equals, hashcode 재정의를 삭제한다
Cl8D fe690b2
feat: MoveController에 존재하던 db 관련 로직을 서비스에게 위임한다
Cl8D File filter
Filter by extension
Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,15 @@ | ||
package chess; | ||
|
||
import chess.controller.ChessHandler; | ||
import chess.service.ChessBoardService; | ||
import chess.service.PieceService; | ||
import chess.service.PositionService; | ||
import chess.database.JdbcTemplate; | ||
import chess.database.properties.ChessProperties; | ||
import chess.service.ServiceManager; | ||
|
||
public final class ChessApplication { | ||
public static void main(String[] args) { | ||
final PieceService pieceService = new PieceService(); | ||
final PositionService positionService = new PositionService(); | ||
final ChessBoardService chessBoardService = new ChessBoardService(pieceService, positionService); | ||
final ChessHandler chessHandler = new ChessHandler(chessBoardService); | ||
final ChessProperties chessProperties = new ChessProperties(); | ||
final ServiceManager serviceManager = new ServiceManager(new JdbcTemplate(chessProperties)); | ||
final ChessHandler chessHandler = new ChessHandler(serviceManager); | ||
chessHandler.run(); | ||
} | ||
} |
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
프로퍼티의 경우 yml로 관리하기 위해서 별도의 라이브러리를 설치하여 진행하였는데, 혹시 구현 요구사항에 위반되는 내용이라면 변경하겠습니다! 🙇♀️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
아닙니다. 저는 사용해도 무방하다고 생각합니다!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
runtimeOnly, implementation 차이를 알고 사용하신걸까욥?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
runtimeOnly는 runtime 때 해당 dependency를 불러오는 것이고, implementation은 컴파일 시점부터 rumtime 때까지 해당 dependency가 유지되는 것이라고 생각했습니다! DB 관련 depdency의 경우 컴파일 시점에서는 해당 의존성이 필요없고 실제로 동작했을 때 DB 관련 커넥션들을 맺으면서 필요하기 때문에 주로 runtimeOnly로 선언하는 것으로 알고 있습니다 🫠...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
혹여나, 그냥 복붙해서 넣으신건가 해서 한번 여쭤봤어요ㅎㅎ.. 무엇이든 파악하고 쓰셨으면 해서요ㅎㅎ👍