public UnityMiscFilesProjectPsiModuleProvider(UnityExternalFilesModuleFactory moduleFactory,
                                               UnityYamlPsiSourceFileFactory psiSourceFileFactory,
                                               AssetSerializationMode assetSerializationMode)
 {
     myModuleFactory          = moduleFactory;
     myPsiSourceFileFactory   = psiSourceFileFactory;
     myAssetSerializationMode = assetSerializationMode;
 }
Exemple #2
0
        public UnityExternalFilesModuleProcessor(Lifetime lifetime, ILogger logger, ISolution solution,
                                                 ChangeManager changeManager,
                                                 IShellLocks locks,
                                                 ISolutionLoadTasksScheduler scheduler,
                                                 IFileSystemTracker fileSystemTracker,
                                                 ProjectFilePropertiesFactory projectFilePropertiesFactory,
                                                 UnityYamlPsiSourceFileFactory psiSourceFileFactory,
                                                 UnityExternalFilesModuleFactory moduleFactory,
                                                 UnityYamlDisableStrategy unityYamlDisableStrategy,
                                                 BinaryUnityFileCache binaryUnityFileCache,
                                                 ISettingsSchema settingsSchema,
                                                 SettingsLayersProvider settingsLayersProvider,
                                                 AssetSerializationMode assetSerializationMode,
                                                 UnityYamlSupport unityYamlSupport)
        {
            myLifetime                     = lifetime;
            myLogger                       = logger;
            mySolution                     = solution;
            myChangeManager                = changeManager;
            myLocks                        = locks;
            myFileSystemTracker            = fileSystemTracker;
            myProjectFilePropertiesFactory = projectFilePropertiesFactory;
            myPsiSourceFileFactory         = psiSourceFileFactory;
            myModuleFactory                = moduleFactory;
            myUnityYamlDisableStrategy     = unityYamlDisableStrategy;
            myBinaryUnityFileCache         = binaryUnityFileCache;
            mySettingsSchema               = settingsSchema;
            mySettingsLayersProvider       = settingsLayersProvider;
            myAssetSerializationMode       = assetSerializationMode;
            myUnityYamlSupport             = unityYamlSupport;

            changeManager.RegisterChangeProvider(lifetime, this);

            myRootPaths = new JetHashSet <FileSystemPath>();

            // SolutionDirectory isn't absolute in tests, and will throw an exception if we use it when we call Exists
            mySolutionDirectory = solution.SolutionDirectory;
            if (!mySolutionDirectory.IsAbsolute)
            {
                mySolutionDirectory = solution.SolutionDirectory.ToAbsolutePath(FileSystemUtil.GetCurrentDirectory());
            }

            scheduler.EnqueueTask(new SolutionLoadTask(GetType().Name + ".Activate",
                                                       SolutionLoadTaskKinds.PreparePsiModules,
                                                       () => myChangeManager.AddDependency(myLifetime, mySolution.PsiModules(), this)));
        }
Exemple #3
0
 public UnityMiscFilesProjectPsiModuleProvider(UnityExternalFilesModuleFactory moduleFactory)
 {
     myModuleFactory = moduleFactory;
 }