Package be.gaudry.model.edu.score
Class QuotationsHelper
java.lang.Object
be.gaudry.model.edu.score.QuotationsHelper
- Since:
- 1.0 25 janv. 2009
- Author:
- Steph GAUDRY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
putInPeriod(Quotation quotation, Collection<Period> periods, Map<Period,BasicScoreList> periodsQuotations)
For a givenquotation
, checks into a given collection ofperiods
if the date of theexamination
matches with a period.
Pay attention than if more than one period is valid for the quotation, the quotation will be inserted only for the first (depending on the iterator provided by the collection) matching period.
-
Constructor Details
-
QuotationsHelper
public QuotationsHelper()No need of instance
-
-
Method Details
-
putInPeriod
public static boolean putInPeriod(Quotation quotation, Collection<Period> periods, Map<Period,BasicScoreList> periodsQuotations)For a givenquotation
, checks into a given collection ofperiods
if the date of theexamination
matches with a period.
Pay attention than if more than one period is valid for the quotation, the quotation will be inserted only for the first (depending on the iterator provided by the collection) matching period.- Parameters:
quotation
-Quotation
to put in the periodsQuotations Map.periods
- Collection of possible matchingperiods
.periodsQuotations
- Map maintaining the relation betweenAbstractScoreList
andPeriod
.- Returns:
true
if the quotation has been inserted into the map,false
otherwise.
-