import 'package:equatable/equatable.dart'; enum ServerType { gcore, geviscope } class Server extends Equatable { final String id; final String alias; final String host; final String user; final String password; final bool enabled; final bool deactivateEcho; final bool deactivateLiveCheck; final ServerType type; const Server({ required this.id, required this.alias, required this.host, required this.user, required this.password, required this.enabled, required this.deactivateEcho, required this.deactivateLiveCheck, required this.type, }); @override List get props => [ id, alias, host, user, password, enabled, deactivateEcho, deactivateLiveCheck, type, ]; Server copyWith({ String? id, String? alias, String? host, String? user, String? password, bool? enabled, bool? deactivateEcho, bool? deactivateLiveCheck, ServerType? type, }) { return Server( id: id ?? this.id, alias: alias ?? this.alias, host: host ?? this.host, user: user ?? this.user, password: password ?? this.password, enabled: enabled ?? this.enabled, deactivateEcho: deactivateEcho ?? this.deactivateEcho, deactivateLiveCheck: deactivateLiveCheck ?? this.deactivateLiveCheck, type: type ?? this.type, ); } }