當前位置: 首頁>>代碼示例>>C#>>正文


C# Projects.ConfigurationSelector類代碼示例

本文整理匯總了C#中MonoDevelop.Projects.ConfigurationSelector的典型用法代碼示例。如果您正苦於以下問題:C# ConfigurationSelector類的具體用法?C# ConfigurationSelector怎麽用?C# ConfigurationSelector使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


ConfigurationSelector類屬於MonoDevelop.Projects命名空間,在下文中一共展示了ConfigurationSelector類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: Execute

		internal protected virtual Task Execute (ProgressMonitor monitor, ExecutionContext context, ConfigurationSelector configuration, SolutionRunConfiguration runConfiguration)
		{
			context.RunConfiguration = runConfiguration;
#pragma warning disable 618 // Type or member is obsolete
			return Execute (monitor, context, configuration);
#pragma warning restore 618 // Type or member is obsolete
		}
開發者ID:sushihangover,項目名稱:monodevelop,代碼行數:7,代碼來源:SolutionExtension.cs

示例2: CustomCommandWidget

		public CustomCommandWidget (IWorkspaceObject entry, CustomCommand cmd, ConfigurationSelector configSelector)
		{
			this.Build();
			this.cmd = cmd;
			if (cmd != null) {
				updating = true;
				comboType.RemoveText (0);
				updating = false;
			}
			
			this.entry = entry;
			UpdateControls ();
			this.WidgetFlags |= Gtk.WidgetFlags.NoShowAll;
			
			StringTagModelDescription tagModel;
			if (entry is SolutionItem)
				tagModel = ((SolutionItem)entry).GetStringTagModelDescription (configSelector);
			else if (entry is WorkspaceItem)
				tagModel = ((WorkspaceItem)entry).GetStringTagModelDescription ();
			else
				tagModel = new StringTagModelDescription ();

			tagSelectorDirectory.TagModel = tagModel;
			tagSelectorDirectory.TargetEntry = workingdirEntry;
			
			tagSelectorCommand.TagModel = tagModel;
			tagSelectorCommand.TargetEntry = entryCommand;
		}
開發者ID:Tak,項目名稱:monodevelop-novell,代碼行數:28,代碼來源:CustomCommandWidget.cs

示例3: Build

		protected override BuildResult Build (IProgressMonitor monitor, SolutionEntityItem entry, ConfigurationSelector configuration)
		{
			BuildResult res = base.Build (monitor, entry, configuration);
			if (res.ErrorCount > 0 || !(entry is DotNetProject))
				return res;
			
			DotNetProject project = (DotNetProject) entry;
			AddinData data = AddinData.GetAddinData (project);
			if (data == null)
				return res;
			
			monitor.Log.WriteLine (AddinManager.CurrentLocalizer.GetString ("Verifying add-in description..."));
			string fileName = data.AddinManifestFileName;
			ProjectFile file = data.Project.Files.GetFile (fileName);
			if (file == null)
				return res;
			
			string addinFile;
			if (file.BuildAction == BuildAction.EmbeddedResource)
				addinFile = project.GetOutputFileName (ConfigurationSelector.Default);
			else
				addinFile = file.FilePath;
			
			AddinDescription desc = data.AddinRegistry.GetAddinDescription (new ProgressStatusMonitor (monitor), addinFile);
			StringCollection errors = desc.Verify ();
			
			foreach (string err in errors) {
				res.AddError (data.AddinManifestFileName, 0, 0, "", err);
				monitor.Log.WriteLine ("ERROR: " + err);
			}
			
			return res;
		}
開發者ID:transformersprimeabcxyz,項目名稱:monodevelop-1,代碼行數:33,代碼來源:AddinProjectExtension.cs

示例4: OnGetReferencedAssemblies

		internal protected override async Task<List<string>> OnGetReferencedAssemblies (ConfigurationSelector configuration)
		{
			var res = await base.OnGetReferencedAssemblies (configuration);
			var asms = Project.TargetRuntime.AssemblyContext.GetAssemblies (Project.TargetFramework).Where (a => a.Package.IsFrameworkPackage).Select (a => a.Location);
			res.AddRange (asms);
			return res;
		}
開發者ID:pabloescribanoloza,項目名稱:monodevelop,代碼行數:7,代碼來源:PortableDotNetProjectFlavor.cs

