Class FinishedSession
- java.lang.Object
-
- com.djrapitops.plan.gathering.domain.FinishedSession
-
- All Implemented Interfaces:
DateHolder
public class FinishedSession extends java.lang.Object implements DateHolder
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
FinishedSession.Id
-
Constructor Summary
Constructors Constructor Description FinishedSession(java.util.UUID playerUUID, ServerUUID serverUUID, long start, long end, long afkTime, DataMap extraData)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
long
getActiveTime()
long
getAfkTime()
long
getDate()
Get the date the object holds.int
getDeathCount()
long
getEnd()
DataMap
getExtraData()
<T> java.util.Optional<T>
getExtraData(java.lang.Class<T> ofType)
long
getLength()
int
getMobKillCount()
int
getPlayerKillCount()
java.util.UUID
getPlayerUUID()
ServerUUID
getServerUUID()
long
getStart()
int
hashCode()
boolean
isFirstSession()
void
setAsFirstSessionIfMatches(java.lang.Long registerDate)
java.lang.String
toString()
-
-
-
Constructor Detail
-
FinishedSession
public FinishedSession(java.util.UUID playerUUID, ServerUUID serverUUID, long start, long end, long afkTime, DataMap extraData)
-
-
Method Detail
-
getPlayerUUID
public java.util.UUID getPlayerUUID()
-
getServerUUID
public ServerUUID getServerUUID()
-
getStart
public long getStart()
-
getEnd
public long getEnd()
-
getAfkTime
public long getAfkTime()
-
getLength
public long getLength()
-
getActiveTime
public long getActiveTime()
-
getMobKillCount
public int getMobKillCount()
-
getDeathCount
public int getDeathCount()
-
getPlayerKillCount
public int getPlayerKillCount()
-
setAsFirstSessionIfMatches
public void setAsFirstSessionIfMatches(java.lang.Long registerDate)
-
isFirstSession
public boolean isFirstSession()
-
getExtraData
public DataMap getExtraData()
-
getExtraData
public <T> java.util.Optional<T> getExtraData(java.lang.Class<T> ofType)
-
getDate
public long getDate()
Description copied from interface:DateHolder
Get the date the object holds.- Specified by:
getDate
in interfaceDateHolder
- Returns:
- Epoch ms - milliseconds passed since January 1st 1970.
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-