import 'package:syncrow_web/pages/spaces_management/space_model/models/space_template_model.dart';
import 'package:syncrow_web/pages/spaces_management/space_model/models/subspace_template_model.dart';

class SubSpaceModelState {
  final List<SubspaceTemplateModel> subSpaces;
  final List<UpdateSubspaceTemplateModel> updatedSubSpaceModels;
  final String errorMessage;
  final Set<String> duplicates;

  SubSpaceModelState(
    this.subSpaces,
    this.updatedSubSpaceModels,
    this.errorMessage,
    this.duplicates,
  );

  SubSpaceModelState copyWith({
    List<SubspaceTemplateModel>? subSpaces,
    List<UpdateSubspaceTemplateModel>? updatedSubSpaceModels,
    String? errorMessage,
    Set<String>? duplicates,
  }) {
    return SubSpaceModelState(
      subSpaces ?? this.subSpaces,
      updatedSubSpaceModels ?? this.updatedSubSpaceModels,
      errorMessage ?? this.errorMessage,
      duplicates ?? this.duplicates,
    );
  }
}
