+ } else if (words[0].equalsIgnoreCase("stats")) {
+ int configuredChannelsCount = core.channels().size();
+ int joinedChannelsCount = core.joinedChannels().size();
+ int extraChannelsCount = core.extraChannels().size();
+ Collection<Bot> bots = core.bots();
+ Set<String> packNames = Sets.newHashSet();
+ int packsCount = 0;
+ for (Bot bot : bots) {
+ packsCount += bot.packs().size();
+ for (Pack pack : bot) {
+ packNames.add(pack.name());
+ }
+ }
+
+ writer.write(String.format("%d channels (%d joined, %d extra), %d bots offering %d packs (%d unique).\n", configuredChannelsCount, joinedChannelsCount, extraChannelsCount, bots.size(), packsCount, packNames.size()));