From 66dcfb658de5a8fcc105456f80fd0334ff432be9 Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Thu, 13 Sep 2018 12:23:12 -0400 Subject: [PATCH 1/2] Add missing IByondClient List call --- .../Components/ByondClient.cs | 8 ++++++-- .../Components/IByondClient.cs | 18 +++++++++++++----- 2 files changed, 19 insertions(+), 7 deletions(-) diff --git a/src/Tgstation.Server.Client/Components/ByondClient.cs b/src/Tgstation.Server.Client/Components/ByondClient.cs index e75c47110c..92c2f8aba5 100644 --- a/src/Tgstation.Server.Client/Components/ByondClient.cs +++ b/src/Tgstation.Server.Client/Components/ByondClient.cs @@ -1,4 +1,5 @@ using System; +using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; using Tgstation.Server.Api; @@ -30,9 +31,12 @@ namespace Tgstation.Server.Client.Components } /// - public Task Read(CancellationToken cancellationToken) => apiClient.Read(Routes.Byond, instance.Id, cancellationToken); + public Task ActiveVersion(CancellationToken cancellationToken) => apiClient.Read(Routes.Byond, instance.Id, cancellationToken); /// - public Task Update(Byond byond, CancellationToken cancellationToken) => apiClient.Update(Routes.Byond, byond ?? throw new ArgumentNullException(nameof(byond)), instance.Id, cancellationToken); + public Task> InstalledVersions(CancellationToken cancellationToken) => apiClient.Read>(Routes.List(Routes.Byond), instance.Id, cancellationToken); + + /// + public Task SetActiveVersion(Byond byond, CancellationToken cancellationToken) => apiClient.Update(Routes.Byond, byond ?? throw new ArgumentNullException(nameof(byond)), instance.Id, cancellationToken); } } \ No newline at end of file diff --git a/src/Tgstation.Server.Client/Components/IByondClient.cs b/src/Tgstation.Server.Client/Components/IByondClient.cs index bfe9e8f003..da4f4d45a3 100644 --- a/src/Tgstation.Server.Client/Components/IByondClient.cs +++ b/src/Tgstation.Server.Client/Components/IByondClient.cs @@ -1,4 +1,5 @@ -using System.Threading; +using System.Collections.Generic; +using System.Threading; using System.Threading.Tasks; using Tgstation.Server.Api.Models; @@ -10,11 +11,18 @@ namespace Tgstation.Server.Client.Components public interface IByondClient { /// - /// Get the information + /// Get the active information /// /// The for the operation - /// A resulting in the information - Task Read(CancellationToken cancellationToken); + /// A resulting in the active information + Task ActiveVersion(CancellationToken cancellationToken); + + /// + /// Get all installed s + /// + /// The for the operation + /// A resulting in an of installed s + Task> InstalledVersions(CancellationToken cancellationToken); /// /// Updates the information @@ -22,6 +30,6 @@ namespace Tgstation.Server.Client.Components /// The information to update /// The for the operation /// A resulting in the updated information - Task Update(Byond byond, CancellationToken cancellationToken); + Task SetActiveVersion(Byond byond, CancellationToken cancellationToken); } } From 4274706b8b6ebd99d89f35aa78d9076f8db05d37 Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Thu, 13 Sep 2018 12:24:12 -0400 Subject: [PATCH 2/2] Bump client preview version --- src/Tgstation.Server.Client/Tgstation.Server.Client.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Tgstation.Server.Client/Tgstation.Server.Client.csproj b/src/Tgstation.Server.Client/Tgstation.Server.Client.csproj index 7b97f583c8..f5bbc82a26 100644 --- a/src/Tgstation.Server.Client/Tgstation.Server.Client.csproj +++ b/src/Tgstation.Server.Client/Tgstation.Server.Client.csproj @@ -3,7 +3,7 @@ netstandard2.0 Full - 4.0.0.0-preview9103 + 4.0.0.0-preview9104 true Cyberboss /tg/station 13