Class Wallet
- java.lang.Object
-
- com.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
-
- com.github.fmjsjx.libcommon.example.bson.model.Wallet
-
- All Implemented Interfaces:
com.github.fmjsjx.libcommon.bson.model.BsonModel
public class Wallet extends com.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidappendFieldUpdates(java.util.List<org.bson.conversions.Bson> updates)protected intdeletedSize()intgetAd()longgetCoin()longgetCoinTotal()longgetCoinUsed()longgetDiamond()intincreaseAd()voidload(org.bson.BsonDocument src)voidload(org.bson.Document src)Playerparent()voidreset()protected voidresetChildren()voidsetAd(int ad)voidsetCoinTotal(long coinTotal)voidsetCoinUsed(long coinUsed)voidsetDiamond(long diamond)org.bson.BsonDocumenttoBson()java.util.Map<java.lang.Object,java.lang.Object>toDelete()org.bson.DocumenttoDocument()java.lang.StringtoString()java.lang.ObjecttoSubUpdate()com.github.fmjsjx.libcommon.bson.DotNotationxpath()
-
-
-
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()
-
load
public void load(org.bson.Document src)
-
load
public void load(org.bson.BsonDocument src)
-
appendFieldUpdates
protected void appendFieldUpdates(java.util.List<org.bson.conversions.Bson> updates)
- Specified by:
appendFieldUpdatesin classcom.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
-
resetChildren
protected void resetChildren()
-
toSubUpdate
public java.lang.Object toSubUpdate()
- Specified by:
toSubUpdatein classcom.github.fmjsjx.libcommon.bson.model.ObjectModel<Wallet>
-
toDelete
public java.util.Map<java.lang.Object,java.lang.Object> toDelete()
- Specified by:
toDeletein interfacecom.github.fmjsjx.libcommon.bson.model.BsonModel
-
deletedSize
protected int deletedSize()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
reset
public void reset()
- Specified by:
resetin interfacecom.github.fmjsjx.libcommon.bson.model.BsonModel
-
-