Class SkyMilesScorer
java.lang.Object
org.deltava.beans.econ.EliteScorer
org.deltava.beans.econ.SkyMilesScorer
A flight scorer for Delta Virtual Airlines. This extends the default implementation by restricting flights to a maximum number of non-ACARS flights per month.
- Since:
- 11.0
- Version:
- 12.4
- Author:
- Luke
-
Field Summary
Fields inherited from class EliteScorer
_score -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidadd(FlightReport fr) Adds a Flight Report.score(FlightReport fr, EliteLevel lvl) Scores a non-ACARS Flight Report.score(ScorePackage pkg, EliteLevel lvl) Scores a Flight Report.Methods inherited from class EliteScorer
addBonus, canScore, getInstance, getScore, getStatsYear, getStatusYear, isNewAirport, isNewCountry, isNewEquipment, isRollover, reset, setBaseModifier and TypeMethodDescriptionprotected voidAdds a conditional bonus entry to the flight score.protected static booleancanScore(FlightReport fr) Checks whether a flight report can be scored.static EliteScorerCreates a PointScorer implementation.getScore()Returns the score bundle.static final intgetStatsYear(Instant dt) Returns what Elite program year flight statistics should be assigned to.static final intgetStatusYear(Instant dt) Returns what Elite program year status should be looked up for.protected booleanisNewAirport(String iata, Instant dt) Returns if an Airport has been visited before a particular date.protected booleanisNewCountry(String code, Instant dt) Returns if a Country has been visited before a particular date.protected booleanisNewEquipment(String eqType, Instant dt) Returns if an equipment type has been used before a particular date.static final booleanReturns whether we are in the rollover period before the start of the new status year.protected voidreset(int id, EliteLevel lvl) Resets the flight score.protected voidAdds a conditional entry to the flight score.
-
Constructor Details
-
SkyMilesScorer
public SkyMilesScorer()
-
-
Method Details
-
add
Adds a Flight Report. This will calculate number of non-ACARS flights per month.- Overrides:
addin classEliteScorer- Parameters:
fr- the FlightReport
-
score
Description copied from class:EliteScorerScores a Flight Report.- Specified by:
scorein classEliteScorer- Parameters:
pkg- the ScorePackagelvl- the Pilot's current EliteLevel- Returns:
- the number of status points earned
-
score
Description copied from class:EliteScorerScores a non-ACARS Flight Report.- Specified by:
scorein classEliteScorer- Parameters:
fr- the FlightReportlvl- the Pilot's current EliteLevel- Returns:
- the number of status points earned
-