-
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 #1024 from bounswe/main
Deploy recent changes and developments 17.12.2023 09.45
- Loading branch information
Showing
544 changed files
with
145,220 additions
and
114,373 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
34 changes: 34 additions & 0 deletions
34
app/backend/src/main/java/com/app/gamereview/dto/request/game/RecommendGameDto.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,34 @@ | ||
package com.app.gamereview.dto.request.game; | ||
|
||
import com.app.gamereview.model.Game; | ||
import lombok.Getter; | ||
import lombok.Setter; | ||
|
||
import java.util.Objects; | ||
|
||
@Getter | ||
@Setter | ||
public class RecommendGameDto implements Comparable<RecommendGameDto>{ | ||
private Game game; | ||
private int score = Integer.MAX_VALUE; | ||
|
||
@Override | ||
public int compareTo(RecommendGameDto o) { | ||
if(game.getGameName().equals(o.getGame().getGameName())) return 0; | ||
if(score == o.score) return 1; | ||
return Integer.compare(this.score, o.score); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) return true; | ||
if (o == null || getClass() != o.getClass()) return false; | ||
RecommendGameDto given = (RecommendGameDto) o; | ||
return this.game.getGameName().equals(given.getGame().getGameName()); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(game.getGameName()); | ||
} | ||
} |
34 changes: 34 additions & 0 deletions
34
app/backend/src/main/java/com/app/gamereview/dto/request/group/RecommendGroupDto.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,34 @@ | ||
package com.app.gamereview.dto.request.group; | ||
|
||
import com.app.gamereview.model.Group; | ||
import lombok.Getter; | ||
import lombok.Setter; | ||
|
||
import java.util.Objects; | ||
|
||
@Getter | ||
@Setter | ||
public class RecommendGroupDto implements Comparable<RecommendGroupDto>{ | ||
private Group group; | ||
private int score = Integer.MAX_VALUE; | ||
|
||
@Override | ||
public int compareTo(RecommendGroupDto o) { | ||
if(group.getId().equals(o.getGroup().getId())) return 0; | ||
if(score == o.score) return 1; | ||
return Integer.compare(this.score, o.score); | ||
} | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) return true; | ||
if (o == null || getClass() != o.getClass()) return false; | ||
RecommendGroupDto given = (RecommendGroupDto) o; | ||
return this.group.getId().equals(given.getGroup().getId()); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(group.getId()); | ||
} | ||
} |
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
Oops, something went wrong.