From 25b458f9e9f5d9234d2e753c63c90e5290ef134b Mon Sep 17 00:00:00 2001 From: ekallin Date: Wed, 6 Dec 2023 18:57:51 +0400 Subject: [PATCH] create lab 8 --- .../DrawingLocoEqutables.cs | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 ProjectElectricLocomotive/ProjectElectricLocomotive/DrawingLocoEqutables.cs diff --git a/ProjectElectricLocomotive/ProjectElectricLocomotive/DrawingLocoEqutables.cs b/ProjectElectricLocomotive/ProjectElectricLocomotive/DrawingLocoEqutables.cs new file mode 100644 index 0000000..8e4bb74 --- /dev/null +++ b/ProjectElectricLocomotive/ProjectElectricLocomotive/DrawingLocoEqutables.cs @@ -0,0 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using ProjectElectricLocomotive.DrawingObjects; +using ProjectElectricLocomotive.Entities; +using System.Diagnostics.CodeAnalysis; + + +namespace ProjectElectricLocomotive.Generics +{ + internal class DrawingLocoEqutables : IEqualityComparer + { + public bool Equals(DrawingLocomotive? x, DrawingLocomotive? y) + { + if (x == null || x.EntityLocomotive == null) + throw new ArgumentNullException(nameof(x)); + + if (y == null || y.EntityLocomotive == null) + throw new ArgumentNullException(nameof(y)); + + + } + } +}