import 'package:freezed_annotation/freezed_annotation.dart';
import 'package:flutter/foundation.dart';

import 'ad_config.dart';
import 'ranks.dart';
import 'groups.dart';
import 'user.dart';
import 'app_config.dart';
import 'upgrade.dart';

part 'launch.freezed.dart';
part 'launch.g.dart';

@freezed
class Launch with _$Launch {
  const factory Launch({
    User? userConfig,
    AppConfig? appConfig,
    Upgrade? upgradeConfig,
    AdConfig? adConfig,
    Groups? groups,
    List<Ranks>? ranks,
    dynamic exData,
    List<dynamic>? nodes,
    String? tunnelConfig,
    int? socksPort,
  }) = _Launch;

  factory Launch.fromJson(Map<String, Object?> json) => _$LaunchFromJson(json);
}
