Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Serialize Class to IniData #225

Open
Bluscream opened this issue Mar 3, 2021 · 0 comments
Open

Serialize Class to IniData #225

Bluscream opened this issue Mar 3, 2021 · 0 comments

Comments

@Bluscream
Copy link

Bluscream commented Mar 3, 2021

How do i (de)-serialize a C# class to IniData?

Something similar to https://json2csharp.com/

public partial class MMCInstanceConfig
{
        public static string AutoCloseConsole { get; set; } = "true";
        public static string ForgeVersion { get; set; }
        public static string InstanceType { get; set; } = "OneSix";
        public static string IntendedVersion { get; set; }
        public static string JavaArchitecture { get; set; } = "64";
        public static string JavaPath { get; set; } = "C:/Program Files/AdoptOpenJDK/jdk-15.0.2.7-hotspot/bin/javaw.exe";
        public static string JavaTimestamp { get; set; } = "1611206204000";
        public static string JavaVersion { get; set; } = "15.0.2";
        public static string JvmArgs { get; set; } = "-XX:+UnlockExperimentalVMOptions";
        public static string LWJGLVersion { get; set; }
        public static string LaunchMaximized { get; set; } = "false";
        public static string LiteloaderVersion { get; set; }
        public static string LogPrePostOutput { get; set; } = "true";
        public static string MCLaunchMethod { get; set; } = "LauncherPart";
        public static string MaxMemAlloc { get; set; } = "512";
        public static string MinMemAlloc { get; set; } = "2048";
        public static string MinecraftWinHeight { get; set; } = "480";
        public static string MinecraftWinWidth { get; set; } = "854";
        public static string OverrideCommands { get; set; } = "false";
        public static string OverrideConsole { get; set; } = "false";
        public static string OverrideJava { get; set; } = "false";
        public static string OverrideJavaArgs { get; set; } = "true";
        public static string OverrideJavaLocation { get; set; } = "true";
        public static string OverrideMCLaunchMethod { get; set; } = "false";
        public static string OverrideMemory { get; set; } = "true";
        public static string OverrideNativeWorkarounds { get; set; } = "false";
        public static string OverrideWindow { get; set; } = "false";
        public static string PermGen { get; set; } = "128";
        public static string PostExitCommand { get; set; }
        public static string PreLaunchCommand { get; set; }
        public static string ShowConsole { get; set; } = "false";
        public static string ShowConsoleOnError { get; set; } = "true";
        public static string UseNativeGLFW { get; set; } = "false";
        public static string UseNativeOpenAL { get; set; } = "false";
        public static string WrapperCommand { get; set; }
        public static string iconKey { get; set; }
        public static string lastLaunchTime { get; set; } = "1614793595994";
        public static string name { get; set; }
        public static string notes { get; set; }
        public static string totalTimePlayed { get; set; } = "184";
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant