-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
4205cf1
commit 5e3fd2d
Showing
1 changed file
with
32 additions
and
0 deletions.
There are no files selected for viewing
32 changes: 32 additions & 0 deletions
32
src/main/java/team7/inplace/global/exception/code/BannerErrorCode.java
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 |
---|---|---|
@@ -0,0 +1,32 @@ | ||
package team7.inplace.global.exception.code; | ||
|
||
import org.springframework.http.HttpStatus; | ||
|
||
public enum BannerErrorCode implements ErrorCode { | ||
NOT_FOUND("B001", "배너를 찾을 수 없습니다.", HttpStatus.NOT_FOUND); | ||
|
||
private final String code; | ||
private final String message; | ||
private final HttpStatus httpStatus; | ||
|
||
BannerErrorCode(String code, String message, HttpStatus httpStatus) { | ||
this.code = code; | ||
this.message = message; | ||
this.httpStatus = httpStatus; | ||
} | ||
|
||
@Override | ||
public HttpStatus httpStatus() { | ||
return httpStatus; | ||
} | ||
|
||
@Override | ||
public String code() { | ||
return code; | ||
} | ||
|
||
@Override | ||
public String message() { | ||
return message; | ||
} | ||
} |