This repository has been archived by the owner on Aug 13, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #56 from f-lab-edu/feature/25
[#25] 사용자 차단 목록 불러오기 기능 구현
- Loading branch information
Showing
8 changed files
with
73 additions
and
6 deletions.
There are no files selected for viewing
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
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
26 changes: 26 additions & 0 deletions
26
src/main/java/me/soo/helloworld/model/blockuser/BlockUserListRequest.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,26 @@ | ||
package me.soo.helloworld.model.blockuser; | ||
|
||
import lombok.AllArgsConstructor; | ||
import lombok.Builder; | ||
import me.soo.helloworld.util.Pagination; | ||
|
||
@Builder | ||
@AllArgsConstructor | ||
public class BlockUserListRequest { | ||
|
||
private final String userId; | ||
|
||
private final int offset; | ||
|
||
private final int limit; | ||
|
||
static public BlockUserListRequest create(String userId, int pageNumber, Pagination pagination) { | ||
int pageLimit = pagination.getMaxPageBlockUser(); | ||
|
||
return BlockUserListRequest.builder() | ||
.userId(userId) | ||
.offset(pagination.calculateOffset(pageLimit, pageNumber)) | ||
.limit(pageLimit) | ||
.build(); | ||
} | ||
} |
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
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
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
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
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