Skip to content

Commit 543c6d6

Browse files
committed
Update Site enum.
1 parent ffe9e83 commit 543c6d6

File tree

2 files changed

+23
-14
lines changed

2 files changed

+23
-14
lines changed

src/main/java/com/andre601/javabotblockapi/BotBlockAPI.java

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323
import java.util.Map;
2424

2525
/**
26-
* Class for handling the sites to post to and the delay for the auto-post option in the
27-
* {@link com.andre601.javabotblockapi.RequestHandler RequestHandler}.
26+
* Class used to define the auth-tokens used for the different sites.
27+
* <br>The instance of this class will be used in the {@link com.andre601.javabotblockapi.requests.PostAction PostAction} class.
2828
*/
2929
public class BotBlockAPI{
3030
private static final int DEFAULT_DELAY = 30;
@@ -37,20 +37,20 @@ public class BotBlockAPI{
3737
* <br>This will also set the update interval to 30 minutes.
3838
*
3939
* @param authTokens
40-
* A Map of sites and their tokens. May not be null.
41-
* <br>You may receive the API-token from your botlist.
40+
* A not null Map of sites and their tokens.
41+
* <br>You may receive the API-token from your bot list.
4242
*/
4343
public BotBlockAPI(@NotNull Map<String, String> authTokens){
4444
this.authTokens = authTokens;
4545
this.updateInterval = DEFAULT_DELAY;
4646
}
4747

4848
/**
49-
* Constructor to set the Map with the sites and tokens and also the update delay..
49+
* Constructor to set the Map with the sites and tokens and also the update delay.
5050
*
5151
* @param authTokens
52-
* A Map of sites and their tokens. May not be null.
53-
* <br>You may receive the API-token from your botlist.
52+
* A not null Map of sites and their tokens.
53+
* <br>You may receive the API-token from your bot list.
5454
* @param updateInterval
5555
* The update interval to set.
5656
*/
@@ -89,8 +89,8 @@ public Builder(){}
8989
* @param site
9090
* The {@link com.andre601.javabotblockapi.Site Site} to get the name from.
9191
* @param token
92-
* The API token from the corresponding botlist. May not be null or empty.
93-
* <br>You may receive the API token from the botlist.
92+
* The API token from the corresponding bot list. May not be null or empty.
93+
* <br>You may receive the API token from the bot list.
9494
*
9595
* @throws NullPointerException
9696
* When the provided token is empty ({@code ""}).
@@ -115,8 +115,8 @@ public Builder addAuthToken(@NotNull Site site, @NotNull String token){
115115
* The name of the site. May not be null.
116116
* <br>A list of supported sites can be found <a href="https://botblock.org/api/docs#count" target="_blank">here</a>.
117117
* @param token
118-
* The API token from the corresponding botlist. May not be null or empty.
119-
* <br>You may receive the API token from the botlist.
118+
* The API token from the corresponding bot list. May not be null or empty.
119+
* <br>You may receive the API token from the bot list.
120120
*
121121
* @throws NullPointerException
122122
* When either the site or token are empty ({@code ""}).

src/main/java/com/andre601/javabotblockapi/Site.java

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,11 @@
1818
package com.andre601.javabotblockapi;
1919

2020
/**
21-
* Enum class with all currently supported sites of BotBlock.org.
22-
* <br>May be used in {@link com.andre601.javabotblockapi.BotBlockAPI BotBlockAPI} or
23-
* {@link com.andre601.javabotblockapi.RequestHandler RequestHandler}.
21+
* Enum class containing all sites currently supported by BotBlock.org.
22+
*
23+
* <p>Those names can be used in methods of either the {@link com.andre601.javabotblockapi.BotBlockAPI BotBlockAPI},
24+
* the {@link com.andre601.javabotblockapi.requests.GetAction GetAction} or the
25+
* {@link com.andre601.javabotblockapi.requests.PostAction PostAction} class.
2426
*
2527
* @since v2.1.0
2628
*/
@@ -91,6 +93,13 @@ public enum Site {
9193
* <a href="https://mythicalbots.xyz" target="_blank">mythicalbots.xyz</a>
9294
*/
9395
MYTHICALBOTS_XYZ("mythicalbots.xyz"),
96+
/**
97+
* <a href="https://top.gg" target="_blank">top.gg</a>
98+
* <br>Note that top.gg is discordbots.org (new domain). {@link #DISCORDBOTS_ORG DISCORDBOTS_ORG} will still work.
99+
*
100+
* @since v3.0.0
101+
*/
102+
TOP_GG("discordbots.org"),
94103
/**
95104
* <a href="https://wonderbotlist.com" target="_blank">wonderbotlist.com</a>
96105
*/

0 commit comments

Comments
 (0)