Class EmbedFooterBuilder
Represents a builder class for an embed footer.
Inheritance
System.Object
EmbedFooterBuilder
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Discord
Assembly: Discord.Net.Core.dll
Syntax
public class EmbedFooterBuilder
Fields
| Improve this Doc View SourceMaxFooterTextLength
Gets the maximum footer length allowed by Discord.
Declaration
public const int MaxFooterTextLength = 2048
Field Value
| Type | Description |
|---|---|
| System.Int32 |
Properties
| Improve this Doc View SourceIconUrl
Gets or sets the icon URL of the footer field.
Declaration
public string IconUrl { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | The icon URL of the footer field. |
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentException | Url is not a well-formed System.Uri. |
Text
Gets or sets the footer text.
Declaration
public string Text { get; set; }
Property Value
| Type | Description |
|---|---|
| System.String | The footer text. |
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentException | Author name length is longer than MaxFooterTextLength. |
Methods
| Improve this Doc View SourceBuild()
Builds the footer field to be used.
Declaration
public EmbedFooter Build()
Returns
| Type | Description |
|---|---|
| EmbedFooter |
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentException | Text length is longer than MaxFooterTextLength.
IconUrl is not a well-formed System.Uri. |
WithIconUrl(String)
Sets the icon URL of the footer field.
Declaration
public EmbedFooterBuilder WithIconUrl(string iconUrl)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | iconUrl | The icon URL of the footer field. |
Returns
| Type | Description |
|---|---|
| EmbedFooterBuilder | The current builder. |
WithText(String)
Sets the name of the footer field.
Declaration
public EmbedFooterBuilder WithText(string text)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | text | The text of the footer field. |
Returns
| Type | Description |
|---|---|
| EmbedFooterBuilder | The current builder. |