• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C# SolutionFolder类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中SolutionFolder的典型用法代码示例。如果您正苦于以下问题:C# SolutionFolder类的具体用法?C# SolutionFolder怎么用?C# SolutionFolder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



SolutionFolder类属于命名空间,在下文中一共展示了SolutionFolder类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: AddProject

        internal void AddProject(AbstractDProject sub)
        {
            var folder = sub.BaseDirectory == BaseDirectory || sub.BaseDirectory.IsChildPathOf (BaseDirectory) ? RootFolder : ExternalDepFolder;

            if (folder == ExternalDepFolder && sub is DubProject) {
                var packageName = (sub as DubProject).packageName.Split(':');
                for (int i = 0; i < packageName.Length - 1; i++) {
                    bool foundSubFolder = false;
                    foreach (var subFolder in folder.GetAllItems<SolutionFolder>()) {
                        if (String.Equals (subFolder.Name, packageName [i], StringComparison.CurrentCultureIgnoreCase)) {
                            folder = subFolder;
                            foundSubFolder = true;
                            break;
                        }
                    }
                    if (!foundSubFolder) {
                        var newSubFolder = new SolutionFolder{ Name = packageName [i] };
                        folder.AddItem (newSubFolder);
                        folder = newSubFolder;
                    }
                }
            }

            if (!folder.Items.Contains (sub))
                folder.AddItem (sub, false);
        }
开发者ID:aBothe,项目名称:Mono-D,代码行数:26,代码来源:DubSolution.cs


示例2: GetCombineDeployFiles

		public virtual DeployFileCollection GetCombineDeployFiles (DeployContext ctx, SolutionFolder combine, ConfigurationSelector configuration)
		{
			if (Next != null)
				return Next.GetDeployFiles (ctx, combine, configuration);
			else
				return new DeployFileCollection ();
		}
开发者ID:pabloescribanoloza,项目名称:monodevelop,代码行数:7,代码来源:DeployServiceExtension.cs


示例3: GetSupportLevel

		public FeatureSupportLevel GetSupportLevel (SolutionFolder parentCombine, SolutionItem entry)
		{
			if (entry is Project)
				return FeatureSupportLevel.SupportedByDefault;
			else
				return FeatureSupportLevel.NotSupported;
		}
开发者ID:Kalnor,项目名称:monodevelop,代码行数:7,代码来源:MakefileIntegrationFeature.cs


