コード例 #1
0
ファイル: PosScratch.cs プロジェクト: sonygunawan/eShopping
        static void Main(string[] args)
        {
            var service = new ProductService(new ProductEFRepository());
            Console.WriteLine(service.GenerateCode());

            //var product = service.New();

            var product = new Product { Id = 1, Code = "P01", Name = "Test" };
            var product1 = new Product { Id = 1, Code = "P01", Name = "Test" };

            Console.WriteLine(product == product1);
            Console.WriteLine(product.Equals(product1));
            Console.WriteLine(product.GetHashCode());
            Console.WriteLine(product1.GetHashCode());
        }