Class Embeds.Configuration
java.lang.Object
io.github.kaktushose.jdac.embeds.internal.Embeds.Configuration
- All Implemented Interfaces:
EmbedConfig
- Enclosing class:
Embeds
-
Constructor Summary
ConstructorsConstructorDescriptionConfiguration(MessageResolver messageResolver, Collection<EmbedDataSource> dataSources) Constructs a new embed configuration builder. -
Method Summary
Modifier and TypeMethodDescriptionbuild()Converts this configuration into anEmbedsinstance that should be used globally.placeholders(Entry... placeholders) Adds one or more new global placeholders.placeholders(Map<String, Object> placeholders) Adds global placeholders with the values of the given map, where the key of the map represents the name of the placeholder and the value of the map the value to replace the placeholder with.sources(EmbedDataSource... source) Adds a newEmbedDataSourcethatEmbeds can be loaded from.
-
Constructor Details
-
Configuration
Constructs a new embed configuration builder.
-
-
Method Details
-
placeholders
Description copied from interface:EmbedConfigAdds one or more new global placeholders. Global placeholders will be available for anyEmbedloaded by this API.- Specified by:
placeholdersin interfaceEmbedConfig- Parameters:
placeholders- theentriesto add- Returns:
- this instance for fluent interface
-
placeholders
Description copied from interface:EmbedConfigAdds global placeholders with the values of the given map, where the key of the map represents the name of the placeholder and the value of the map the value to replace the placeholder with.
Global placeholders will be available for any
Embedloaded by this API.- Specified by:
placeholdersin interfaceEmbedConfig- Parameters:
placeholders- theMapto get the values from- Returns:
- this instance for fluent interface
-
sources
Description copied from interface:EmbedConfigAdds a newEmbedDataSourcethatEmbeds can be loaded from.- Specified by:
sourcesin interfaceEmbedConfig- Parameters:
source- theEmbedDataSourceto add- Returns:
- this instance for fluent interface
-
build
-