public GetProfilerLocations ( ) : ProfilerLocation[] | ||
return | ProfilerLocation[] |
public bool HasBeenInstalled(MachinePrerequisite machinePreq) { if (machinePreq == null) { throw new ArgumentNullException("machinePreq"); } var profLocs = EnvironmentRepository.GetProfilerLocations(); if (profLocs == null || profLocs.Length == 0) { return(false); } foreach (var profLoc in profLocs) { using (var classesRootKey = EnvironmentRepository.OpenRegistryBaseKey(RegistryHive.ClassesRoot, profLoc.RegistryView)) using (var inprocServer32Key = EnvironmentRepository.OpenRegistrySubKey(classesRootKey, ProfilerLocation.InprocServer32Path)) { machinePreq.OnProfilerStatusChecking(profLoc); if (!IsProfilerInstalled(inprocServer32Key, ProfilerLocation.GetExpectedFileDescription(machinePreq.PackageVersion))) { return(false); } } } return(true); }
void UnregisterProfiler(MachineWideUninstallation mwUninstl) { var profLocs = EnvironmentRepository.GetProfilerLocations(); if (profLocs == null || profLocs.Length == 0) { return; } foreach (var profLoc in EnvironmentRepository.GetProfilerLocations()) { mwUninstl.OnProfilerUnregistering(profLoc); var stdout = Regsvr32Executor.StartUninstalling(profLoc.PathOfInstalling); mwUninstl.OnProfilerUnregistered(stdout); } }