Class Wallet

  • All Implemented Interfaces:
    com.github.fmjsjx.libcommon.bson.model.BsonModel

    public class Wallet
    extends com.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
    • Field Summary

      • Fields inherited from class com.github.fmjsjx.libcommon.bson.model.ObjectModel

        FULL, updatedFields
    • Constructor Summary

      Constructors 
      Constructor Description
      Wallet​(Player parent)  
    • Constructor Detail

      • Wallet

        public Wallet​(Player parent)
    • Method Detail

      • getCoinTotal

        public long getCoinTotal()
      • setCoinTotal

        public void setCoinTotal​(long coinTotal)
      • getCoinUsed

        public long getCoinUsed()
      • setCoinUsed

        public void setCoinUsed​(long coinUsed)
      • getCoin

        public long getCoin()
      • getDiamond

        public long getDiamond()
      • setDiamond

        public void setDiamond​(long diamond)
      • getAd

        public int getAd()
      • setAd

        public void setAd​(int ad)
      • increaseAd

        public int increaseAd()
      • parent

        public Player parent()
      • xpath

        public com.github.fmjsjx.libcommon.bson.DotNotation xpath()
      • toBson

        public org.bson.BsonDocument toBson()
      • toDocument

        public org.bson.Document toDocument()
      • toData

        public java.util.Map<java.lang.String,​?> toData()
        Specified by:
        toData in interface com.github.fmjsjx.libcommon.bson.model.BsonModel
        Specified by:
        toData in class com.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
      • load

        public void load​(org.bson.Document src)
      • load

        public void load​(org.bson.BsonDocument src)
      • load

        public void load​(com.jsoniter.any.Any src)
      • load

        public void load​(com.fasterxml.jackson.databind.JsonNode src)
      • coinTotalUpdated

        public boolean coinTotalUpdated()
      • coinUsedUpdated

        public boolean coinUsedUpdated()
      • coinUpdated

        public boolean coinUpdated()
      • diamondUpdated

        public boolean diamondUpdated()
      • adUpdated

        public boolean adUpdated()
      • appendFieldUpdates

        protected void appendFieldUpdates​(java.util.List<org.bson.conversions.Bson> updates)
        Specified by:
        appendFieldUpdates in class com.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
      • resetChildren

        protected void resetChildren()
      • toSubUpdate

        public java.lang.Object toSubUpdate()
        Specified by:
        toSubUpdate in class com.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
      • toDelete

        public java.util.Map<java.lang.Object,​java.lang.Object> toDelete()
        Specified by:
        toDelete in interface com.github.fmjsjx.libcommon.bson.model.BsonModel
      • deletedSize

        protected int deletedSize()
      • coin

        public long coin()
      • ago

        public java.time.LocalDate ago​(int days)
      • testMethodCode

        public java.time.ZonedDateTime testMethodCode​(java.time.LocalDateTime time,
                                                      java.time.ZoneId zone)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • reset

        public void reset()
        Specified by:
        reset in interface com.github.fmjsjx.libcommon.bson.model.BsonModel
      • deleted

        public boolean deleted()
        Specified by:
        deleted in interface com.github.fmjsjx.libcommon.bson.model.BsonModel