Package io.jmix.notifications
Interface NotificationTypesRepository
- All Known Implementing Classes:
 NotificationTypesRepositoryImpl
public interface NotificationTypesRepository
Service that allows to register notification types and get information about available ones.
- 
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enum - 
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Unregisters all notification types.Gets all available notification typesgetTypeByNameOpt(String name) Tries to get notification type by provided name.voidregisterTypes(NotificationType... notificationTypes) Registers provided notification types withNotificationTypesRepository.NotificationTypeRegistrationMode.STRICTmode.voidregisterTypes(NotificationTypesRepository.NotificationTypeRegistrationMode mode, NotificationType... notificationTypes) Registers provided notification types with provided mode 
- 
Method Details
- 
getAllTypes
Collection<NotificationType> getAllTypes()Gets all available notification types- Returns:
 - collection of notification types
 
 - 
getTypeByNameOpt
Tries to get notification type by provided name.- Parameters:
 name- type name- Returns:
 - Optional with found notification type or empty Optional if type with provided name not found
 
 - 
clear
void clear()Unregisters all notification types. - 
registerTypes
Registers provided notification types withNotificationTypesRepository.NotificationTypeRegistrationMode.STRICTmode.- Parameters:
 notificationTypes- notification types
 - 
registerTypes
void registerTypes(NotificationTypesRepository.NotificationTypeRegistrationMode mode, NotificationType... notificationTypes) Registers provided notification types with provided mode- Parameters:
 mode- registration modenotificationTypes- notification types
 
 -