示例4: Fill

		public void Fill (SolutionFolder parentCombine, SolutionItem entry, ISolutionItemFeature[] features)
		{
			selectedFeatures.Clear ();
			selectedEditors.Clear ();
			
			this.entry = entry;
			this.parentCombine = parentCombine;
			
			foreach (Gtk.Widget w in box.Children) {
				box.Remove (w);
				w.Destroy ();
			}
			// Show enabled features at the beginning
			foreach (ISolutionItemFeature feature in features)
				if (feature.GetSupportLevel (parentCombine, entry) == FeatureSupportLevel.Enabled) {
					Gtk.Widget editor = AddFeature (feature);
					selectedFeatures.Add (feature);
					selectedEditors.Add (editor);
				}
			foreach (ISolutionItemFeature feature in features)
				if (feature.GetSupportLevel (parentCombine, entry) != FeatureSupportLevel.Enabled)
					AddFeature (feature);
			
			if (box.Children.Length == 0) {
				// No features
				Label lab = new Label ();
				lab.Xalign = 0;
				lab.Text = GettextCatalog.GetString ("There are no additional features available for this project.");
				box.PackStart (lab, false, false, 0);
				lab.Show ();
			}
			scrolled.AddWithViewport (box);
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:33,代码来源:CombineEntryFeatureSelector.cs


示例5: ApplyFeature

		public void ApplyFeature (SolutionFolder parentCombine, SolutionItem entry, Widget editor)
		{
			GtkFeatureWidget fw = (GtkFeatureWidget) editor;
			ReferenceManager refmgr = new ReferenceManager ((DotNetProject) entry);
			refmgr.GtkPackageVersion = fw.SelectedVersion;
			refmgr.Dispose ();
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:7,代码来源:GtkFeatureWidget.cs


示例6: CheckProjectContainsItself

        public void CheckProjectContainsItself()
        {
            var folder = new SolutionFolder ();
            var project = new DotNetAssemblyProject { Name = "foo" };
            folder.AddItem (project);

            Assert.IsNotNull (folder.GetProjectContainingFile (project.FileName), "#1");
        }
开发者ID:Kalnor,项目名称:monodevelop,代码行数:8,代码来源:SolutionFolderTests.cs


示例7: ApplyFeature

		public void ApplyFeature (SolutionFolder parentFolder, SolutionItem entry, Gtk.Widget editor)
		{
			// The solution may not be saved yet
			if (parentFolder.ParentSolution.FileName.IsNullOrEmpty || !System.IO.File.Exists (parentFolder.ParentSolution.FileName))
				parentFolder.ParentSolution.Saved += OnSolutionSaved;
			else
				OnSolutionSaved (parentFolder.ParentSolution, null);
		}
开发者ID:yayanyang,项目名称:monodevelop,代码行数:8,代码来源:GitSupportFeature.cs


示例8: GetSupportLevel

		public FeatureSupportLevel GetSupportLevel (SolutionFolder parentCombine, SolutionItem entry)
		{
			if (entry is TranslationProject && parentCombine != null)
				return FeatureSupportLevel.Enabled;
			else if ((entry is Project) && parentCombine != null)
				return FeatureSupportLevel.Supported;
			else
				return FeatureSupportLevel.NotSupported;
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:9,代码来源:GettextFeature.cs


示例9: ProtobuildSubmodule

		public ProtobuildSubmodule (ProtobuildModuleInfo latestModuleInfo, ProtobuildModuleInfo submodule, SolutionFolder rootFolder)
        {
            parentModule = latestModuleInfo;
            currentModule = submodule;
			RootFolder = rootFolder;
			Packages = new ProtobuildPackages(this);
			Definitions = new ItemCollection<IProtobuildDefinition>();
			Submodules = new ItemCollection<ProtobuildSubmodule>();
		}
开发者ID:Protobuild,项目名称:Protobuild.IDE.MonoDevelop,代码行数:9,代码来源:ProtobuildSubmodule.cs


示例10: GetFeatures

		public static ISolutionItemFeature[] GetFeatures (SolutionFolder parentCombine, SolutionItem entry)
		{
			List<ISolutionItemFeature> list = new List<ISolutionItemFeature> ();
			foreach (ISolutionItemFeature e in AddinManager.GetExtensionObjects ("/MonoDevelop/Ide/ProjectFeatures", typeof(ISolutionItemFeature), true)) {
				FeatureSupportLevel level = e.GetSupportLevel (parentCombine, entry);
				if (level == FeatureSupportLevel.Enabled || level == FeatureSupportLevel.SupportedByDefault)
					list.Add (e);
			}
			return list.ToArray ();
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:10,代码来源:ISolutionItemFeature.cs


示例11: SolutionFolderTestGroup

		public SolutionFolderTestGroup (SolutionFolder c): base (c.Name, c)
		{
			string storeId = c.ItemId;
			string resultsPath = MonoDevelop.NUnit.RootTest.GetTestResultsDirectory (c.BaseDirectory);
			ResultsStore = new XmlResultsStore (resultsPath, storeId);
			
			combine = c;
			combine.ItemAdded += OnEntryChanged;
			combine.ItemRemoved += OnEntryChanged;
			combine.NameChanged += OnCombineRenamed;
		}
开发者ID:telebovich,项目名称:monodevelop,代码行数:11,代码来源:SolutionFolderTestGroup.cs


示例12: SolutionFolderTestGroup

		public SolutionFolderTestGroup (SolutionFolder c): base (c.Name, c)
		{
			string storeId = c.ItemId;
			string resultsPath = Path.Combine (c.BaseDirectory, "test-results");
			ResultsStore = new XmlResultsStore (resultsPath, storeId);
			
			combine = c;
			combine.ItemAdded += OnEntryChanged;
			combine.ItemRemoved += OnEntryChanged;
			combine.NameChanged += OnCombineRenamed;
		}
开发者ID:transformersprimeabcxyz,项目名称:monodevelop-1,代码行数:11,代码来源:SolutionFolderTestGroup.cs


示例13: GetSupportLevel

		public FeatureSupportLevel GetSupportLevel (SolutionFolder parentCombine, SolutionItem entry)
		{
			if (!(entry is DotNetProject) || !GtkDesignInfo.SupportsRefactoring (entry as DotNetProject))
				return FeatureSupportLevel.NotSupported;
			else if (GtkDesignInfo.SupportsDesigner ((Project)entry))
				return FeatureSupportLevel.Enabled;
			else if (entry is DotNetAssemblyProject)
				return FeatureSupportLevel.SupportedByDefault;
			else
				return FeatureSupportLevel.Supported;
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:11,代码来源:GtkFeatureWidget.cs


示例14: CreateProjectCreateInformation

		ProjectCreateInformation CreateProjectCreateInformation (NewProjectConfiguration config, SolutionFolder parentFolder)
		{
			ProjectCreateInformation cinfo = new ProjectCreateInformation ();
			cinfo.SolutionPath = new FilePath (config.SolutionLocation).ResolveLinks ();
			cinfo.ProjectBasePath = new FilePath (config.ProjectLocation).ResolveLinks ();
			cinfo.ProjectName = config.ProjectName;
			cinfo.SolutionName = config.SolutionName;
			cinfo.ParentFolder = parentFolder;
			cinfo.ActiveConfiguration = IdeApp.Workspace.ActiveConfiguration;
			cinfo.Parameters = config.Parameters;
			return cinfo;
		}
开发者ID:pabloescribanoloza,项目名称:monodevelop,代码行数:12,代码来源:ProjectTemplatingProvider.cs


示例15: GetSupportLevel

		public FeatureSupportLevel GetSupportLevel (SolutionFolder parentCombine, SolutionItem entry)
		{
			if (parentCombine == null)
				return FeatureSupportLevel.NotSupported;
			
			if (entry is PackagingProject)
				return FeatureSupportLevel.Enabled;
			else if (entry is Project)
				return FeatureSupportLevel.SupportedByDefault;
			else
				return FeatureSupportLevel.NotSupported;
		}
开发者ID:Kalnor,项目名称:monodevelop,代码行数:12,代码来源:PackagingFeature.cs


示例16: AddSolutionFolder

        public static SolutionFolder AddSolutionFolder(this Solution solution, string name, params FilePath[] files)
        {
            var solutionFolder = new SolutionFolder {
                Name = name
            };

            foreach (FilePath file in files) {
                solutionFolder.Files.Add (file);
            }

            solution.RootFolder.AddItem (solutionFolder);
            return solutionFolder;
        }
开发者ID:lordfinal,项目名称:monodevelop-dnx-addin,代码行数:13,代码来源:SolutionExtensions.cs


示例17: SolutionFolderTestGroup

		public SolutionFolderTestGroup (SolutionFolder c): base (c.Name, c)
		{
			string storeId = c.ItemId;
			string resultsPath = UnitTestService.GetTestResultsDirectory (c.BaseDirectory);
			ResultsStore = new BinaryResultsStore (resultsPath, storeId);
			
			folder = c;
			folder.NameChanged += OnCombineRenamed;

			if (c.IsRoot) {
				folder.ParentSolution.SolutionItemAdded += OnEntryChanged;
				folder.ParentSolution.SolutionItemRemoved += OnEntryChanged;
			}
		}
开发者ID:FreeBSD-DotNet,项目名称:monodevelop,代码行数:14,代码来源:SolutionFolderTestGroup.cs


示例18: ProcessTemplate

		ProcessedTemplateResult ProcessTemplate (DefaultSolutionTemplate template, NewProjectConfiguration config, SolutionFolder parentFolder)
		{
			IEnumerable<IWorkspaceFileObject> newItems = null;
			ProjectCreateInformation cinfo = CreateProjectCreateInformation (config, parentFolder);

			if (parentFolder == null) {
				IWorkspaceFileObject newItem = template.Template.CreateWorkspaceItem (cinfo);
				if (newItem != null) {
					newItems = new [] { newItem };
				}
			} else {
				newItems = template.Template.CreateProjects (parentFolder, cinfo);
			}
			return new DefaultProcessedTemplateResult (template.Template, newItems, cinfo.ProjectBasePath);
		}
开发者ID:pabloescribanoloza,项目名称:monodevelop,代码行数:15,代码来源:ProjectTemplatingProvider.cs


示例19: SolutionFolderTestGroup

		public SolutionFolderTestGroup (SolutionFolder c): base (c.Name, c)
		{
			string storeId = c.ItemId;
			string resultsPath = MonoDevelop.NUnit.RootTest.GetTestResultsDirectory (c.BaseDirectory);
			ResultsStore = new BinaryResultsStore (resultsPath, storeId);
			
			folder = c;
			folder.NameChanged += OnCombineRenamed;

			if (c.IsRoot) {
				folder.ParentSolution.SolutionItemAdded += OnEntryChanged;
				folder.ParentSolution.SolutionItemRemoved += OnEntryChanged;
				IdeApp.Workspace.ReferenceAddedToProject += OnReferenceChanged;
				IdeApp.Workspace.ReferenceRemovedFromProject += OnReferenceChanged;
			}
		}
开发者ID:pabloescribanoloza,项目名称:monodevelop,代码行数:16,代码来源:SolutionFolderTestGroup.cs


示例20: GetSupportLevel

		public FeatureSupportLevel GetSupportLevel (SolutionFolder parentCombine, SolutionItem entry)
		{
			if (!(entry is DotNetProject) || !GtkDesignInfo.SupportsRefactoring (entry as DotNetProject))
				return FeatureSupportLevel.NotSupported;
			
			ReferenceManager refmgr = new ReferenceManager ((DotNetProject)entry);
			if (refmgr.SupportedGtkVersions.Count == 0)
				return FeatureSupportLevel.NotSupported;
			
			if (GtkDesignInfo.SupportsDesigner ((Project)entry))
				return FeatureSupportLevel.Enabled;
			else if (entry is DotNetAssemblyProject)
				return FeatureSupportLevel.SupportedByDefault;
			else
				return FeatureSupportLevel.Supported;
		}
开发者ID:Kalnor,项目名称:monodevelop,代码行数:16,代码来源:GtkFeatureWidget.cs



注:本文中的SolutionFolder类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# SolutionItem类代码示例发布时间:2022-05-24
下一篇:
C# SolutionEvents类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap