// coverage:ignore-file
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint
// ignore_for_file: unused_element, deprecated_member_use, deprecated_member_use_from_same_package, use_function_type_syntax_for_parameters, unnecessary_const, avoid_init_to_null, invalid_override_different_default_values_named, prefer_expression_function_bodies, annotate_overrides, invalid_annotation_target, unnecessary_question_mark

part of 'company_branch_flat_dto.dart';

// **************************************************************************
// FreezedGenerator
// **************************************************************************

T _$identity<T>(T value) => value;

final _privateConstructorUsedError = UnsupportedError(
    'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models');

CompanyBranchFlatDto _$CompanyBranchFlatDtoFromJson(Map<String, dynamic> json) {
  return _CompanyBranchFlatDto.fromJson(json);
}

/// @nodoc
mixin _$CompanyBranchFlatDto {
  @JsonKey(name: 'company_id')
  int get companyId => throw _privateConstructorUsedError;
  @JsonKey(name: 'company_name')
  String get companyName => throw _privateConstructorUsedError;
  @JsonKey(name: 'branch_id')
  int? get branchId => throw _privateConstructorUsedError;
  @JsonKey(name: 'branch_name')
  String? get branchName => throw _privateConstructorUsedError;
  @JsonKey(name: 'company_types')
  List<String>? get companyTypes => throw _privateConstructorUsedError;
  @JsonKey(name: 'is_partner')
  bool get isPartner => throw _privateConstructorUsedError;
  @JsonKey(name: 'is_customer')
  bool get isCustomer => throw _privateConstructorUsedError;

  /// Serializes this CompanyBranchFlatDto to a JSON map.
  Map<String, dynamic> toJson() => throw _privateConstructorUsedError;

  /// Create a copy of CompanyBranchFlatDto
  /// with the given fields replaced by the non-null parameter values.
  @JsonKey(includeFromJson: false, includeToJson: false)
  $CompanyBranchFlatDtoCopyWith<CompanyBranchFlatDto> get copyWith =>
      throw _privateConstructorUsedError;
}

/// @nodoc
abstract class $CompanyBranchFlatDtoCopyWith<$Res> {
  factory $CompanyBranchFlatDtoCopyWith(CompanyBranchFlatDto value,
          $Res Function(CompanyBranchFlatDto) then) =
      _$CompanyBranchFlatDtoCopyWithImpl<$Res, CompanyBranchFlatDto>;
  @useResult
  $Res call(
      {@JsonKey(name: 'company_id') int companyId,
      @JsonKey(name: 'company_name') String companyName,
      @JsonKey(name: 'branch_id') int? branchId,
      @JsonKey(name: 'branch_name') String? branchName,
      @JsonKey(name: 'company_types') List<String>? companyTypes,
      @JsonKey(name: 'is_partner') bool isPartner,
      @JsonKey(name: 'is_customer') bool isCustomer});
}

/// @nodoc
class _$CompanyBranchFlatDtoCopyWithImpl<$Res,
        $Val extends CompanyBranchFlatDto>
    implements $CompanyBranchFlatDtoCopyWith<$Res> {
  _$CompanyBranchFlatDtoCopyWithImpl(this._value, this._then);

  // ignore: unused_field
  final $Val _value;
  // ignore: unused_field
  final $Res Function($Val) _then;

  /// Create a copy of CompanyBranchFlatDto
  /// with the given fields replaced by the non-null parameter values.
  @pragma('vm:prefer-inline')
  @override
  $Res call({
    Object? companyId = null,
    Object? companyName = null,
    Object? branchId = freezed,
    Object? branchName = freezed,
    Object? companyTypes = freezed,
    Object? isPartner = null,
    Object? isCustomer = null,
  }) {
    return _then(_value.copyWith(
      companyId: null == companyId
          ? _value.companyId
          : companyId // ignore: cast_nullable_to_non_nullable
              as int,
      companyName: null == companyName
          ? _value.companyName
          : companyName // ignore: cast_nullable_to_non_nullable
              as String,
      branchId: freezed == branchId
          ? _value.branchId
          : branchId // ignore: cast_nullable_to_non_nullable
              as int?,
      branchName: freezed == branchName
          ? _value.branchName
          : branchName // ignore: cast_nullable_to_non_nullable
              as String?,
      companyTypes: freezed == companyTypes
          ? _value.companyTypes
          : companyTypes // ignore: cast_nullable_to_non_nullable
              as List<String>?,
      isPartner: null == isPartner
          ? _value.isPartner
          : isPartner // ignore: cast_nullable_to_non_nullable
              as bool,
      isCustomer: null == isCustomer
          ? _value.isCustomer
          : isCustomer // ignore: cast_nullable_to_non_nullable
              as bool,
    ) as $Val);
  }
}

