mirror of
https://dev.azure.com/TeilRad/sharee.bike%20App/_git/Code
synced 2025-06-22 05:47:28 +02:00
Version 3.0.337
This commit is contained in:
parent
fd0e63cf10
commit
573fe77e12
2336 changed files with 33688 additions and 86082 deletions
|
@ -13,14 +13,5 @@ namespace TINK.Services.CopriApi.ServerUris
|
|||
public static bool GetIsCopri(this string hostName)
|
||||
=> new Uri(CopriServerUriList.TINK_DEVEL).Host == hostName
|
||||
|| new Uri(CopriServerUriList.TINK_LIVE).Host == hostName;
|
||||
|
||||
/// <summary> Get folder name depending on host name. </summary>
|
||||
/// <param name="hostName">Host name.</param>
|
||||
/// <returns>Folder name.</returns>
|
||||
public static string GetAppFolderName(this string hostName)
|
||||
=> hostName.GetIsCopri()
|
||||
? "tinkapp" /* resource tree is more complex for TINK/ konrad*/
|
||||
: "app";
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
using Newtonsoft.Json;
|
||||
using System;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace TINK.Model.Services.CopriApi.ServerUris
|
||||
{
|
||||
|
@ -26,7 +26,7 @@ namespace TINK.Model.Services.CopriApi.ServerUris
|
|||
public const string SHAREE_LIVE = @"https://shareeapp-primary.copri.eu/APIjsonserver";
|
||||
|
||||
/// <summary>Constructs default uri list.</summary>
|
||||
public CopriServerUriList(Uri activeUri = null) : this (
|
||||
public CopriServerUriList(Uri activeUri = null) : this(
|
||||
new List<Uri>
|
||||
{
|
||||
new Uri(SHAREE_LIVE),
|
||||
|
@ -41,7 +41,7 @@ namespace TINK.Model.Services.CopriApi.ServerUris
|
|||
/// <summary> Constructs uris object. </summary>
|
||||
/// <param name="p_oSource">Object to copy from.</param>
|
||||
public CopriServerUriList(CopriServerUriList p_oSource) : this(
|
||||
p_oSource.Uris.ToArray(),
|
||||
p_oSource.Uris.ToArray(),
|
||||
p_oSource.ActiveUri)
|
||||
{
|
||||
}
|
||||
|
@ -51,7 +51,7 @@ namespace TINK.Model.Services.CopriApi.ServerUris
|
|||
/// <param name="p_oActiveUri">Zero based index of active uri.</param>
|
||||
/// <param name="p_oDevelUri">Uri of the development server.</param>
|
||||
public CopriServerUriList(
|
||||
Uri[] uris,
|
||||
Uri[] uris,
|
||||
Uri p_oActiveUri)
|
||||
{
|
||||
if (uris == null || uris.Length < 1)
|
||||
|
@ -61,7 +61,7 @@ namespace TINK.Model.Services.CopriApi.ServerUris
|
|||
|
||||
if (!uris.Contains(p_oActiveUri))
|
||||
{
|
||||
throw new ArgumentException($"Active uri {p_oActiveUri} not contained in ({string.Join("; ", uris.Select(x => x.AbsoluteUri))}).");
|
||||
throw new ArgumentException($"Active uri {p_oActiveUri} not contained in ({string.Join("; ", uris.Select(x => x.AbsoluteUri))}).");
|
||||
}
|
||||
|
||||
Uris = new List<Uri>(uris);
|
||||
|
@ -81,7 +81,7 @@ namespace TINK.Model.Services.CopriApi.ServerUris
|
|||
|
||||
/// <summary> Gets the known uris. </summary>
|
||||
[JsonProperty]
|
||||
public IList<Uri> Uris { get ; }
|
||||
public IList<Uri> Uris { get; }
|
||||
|
||||
/// <summary> Gets the default uri which is active after first installation. </summary>
|
||||
public static Uri DefaultActiveUri
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue