Compare commits
5 Commits
89bcc242cf
...
location
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c3caa7e25c | ||
|
|
852e2a005f | ||
|
|
03243c93c6 | ||
|
|
f1817c5974 | ||
|
|
67cdf2c384 |
@@ -5,14 +5,12 @@ namespace LightlessSync.API.Dto.Files;
|
||||
[MessagePackObject(keyAsPropertyName: true)]
|
||||
public record DownloadFileDto : ITransferFileDto
|
||||
{
|
||||
public bool FileExists { get; set; } = true;
|
||||
public string Hash { get; set; } = string.Empty;
|
||||
public string Url { get; set; } = string.Empty;
|
||||
public string CDNDownloadUrl { get; set; } = string.Empty;
|
||||
public List<string> HasFileDirectUrls { get; set; } = new();
|
||||
public List<string> PullThroughDirectUrls { get; set; } = new();
|
||||
public long Size { get; set; } = 0;
|
||||
public bool IsForbidden { get; set; } = false;
|
||||
public bool FileExists { get; set; } = true;
|
||||
public string Hash { get; set; } = string.Empty;
|
||||
public string Url { get; set; } = string.Empty;
|
||||
public string CDNDownloadUrl { get; set; } = string.Empty;
|
||||
public long Size { get; set; } = 0;
|
||||
public bool IsForbidden { get; set; } = false;
|
||||
public string ForbiddenBy { get; set; } = string.Empty;
|
||||
public long RawSize { get; set; } = 0;
|
||||
}
|
||||
@@ -23,9 +23,8 @@ public class LightlessFiles
|
||||
public const string Distribution = "/dist";
|
||||
public const string Distribution_Get = "get";
|
||||
|
||||
public const string Main = "/main";
|
||||
public const string Main_SendReady = "sendReady";
|
||||
public const string Main_ShardFiles = "shardFiles";
|
||||
public const string Main = "/main";
|
||||
public const string Main_SendReady = "sendReady";
|
||||
|
||||
public const string Speedtest = "/speedtest";
|
||||
public const string Speedtest_Run = "run";
|
||||
@@ -46,6 +45,5 @@ public class LightlessFiles
|
||||
public static Uri ServerFilesDirectDownloadFullPath(Uri baseUri, string hash) => new(baseUri, ServerFiles + "/" + ServerFiles_DirectDownload + "/" + hash);
|
||||
public static Uri DistributionGetFullPath(Uri baseUri, string hash) => new(baseUri, Distribution + "/" + Distribution_Get + "?file=" + hash);
|
||||
public static Uri SpeedtestRunFullPath(Uri baseUri) => new(baseUri, Speedtest + "/" + Speedtest_Run);
|
||||
public static Uri MainSendReadyFullPath(Uri baseUri, string uid, Guid request) => new(baseUri, Main + "/" + Main_SendReady + "/" + "?uid=" + uid + "&requestId=" + request.ToString());
|
||||
public static Uri MainShardFilesFullPath(Uri baseUri) => new(baseUri, Main + "/" + Main_ShardFiles);
|
||||
public static Uri MainSendReadyFullPath(Uri baseUri, string uid, Guid request) => new(baseUri, Main + "/" + Main_SendReady + "/" + "?uid=" + uid + "&requestId=" + request.ToString());
|
||||
}
|
||||
Reference in New Issue
Block a user