public class UserNetFramework
/// .NET Framework 2.0 SP2
public bool InstalledNETFramework20SP2 => _list.Contains(NETFramework20SP2);
private const string NETFramework20SP2 = ".NET Framework 2.0 SP2";
/// .NET Framework 3.0 SP2
public bool InstalledNETFramework30SP2 => _list.Contains(NETFramework30SP2);
private const string NETFramework30SP2 = ".NET Framework 3.0 SP2";
/// .NET Framework 3.5 SP1
public bool InstalledNETFramework35SP1 => _list.Contains(NETFramework35SP1);
private const string NETFramework35SP1 = ".NET Framework 3.5 SP1";
/// .NET Framework 4 Client Profile
public bool InstalledNETFramework4CP => _list.Contains(NETFramework4CP);
private const string NETFramework4CP = ".NET Framework 4 Client Profile";
/// .NET Framework 4 Full
public bool InstalledNETFramework4F => _list.Contains(NETFramework4F);
private const string NETFramework4F = ".NET Framework 4 Full";
/// .NET Framework 4.5 Client Profile
public bool InstalledNETFramework45CP => _list.Contains(NETFramework45CP);
private const string NETFramework45CP = ".NET Framework 4.5 Client Profile";
public bool InstalledNETFramework45 => _list.Contains(NETFramework45);
private const string NETFramework45 = ".NET Framework 4.5";
public bool InstalledNETFramework451 => _list.Contains(NETFramework451);
private const string NETFramework451 = ".NET Framework 4.5.1";
public bool InstalledNETFramework452 => _list.Contains(NETFramework452);
private const string NETFramework452 = ".NET Framework 4.5.2";
public bool InstalledNETFramework46 => _list.Contains(NETFramework46);
private const string NETFramework46 = ".NET Framework 4.6";
public bool InstalledNETFramework461 => _list.Contains(NETFramework461);
private const string NETFramework461 = ".NET Framework 4.6.1";
/// .NET Framework 4.7 Client Profile
public bool InstalledNETFramework47CP => _list.Contains(NETFramework47CP);
private const string NETFramework47CP = ".NET Framework 4.7 Client Profile";
public bool InstalledNETFramework47 => _list.Contains(NETFramework47);
private const string NETFramework47 = ".NET Framework 4.7";
private readonly HashSet<string> _list = new HashSet<string>();
public static UserNetFramework Parser(string str)
var userNetFramework = new UserNetFramework();
foreach (var temp in new[]
str = str.Replace(temp, "");
userNetFramework._list.Add(temp);