diff options
author | Toby Vincent <tobyv13@gmail.com> | 2021-04-22 01:07:58 -0500 |
---|---|---|
committer | Toby Vincent <tobyv13@gmail.com> | 2021-05-02 15:00:44 -0500 |
commit | cfcca407247236c785d6e09678ffd848444fb3f7 (patch) | |
tree | 95c0d24ba9f68fdba9ac3a3607f8874eccca9fe5 | |
parent | 98bc754455679574c87bd876117846c7621c423e (diff) |
Signed-off-by: Toby Vincent <tobyv13@gmail.com>
-rw-r--r-- | IEdge.cs | 11 | ||||
-rw-r--r-- | IVertex.cs | 13 | ||||
-rw-r--r-- | Interfaces.csproj (renamed from CS340.Interfaces.csproj) | 0 |
3 files changed, 24 insertions, 0 deletions
diff --git a/IEdge.cs b/IEdge.cs new file mode 100644 index 0000000..4fb68da --- /dev/null +++ b/IEdge.cs @@ -0,0 +1,11 @@ +using System; + +namespace Interfaces +{ + public interface IEdge<T> where T : IComparable<T> + { + int U { get; set; } + int V { get; set; } + T Weight { get; set; } + } +} diff --git a/IVertex.cs b/IVertex.cs new file mode 100644 index 0000000..40165db --- /dev/null +++ b/IVertex.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; + +namespace Interfaces +{ + public interface IVertex<T, U> : INode<U>, IComparable<INode<U>> + where T : IEdge<U>, new() + where U : IComparable<U> + { + List<T> Edges { get; set; } + int Parent { get; set; } + } +} diff --git a/CS340.Interfaces.csproj b/Interfaces.csproj index b76c640..b76c640 100644 --- a/CS340.Interfaces.csproj +++ b/Interfaces.csproj |