using System; using System.Collections.Generic; using Newtonsoft.Json; namespace Tesses.CMS { public class ProjectRelease { [JsonIgnore] public long Id {get;set;} [JsonIgnore] public long ProjectId {get;set;} [JsonIgnore] public long UserId {get;set;} [JsonProperty("tag")] public string Tag {get;set;} [JsonProperty("release_number")] public long ReleaseNumber {get;set;} [JsonProperty("platforms")] public List Platforms {get;set;}=new List(); [JsonProperty("creation_time")] public DateTime CreationTime {get;set;}=DateTime.Now; } public enum CPUArchitecture { X86, X86_64, Arm, Aarch64, Mips, Mips64, RiscV, RiscV64, PowerPC, PowerPC64, PowerPCLE, PowerPC64LE, Sparc, Sparc64, Itanium, Other } public enum ProjectReleaseOSPlatform { Windows, Mac, Linux, Amiga, TempleOS, Android, Ios, N64, GBA, Gamecube, DS, Wii, DSI, ThreeDS, WiiU, Switch, PS2, DOS, PS3, PS4, PS5, XBox, XBox360, XBoxOne, XBoxSeriesX, TessesPlay, TessesOS, TessesPDA, Other } public enum PlatformVariant { Msi, ExeInstaller, XCopyable, PortableAppsCom, Tarball, Deb, AppImage, Flatpak, Dmg, Wad, Pkg, Apk, Ipa, Appx, Iso, InstallScript, Nupkg, Npm, TPkg, Other, } public class ProjectReleasePlatform { [JsonProperty("cpu_arch")] public CPUArchitecture Arch {get;set;} [JsonProperty("cpu_arch_other")] public string ArchOther {get;set;}=""; [JsonProperty("platform")] public ProjectReleaseOSPlatform Platform {get;set;} [JsonProperty("platform_other")] public string PlatformOther {get;set;}=""; [JsonProperty("platform_variant")] public PlatformVariant Variant {get;set;} [JsonProperty("platform_variant_other")] public string VariantOther {get;set;}=""; [JsonProperty("filename")] public string FileName {get;set;}=""; } }