From 31207679094b378a2d4b35eb310f679960d6205f Mon Sep 17 00:00:00 2001 From: bigfoot547 Date: Wed, 22 Jan 2025 03:59:51 -0600 Subject: wip: jre download stuff --- src/launcher/jre/manifest.rs | 31 ++++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) (limited to 'src/launcher/jre') diff --git a/src/launcher/jre/manifest.rs b/src/launcher/jre/manifest.rs index 9b84377..ca21a2b 100644 --- a/src/launcher/jre/manifest.rs +++ b/src/launcher/jre/manifest.rs @@ -19,28 +19,29 @@ pub struct JavaRuntimeInfo { // I don't see how half of this information is useful with how the JRE system currently functions -figboot pub availability: Availability, pub manifest: DownloadInfo, - pub version: Version + //pub version: Version } pub type JavaRuntimesManifest = HashMap>>; -#[derive(Debug, Deserialize, Clone, Copy, Eq, PartialEq)] -#[serde(rename_all = "lowercase")] -pub enum FileType { - File, - Directory, - Link +#[derive(Debug, Deserialize)] +pub struct FileDownloads { + lzma: Option, + raw: DownloadInfo } #[derive(Debug, Deserialize)] -pub struct JavaRuntimeFile { - #[serde(rename = "type")] - pub file_type: FileType, - #[serde(default)] - pub executable: bool, - - pub lzma: DownloadInfo, - pub raw: DownloadInfo +#[serde(rename_all = "lowercase", tag = "type")] +pub enum JavaRuntimeFile { + File { + #[serde(default)] + executable: bool, + downloads: FileDownloads + }, + Directory, + Link { + target: String + } } #[derive(Debug, Deserialize)] -- cgit v1.2.3-70-g09d2