Package mekhq.campaign.roleplay
Record Class TravelLog.SystemSummary
java.lang.Object
java.lang.Record
mekhq.campaign.roleplay.TravelLog.SystemSummary
- Record Components:
systemId- the system's idsystemName- its display namefirstVisit- the first date anything happened therelastVisit- the last date anything happened therevisits- how many separate stays the main force had theredaysPresent- how many days the main force spent therecontracts- how many contracts were there
- Enclosing class:
TravelLog
public static record TravelLog.SystemSummary(String systemId, String systemName, LocalDate firstVisit, LocalDate lastVisit, int visits, long daysPresent, int contracts)
extends Record
One row of the by-system view.
-
Constructor Summary
ConstructorsConstructorDescriptionSystemSummary(String systemId, String systemName, LocalDate firstVisit, LocalDate lastVisit, int visits, long daysPresent, int contracts) Creates an instance of aSystemSummaryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionintReturns the value of thecontractsrecord component.longReturns the value of thedaysPresentrecord component.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefirstVisitrecord component.final inthashCode()Returns a hash code value for this object.Returns the value of thelastVisitrecord component.systemId()Returns the value of thesystemIdrecord component.Returns the value of thesystemNamerecord component.final StringtoString()Returns a string representation of this record class.intvisits()Returns the value of thevisitsrecord component.
-
Constructor Details
-
SystemSummary
public SystemSummary(String systemId, String systemName, LocalDate firstVisit, LocalDate lastVisit, int visits, long daysPresent, int contracts) Creates an instance of aSystemSummaryrecord class.- Parameters:
systemId- the value for thesystemIdrecord componentsystemName- the value for thesystemNamerecord componentfirstVisit- the value for thefirstVisitrecord componentlastVisit- the value for thelastVisitrecord componentvisits- the value for thevisitsrecord componentdaysPresent- the value for thedaysPresentrecord componentcontracts- the value for thecontractsrecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
systemId
Returns the value of thesystemIdrecord component.- Returns:
- the value of the
systemIdrecord component
-
systemName
Returns the value of thesystemNamerecord component.- Returns:
- the value of the
systemNamerecord component
-
firstVisit
Returns the value of thefirstVisitrecord component.- Returns:
- the value of the
firstVisitrecord component
-
lastVisit
Returns the value of thelastVisitrecord component.- Returns:
- the value of the
lastVisitrecord component
-
visits
public int visits()Returns the value of thevisitsrecord component.- Returns:
- the value of the
visitsrecord component
-
daysPresent
public long daysPresent()Returns the value of thedaysPresentrecord component.- Returns:
- the value of the
daysPresentrecord component
-
contracts
public int contracts()Returns the value of thecontractsrecord component.- Returns:
- the value of the
contractsrecord component
-