constructor property

String? constructor
final

The name of the constructor that should be used for copyWith() Example: CopyWith.fromJson(Map<String, Object?> json) will be fromJson.

  • null enables auto guessing of the constructor (the default)
  • "" (Empty string) will use the default constructor
  • "_example" will use the _example constructor

Implementation

// The displayName would be `CopyWith.fromJson`
///
/// * `null` enables auto guessing of the constructor (the default)
/// * `""` (Empty string) will use the default constructor
/// * `"_example"` will use the _example constructor
final String? constructor;