Skip to content

Commit

Permalink
chore: MockStageArtistsGenerator Javadoc ์ถ”๊ฐ€
Browse files Browse the repository at this point in the history
  • Loading branch information
seokjin8678 committed Apr 14, 2024
1 parent 11dc13a commit 541c543
Showing 1 changed file with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,17 @@
@Component
public class MockStageArtistsGenerator {

/**
* ์˜์†๋˜์ง€ ์•Š์€ ์ƒํƒœ์˜ StageArtist ๋ชฉ๋ก์„ ์ƒ์„ฑํ•ฉ๋‹ˆ๋‹ค. <br/> StageArtist๋Š” Stage์™€ Artist์˜ ์‹๋ณ„์ž๊ฐ€ ํ•„์š”ํ•˜๋ฏ€๋กœ, ์ธ์ž๋กœ ๋“ค์–ด์˜ค๋Š” Stage, Artist๋Š” ์˜์†๋œ ์ƒํƒœ์—ฌ์•ผ
* ํ•ฉ๋‹ˆ๋‹ค. <br/> ๊ณต์—ฐ์— stagePerArtist ๋งŒํผ ์•„ํ‹ฐ์ŠคํŠธ๋ฅผ ์ฐธ์—ฌ์‹œํ‚ค๋Š”๊ฒŒ ๋ถˆ๊ฐ€๋Šฅํ•  ๊ฒฝ์šฐ, ๊ฐ ๊ณต์—ฐ ๋ณ„ ์ตœ์†Œ 1๋ช…์€ ์ฐธ๊ฐ€ํ•˜๋Š” ๊ฒƒ์„ ๋ณด์žฅํ•ฉ๋‹ˆ๋‹ค. <br/> ๋”ฐ๋ผ์„œ, stages.size() >
* artists.size() ์ด๋ฉด ์˜ˆ์™ธ๊ฐ€ ๋ฐœ์ƒํ•ฉ๋‹ˆ๋‹ค. <br/> ์ƒ์„ฑ๋œ StageArtist ๋ชฉ๋ก์—๋Š” ์ค‘๋ณต๋œ Artist๊ฐ€ ์กด์žฌํ•˜์ง€ ์•Š์Šต๋‹ˆ๋‹ค.<br/>
*
* @param stagePerArtist ๊ฐ ๊ณต์—ฐ์— ์ฐธ์—ฌ๋  ์•„ํ‹ฐ์ŠคํŠธ์˜ ์ˆ˜
* @param stages ์˜์† ์ƒํƒœ์˜ ์•„ํ‹ฐ์ŠคํŠธ๊ฐ€ ์ฐธ์—ฌ๋  ๊ณต์—ฐ ๋ชฉ๋ก
* @param artists ์˜์† ์ƒํƒœ์˜ ๊ณต์—ฐ์— ์ฐธ์—ฌํ•  ์•„ํ‹ฐ์ŠคํŠธ ๋ชฉ๋ก
* @return ์ค‘๋ณต๋œ Artist๊ฐ€ ์—†๋Š” ์˜์†๋˜์ง€ ์•Š์€ StageArtist ์—”ํ‹ฐํ‹ฐ ๋ฆฌ์ŠคํŠธ
* @throws UnexpectedException ๊ณต์—ฐ์˜ ๊ฐœ์ˆ˜๊ฐ€ ์•„ํ‹ฐ์ŠคํŠธ์˜ ๊ฐœ์ˆ˜๋ฅผ ์ดˆ๊ณผํ•˜๋ฉด
*/
public List<StageArtist> generate(int stagePerArtist, List<Stage> stages, List<Artist> artists) {
if (stages.size() > artists.size()) {
throw new UnexpectedException("๊ณต์—ฐ์˜ ๊ฐœ์ˆ˜๋Š” ์•„ํ‹ฐ์ŠคํŠธ์˜ ๊ฐœ์ˆ˜๋ฅผ ์ดˆ๊ณผํ•  ์ˆ˜ ์—†์Šต๋‹ˆ๋‹ค.");
Expand Down

0 comments on commit 541c543

Please sign in to comment.