Package com.mewna.catnip.entity.misc
Interface Emoji.ActivityEmoji
- All Superinterfaces:
Emoji
,Entity
,HasNullableName
,Snowflake
,Timestamped
- All Known Implementing Classes:
ActivityEmojiImpl
- Enclosing interface:
- Emoji
The emoji in a user's activity, ex. for custom status messages. Note
that the majority of getters on this class return default falsey values.
The only fields currently set with non-default-falsey values are
id
, animated
, and name
.-
Nested Class Summary
Nested classes/interfaces inherited from interface com.mewna.catnip.entity.misc.Emoji
Emoji.ActivityEmoji, Emoji.CustomEmoji, Emoji.UnicodeEmoji
Nested classes/interfaces inherited from interface com.mewna.catnip.entity.partials.Timestamped
Timestamped.TimestampStyle
-
Method Summary
Modifier and TypeMethodDescriptiondefault boolean
custom()
Whether this emoji iscustom
.default String
A string that may be sent in a message and will render this emoji, if the user has permission to.default String
A string that may be added as a reaction to a message, if the user has permission to.default String
id()
ID of this emoji, or null if it has no ID.default boolean
Checks whether or not this emoji is the provided emoji string.default boolean
managed()
Whether this emoji is managed.default boolean
Whether this emoji must be wrapped in colons.roles()
Roles that are allowed to use this emoji.default User
user()
User who uploaded this emoji.Methods inherited from interface com.mewna.catnip.entity.partials.Snowflake
creationTime, creationTimestamp, idAsLong
Methods inherited from interface com.mewna.catnip.entity.partials.Timestamped
asDiscordTimestamp, parseTimestamp
-
Method Details
-
id
Description copied from interface:Emoji
ID of this emoji, or null if it has no ID.
Always null forunicode
emoji. -
roles
Description copied from interface:Emoji
Roles that are allowed to use this emoji. If empty, all users can use it.
Always empty forunicode
emoji. -
user
Description copied from interface:Emoji
User who uploaded this emoji.
Always null forunicode
emoji. -
managed
@CheckReturnValue default boolean managed()Description copied from interface:Emoji
Whether this emoji is managed.
Always false forunicode
emoji. -
custom
@CheckReturnValue default boolean custom()Description copied from interface:Emoji
Whether this emoji iscustom
. -
requiresColons
@CheckReturnValue default boolean requiresColons()Description copied from interface:Emoji
Whether this emoji must be wrapped in colons.- Specified by:
requiresColons
in interfaceEmoji
- Returns:
- True if it should be wrapped in colons, false otherwise.
-
forMessage
Description copied from interface:Emoji
A string that may be sent in a message and will render this emoji, if the user has permission to.- Specified by:
forMessage
in interfaceEmoji
- Returns:
- A string that yields this emoji when inside a message.
-
forReaction
Description copied from interface:Emoji
A string that may be added as a reaction to a message, if the user has permission to.- Specified by:
forReaction
in interfaceEmoji
- Returns:
- A string that yields this emoji when added as a reaction.
-
is
Description copied from interface:Emoji
Checks whether or not this emoji is the provided emoji string.
If this emoji isunicode
, it'sname
is compared for equality with the provided string.
If this emoji iscustom
, the following checks, in order, are applied:id
equalityforMessage()
equalityEmoji.forReaction()
forReaction()} equality
-