Class AllowedMentions


  • public class AllowedMentions
    extends Object
    A class for holding the allowed_mentions object with an built-in factory for default values. Also this class wraps the AllowedMentionsData JSON to a Discord4J class.
    See Also:
    Reference
    • Method Detail

      • builder

        public static AllowedMentions.Builder builder()
        Create a builder for this AllowedMentions class. Building this object without any configuration is equivalent to suppressing all mentions.
        Returns:
        A builder class for allowed mentions
      • suppressAll

        public static AllowedMentions suppressAll()
        Create an AllowedMentions object that will suppress all mentions.
        Returns:
        A suppressing allowed mentions
      • suppressEveryone

        public static AllowedMentions suppressEveryone()
        Create an AllowedMentions object that will suppress @everyone and @here mentions.
        Returns:
        A suppressing allowed mentions
      • toData

        public discord4j.discordjson.json.AllowedMentionsData toData()
        Map this AllowedMentions object to a AllowedMentionsData JSON
        Returns:
        JSON object