/// @nodoc
abstract class _$$CompanyBranchFlatDtoImplCopyWith<$Res>
    implements $CompanyBranchFlatDtoCopyWith<$Res> {
  factory _$$CompanyBranchFlatDtoImplCopyWith(_$CompanyBranchFlatDtoImpl value,
          $Res Function(_$CompanyBranchFlatDtoImpl) then) =
      __$$CompanyBranchFlatDtoImplCopyWithImpl<$Res>;
  @override
  @useResult
  $Res call(
      {@JsonKey(name: 'company_id') int companyId,
      @JsonKey(name: 'company_name') String companyName,
      @JsonKey(name: 'branch_id') int? branchId,
      @JsonKey(name: 'branch_name') String? branchName,
      @JsonKey(name: 'company_types') List<String>? companyTypes,
      @JsonKey(name: 'is_partner') bool isPartner,
      @JsonKey(name: 'is_customer') bool isCustomer});
}

/// @nodoc
class __$$CompanyBranchFlatDtoImplCopyWithImpl<$Res>
    extends _$CompanyBranchFlatDtoCopyWithImpl<$Res, _$CompanyBranchFlatDtoImpl>
    implements _$$CompanyBranchFlatDtoImplCopyWith<$Res> {
  __$$CompanyBranchFlatDtoImplCopyWithImpl(_$CompanyBranchFlatDtoImpl _value,
      $Res Function(_$CompanyBranchFlatDtoImpl) _then)
      : super(_value, _then);

  /// Create a copy of CompanyBranchFlatDto
  /// with the given fields replaced by the non-null parameter values.
  @pragma('vm:prefer-inline')
  @override
  $Res call({
    Object? companyId = null,
    Object? companyName = null,
    Object? branchId = freezed,
    Object? branchName = freezed,
    Object? companyTypes = freezed,
    Object? isPartner = null,
    Object? isCustomer = null,
  }) {
    return _then(_$CompanyBranchFlatDtoImpl(
      companyId: null == companyId
          ? _value.companyId
          : companyId // ignore: cast_nullable_to_non_nullable
              as int,
      companyName: null == companyName
          ? _value.companyName
          : companyName // ignore: cast_nullable_to_non_nullable
              as String,
      branchId: freezed == branchId
          ? _value.branchId
          : branchId // ignore: cast_nullable_to_non_nullable
              as int?,
      branchName: freezed == branchName
          ? _value.branchName
          : branchName // ignore: cast_nullable_to_non_nullable
              as String?,
      companyTypes: freezed == companyTypes
          ? _value._companyTypes
          : companyTypes // ignore: cast_nullable_to_non_nullable
              as List<String>?,
      isPartner: null == isPartner
          ? _value.isPartner
          : isPartner // ignore: cast_nullable_to_non_nullable
              as bool,
      isCustomer: null == isCustomer
          ? _value.isCustomer
          : isCustomer // ignore: cast_nullable_to_non_nullable
              as bool,
    ));
  }
}

/// @nodoc
@JsonSerializable()
class _$CompanyBranchFlatDtoImpl implements _CompanyBranchFlatDto {
  const _$CompanyBranchFlatDtoImpl(
      {@JsonKey(name: 'company_id') required this.companyId,
      @JsonKey(name: 'company_name') required this.companyName,
      @JsonKey(name: 'branch_id') this.branchId,
      @JsonKey(name: 'branch_name') this.branchName,
      @JsonKey(name: 'company_types') final List<String>? companyTypes,
      @JsonKey(name: 'is_partner') this.isPartner = false,
      @JsonKey(name: 'is_customer') this.isCustomer = false})
      : _companyTypes = companyTypes;

  factory _$CompanyBranchFlatDtoImpl.fromJson(Map<String, dynamic> json) =>
      _$$CompanyBranchFlatDtoImplFromJson(json);

