Interface PlayerManagementService
public interface PlayerManagementService
Players management service.
- Author:
- andresbustamante
-
Method Summary
Modifier and TypeMethodDescriptionvoiddeactivatePlayer(Player player, net.andresbustamante.yafoot.commons.model.UserContext userContext) Deactivates a player and deletes his/her history in the application.savePlayer(Player player, net.andresbustamante.yafoot.commons.model.UserContext userContext) Creates a new player in the application.voidupdatePlayer(Player player, net.andresbustamante.yafoot.commons.model.UserContext userContext) Updates basic details for a player.
-
Method Details
-
savePlayer
Integer savePlayer(Player player, net.andresbustamante.yafoot.commons.model.UserContext userContext) throws net.andresbustamante.yafoot.commons.exceptions.DatabaseException, net.andresbustamante.yafoot.commons.exceptions.ApplicationException Creates a new player in the application.- Parameters:
player- Player to createuserContext- Request context- Returns:
- New player's identifier
- Throws:
net.andresbustamante.yafoot.commons.exceptions.DatabaseExceptionnet.andresbustamante.yafoot.commons.exceptions.ApplicationException
-
updatePlayer
void updatePlayer(Player player, net.andresbustamante.yafoot.commons.model.UserContext userContext) throws net.andresbustamante.yafoot.commons.exceptions.DirectoryException, net.andresbustamante.yafoot.commons.exceptions.DatabaseException, net.andresbustamante.yafoot.commons.exceptions.ApplicationException Updates basic details for a player.- Parameters:
player- Player to updateuserContext- Request context- Throws:
net.andresbustamante.yafoot.commons.exceptions.DatabaseExceptionnet.andresbustamante.yafoot.commons.exceptions.DirectoryExceptionnet.andresbustamante.yafoot.commons.exceptions.ApplicationException
-
deactivatePlayer
void deactivatePlayer(Player player, net.andresbustamante.yafoot.commons.model.UserContext userContext) throws net.andresbustamante.yafoot.commons.exceptions.DirectoryException, net.andresbustamante.yafoot.commons.exceptions.DatabaseException Deactivates a player and deletes his/her history in the application.- Parameters:
player- Player to deactivateuserContext- Request context- Throws:
net.andresbustamante.yafoot.commons.exceptions.DatabaseExceptionnet.andresbustamante.yafoot.commons.exceptions.DirectoryException
-