-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat : GitHubResource를 저장하는 Embedded 객체 구현 (#112)
- Loading branch information
Showing
2 changed files
with
42 additions
and
4 deletions.
There are no files selected for viewing
28 changes: 28 additions & 0 deletions
28
src/main/java/gdsc/binaryho/imhere/core/member/GitHubResource.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,28 @@ | ||
package gdsc.binaryho.imhere.core.member; | ||
|
||
import javax.persistence.Column; | ||
import javax.persistence.Embeddable; | ||
import lombok.AccessLevel; | ||
import lombok.AllArgsConstructor; | ||
import lombok.Getter; | ||
import lombok.NoArgsConstructor; | ||
|
||
@Embeddable | ||
@Getter | ||
@AllArgsConstructor(access = AccessLevel.PROTECTED) | ||
@NoArgsConstructor(access = AccessLevel.PROTECTED) | ||
public class GitHubResource { | ||
|
||
@Column(unique = true, name = "git_hub_id", nullable = false) | ||
private String id; | ||
|
||
@Column(name = "git_hub_handle", nullable = false) | ||
private String handle; | ||
|
||
@Column(name = "git_hub_profile") | ||
private String profile; | ||
|
||
protected void updateHandle(String gitHubHandle) { | ||
this.handle = gitHubHandle; | ||
} | ||
} |
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