import 'package:equatable/equatable.dart';
import 'package:meta/meta.dart';

@immutable
abstract class ShoppingCartState extends Equatable {
  @override
  List<Object> get props => [];
}

class InitialShoppingCartState extends ShoppingCartState {
  @override
  String toString() {
    // TODO: implement toString
    return 'InitialShoppingCartState{}';
  }
}

class GetProductListSuccess extends ShoppingCartState {
  @override
  String toString() {
    return 'GetProductListSuccess{}';
  }
}

class ShoppingCartFailure extends ShoppingCartState {
  final String error;

  ShoppingCartFailure(this.error);

  @override
  String toString() {
    // TODO: implement toString
    return 'ShoppingCartFailure{error: $error}';
  }
}

class ShoppingCartLoading extends ShoppingCartState {
  @override
  String toString() {
    // TODO: implement toString
    return 'ShoppingCartLoading{}';
  }
}

class CheckDbState extends ShoppingCartState {
  @override
  String toString() {
    return 'CheckDbState{}';
  }
}

class PaymentSuccess extends ShoppingCartState {
  @override
  String toString() {
    return 'PaymentSuccess{}';
  }
}
