defaultValue property
Set true
to use this enum value as default value instead of null in
null-safety.
This property currently only used for enum types. In future might be used for other properties too. If the defaultValue is not provided the first enum will be used as default value.
@HiveType(typeId: 1)
enum MyEnum {
@HiveField(0)
apple,
@HiveField(1, defaultValue: true)
pear
}
Implementation
final bool defaultValue;