示例5: Build

        /// <summary>
        ///   Builds the specified solution item.
        /// </summary>
        /// <param name = "monitor">The monitor.</param>
        /// <param name = "item">The item.</param>
        /// <param name = "configuration">The configuration.</param>
        /// <returns>The build result.</returns>
        protected override BuildResult Build(IProgressMonitor monitor, SolutionEntityItem item, ConfigurationSelector configuration)
        {
            BuildResult result = new BuildResult ();

            // Pre-build
            monitor.BeginTask (GettextCatalog.GetString ("Pre-Building..."), 1);
            this.PreBuild (result, monitor, item, configuration);
            monitor.EndTask();
            if (result.ErrorCount > 0) {
                return result;
            }

            // Build
            monitor.BeginTask (GettextCatalog.GetString ("Building"), 1);
            result.Append (base.Build (monitor, item, configuration));
            monitor.EndTask();
            if (result.ErrorCount > 0) {
                return result;
            }

            // Post-build
            monitor.BeginTask (GettextCatalog.GetString ("Post-Building..."), 1);
            this.PostBuild (result, monitor, item, configuration);
            monitor.EndTask();

            return result;
        }
開發者ID:Monobjc,項目名稱:monobjc-monodevelop,代碼行數:34,代碼來源:MonobjcBuildExtension.cs

示例6: CanExecute

		/// <summary>
		/// Flags Unity projects for debugging with this addin
		/// </summary>
		protected override bool CanExecute (SolutionEntityItem item, ExecutionContext context, ConfigurationSelector configuration)
		{
			if (CanExecuteProject (item as Project, context)) {
				return context.ExecutionHandler.CanExecute (new UnityExecutionCommand (item.BaseDirectory.FullPath));
			}
			return base.CanExecute (item, context, configuration);
		}
開發者ID:Tak,項目名稱:MonoDevelop.Debugger.Soft.Unity,代碼行數:10,代碼來源:UnityProjectServiceExtension.cs

示例7: GetProjectDeployFiles

		public virtual DeployFileCollection GetProjectDeployFiles (DeployContext ctx, Project project, ConfigurationSelector configuration)
		{
			if (Next != null)
				return Next.GetDeployFiles (ctx, project, configuration);
			else
				return new DeployFileCollection ();
		}
開發者ID:pabloescribanoloza,項目名稱:monodevelop,代碼行數:7,代碼來源:DeployServiceExtension.cs

示例8: GetSourcePaths

		public override IEnumerable<string> GetSourcePaths (ConfigurationSelector sel)
		{
			useOriginalBasePath = true;
			var en = base.GetSourcePaths (sel).ToList();
			useOriginalBasePath = false;
			return en;
		}
開發者ID:DinrusGroup,項目名稱:Mono-D,代碼行數:7,代碼來源:DubSubPackage.cs

示例9: DoBuild

		protected override BuildResult DoBuild (IProgressMonitor monitor, ConfigurationSelector configuration)
		{
			useOriginalBasePath = true;
			var res = base.DoBuild (monitor, configuration);
			useOriginalBasePath = false;
			return res;
		}
開發者ID:DinrusGroup,項目名稱:Mono-D,代碼行數:7,代碼來源:DubSubPackage.cs

示例10: GetProjectDeployFiles

		public override DeployFileCollection GetProjectDeployFiles (DeployContext ctx, Project project, ConfigurationSelector config)
		{
			DeployFileCollection col = base.GetProjectDeployFiles (ctx, project, config);
			
			LinuxDeployData data = LinuxDeployData.GetLinuxDeployData (project);
			
			if (ctx.Platform == "Linux") {
				DotNetProject netProject = project as DotNetProject;
				if (netProject != null) {
					DotNetProjectConfiguration conf = netProject.GetConfiguration (config) as DotNetProjectConfiguration;
					if (conf != null) {
						if (conf.CompileTarget == CompileTarget.Exe || conf.CompileTarget == CompileTarget.WinExe) {
							if (data.GenerateScript) {
								col.Add (GenerateLaunchScript (ctx, netProject, data, conf));
							}
						}
						if (conf.CompileTarget == CompileTarget.Library || conf.CompiledOutputName.FileName.EndsWith (".dll")) {
							if (data.GeneratePcFile) {
								col.Add (GeneratePcFile (ctx, netProject, data, conf));
							}
						}
					}
				}
			}
			
			// If the project is deploying an app.desktop file, rename it to the name of the project.
			foreach (DeployFile file in col) {
				if (Path.GetFileName (file.RelativeTargetPath) == "app.desktop") {
					string dir = Path.GetDirectoryName (file.RelativeTargetPath);
					file.RelativeTargetPath = Path.Combine (dir, data.PackageName + ".desktop");
				}
			}
			
			return col;
		}
