part of 'generated.dart';

class DeleteVendorVariablesBuilder {
  String id;

  final FirebaseDataConnect _dataConnect;
  DeleteVendorVariablesBuilder(this._dataConnect, {required  this.id,});
  Deserializer<DeleteVendorData> dataDeserializer = (dynamic json)  => DeleteVendorData.fromJson(jsonDecode(json));
  Serializer<DeleteVendorVariables> varsSerializer = (DeleteVendorVariables vars) => jsonEncode(vars.toJson());
  Future<OperationResult<DeleteVendorData, DeleteVendorVariables>> execute() {
    return ref().execute();
  }

  MutationRef<DeleteVendorData, DeleteVendorVariables> ref() {
    DeleteVendorVariables vars= DeleteVendorVariables(id: id,);
    return _dataConnect.mutation("deleteVendor", dataDeserializer, varsSerializer, vars);
  }
}

@immutable
class DeleteVendorVendorDelete {
  final String id;
  DeleteVendorVendorDelete.fromJson(dynamic json):
  
  id = nativeFromJson<String>(json['id']);
  @override
  bool operator ==(Object other) {
    if(identical(this, other)) {
      return true;
    }
    if(other.runtimeType != runtimeType) {
      return false;
    }

    final DeleteVendorVendorDelete otherTyped = other as DeleteVendorVendorDelete;
    return id == otherTyped.id;
    
  }
  @override
  int get hashCode => id.hashCode;
  

  Map<String, dynamic> toJson() {
    Map<String, dynamic> json = {};
    json['id'] = nativeToJson<String>(id);
    return json;
  }

  DeleteVendorVendorDelete({
    required this.id,
  });
}

@immutable
class DeleteVendorData {
  final DeleteVendorVendorDelete? vendor_delete;
  DeleteVendorData.fromJson(dynamic json):
  
  vendor_delete = json['vendor_delete'] == null ? null : DeleteVendorVendorDelete.fromJson(json['vendor_delete']);
  @override
  bool operator ==(Object other) {
    if(identical(this, other)) {
      return true;
    }
    if(other.runtimeType != runtimeType) {
      return false;
    }

    final DeleteVendorData otherTyped = other as DeleteVendorData;
    return vendor_delete == otherTyped.vendor_delete;
    
  }
  @override
  int get hashCode => vendor_delete.hashCode;
  

  Map<String, dynamic> toJson() {
    Map<String, dynamic> json = {};
    if (vendor_delete != null) {
      json['vendor_delete'] = vendor_delete!.toJson();
    }
    return json;
  }

  DeleteVendorData({
    this.vendor_delete,
  });
}

@immutable
class DeleteVendorVariables {
  final String id;
  @Deprecated('fromJson is deprecated for Variable classes as they are no longer required for deserialization.')
  DeleteVendorVariables.fromJson(Map<String, dynamic> json):
  
  id = nativeFromJson<String>(json['id']);
  @override
  bool operator ==(Object other) {
    if(identical(this, other)) {
      return true;
    }
    if(other.runtimeType != runtimeType) {
      return false;
    }

    final DeleteVendorVariables otherTyped = other as DeleteVendorVariables;
    return id == otherTyped.id;
    
  }
  @override
  int get hashCode => id.hashCode;
  

  Map<String, dynamic> toJson() {
    Map<String, dynamic> json = {};
    json['id'] = nativeToJson<String>(id);
    return json;
  }

  DeleteVendorVariables({
    required this.id,
  });
}

