Record Class MilitaryCampaignAnalyzer.SupplyRequirements
java.lang.Object
java.lang.Record
org.episteme.social.history.MilitaryCampaignAnalyzer.SupplyRequirements
- Record Components:
foodKgPerDay- total food weight needed dailywaterLitersPerDay- total water volume needed dailyfodderKgPerDay- total animal feed weight needed dailyammunitionKg- total ammunition weight for operationfuelLitersPerDay- total fuel volume for cooking/machines
- All Implemented Interfaces:
Serializable
- Enclosing class:
MilitaryCampaignAnalyzer
public static record MilitaryCampaignAnalyzer.SupplyRequirements(double foodKgPerDay, double waterLitersPerDay, double fodderKgPerDay, double ammunitionKg, double fuelLitersPerDay)
extends Record
implements Serializable
Quantified daily needs for a specific army.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSupplyRequirements(double foodKgPerDay, double waterLitersPerDay, double fodderKgPerDay, double ammunitionKg, double fuelLitersPerDay) Creates an instance of aSupplyRequirementsrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the value of theammunitionKgrecord component.final booleanIndicates whether some other object is "equal to" this one.doubleReturns the value of thefodderKgPerDayrecord component.doubleReturns the value of thefoodKgPerDayrecord component.doubleReturns the value of thefuelLitersPerDayrecord component.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.doubleReturns the value of thewaterLitersPerDayrecord component.
-
Constructor Details
-
SupplyRequirements
public SupplyRequirements(double foodKgPerDay, double waterLitersPerDay, double fodderKgPerDay, double ammunitionKg, double fuelLitersPerDay) Creates an instance of aSupplyRequirementsrecord class.- Parameters:
foodKgPerDay- the value for thefoodKgPerDayrecord componentwaterLitersPerDay- the value for thewaterLitersPerDayrecord componentfodderKgPerDay- the value for thefodderKgPerDayrecord componentammunitionKg- the value for theammunitionKgrecord componentfuelLitersPerDay- the value for thefuelLitersPerDayrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with thecomparemethod from their corresponding wrapper classes. -
foodKgPerDay
public double foodKgPerDay()Returns the value of thefoodKgPerDayrecord component.- Returns:
- the value of the
foodKgPerDayrecord component
-
waterLitersPerDay
public double waterLitersPerDay()Returns the value of thewaterLitersPerDayrecord component.- Returns:
- the value of the
waterLitersPerDayrecord component
-
fodderKgPerDay
public double fodderKgPerDay()Returns the value of thefodderKgPerDayrecord component.- Returns:
- the value of the
fodderKgPerDayrecord component
-
ammunitionKg
public double ammunitionKg()Returns the value of theammunitionKgrecord component.- Returns:
- the value of the
ammunitionKgrecord component
-
fuelLitersPerDay
public double fuelLitersPerDay()Returns the value of thefuelLitersPerDayrecord component.- Returns:
- the value of the
fuelLitersPerDayrecord component
-