@Service public final class LotServiceImpl extends Object implements LotService
| Constructor and Description |
|---|
LotServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
long |
countLots()
Compte le nombre de lots
|
void |
createLot(Lot lot)
Créée un lot
|
void |
createPartie(Partie partie)
Créé une partie
|
void |
deleteLot(Lot lot)
Supprime un lot
|
void |
deletePartie(Partie partie)
Supprime une partie
|
boolean |
isLotAccessibleByUser(Lot lot,
Utilisateur utilisateur)
Détermine si un utilisateur peut accéder à un lot
|
List<Lot> |
listLots(Utilisateur utilisateur)
Liste les lots pour lesquelles l'utilisateur a les droits (triés par réf)
|
SortedSet<Lot> |
listLotsForUser(Utilisateur utilisateur)
Liste les lots pour lesquelles l'utilisateur a les droits (triés par réf)
|
List<Partie> |
listParties()
Liste les parties possibles pour un lot
|
Lot |
loadLot(Integer idLot)
Charge un lot
|
Lot |
loadLot(String ref)
Charge un lot
|
Partie |
loadPartie(Integer idPartie)
Charger une partie
|
Partie |
loadPartie(String nom)
Charger une partie
|
void |
refreshLot(Lot lot)
Rafraichit un lot (pour éviter des LazyLoadingException)
|
void |
updateLot(Lot lot)
Met à jour un lot
|
boolean |
updateOrdeleteLotEnabled(Lot lot,
Utilisateur utilisateur)
Détermine si un utilisateur peut modifier ou supprimer un lot
|
void |
updatePartie(Partie partie)
Modifie une partie
|
public long countLots()
countLots in interface LotServicepublic void refreshLot(Lot lot)
refreshLot in interface LotServicelot - Lotpublic void createLot(Lot lot) throws DataConstraintException
createLot in interface LotServicelot - LotDataConstraintException - Si le lot (nom) existe déjàpublic void createPartie(Partie partie) throws DataConstraintException
createPartie in interface LotServicepartie - PartieDataConstraintException - En cas de doublons (champs uniques)public void deleteLot(Lot lot) throws DataConstraintException
deleteLot in interface LotServicelot - LotDataConstraintException - Si le lot a des données liéespublic void deletePartie(Partie partie) throws DataConstraintException
deletePartie in interface LotServicepartie - PartieDataConstraintException - En cas de données liéespublic List<Lot> listLots(Utilisateur utilisateur)
listLots in interface LotServiceutilisateur - Utilisateurpublic SortedSet<Lot> listLotsForUser(Utilisateur utilisateur)
listLotsForUser in interface LotServiceutilisateur - Utilisateur non adminpublic boolean updateOrdeleteLotEnabled(Lot lot, Utilisateur utilisateur)
updateOrdeleteLotEnabled in interface LotServicelot - Lotutilisateur - Utilisateurpublic boolean isLotAccessibleByUser(Lot lot, Utilisateur utilisateur)
isLotAccessibleByUser in interface LotServicelot - Lotutilisateur - Utilisateurpublic List<Partie> listParties()
listParties in interface LotServicepublic Lot loadLot(Integer idLot) throws DataNotFoundException
loadLot in interface LotServiceidLot - IDDataNotFoundException - Si le lot n'existe paspublic Lot loadLot(String ref) throws DataNotFoundException
loadLot in interface LotServiceref - RéférenceDataNotFoundException - Si le lot n'existe paspublic Partie loadPartie(Integer idPartie) throws DataNotFoundException
loadPartie in interface LotServiceidPartie - IDDataNotFoundException - Si non trouvéepublic Partie loadPartie(String nom) throws DataNotFoundException
loadPartie in interface LotServicenom - NomDataNotFoundException - Si non trouvéepublic void updateLot(Lot lot) throws DataConstraintException
updateLot in interface LotServicelot - LotDataConstraintException - Si le lot (nom) existe déjàpublic void updatePartie(Partie partie) throws DataConstraintException
updatePartie in interface LotServicepartie - PartieDataConstraintException - En cas de doublons (champs uniques)Copyright © 2009-2013 IRD. All Rights Reserved.