Package org.javacord.api.util
Class DiscordRegexPattern
- java.lang.Object
-
- org.javacord.api.util.DiscordRegexPattern
-
public class DiscordRegexPattern extends java.lang.ObjectThis class contains some useful precompiled regex patterns.
-
-
Field Summary
Fields Modifier and Type Field Description static java.util.regex.PatternCHANNEL_MENTIONA pattern which checks for mentioned channels (e.g.static java.util.regex.PatternCUSTOM_EMOJIA pattern which checks for custom emojis (e.g.static java.util.regex.PatternMESSAGE_LINKA pattern which checks for message links (e.g.static java.util.regex.PatternROLE_MENTIONA pattern which checks for mentioned roles (e.g.static java.util.regex.PatternSNOWFLAKEA pattern to match snowflakes.static java.util.regex.PatternUSER_MENTIONA pattern which checks for mentioned users (e.g.static java.util.regex.PatternWEBHOOK_URLA pattern which checks for webhook urls (e.g.
-
-
-
Field Detail
-
USER_MENTION
public static final java.util.regex.Pattern USER_MENTION
A pattern which checks for mentioned users (e.g.<@1234567890>).
-
ROLE_MENTION
public static final java.util.regex.Pattern ROLE_MENTION
A pattern which checks for mentioned roles (e.g.<@&1234567890>).
-
CHANNEL_MENTION
public static final java.util.regex.Pattern CHANNEL_MENTION
A pattern which checks for mentioned channels (e.g.<#1234567890>).
-
CUSTOM_EMOJI
public static final java.util.regex.Pattern CUSTOM_EMOJI
A pattern which checks for custom emojis (e.g.<:my_emoji:1234567890>).
-
MESSAGE_LINK
public static final java.util.regex.Pattern MESSAGE_LINK
A pattern which checks for message links (e.g.https://discord.com/channels/@me/1234/5678)
-
WEBHOOK_URL
public static final java.util.regex.Pattern WEBHOOK_URL
A pattern which checks for webhook urls (e.g.https://discord.com/api/webhooks/1234/abcd)
-
SNOWFLAKE
public static final java.util.regex.Pattern SNOWFLAKE
A pattern to match snowflakes.
-
-