seungeon Kim
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Make a copy
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Make a copy Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    그룹 피어세션 활동 시간표 개인 활동 발표 (10분씩 * 4명) 총 40분 질의응답 20분 그룹 피어세션 활동 가이드 각자 자신의 설계 과정, 구현 과정을 10분내로 그룹에게 설명하세요. 공동작업 https://hackmd.io 추천 요구사항을 해결하기 위한 구조를 설명하세요 결정하고 구현하기 이전에 고려했던 다른 구조가 있었으면 (최종 버전보다는 짧게) 공유하세요 설계한 구조를 구현하기 위해 신경썼던 부분을 설명하세요 구현하면서 바뀐 부분이 있으면 (최종 방식보다는 간단하게) 공유하세요 다른 사람의 설명을 들으면서 궁금한 사항을 질문 형태로 기록합니다 모든 사람의 발표가 끝나고 난 후, 질의응답 시간에는 질문을 읽고 토론합니다 토론에 대해 꼭 결론이 있을 필요는 없습니다 그룹 피어세션 리포트 작성하기 다음과 같은 내용을 포함하며 형식은 자유롭게 작성하세요 개인별 브랜치 링크 개인별 설계 의도 소개 개인별 구현 방식 설명 질의응답 항목과 의견들 # Ryan Son - 요구사항을 읽고 Board, Pawn은 필요하겠다고 판단하여 먼저 정의 - 체스판 초기화 -> 테스트, Board 이동로직/점수 계산 -> 테스트, 사용자 입력 검증 및 파싱 -> 테스트 순으로 구현 ![image](https://user-images.githubusercontent.com/69730931/192848780-4ef726de-3f7b-4e78-a736-d6ed56aff1ce.png) ## 사용자 입력 읽기 및 파싱 - `CommandReader`가 사용자 입력을 받고 `CommandParser`가 문자열로 된 사용자 입력을 앱 도메인에서 이용하는 모델(`MoveCommand`) 로 변경합니다. - `MoveCommand`는 출발점과 목적지를 가진 모델로, `rank`와 `file`값을 정수형으로 가지고 있습니다. ## 체스판 초기화, 체스말 이동, 점수 계산 및 콘솔 출력 (`Board`) - 체스판 타입인 `Board`는 요구사항대로 체스판을 초기화하는 이니셜라이저와 테스트를 위해 주어진 체스판 상태로 초기화하는 이니셜라이저로 생성자를 구성하였습니다. - 체스판 위의 체스말을 이동시키는 `move(from:to:)`, 점수를 계산하여 출력하는 `currentPoints()`와 콘솔에 체스판 현황을 출력하는 `display()` 메서드를 제공합니다. ## 체스말 현재는 `Pawn`이 유일한 체스말 타입입니다. `Pawn`은 체스말 타입의 요구사항을 명세한 `Piece` 프로토콜을 준수합니다. `Piece` 프로토콜은 체스말마다 다르게 구현될 필요가 있는 사항이 아니라면 일부 기본구현을 제공합니다. # Mason ## 설계 구현 설명 - 요구사항을 꼼꼼히 확인하여 도식화 진행 ![](https://i.imgur.com/KKlBN8I.png) ![](https://i.imgur.com/TyovRWI.png) - 단계를 구분하려면 역할을 나누어야겠다고 생각함. - 뷰나 출력을 구현하지 않으니 다른 곳에서도 사용할 수 있도록 구성하는 것을 의도 - 입력이 제대로 되었는지, 내부에서 이동 가능한지 검증(해당 위치로 갈 수 있는지) - Board를 중심으로 로직 처리를 하려고 의도 - Board가 혼자서 처리하는 것이 아니라 역할을 나누어주려 노력함 - Primitive type을 사용하기보다 커스텀 타입을 정의하도록 노력함(Pawn, Piece, Rank) - 상위에서 하위로 로직을 구성 (Board부터) - 추상(프로토콜) -> 구체(구현) - private method 테스트하기 어려우니 RankManager와 같은 하위 타입으로 구분하여 역할을 위임 (제대로 이해한 것이 맞는지?) ## 받은 피드백 - MockBoard를 사용하면 의도한 동작을 테스트할 수 있을 것이라 피드백 받음 - pawn.color.description -> pawn.description - Rank, File 타입으로 나누었으니 Position은 필요 없을 수 있다. # taemin Yun # seungeon Kim https://github.com/Seungeon-Kim/swift-chess-app/tree/feature-step1 ### Command 사용자의 명령이 유효한지 확인하고, 위치의 이동을 위한 Position 모델을 반환해 줍니다. ### Pawn 폰의 색상(Color)과 현재 위치(Position)를 나타내는 멤버 변수를 가집니다. ### Position File / Rank를 멤버변수로 가지고 있으며, 각 멤버 변수는 8x8 사이즈의 chessBoard의 범위를 초과하는 경우를 막기위해 enum 타입으로 정의되어있습니다. ### ChessBoard 체스판 위에 올라가는 pawn들의 관리 / 생성 / 삭제 / 이동을 관리해줍니다. ### ChessGame 체스 게임의 룰과 진행을 위한 관리를 해줍니다. ### Error 상황에 따른 에러메세지와 코드를 관리하기 위한 모델입니다 ### 질의 - pawn 생성 테스트를 어떻게 했는지?? - equaptable을 채택한 pawn과 동일한 비교 대상을 생성하여 테스트를 진행 ## 설계 구현 설명 - 인터페이스 구현은 안된 상태 - 요구사항을 구현하는 것에 집중함 - ChessBoard, ChessGame으로 구분. 하나로 합치기에는 역할이 너무 클 것으로 예상했었음. - ChessGame: 게임 룰, 플레이어 관리 - display()는 단순 출력이므로 테스트를 작성하지 않아도 될 것으로 생각했으나 잘못 보여질 수도 있으므로 테스트를 추가하기로 함. - 게임에서 Pawn을 생성하는 것이 옳을 것 같아 Game에서 체스말 생성을 해줌 ## 받은 피드백 - String을 전달받는 팩토리 메서드를 구성하기보다 이니셜라이저를 정의해서 사용할 것을 피드백 받음 - 이동 로직 find, remove, add 순으로 진행하는데, ... - black, white pawn 배열을 따로 정의 -> - 커맨드 생성 시 에러가 발생하면 nil 보다 에러를 반환하는 것이 더 좋지 --- # Week 2 다음과 같은 내용을 포함하며 형식은 자유롭게 작성하세요 개인별 브랜치 링크 개인별 설계나 구현 개선사항 그 밖의 질의응답 항목과 의견들 지난 2주동안 설계, 구현, 개선 과정에 대한 소감 # Ryan Son - Taemin: 객체에 테스트를 위한 init이 있군요?! - 추상화하여 Mock 타입을 만들어 테스트를 위한 체스말을 세팅하는 형식으로 변경해보겠습니다. - Taemin: 테스트를 위한 클로저?! - 타입 자체가 - Taemin: 저도 맨 윗줄이 rank 1로 했어요. - seungeon: 이렇게 메모 남기는것도 좋네요! # Mason # taemin Yun uml -> test -> comments - Taemin: 다들 목 객체 어떻게 만드십니까들?! - Ryan: 순서대로 설명해주셔서 쉽게 이해할 수 있었습니다! - Ryan: 테스트 명세는 어떻게 나누셨나요? - Ryan: isBlocked(from:to:board:) 로직을 설명해주실 수 있으실까요? # Seungeon-Kim - Ryan: class와 sturct를 사용하는 기준은 무엇인가요? - 속성들의 Semantic type?(value / reference) 여부 - mutating 빈도 위 내용 정도로 구분합니다. - Ryan: 방향과 재귀를 이용한 MovablePosition 계산 방법이 인상적이었습니다. - Taemin: 맞아요 감사합니다! - Taemin: Board가 아니라 Game에서 실제 게임이 이루어지는 거군요? - 넵, Board는 단순히 piece에 대한 CRUD?정도만 관리하고 체스 게임의 진행은 Game에서 이루어집니다 - Taemin: Position { get } 이렇게 가능하지 않나요? - get-only property라서 position의 변경이 불가능해집니다.

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully