register method
Implementation
void register(
NotificationAction action, {
NotificationActionCallback? handler,
}) {
_validateId(action.id);
if (action.title.trim().isEmpty) {
throw const InvalidNotificationPayloadException(
'Action title must not be empty.',
);
}
_actions[action.id] = action;
if (handler != null) _handlers[action.id] = handler;
}