Skip to content
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

๐Ÿš€ Step1 - ๊ฒฝ๋กœ ์กฐํšŒ ํƒ€์ž… ์ถ”๊ฐ€ #338

Open
wants to merge 9 commits into
base: hugehoo
Choose a base branch
from

Conversation

hugehoo
Copy link

@hugehoo hugehoo commented Apr 4, 2023

์•ˆ๋…•ํ•˜์„ธ์š” ๋ฆฌ๋ทฐ์–ด๋‹˜
์‹œ๊ฐ„์ด ๋งŽ์ด ๋Šฆ์—ˆ์ง€๋งŒ, ๋Šฆ๊ฒŒ๋ผ๋„ ์™„์ฃผํ•˜๊ณ ์ž PR ์˜ฌ๋ฆฝ๋‹ˆ๋‹ค.
๊ณผ์ •์ด ๋๋‚ฌ์Œ์—๋„ ๋ฆฌ๋ทฐ ํ•ด์ฃผ์…”์„œ ์ •๋ง ๊ฐ์‚ฌํ•ฉ๋‹ˆ๋‹ค!

  • ์‚ฌ์ „ ์‹ค์Šต ์ด๋ฏธ์ง€: PathDocumentation์„ ๋ฌธ์„œํ™”ํ–ˆ์Šต๋‹ˆ๋‹ค.
    image

Copy link

@heesunjeong heesunjeong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

์•ˆ๋…•ํ•˜์„ธ์š” :) ๋งˆ์ง€๋ง‰ ๋ฏธ์…˜ ๋ฆฌ๋ทฐ๋ฅผ ๋งก๊ฒŒ๋œ ์ •ํฌ์„ ์ž…๋‹ˆ๋‹ค! ๋งˆ์ง€๋ง‰๊นŒ์ง€ ์ž˜ ๋ถ€ํƒ๋“œ๋ ค์š”~!
๋ฌธ์„œ์™€ ์‹ค์Šต๊ณผ 1๋‹จ๊ณ„ ๋ฏธ์…˜ ๊ตฌํ˜„ ์ž˜ ํ•ด์ฃผ์…จ์Šต๋‹ˆ๋‹ค! ๐Ÿ‘
๋ช‡๊ฐ€์ง€ ์กฐ๊ธˆ ๋” ์ฐธ๊ณ ํ•ด๋ณด์‹œ๋ฉด ์ข‹์„ ๋ถ€๋ถ„์„ ์ฝ”๋ฉ˜ํŠธ๋กœ ์ถ”๊ฐ€ํ–ˆ๋Š”๋ฐ์š”, ํ™•์ธ๋ถ€ํƒ๋“œ๋ ค์š”!

private List<Line> lines;

public SubwayMap(List<Line> lines) {
public DistancePathFinder(List<Line> lines) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DistancePathFinder์™€ DurationPathFinder์˜ ๋กœ์ง์ด Section์˜ ์–ด๋–ค ๊ฐ’์„ ์‚ฌ์šฉํ•˜๋Š”์ง€๋งŒ ๋‹ค๋ฅด๊ณ  ๊ฑฐ์˜ ๋™์ผํ•œ๋ฐ์š”,
์ค‘๋ณต์„ ์ œ๊ฑฐํ•˜๋Š” ๋ฆฌํŒฉํ† ๋ง์„ ๋„์ „ํ•ด๋ณด์‹œ๋ฉด ์–ด๋–จ๊นŒ์š”? ํ•œ๊ฐ€์ง€ ๋ฐฉ๋ฒ•์œผ๋กœ๋Š” enum์„ ์กฐ๊ธˆ ๋” ํ™œ์šฉํ•ด๋ณด์…”๋„ ์ข‹์„ ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค :)

Comment on lines +80 to +81
int ์ตœ์†Œ์‹œ๊ฐ„ = Math.min(๊ฒฝ๋กœ_1_์ตœ์†Œ์‹œ๊ฐ„, ๊ฒฝ๋กœ_2_์ตœ์†Œ์‹œ๊ฐ„);
assertThat(duration).isEqualTo(์ตœ์†Œ์‹œ๊ฐ„);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ํ…Œ์ŠคํŠธ ์ฝ”๋“œ์—์„œ๋Š” ๋กœ์ง์„ ์‚ฌ์šฉํ•˜๋Š” ๊ฒƒ๋ณด๋‹ค ํ•˜๋“œ์ฝ”๋”ฉ๋œ ๊ฐ’์œผ๋กœ ๊ฒ€์ฆํ•ด๋ณด์‹œ๋ฉด ์–ด๋–จ๊นŒ์š”?
https://jojoldu.tistory.com/615

.when().get("/paths?source={sourceId}&target={targetId}&searchType={type}", source, target, type)
.then().log().all().extract();
}

private ExtractableResponse<Response> ๋‘_์—ญ์˜_์ตœ๋‹จ_๊ฑฐ๋ฆฌ_๊ฒฝ๋กœ_์กฐํšŒ๋ฅผ_์š”์ฒญ(Long source, Long target) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PathSteps์„ ํ™œ์šฉํ•˜์—ฌ ์ค‘๋ณต์„ ์ค„์—ฌ๋ณผ ์ˆ˜ ์žˆ์„ ๊ฒƒ ๊ฐ™์Šต๋‹ˆ๋‹ค~!


@DisplayName("Subway Path TEST ๋ฌธ์„œํ™”")
public class PathDocumentation extends Documentation {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

๋” ํ’๋ถ€ํ•œ ๋ฌธ์„œ๋ฅผ ์œ„ํ•ด์„œ ์Šค๋‹ˆํŽซ์„ ํ™œ์šฉํ•ด์„œ ๋ฌธ์„œ๋ฅผ ์ปค์Šคํ…€ํ•ด๋ณด์‹œ๋ฉด ์–ด๋–จ๊นŒ์š”?!

import nextstep.subway.domain.SectionEdge;
import nextstep.subway.domain.Station;

public class DistancePathFinder implements PathFinder {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

์ƒˆ๋กœ ์ž‘์„ฑํ•ด์ฃผ์‹  ์ฝ”๋“œ์— ๋Œ€ํ•ด์„œ ๋‹จ์œ„ํ…Œ์ŠคํŠธ๋ฅผ ์ž‘์„ฑํ•ด๋ณด์‹œ๋ฉด ์–ด๋–จ๊นŒ์š”?!

}

/**
* Circular ๊ฒฝ๋กœ๋Š” ์ƒ์„ฑ ๋ถˆ๊ฐ€.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

์ž‘์„ฑํ•ด์ฃผ์…จ๋˜ ์ธ์ˆ˜์กฐ๊ฑด์„ ์‚ญ์ œํ•˜์‹  ์ด์œ ๊ฐ€ ์žˆ์œผ์‹ค๊นŒ์š”? ๐Ÿ˜ข

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants