PollCreateParams constructor

PollCreateParams({
  1. required String title,
  2. required List<String> options,
  3. PollData? data,
  4. bool? allowUserSuggestion,
  5. bool? allowMultipleVotes,
  6. int closeAt = -1,
})

Implementation

PollCreateParams({
  required this.title,
  required this.options,
  this.data,
  this.allowUserSuggestion,
  this.allowMultipleVotes,
  this.closeAt = -1, // Default value
})  : assert(options.isNotEmpty && options.length <= 20),
      assert(title.length <= 2000);