Class PlayerCountQueries

java.lang.Object
com.djrapitops.plan.storage.database.queries.analysis.PlayerCountQueries

public class PlayerCountQueries extends Object
Queries for server overview tab data.
  • Method Details

    • uniquePlayerCount

      public static Query<Integer> uniquePlayerCount(long after, long before, ServerUUID serverUUID)
    • uniquePlayerCount

      public static Query<Integer> uniquePlayerCount(long after, long before)
      Fetch uniquePlayer count for ALL servers.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      Returns:
      Unique player count (players who played within time frame)
    • uniquePlayerCounts

      public static Query<Map<ServerUUID,Integer>> uniquePlayerCounts(long after, long before)
    • uniquePlayerCounts

      public static Query<NavigableMap<Long,Integer>> uniquePlayerCounts(long after, long before, long timeZoneOffset, ServerUUID serverUUID)
      Fetch a EpochMs - Count map of unique players on a server.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      serverUUID - UUID of the Plan server
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many unique players played that day
    • hourlyUniquePlayerCounts

      public static Query<NavigableMap<Long,Integer>> hourlyUniquePlayerCounts(long after, long before, long timeZoneOffset, ServerUUID serverUUID)
      Fetch a EpochMs - Count map of unique players on a server.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      serverUUID - UUID of the Plan server
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many unique players played that day
    • uniquePlayerCounts

      public static Query<NavigableMap<Long,Integer>> uniquePlayerCounts(long after, long before, long timeZoneOffset)
      Fetch a EpochMs - Count map of unique players on ALL servers.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many unique players played that day
    • hourlyUniquePlayerCounts

      public static Query<NavigableMap<Long,Integer>> hourlyUniquePlayerCounts(long after, long before, long timeZoneOffset)
      Fetch a EpochMs - Count map of unique players on ALL servers.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many unique players played that day
    • averageUniquePlayerCount

      public static Query<Integer> averageUniquePlayerCount(long after, long before, long timeZoneOffset, ServerUUID serverUUID)
    • averageUniquePlayerCount

      public static Query<Integer> averageUniquePlayerCount(long after, long before, long timeZoneOffset)
    • newPlayerCount

      public static Query<Integer> newPlayerCount(long after, long before, ServerUUID serverUUID)
    • newPlayerCount

      public static Query<Integer> newPlayerCount(long after, long before)
    • newPlayerCounts

      public static Query<Map<ServerUUID,Integer>> newPlayerCounts(long after, long before)
    • newPlayerCounts

      public static Query<NavigableMap<Long,Integer>> newPlayerCounts(long after, long before, long timeZoneOffset, ServerUUID serverUUID)
      Fetch a EpochMs - Count map of new players on a server.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      serverUUID - UUID of the Plan server
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many new players joined that day
    • hourlyNewPlayerCounts

      public static Query<NavigableMap<Long,Integer>> hourlyNewPlayerCounts(long after, long before, long timeZoneOffset, UUID serverUUID)
      Fetch a EpochMs - Count map of new players on a server.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      serverUUID - UUID of the Plan server
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many new players joined that day
    • newPlayerCounts

      public static Query<NavigableMap<Long,Integer>> newPlayerCounts(long after, long before, long timeZoneOffset)
      Fetch a EpochMs - Count map of new players on a server.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many new players joined that day
    • hourlyNewPlayerCounts

      public static Query<NavigableMap<Long,Integer>> hourlyNewPlayerCounts(long after, long before, long timeZoneOffset)
      Fetch a EpochMs - Count map of new players on a server.
      Parameters:
      after - After epoch ms
      before - Before epoch ms
      timeZoneOffset - Offset from TimeZone.getOffset(long), applied to the dates before grouping.
      Returns:
      Map: Epoch ms (Start of day at 0 AM, no offset) - How many new players joined that day
    • averageNewPlayerCount

      public static Query<Integer> averageNewPlayerCount(long after, long before, long timeZoneOffset, ServerUUID serverUUID)
    • retainedPlayerCount

      public static Query<Integer> retainedPlayerCount(long after, long before, ServerUUID serverUUID)
    • operators

      public static Query<Integer> operators(ServerUUID serverUUID)