From 4249a9aa9db496531116280aae3e383217ef85f3 Mon Sep 17 00:00:00 2001 From: Simon Gockner Date: Mon, 27 Jan 2020 11:58:45 +0100 Subject: [PATCH] - add type to IGBaseTable --- GBase/GBaseTable.cs | 11 +++++++++-- GBase/Interfaces/IGBaseTable.cs | 8 +++++++- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/GBase/GBaseTable.cs b/GBase/GBaseTable.cs index b0c347c..712dcab 100644 --- a/GBase/GBaseTable.cs +++ b/GBase/GBaseTable.cs @@ -23,6 +23,11 @@ namespace GBase Entries = new List(); } + /// + /// The of the class that this represents + /// + public Type Type { get; private set; } + /// /// The name of this /// @@ -37,11 +42,13 @@ namespace GBase /// /// Initialize this /// + /// The of the class that this represents /// The name of this /// A to cancel the asynchronous operation /// True if successful, false if not - public async Task Init(string name, CancellationToken cancellationToken) + public async Task Init(Type type, string name, CancellationToken cancellationToken) { + Type = type; Name = name; //TODO: Init Entries list depending on GBaseEntryAttributes set for this GBaseTable @@ -55,7 +62,7 @@ namespace GBase /// A to await public async ValueTask DisposeAsync() { - throw new System.NotImplementedException(); + throw new NotImplementedException(); } } } \ No newline at end of file diff --git a/GBase/Interfaces/IGBaseTable.cs b/GBase/Interfaces/IGBaseTable.cs index 1fa97ca..7309503 100644 --- a/GBase/Interfaces/IGBaseTable.cs +++ b/GBase/Interfaces/IGBaseTable.cs @@ -14,6 +14,11 @@ namespace GBase.Interfaces /// public interface IGBaseTable : IAsyncDisposable { + /// + /// The of the class that this represents + /// + Type Type { get; } + /// /// The name of this /// @@ -27,9 +32,10 @@ namespace GBase.Interfaces /// /// Initialize this /// + /// The of the class that this represents /// The name of this /// A to cancel the asynchronous operation /// True if successful, false if not - Task Init(string name, CancellationToken cancellationToken); + Task Init(Type type, string name, CancellationToken cancellationToken); } } \ No newline at end of file