part of 'two_gang_glass_switch_bloc.dart';

@immutable
abstract class TwoGangGlassSwitchEvent extends Equatable {
  const TwoGangGlassSwitchEvent();
}

class TwoGangGlassSwitchFetchDeviceEvent extends TwoGangGlassSwitchEvent {
  final String deviceId;

  const TwoGangGlassSwitchFetchDeviceEvent(this.deviceId);

  @override
  List<Object> get props => [deviceId];
}

class TwoGangGlassSwitchControl extends TwoGangGlassSwitchEvent {
  final String deviceId;
  final String code;
  final bool value;

  const TwoGangGlassSwitchControl({
    required this.deviceId,
    required this.code,
    required this.value,
  });

  @override
  List<Object> get props => [deviceId, code, value];
}

class TwoGangGlassSwitchBatchControl extends TwoGangGlassSwitchEvent {
  final List<String> deviceIds;
  final String code;
  final bool value;

  const TwoGangGlassSwitchBatchControl({
    required this.deviceIds,
    required this.code,
    required this.value,
  });

  @override
  List<Object> get props => [deviceIds, code, value];
}

class TwoGangGlassSwitchFetchBatchStatusEvent extends TwoGangGlassSwitchEvent {
  final List<String> deviceIds;

  const TwoGangGlassSwitchFetchBatchStatusEvent(this.deviceIds);

  @override
  List<Object> get props => [deviceIds];
}

class TwoGangGlassFactoryReset extends TwoGangGlassSwitchEvent {
  final String deviceId;
  final FactoryResetModel factoryReset;

  const TwoGangGlassFactoryReset({
    required this.deviceId,
    required this.factoryReset,
  });

  @override
  List<Object> get props => [deviceId, factoryReset];
}

class StatusUpdated extends TwoGangGlassSwitchEvent {
  final TwoGangGlassStatusModel deviceStatus;

  const StatusUpdated(this.deviceStatus);

  @override
  List<Object> get props => [deviceStatus];
}