  @override
  @JsonKey(name: 'company_id')
  final int companyId;
  @override
  @JsonKey(name: 'company_name')
  final String companyName;
  @override
  @JsonKey(name: 'branch_id')
  final int? branchId;
  @override
  @JsonKey(name: 'branch_name')
  final String? branchName;
  final List<String>? _companyTypes;
  @override
  @JsonKey(name: 'company_types')
  List<String>? get companyTypes {
    final value = _companyTypes;
    if (value == null) return null;
    if (_companyTypes is EqualUnmodifiableListView) return _companyTypes;
    // ignore: implicit_dynamic_type
    return EqualUnmodifiableListView(value);
  }

  @override
  @JsonKey(name: 'is_partner')
  final bool isPartner;
  @override
  @JsonKey(name: 'is_customer')
  final bool isCustomer;

  @override
  String toString() {
    return 'CompanyBranchFlatDto(companyId: $companyId, companyName: $companyName, branchId: $branchId, branchName: $branchName, companyTypes: $companyTypes, isPartner: $isPartner, isCustomer: $isCustomer)';
  }

  @override
  bool operator ==(Object other) {
    return identical(this, other) ||
        (other.runtimeType == runtimeType &&
            other is _$CompanyBranchFlatDtoImpl &&
            (identical(other.companyId, companyId) ||
                other.companyId == companyId) &&
            (identical(other.companyName, companyName) ||
                other.companyName == companyName) &&
            (identical(other.branchId, branchId) ||
                other.branchId == branchId) &&
            (identical(other.branchName, branchName) ||
                other.branchName == branchName) &&
            const DeepCollectionEquality()
                .equals(other._companyTypes, _companyTypes) &&
            (identical(other.isPartner, isPartner) ||
                other.isPartner == isPartner) &&
            (identical(other.isCustomer, isCustomer) ||
                other.isCustomer == isCustomer));
  }

  @JsonKey(includeFromJson: false, includeToJson: false)
  @override
  int get hashCode => Object.hash(
      runtimeType,
      companyId,
      companyName,
      branchId,
      branchName,
      const DeepCollectionEquality().hash(_companyTypes),
      isPartner,
      isCustomer);

  /// Create a copy of CompanyBranchFlatDto
  /// with the given fields replaced by the non-null parameter values.
  @JsonKey(includeFromJson: false, includeToJson: false)
  @override
  @pragma('vm:prefer-inline')
  _$$CompanyBranchFlatDtoImplCopyWith<_$CompanyBranchFlatDtoImpl>
      get copyWith =>
          __$$CompanyBranchFlatDtoImplCopyWithImpl<_$CompanyBranchFlatDtoImpl>(
              this, _$identity);

  @override
  Map<String, dynamic> toJson() {
    return _$$CompanyBranchFlatDtoImplToJson(
      this,
    );
  }
}

abstract class _CompanyBranchFlatDto implements CompanyBranchFlatDto {
  const factory _CompanyBranchFlatDto(
          {@JsonKey(name: 'company_id') required final int companyId,
          @JsonKey(name: 'company_name') required final String companyName,
          @JsonKey(name: 'branch_id') final int? branchId,
          @JsonKey(name: 'branch_name') final String? branchName,
          @JsonKey(name: 'company_types') final List<String>? companyTypes,
          @JsonKey(name: 'is_partner') final bool isPartner,
          @JsonKey(name: 'is_customer') final bool isCustomer}) =
      _$CompanyBranchFlatDtoImpl;

  factory _CompanyBranchFlatDto.fromJson(Map<String, dynamic> json) =
      _$CompanyBranchFlatDtoImpl.fromJson;

  @override
  @JsonKey(name: 'company_id')
  int get companyId;
  @override
  @JsonKey(name: 'company_name')
  String get companyName;
  @override
  @JsonKey(name: 'branch_id')
  int? get branchId;
  @override
  @JsonKey(name: 'branch_name')
  String? get branchName;
  @override
  @JsonKey(name: 'company_types')
  List<String>? get companyTypes;
  @override
  @JsonKey(name: 'is_partner')
  bool get isPartner;
  @override
  @JsonKey(name: 'is_customer')
  bool get isCustomer;

  /// Create a copy of CompanyBranchFlatDto
  /// with the given fields replaced by the non-null parameter values.
  @override
  @JsonKey(includeFromJson: false, includeToJson: false)
  _$$CompanyBranchFlatDtoImplCopyWith<_$CompanyBranchFlatDtoImpl>
      get copyWith => throw _privateConstructorUsedError;
}
