internal EditPuTTY(PuTTY connection)
        {
            //
            // The InitializeComponent() call is required for Windows Forms designer support.
            //
            InitializeComponent();
            this.connection = connection;
            this.NewCompression = this.connection.Compression;
            this.NewForceIPv4 = this.connection.ForceIPv4;
            this.NewForceIPv6 = this.connection.ForceIPv6;
            this.NewHost = this.connection.Host;
            this.NewPort = this.connection.Port;
            this.NewUsername = this.connection.Username;
            this.NewX11 = this.connection.X11;

            this.textBoxHost.Text = this.connection.Host;
            this.textBoxPort.Text = this.connection.Port;
            this.textBoxUsername.Text = this.connection.Username;
            this.checkBoxCompression.Checked = this.connection.Compression;
            this.checkBoxIPv4.Checked = this.connection.ForceIPv4;
            this.checkBoxIPv6.Checked = this.connection.ForceIPv6;
            this.checkBoxX11.Checked = this.connection.X11;
        }
        internal static void load(string file, string baseFolder)
        {
            if(!File.Exists(file))
            {
                return;
            }

            var lines = File.ReadAllLines(file);
            if(lines.Length < 2)
            {
                return;
            }

            if(lines[1].Trim() == "RDP" && lines.Length >= 3)
            {
                var rdp = new RDP(baseFolder);
                rdp.Filename = file;
                rdp.Name = lines[0].Trim();
                rdp.RDPFile = lines[2];
            }

            if(lines[1].Trim() == "WinSCP" && lines.Length >= 6)
            {
                var winSCP = new WinSCP(baseFolder);
                winSCP.Filename = file;
                winSCP.Name = lines[0].Trim();
                winSCP.Host = lines[2].Trim();
                winSCP.Port = lines[3].Trim();
                winSCP.Protocol = lines[4].Trim();
                winSCP.Username = lines[5].Trim();
            }

            if(lines[1].Trim() == "PuTTY" && lines.Length >= 9)
            {
                var putty = new PuTTY(baseFolder);
                putty.Filename = file;
                putty.Name = lines[0].Trim();
                putty.Compression = lines[2].Trim() == "true";
                putty.ForceIPv4 = lines[3].Trim() == "true";
                putty.ForceIPv6 = lines[4].Trim() == "true";
                putty.Host = lines[5].Trim();
                putty.Port = lines[6].Trim();
                putty.Username = lines[7].Trim();
                putty.X11 = lines[8].Trim() == "true";
            }

            if(lines[1].Trim() == "SSHTunnel" && lines.Length >= 9)
            {
                var tunnel = new SSHTunnel(baseFolder);
                tunnel.Filename = file;
                tunnel.Name = lines[0].Trim();
                tunnel.Username = lines[2].Trim();
                tunnel.LocalEndpoint = lines[3].Trim();
                tunnel.LocalPort = lines[4].Trim();
                tunnel.RemoteEndpoint = lines[5].Trim();
                tunnel.RemotePort = lines[6].Trim();
                tunnel.SSHHost = lines[7].Trim();
                tunnel.SSHHostPort = lines[8].Trim();
            }

            return;
        }