Interface Platform
- All Known Implementing Classes:
BukkitPlatform, BungeePlatform, HytalePlatform, MinestomPlatform, NukkitPlatform, SpongePlatform, VelocityPlatform
public interface Platform
Represents the platform environment (e.g. Bukkit, BungeeCord, Velocity, standard JVM)
in which the FastStats library is running.
-
Method Summary
Modifier and TypeMethodDescriptionRetrieves the platform-specific configuration.Collection<Metric<?>> Gets default platform-specific metrics.Gets the name of the project (plugin, mod, ...) reporting metrics.default voidLogs error messages.default voidLogs informational messages.default voidlogWarning(String message) Logs warning messages.
-
Method Details
-
getProjectName
String getProjectName()Gets the name of the project (plugin, mod, ...) reporting metrics.This name is submitted along with the metrics so the service can associate the data with the correct project.
- Returns:
- the project name
-
getConfig
Config getConfig()Retrieves the platform-specific configuration.- Returns:
- the platform config instance
-
getMetrics
Collection<Metric<?>> getMetrics()Gets default platform-specific metrics.- Returns:
- a collection of platform metrics
-
logInfo
Logs informational messages.- Parameters:
message- the message to log
-
logWarning
Logs warning messages.- Parameters:
message- the message to log
-
logError
-