Class JdaAnalytics
java.lang.Object
dev.jacrispys.JavaBot.api.analytics.JdaAnalytics
- All Implemented Interfaces:
AudioAnalytics
,GeneralJdaAnalytics
,Stats
Implementation of guild non-specific
AudioAnalytics
and GeneralJdaAnalytics
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T extends net.dv8tion.jda.api.entities.UserSnowflake>
AudioUsergetAudioUser
(T user) long
long
long
getPlays()
long
long
-
Field Details
-
api
-
jda
public final net.dv8tion.jda.api.JDA jda -
sqlStats
-
-
Constructor Details
-
JdaAnalytics
-
-
Method Details
-
getPlays
- Specified by:
getPlays
in interfaceAudioAnalytics
- Returns:
- the TOTAL amount of songs played (all time)
- Throws:
SQLException
- when the query cannot be completed
-
getPauses
- Specified by:
getPauses
in interfaceAudioAnalytics
- Returns:
- the TOTAL amount of times the bot has been paused (all time)
- Throws:
SQLException
- when the query cannot be completed
-
getTotalPlaytime
- Specified by:
getTotalPlaytime
in interfaceAudioAnalytics
- Returns:
- the total timme spent listening to the bot (all time)
- Throws:
SQLException
- when the query cannot be completed
-
getTopListeners
- Specified by:
getTopListeners
in interfaceAudioAnalytics
- Returns:
- top users (all time)
-
getTopSongs
- Specified by:
getTopSongs
in interfaceAudioAnalytics
- Returns:
- top played songs (all time)
-
getAudioUser
- Specified by:
getAudioUser
in interfaceAudioAnalytics
- Type Parameters:
T
- Allow instantiation from any member/user class- Parameters:
user
- instance to get from JDA- Returns:
- custom audio user object
-
getHijackCount
- Specified by:
getHijackCount
in interfaceAudioAnalytics
- Returns:
- total times the bot has entered hijack mode (all time)
- Throws:
SQLException
- when the query cannot be completed
-
getTotalUses
- Specified by:
getTotalUses
in interfaceStats
- Returns:
- total number of times the bot has received a command.
- Throws:
SQLException
- when the query cannot be completed
-