mirror of
https://github.com/rudollee/LearningMVC.git
synced 2025-06-07 16:06:21 +00:00
23 lines
422 B
C#
23 lines
422 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Web;
|
|
|
|
namespace LanguageFeatures.Models
|
|
{
|
|
public class ShoppingCart: IEnumerable<Product>
|
|
{
|
|
public List<Product> Products { get; set; }
|
|
|
|
public IEnumerator<Product> GetEnumerator()
|
|
{
|
|
return Products.GetEnumerator();
|
|
}
|
|
|
|
IEnumerator IEnumerable.GetEnumerator()
|
|
{
|
|
return GetEnumerator();
|
|
}
|
|
}
|
|
} |