Class Earning

All Implemented Interfaces:
Killer, Dateable, Cloneable, Iterable<String>, Serializable

public class Earning extends Entity implements Dateable
Represents the earned sum of money for a sold Offer in the Market
Author:
madmetzger
  • Field Details

  • Constructor Details

    • Earning

      public Earning(Integer value, String sellerName, boolean shouldReward)
      Constructs Earning for sold price.
      Parameters:
      value - Earned money
      sellerName - Name of the selling player
      shouldReward - True if the trade should be rewarded in trade score
    • Earning

      public Earning(RPObject object)
      Create an Earning from a RPObject
      Parameters:
      object -
  • Method Details

    • generateRPClass

      public static void generateRPClass()
    • getValue

      public Integer getValue()
      Returns:
      the earned money
    • getSeller

      public String getSeller()
      Returns:
      the name of the selling player
    • shouldReward

      public boolean shouldReward()
      Returns:
      true iff the earning player should get the trading bonus for this earning
    • getTimestamp

      public long getTimestamp()
      Specified by:
      getTimestamp in interface Dateable
      Returns:
      point of time relevant for this object