
import 'dart:convert';

import 'address.dart';

class Store {
  int? id;
  String? name;
  Address? address;

  Store.fromJson(Map<String, dynamic> json)
    : id = json['id'],
      name = json['name'],
      address = Address.fromJson(json['address']);

  Map<String, dynamic> toJson() => {
    'id': id,
    'name': name,
    'address': address,
  };

  @override
  String toString() {
    return json.encode(this);
  }
}