android_params.dart 2.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. import 'package:json_annotation/json_annotation.dart';
  2. part 'android_params.g.dart';
  3. /// Object config for Android.
  4. @JsonSerializable(explicitToJson: true)
  5. class AndroidParams {
  6. const AndroidParams({
  7. this.isCustomNotification,
  8. this.isCustomSmallExNotification,
  9. this.isShowLogo,
  10. this.logoUrl,
  11. this.isShowCallID,
  12. this.ringtonePath,
  13. this.backgroundColor,
  14. this.backgroundUrl,
  15. this.actionColor,
  16. this.textColor,
  17. this.incomingCallNotificationChannelName,
  18. this.missedCallNotificationChannelName,
  19. this.isShowFullLockedScreen,
  20. this.isImportant,
  21. this.isBot,
  22. });
  23. /// Using custom notifications.
  24. final bool? isCustomNotification;
  25. /// Using custom notification small on some devices clipped out in android.
  26. final bool? isCustomSmallExNotification;
  27. /// Show logo app inside full screen.
  28. final bool? isShowLogo;
  29. /// Logo aoo inside full screen, example: http://... https://... or "assets/abc.png"
  30. final String? logoUrl;
  31. /// Show call id app inside full screen.
  32. final bool? isShowCallID;
  33. /// File name ringtone, put file into /android/app/src/main/res/raw/ringtone_default.mp3 -> value: `ringtone_default`
  34. final String? ringtonePath;
  35. /// Incoming call screen background color.
  36. final String? backgroundColor;
  37. /// Using image background for Incoming call screen. example: http://... https://... or "assets/abc.png"
  38. final String? backgroundUrl;
  39. /// Color used in button/text on notification.
  40. final String? actionColor;
  41. /// Color used for the text in the full screen notification
  42. final String? textColor;
  43. /// Notification channel name of incoming call.
  44. final String? incomingCallNotificationChannelName;
  45. /// Notification channel name of missed call.
  46. final String? missedCallNotificationChannelName;
  47. /// Show full locked screen.
  48. final bool? isShowFullLockedScreen;
  49. /// Caller is important to the user of this device with regards to how frequently they interact.
  50. /// https://developer.android.com/reference/androidx/core/app/Person#isImportant()
  51. final bool? isImportant;
  52. /// Used primarily to identify automated tooling.
  53. /// https://developer.android.com/reference/androidx/core/app/Person#isBot()
  54. final bool? isBot;
  55. factory AndroidParams.fromJson(Map<String, dynamic> json) =>
  56. _$AndroidParamsFromJson(json);
  57. Map<String, dynamic> toJson() => _$AndroidParamsToJson(this);
  58. }