Ignore:
Timestamp:
04/06/22 18:15:57 (8 months ago)
Author:
István Váradi <ivaradi@…>
Branch:
python3
hg-Phase:
(<MercurialRepository 1 'hg:/home/ivaradi/mlx/hg' '/'>, 'public')
Message:

New style briefing (re #357)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/rpc.py

    r1044 r1046  
    369369                self.arrivalTime += datetime.timedelta(days = 1)
    370370
     371    @property
     372    def payload(self):
     373        """Get the default payload of the flight."""
     374        payload= (self.numCabinCrew - self.dowNumCabinCrew) *  \
     375            const.WEIGHT_CABIN_CREW
     376        payload += self.numPassengers * \
     377            (const.WEIGHT_PASSENGER_CHARTER
     378             if self.flightType==const.FLIGHTTYPE_CHARTER
     379             else const.WEIGHT_PASSENGER)
     380        payload += self.numChildren * const.WEIGHT_CHILD
     381        payload += self.numInfants * const.WEIGHT_INFANT
     382        payload += self.bagWeight
     383        payload += self.cargoWeight
     384        payload += self.mailWeight
     385        return payload
     386
    371387    def readFromFile(self, f, fleet):
    372388        """Read the data of the flight from a file via the given file
Note: See TracChangeset for help on using the changeset viewer.