開發者ID:FreeBSD-DotNet,項目名稱:monodevelop,代碼行數:35,代碼來源:LinuxDeployExtension.cs

示例11: DoExecute

        protected override void DoExecute(IProgressMonitor monitor, ExecutionContext context, ConfigurationSelector configuration)
        {
            IodineConfiguration config = (IodineConfiguration)GetConfiguration (configuration);
            IConsole console = config.ExternalConsole ?
                context.ExternalConsoleFactory.CreateConsole (!config.PauseConsoleOutput) :
                context.ConsoleFactory.CreateConsole (!config.PauseConsoleOutput);

            AggregatedOperationMonitor aggregatedMonitor = new AggregatedOperationMonitor (monitor);
            try {
                string param = string.Format ("\"{0}\" {1}", config.MainFile, config.CommandLineParameters);

                IProcessAsyncOperation op = Runtime.ProcessService.StartConsoleProcess ("iodine",
                        param, BaseDirectory,
                        config.EnvironmentVariables, console, null);

                monitor.CancelRequested += delegate {
                    op.Cancel ();
                };

                aggregatedMonitor.AddOperation (op);
                op.WaitForCompleted ();
                monitor.Log.WriteLine ("Iodine exited with code: " + op.ExitCode);

            } catch (Exception e) {
                monitor.ReportError (GettextCatalog.GetString ("Cannot execute \"{0}\"", config.MainFile), e);
            } finally {
                console.Dispose ();
                aggregatedMonitor.Dispose ();
            }
        }
開發者ID:IodineLang,項目名稱:IodineBindings,代碼行數:30,代碼來源:IodineProject.cs

示例12: Clean

		protected override void Clean (MonoDevelop.Core.IProgressMonitor monitor, SolutionEntityItem item, ConfigurationSelector configuration)
		{
			var proj = item as MonoGameContentProject;
			MonoGameContentProjectConfiguration cfg = null;
			if (proj != null)
				cfg = proj.GetConfiguration (configuration) as MonoGameContentProjectConfiguration;
			if (proj == null) {
				monitor.Log.WriteLine("Cleaning for Unknown MonoGame Project");
				base.Clean (monitor, item, configuration);
			}
			var manager = new PipelineManager(proj.BaseDirectory.FullPath,
			                                  Path.Combine(cfg.OutputDirectory, cfg.MonoGamePlatform),
			                                  cfg.IntermediateOutputDirectory);
			monitor.Log.WriteLine("Detected {0} MonoGame Platform", cfg.MonoGamePlatform);                              
			foreach(var file in proj.Files)
			{
				if (file.BuildAction == "Compile") {
					try {
						monitor.Log.WriteLine("Cleaning {0}", file.FilePath.FileName);
						manager.CleanContent(file.FilePath.FullPath, null);
					}
					catch(Exception ex)
					{
						monitor.Log.WriteLine(ex.Message);
					}
				}
			}
			base.Clean (monitor, item, configuration);
		}
開發者ID:GhostTap,項目名稱:MonoGame,代碼行數:29,代碼來源:MonoGameContentBuildExtension.cs

示例13: GetReferencedDProjects

		public virtual IEnumerable<AbstractDProject> GetReferencedDProjects(ConfigurationSelector configuration)
		{
			AbstractDProject p;
			foreach (var dep in References.ReferencedProjectIds)
				if ((p = ParentSolution.GetSolutionItem(dep) as AbstractDProject) != null)
					yield return p;
		}
開發者ID:DinrusGroup,項目名稱:Mono-D,代碼行數:7,代碼來源:AbstractDProject.cs

示例14: GetReferencedItems

		public override IEnumerable<SolutionItem> GetReferencedItems(ConfigurationSelector configuration)
		{
			SolutionItem p;
			foreach (var dep in References.ReferencedProjectIds)
				if ((p = ParentSolution.GetSolutionItem(dep)) != null)
					yield return p;
		}
開發者ID:DinrusGroup,項目名稱:Mono-D,代碼行數:7,代碼來源:AbstractDProject.cs

示例15: OnGetOutputFileName

 protected override FilePath OnGetOutputFileName (ConfigurationSelector configuration)
 {
   var output = base.OnGetOutputFileName (configuration);
   if (!disableOutputNameChange && IsSupportedProject)
     return output.ChangeExtension (PluginExtension);
   return output;
 }
開發者ID:mcneel,項目名稱:RhinoCommonXamarinStudioAddin,代碼行數:7,代碼來源:RhinoProjectServiceExtension.cs


注:本文中的MonoDevelop.Projects.ConfigurationSelector類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。