public static string ReturnCarCollectionOverview(DataSet dataSet)
        {
            var categoriesTable = dataSet.Tables[0];
            var detailTable = dataSet.Tables[1];

            var collectionContainer = new CarCollectionOverview();

            for (var x = 0; x < categoriesTable.Rows.Count; x++)
            {
                var collection = new CarCollection(categoriesTable.Rows[x][0].ToString());
                collectionContainer.AddCategory(collection);
            }

            for (var i = 0; i < detailTable.Rows.Count; i++)
            {
                var car = new CarDetail(detailTable.Rows[i][0].ToString(), detailTable.Rows[i][1].ToString(),
                                        detailTable.Rows[i][2].ToString(), detailTable.Rows[i][3].ToString(),
                                        detailTable.Rows[i][4].ToString(), detailTable.Rows[i][5].ToString(),
                                        detailTable.Rows[i][6].ToString(), detailTable.Rows[i][7].ToString(),
                                        detailTable.Rows[i][8].ToString(), detailTable.Rows[i][9].ToString(),
                                        detailTable.Rows[i][10].ToString());

                var collection = collectionContainer.FindCollectionByName(detailTable.Rows[i][1].ToString());
                collection.AddCar(car);
            }

            return collectionContainer.ToJson();
        }
 public void AddCategory(CarCollection category)
 {
     CarCategoryCollection.Add(category);
 }
 public void AddCategory(CarCollection category)
 {
     CarCategoryCollection.Add(category);
 }