Interface ScoreService
-
- All Known Implementing Classes:
DefaultScoreService
public interface ScoreService
Score service interface which allow to manage a score
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description void
addScore(ScoreDetail scoreDetail)
void
deleteScore(ScorePK scorePK)
Method: deleteScorevoid
deleteScoreByFatherPK(ScorePK scorePK, String fatherId)
Methode: deleteScoreByFatherPKstatic ScoreService
get()
Collection<ScoreDetail>
getAllScores(ScorePK scorePK)
Method: getAllScoresfloat
getAverageScoreByFatherId(ScorePK scorePK, String fatherId)
Method: getAverageScoreByFatherIdCollection<ScoreDetail>
getBestScoresByFatherId(ScorePK scorePK, int nbBestScores, String fatherId)
Method: getBestScoresByFatherIdint
getNbVotersByFatherId(ScorePK scorePK, String fatherId)
Method: getNbVotersByFatherIdCollection<ScoreDetail>
getScoresByFatherId(ScorePK scorePK, String fatherId)
Method: getScoresByFatherIdint
getUserNbParticipationsByFatherId(ScorePK scorePK, String fatherId, String userId)
ScoreDetail
getUserScoreByFatherIdAndParticipationId(ScorePK scorePK, String fatherId, String userId, int participationId)
Method: getUserScoresByFatherIdAndParticipationIdCollection<ScoreDetail>
getUserScores(ScorePK scorePK, String userId)
Method: getUserScoresCollection<ScoreDetail>
getUserScoresByFatherId(ScorePK scorePK, String fatherId, String userId)
Method: getUserScoresByFatherIdCollection<ScoreDetail>
getWorstScoresByFatherId(ScorePK scorePK, int nbWorstScores, String fatherId)
Method: getWorstScoresByFatherIdvoid
updateScore(ScoreDetail scoreDetail)
-
-
-
Method Detail
-
get
static ScoreService get()
-
addScore
void addScore(ScoreDetail scoreDetail)
- Parameters:
scoreDetail
- the scrore detail to add
-
deleteScore
void deleteScore(ScorePK scorePK)
Method: deleteScore- Parameters:
scorePK
- the score identifier
-
deleteScoreByFatherPK
void deleteScoreByFatherPK(ScorePK scorePK, String fatherId)
Methode: deleteScoreByFatherPK- Parameters:
scorePK
- the score identifierfatherId
- the father identifier
-
getAllScores
Collection<ScoreDetail> getAllScores(ScorePK scorePK)
Method: getAllScores- Parameters:
scorePK
- the score identifier- Returns:
-
getUserScores
Collection<ScoreDetail> getUserScores(ScorePK scorePK, String userId)
Method: getUserScores- Parameters:
scorePK
- the score identifieruserId
- the user identifier- Returns:
-
getUserScoresByFatherId
Collection<ScoreDetail> getUserScoresByFatherId(ScorePK scorePK, String fatherId, String userId)
Method: getUserScoresByFatherId- Parameters:
scorePK
- the score identifierfatherId
- the father identifieruserId
- the user identifier- Returns:
-
getBestScoresByFatherId
Collection<ScoreDetail> getBestScoresByFatherId(ScorePK scorePK, int nbBestScores, String fatherId)
Method: getBestScoresByFatherId- Parameters:
scorePK
- the score identifiernbBestScores
-fatherId
- the father identifier- Returns:
-
getWorstScoresByFatherId
Collection<ScoreDetail> getWorstScoresByFatherId(ScorePK scorePK, int nbWorstScores, String fatherId)
Method: getWorstScoresByFatherId- Parameters:
scorePK
- the score identifiernbWorstScores
-fatherId
- the father identifier- Returns:
-
getNbVotersByFatherId
int getNbVotersByFatherId(ScorePK scorePK, String fatherId)
Method: getNbVotersByFatherId- Parameters:
scorePK
- the score identifierfatherId
- the father identifier- Returns:
-
getAverageScoreByFatherId
float getAverageScoreByFatherId(ScorePK scorePK, String fatherId)
Method: getAverageScoreByFatherId- Parameters:
scorePK
- the score identifierfatherId
- the father identifier- Returns:
-
getUserScoreByFatherIdAndParticipationId
ScoreDetail getUserScoreByFatherIdAndParticipationId(ScorePK scorePK, String fatherId, String userId, int participationId)
Method: getUserScoresByFatherIdAndParticipationId- Parameters:
scorePK
- the score identifierfatherId
- the father identifieruserId
- the user identifierparticipationId
-- Returns:
-
getScoresByFatherId
Collection<ScoreDetail> getScoresByFatherId(ScorePK scorePK, String fatherId)
Method: getScoresByFatherId- Parameters:
scorePK
- the score identifierfatherId
- the father identifier- Returns:
-
getUserNbParticipationsByFatherId
int getUserNbParticipationsByFatherId(ScorePK scorePK, String fatherId, String userId)
- Parameters:
scorePK
- the score identifierfatherId
- the father identifieruserId
- the user identifier- Returns:
-
updateScore
void updateScore(ScoreDetail scoreDetail)
- Parameters:
scoreDetail
- the score detail to update
-
-