mirror of
https://git.selfprivacy.org/kherel/selfprivacy.org.app.git
synced 2024-11-19 07:09:14 +00:00
35 lines
560 B
Dart
35 lines
560 B
Dart
import 'package:hive/hive.dart';
|
|
|
|
part 'server_domain.g.dart';
|
|
|
|
@HiveType(typeId: 3)
|
|
class ServerDomain {
|
|
ServerDomain({
|
|
required this.domainName,
|
|
required this.zoneId,
|
|
required this.provider,
|
|
});
|
|
|
|
@HiveField(0)
|
|
final String domainName;
|
|
|
|
@HiveField(1)
|
|
final String zoneId;
|
|
|
|
@HiveField(2, defaultValue: DnsProvider.Cloudflare)
|
|
final DnsProvider provider;
|
|
|
|
@override
|
|
String toString() {
|
|
return '$domainName: $zoneId';
|
|
}
|
|
}
|
|
|
|
@HiveType(typeId: 100)
|
|
enum DnsProvider {
|
|
@HiveField(0)
|
|
Unknown,
|
|
@HiveField(1)
|
|
Cloudflare,
|
|
}
|