Interface JDACProperty<T>
- All Superinterfaces:
SpecificProperty<T>
- All Known Implementing Classes:
JDACEnumerationProperty, JDACMappingProperty, JDACSingletonProperty
A JDACProperty is an identifier for a certain component of a JDA-Commands.
A JDA-Commands component is just some sort of arbitrary information. That could be some service like MessageResolver,
some setting configured by the user via a builder (like JDACBuilder.localizeCommands(boolean)), a custom implementation of an interface
(like Instantiator) or something else.
There are basically 3 types of properties:
- Singleton for values consisting of one instance
- Enumeration for values consisting of multiple instances (reference to
Collection) - Mapping for values representing a mapping between keys and values (reference to
Map)
Beside their purpose, each type hold a slightly different set of information, but they share some common values: - a unique name - a scope to which this property is bound - a source, from which the values of this property can be retrieved.
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Collection<JDACProperty<?>> A collection consisting of allPropertys that are settable by the user through JDACBuilderstatic final JDACProperty<Collection<ClassFinder>> static final JDACProperty<Definitions> TheDefinitionsinstance available after fully starting the framework.static final JDACProperty<Descriptor> static final JDACProperty<Consumer<EmbedConfig>> static final JDACProperty<Collection<EmbedDataSource>> static final JDACProperty<EmojiResolver> TheEmojiResolverservice provided by JDA-Commands.static final JDACProperty<Collection<EmojiSource>> static final JDACProperty<ErrorMessageFactory> static final JDACProperty<ExpirationStrategy> static final Collection<JDACProperty<?>> A collection consisting of allPropertys that are settable by the user and loadable through extensionsstatic final JDACProperty<Map<Class<? extends Extension.Data>, Extension.Data>> static final JDACProperty<ExtensionFilter> static final JDACProperty<CommandDefinition.CommandConfig> static final JDACProperty<InteractionDefinition.ReplyConfig> static final JDACProperty<GuildScopeProvider> static final JDACProperty<I18n> TheI18nservice provided by JDA-Commands.static final JDACProperty<Instantiator> static final JDACProperty<JDACIntrospection> TheJDACIntrospectioninstance itself used to retrieve properties in this scope.static final JDACProperty<InvocationContext<?>> TheInvocationContextof this interaction.static final JDACProperty<JDA> TheJDAinstance bound to this specific Runtime.static final JDACProperty<JDACommands> TheJDACommandsinstance available after fully starting the framework.static final JDACProperty<GenericInteractionCreateEvent> TheGenericInteractionCreateEventof this interaction.static final JDACProperty<KeyValueStore> TheKeyValueStoreassociated with this runtime.static final JDACProperty<LocalizationFunction> TheLocalizationFunctionbacked byMessageResolverused to localize/resolve commands and descriptions.static final JDACProperty<Boolean> static final JDACProperty<Localizer> static final JDACProperty<ClassFinder> static final JDACProperty<MessageResolver> TheMessageResolverservice provided byt JDA-Commands.static final JDACProperty<Collection<Map.Entry<Priority, Middleware>>> MIDDLEWARE property holds multipleMiddlewares associated with theirPrioritystatic final JDACProperty<Collection<String>> static final JDACProperty<PermissionsProvider> static final JDACProperty<PlaceholderResolver> ThePlaceholderResolverservice provided by JDA-Commands.static final Collection<JDACProperty<?>> A collection consisting of allPropertys that are provided by JDA-Commandsstatic final JDACProperty<String> The identifier bound to this runtime.static final JDACProperty<Boolean> static final JDACProperty<Collection<Resolver<String>>> static final JDACProperty<Map<AdapterType<?, ?>, TypeAdapter<?, ?>>> The TYPE_ADAPTER property mapsAdapterTypes containing the source and targetsTypes to their associatedTypeAdapterstatic final JDACProperty<Map<Class<? extends Annotation>, Validator<?, ?>>> The VALIDATOR property maps aValidatorto its identifying annotation. -
Method Summary
Methods inherited from interface SpecificProperty
generalized, scopedGet
-
Field Details
-
CLASS_FINDER
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=IGNORE) static final JDACProperty<Collection<ClassFinder>> CLASS_FINDER- See Also:
-
EMOJI_SOURCES
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=IGNORE) static final JDACProperty<Collection<EmojiSource>> EMOJI_SOURCES- See Also:
-
EMBED_SOURCES
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=COMBINE) static final JDACProperty<Collection<EmbedDataSource>> EMBED_SOURCES- See Also:
-
DESCRIPTOR
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION) static final JDACProperty<Descriptor> DESCRIPTOR- See Also:
-
LOCALIZER
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION) static final JDACProperty<Localizer> LOCALIZER- See Also:
-
INSTANTIATOR
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION) static final JDACProperty<Instantiator> INSTANTIATOR- See Also:
-
MIDDLEWARE
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=COMBINE) static final JDACProperty<Collection<Map.Entry<Priority, Middleware>>> MIDDLEWAREMIDDLEWARE property holds multipleMiddlewares associated with theirPriority- See Also:
-
TYPE_ADAPTER
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=COMBINE) static final JDACProperty<Map<AdapterType<?,?>, TypeAdapter<?, TYPE_ADAPTER?>>> The TYPE_ADAPTER property mapsAdapterTypes containing the source and targetsTypes to their associatedTypeAdapter- See Also:
-
VALIDATOR
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=COMBINE) static final JDACProperty<Map<Class<? extends Annotation>, Validator<?,?>>> VALIDATORThe VALIDATOR property maps aValidatorto its identifying annotation.- See Also:
-
PERMISSION_PROVIDER
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION) static final JDACProperty<PermissionsProvider> PERMISSION_PROVIDER- See Also:
-
ERROR_MESSAGE_FACTORY
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION) static final JDACProperty<ErrorMessageFactory> ERROR_MESSAGE_FACTORY- See Also:
-
GUILD_SCOPE_PROVIDER
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION) static final JDACProperty<GuildScopeProvider> GUILD_SCOPE_PROVIDER- See Also:
-
STRING_RESOLVER
@PropertyInformation(scope=CONFIGURATION, source=EXTENSION, fallbackBehaviour=COMBINE) static final JDACProperty<Collection<Resolver<String>>> STRING_RESOLVER- See Also:
-
GLOBAL_COMMAND_CONFIG
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<CommandDefinition.CommandConfig> GLOBAL_COMMAND_CONFIG- See Also:
-
GLOBAL_REPLY_CONFIG
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<InteractionDefinition.ReplyConfig> GLOBAL_REPLY_CONFIG- See Also:
-
PACKAGES
@PropertyInformation(scope=CONFIGURATION, source=BUILDER, fallbackBehaviour=COMBINE) static final JDACProperty<Collection<String>> PACKAGES- See Also:
-
EXPIRATION_STRATEGY
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<ExpirationStrategy> EXPIRATION_STRATEGY- See Also:
-
LOCALIZE_COMMANDS
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<Boolean> LOCALIZE_COMMANDS- See Also:
-
SHUTDOWN_JDA
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<Boolean> SHUTDOWN_JDA- See Also:
-
EXTENSION_DATA
@PropertyInformation(scope=CONFIGURATION, source=BUILDER, fallbackBehaviour=COMBINE) static final JDACProperty<Map<Class<? extends Extension.Data>, Extension.Data>> EXTENSION_DATA- See Also:
-
EXTENSION_FILTER
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<ExtensionFilter> EXTENSION_FILTER- See Also:
-
EMBED_CONFIG
@PropertyInformation(scope=CONFIGURATION, source=BUILDER) static final JDACProperty<Consumer<EmbedConfig>> EMBED_CONFIG- See Also:
-
INTROSPECTION
@PropertyInformation(scope=CONFIGURATION, source=PROVIDED) static final JDACProperty<JDACIntrospection> INTROSPECTIONTheJDACIntrospectioninstance itself used to retrieve properties in this scope. -
I18N
- Implementation Note:
- the
JDACPropertyProviderfor this value is defined in the constructor ofJDACBuilder
-
MESSAGE_RESOLVER
@PropertyInformation(scope=CONFIGURATION, source=PROVIDED) static final JDACProperty<MessageResolver> MESSAGE_RESOLVER- Implementation Note:
- the
JDACPropertyProviderfor this value is defined in the constructor ofJDACBuilder
-
EMOJI_RESOLVER
@PropertyInformation(scope=CONFIGURATION, source=PROVIDED) static final JDACProperty<EmojiResolver> EMOJI_RESOLVERTheEmojiResolverservice provided by JDA-Commands. Needs the value ofEMOJI_RESOLVER.- Implementation Note:
- the
JDACPropertyProviderfor this value is defined in the constructor ofJDACBuilder
-
PLACEHOLDER_RESOLVER
@PropertyInformation(scope=CONFIGURATION, source=PROVIDED) static final JDACProperty<PlaceholderResolver> PLACEHOLDER_RESOLVERThePlaceholderResolverservice provided by JDA-Commands.- Implementation Note:
- the
JDACPropertyProviderfor this value is defined in the constructor ofJDACBuilder
-
MERGED_CLASS_FINDER
@PropertyInformation(scope=CONFIGURATION, source=PROVIDED) static final JDACProperty<ClassFinder> MERGED_CLASS_FINDERAnClassFinderinstance that is backed by allClassFinderofCLASS_FINDER. It will search in all registeredClassFinderfor the requested class.- Implementation Note:
- the
JDACPropertyProviderfor this value is defined in the constructor ofJDACBuilder
-
JDA_COMMANDS
@PropertyInformation(scope=INITIALIZED, source=PROVIDED) static final JDACProperty<JDACommands> JDA_COMMANDSTheJDACommandsinstance available after fully starting the framework. -
DEFINITIONS
@PropertyInformation(scope=INITIALIZED, source=PROVIDED) static final JDACProperty<Definitions> DEFINITIONSTheDefinitionsinstance available after fully starting the framework. -
LOCALIZATION_FUNCTION
@PropertyInformation(scope=INITIALIZED, source=PROVIDED) static final JDACProperty<LocalizationFunction> LOCALIZATION_FUNCTIONTheLocalizationFunctionbacked byMessageResolverused to localize/resolve commands and descriptions.- See Also:
-
JDA
TheJDAinstance bound to this specific Runtime. -
RUNTIME_ID
The identifier bound to this runtime. Same asEvent.runtimeId(). -
KEY_VALUE_STORE
@PropertyInformation(scope=RUNTIME, source=PROVIDED) static final JDACProperty<KeyValueStore> KEY_VALUE_STORETheKeyValueStoreassociated with this runtime. Same asInvocationContext.keyValueStore()orEvent.kv(). -
JDA_EVENT
@PropertyInformation(scope=PREPARATION, source=PROVIDED) static final JDACProperty<GenericInteractionCreateEvent> JDA_EVENTTheGenericInteractionCreateEventof this interaction. Same asEvent.jdaEvent(). -
INVOCATION_CONTEXT
@PropertyInformation(scope=INTERACTION, source=PROVIDED) static final JDACProperty<InvocationContext<?>> INVOCATION_CONTEXTTheInvocationContextof this interaction. Same as inMiddleware.accept(InvocationContext). -
EXTENSION
A collection consisting of allPropertys that are settable by the user and loadable through extensions- See Also:
-
BUILDER
A collection consisting of allPropertys that are settable by the user through JDACBuilder- See Also:
-
PROVIDED
A collection consisting of allPropertys that are provided by JDA-Commands- See Also:
-