VSSonarExtensionUi.Model.Configuration.RoslynManagerModel.RoslynManagerModel C# (CSharp) Method

RoslynManagerModel() public method

Initializes a new instance of the RoslynManagerModel class.
public RoslynManagerModel ( IEnumerable pluginsIn, INotificationManager notificationManagerIn, IConfigurationHelper configHelper, ISonarRestService rest ) : System
pluginsIn IEnumerable The plugins in.
notificationManagerIn INotificationManager The notification manager in.
configHelper IConfigurationHelper The configuration helper.
rest ISonarRestService
return System
        public RoslynManagerModel(
            IEnumerable<IAnalysisPlugin> pluginsIn,
            INotificationManager notificationManagerIn,
            IConfigurationHelper configHelper,
            ISonarRestService rest)
        {
            this.roslynHomePath = Path.Combine(configHelper.ApplicationPath, "Diagnostics");
            this.roslynExternalUserDiagPath = Path.Combine(this.roslynHomePath, "UserDiagnostics");
            this.roslynEmbbedDiagPath = Path.Combine(this.roslynHomePath, "InternalDiagnostics");

            if (!Directory.Exists(this.roslynHomePath))
            {
                Directory.CreateDirectory(this.roslynHomePath);
            }

            if (!Directory.Exists(this.roslynExternalUserDiagPath))
            {
                Directory.CreateDirectory(this.roslynExternalUserDiagPath);
            }

            if (!Directory.Exists(this.roslynEmbbedDiagPath))
            {
                Directory.CreateDirectory(this.roslynEmbbedDiagPath);
            }

            this.rest = rest;
            this.confHelper = configHelper;
            this.plugins = pluginsIn;
            this.notificationManager = notificationManagerIn;
            this.ExtensionDiagnostics = new Dictionary<string, VSSonarExtensionDiagnostic>();
            this.embedVersionController = new EmbbedVersionController(this.notificationManager, rest, configHelper, this.roslynEmbbedDiagPath);

            // register model
            AssociationModel.RegisterNewModelInPool(this);
        }