Class WebhookEmbed.EmbedField
- java.lang.Object
-
- club.minnced.discord.webhook.send.WebhookEmbed.EmbedField
-
- All Implemented Interfaces:
org.json.JSONString
- Enclosing class:
- WebhookEmbed
public static class WebhookEmbed.EmbedField extends Object implements org.json.JSONString
-
-
Constructor Summary
Constructors Constructor Description EmbedField(boolean inline, @NotNull String name, @NotNull String value)
Creates a new embed field
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description @NotNull String
getName()
The name of this field.@NotNull String
getValue()
The value of this field.boolean
isInline()
Whether this field should share a row with other fieldsString
toJSONString()
String
toString()
JSON representation of this field
-
-
-
Constructor Detail
-
EmbedField
public EmbedField(boolean inline, @NotNull @NotNull String name, @NotNull @NotNull String value)
Creates a new embed field- Parameters:
inline
- Whether or not this should share a row with other fieldsname
- The name of the fieldvalue
- The value of the field- See Also:
WebhookEmbedBuilder.addField(club.minnced.discord.webhook.send.WebhookEmbed.EmbedField)
-
-
Method Detail
-
isInline
public boolean isInline()
Whether this field should share a row with other fields- Returns:
- True, if this should be in the same row as other fields
-
getName
@NotNull public @NotNull String getName()
The name of this field.
This is displayed above the value in a bold font.- Returns:
- The name
-
getValue
@NotNull public @NotNull String getValue()
The value of this field.
This is displayed below the name in a regular font.- Returns:
- The value
-
toString
public String toString()
JSON representation of this field
-
toJSONString
public String toJSONString()
- Specified by:
toJSONString
in interfaceorg.json.JSONString
-
-