Map<String, dynamic> toJson() => { "path": path, "orientation": orientation, "barcodes": List<dynamic>.from(barcodes.map((x) => x.toJson())), };