Interface StoreLayout
- All Known Implementing Classes:
LegacyStoreLayout
,LocalStoreLayout
public interface StoreLayout
A
StoreLayout
defines how store actions should be handled according to their type. It enforces an
implementation for a minimal set of actions required by Discord4J, and enables the declaration of custom action
types.-
Method Summary
Modifier and TypeMethodDescriptiondefault ActionMapper
Defines a mapping for custom action types.Returns aDataAccessor
that defines action handlers for reading data from the store.Returns aGatewayDataUpdater
that defines action handlers for updates received from the Discord gateway.
-
Method Details
-
getDataAccessor
DataAccessor getDataAccessor()Returns aDataAccessor
that defines action handlers for reading data from the store.- Returns:
- a
DataAccessor
-
getGatewayDataUpdater
GatewayDataUpdater getGatewayDataUpdater()Returns aGatewayDataUpdater
that defines action handlers for updates received from the Discord gateway.- Returns:
- a
GatewayDataUpdater
-
getCustomActionMapper
Defines a mapping for custom action types. By default returns an emptyActionMapper
, implementations may override this method to supply custom mappings.- Returns:
- an
ActionMapper
-