public class PlayerKill extends java.lang.Object implements DateHolder
Constructor and Description |
---|
PlayerKill(java.util.UUID victim,
java.lang.String weapon,
long date)
Creates a PlayerKill object with given parameters.
|
PlayerKill(java.util.UUID victim,
java.lang.String weapon,
long date,
java.lang.String victimName) |
PlayerKill(java.util.UUID victim,
java.lang.String weapon,
long date,
java.lang.String victimName,
java.lang.String killerName) |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
long |
getDate()
Get the date the object holds.
|
java.util.Optional<java.lang.String> |
getKillerName() |
java.lang.String |
getWeapon()
Get the Weapon used as string.
|
java.util.UUID |
getVictim()
Get the victim's UUID.
|
java.util.Optional<java.lang.String> |
getVictimName() |
int |
hashCode() |
boolean |
isNotSelfKill() |
boolean |
isSelfKill() |
java.lang.String |
toString() |
public PlayerKill(java.util.UUID victim, java.lang.String weapon, long date)
victim
- UUID of the victim.weapon
- Weapon used.date
- Epoch millisecond at which the kill occurred.public PlayerKill(java.util.UUID victim, java.lang.String weapon, long date, java.lang.String victimName)
public PlayerKill(java.util.UUID victim, java.lang.String weapon, long date, java.lang.String victimName, java.lang.String killerName)
public java.util.UUID getVictim()
public java.util.Optional<java.lang.String> getVictimName()
public java.util.Optional<java.lang.String> getKillerName()
public long getDate()
DateHolder
getDate
in interface DateHolder
public java.lang.String getWeapon()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
public boolean isSelfKill()
public boolean isNotSelfKill()