当前位置: 首页>>代码示例>>C#>>正文


C# IProjectSpecifier类代码示例

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


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

示例1: ProjectLink

		public ProjectLink(ICruiseUrlBuilder urlBuilder, IProjectSpecifier projectSpecifier, string text, string action)
			: base (text)
		{
			this.urlBuilder = urlBuilder;
			this.action = action;
			this.buildSpecifier = projectSpecifier;
		}
开发者ID:kascomp,项目名称:CruiseControl.NET,代码行数:7,代码来源:ProjectLink.cs

示例2: ForceBuild

        public bool ForceBuild(IProjectSpecifier projectSpecifier)
        {
            bool clientInfoRequired = false;
            ArrayList clientInfoList = new ArrayList();
            ICruiseManager manager = GetCruiseManager(projectSpecifier.ServerSpecifier);
            IForceFilter[] forceFilters = this.GetProject(manager, projectSpecifier.ProjectName).ForceFilters;

            if (forceFilters != null && forceFilters.Length != 0)
            {
                foreach (IForceFilter forceFilter in forceFilters)
                {
                    if (forceFilter.RequiresClientInformation)
                    {
                        clientInfoRequired = true;
                        ForceFilterClientInfo info = forceFilter.GetClientInfo();
                        clientInfoList.Add(info);
                    }
                }
            }
            if (clientInfoRequired)
            {
                ForceFilterClientInfo[] clientInfo;
                clientInfo = (ForceFilterClientInfo[]) clientInfoList.ToArray(typeof(ForceFilterClientInfo));
                return manager.ForceBuild(projectSpecifier.ProjectName, clientInfo);
            }
            else
            {
                return manager.ForceBuild(projectSpecifier.ProjectName);
            }
        }
开发者ID:vardars,项目名称:ci-factory,代码行数:30,代码来源:ServerAggregatingCruiseManagerWrapper.cs

示例3: BuildProjectUrl

        /// <summary>
        /// Builds the project URL.	
        /// </summary>
        /// <param name="action">The action.</param>
        /// <param name="projectSpecifier">The project specifier.</param>
        /// <returns></returns>
        /// <remarks></remarks>
		public string BuildProjectUrl(string action, IProjectSpecifier projectSpecifier)
		{
			return urlBuilder.BuildUrl(
				action, 
				string.Empty,
				GeneratePath(projectSpecifier.ServerSpecifier.ServerName, projectSpecifier.ProjectName, string.Empty));
		}
开发者ID:kascomp,项目名称:CruiseControl.NET,代码行数:14,代码来源:DefaultCruiseUrlBuilder.cs

示例4: DiagnoseSecurityPermissions

 /// <summary>
 /// Checks the security permissions for a user for a project.
 /// </summary>
 /// <param name="projectSpecifier">The project to check.</param>
 /// <param name="userName">The name of the user.</param>
 /// <param name="sessionToken"></param>
 /// <returns>A set of diagnostics information.</returns>
 public virtual List<SecurityCheckDiagnostics> DiagnoseSecurityPermissions(IProjectSpecifier projectSpecifier, string sessionToken, string userName)
 {
     var response = GetCruiseManager(projectSpecifier, sessionToken)
         .DiagnoseSecurityPermissions(userName, new string[] {
             projectSpecifier.ProjectName
         });
     return response;
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:15,代码来源:ServerAggregatingCruiseManagerWrapper.cs

示例5: CreateBuildSpecifiers

		private IBuildSpecifier[] CreateBuildSpecifiers(IProjectSpecifier projectSpecifier, string[] buildNames)
		{
			var buildSpecifiers = new List<IBuildSpecifier>();
			foreach (string buildName in buildNames)
			{
				buildSpecifiers.Add(new DefaultBuildSpecifier(projectSpecifier, buildName));
			}
			return buildSpecifiers.ToArray();
		}
开发者ID:nickdevore,项目名称:CruiseControl.NET,代码行数:9,代码来源:ServerAggregatingCruiseManagerWrapper.cs

示例6: GetProjectPluginLinks

 public IAbsoluteLink[] GetProjectPluginLinks(IProjectSpecifier projectSpecifier)
 {
     ArrayList links = new ArrayList();
     foreach (IPlugin plugin in pluginConfiguration.ProjectPlugins)
     {
         links.Add(LinkFactory.CreateProjectLink(projectSpecifier, plugin.LinkDescription, plugin.NamedActions[0].ActionName));
     }
     return (IAbsoluteLink[]) links.ToArray(typeof (IAbsoluteLink));
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:9,代码来源:DefaultPluginLinkCalculator.cs

示例7: DeleteProjectModel

 public DeleteProjectModel(IProjectSpecifier projectSpecifier, string message, bool allowDelete,
     bool purgeWorkingDirectory, bool purgeArtifactDirectory, bool purgeSourceControlEnvironment)
 {
     this.message = message;
     this.allowDelete = allowDelete;
     this.purgeSourceControlEnvironment = purgeSourceControlEnvironment;
     this.purgeArtifactDirectory = purgeArtifactDirectory;
     this.purgeWorkingDirectory = purgeWorkingDirectory;
     this.projectSpecifier = projectSpecifier;
 }
开发者ID:vardars,项目名称:ci-factory,代码行数:10,代码来源:DeleteProjectModel.cs

示例8: GenerateAllBuildsView

        public HtmlFragmentResponse GenerateAllBuildsView(IProjectSpecifier projectSpecifier, string sessionToken)
        {
            Hashtable primaryContext = new Hashtable();
            Hashtable secondaryContext = new Hashtable();

            secondaryContext["links"] = linkListFactory.CreateStyledBuildLinkList(farmService.GetBuildSpecifiers(projectSpecifier, sessionToken), BuildReportBuildPlugin.ACTION_NAME);
            primaryContext["buildRows"] = velocityTransformer.Transform(@"BuildRows.vm", secondaryContext);
            primaryContext["allBuildsLink"] = linkFactory.CreateProjectLink(projectSpecifier, string.Empty, ViewAllBuildsProjectPlugin.ACTION_NAME);

            return velocityViewGenerator.GenerateView(@"AllBuilds.vm", primaryContext);
        }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:11,代码来源:RecentBuildLister.cs

示例9: DefaultBuildSpecifier

 public DefaultBuildSpecifier(IProjectSpecifier projectSpecifier, string buildName)
 {
     if (projectSpecifier == null)
     {
         throw new CruiseControlException("Build Specifier cannot be instantiated with a null Project Specifier");
     }
     if (buildName == null)
     {
         throw new CruiseControlException("Build Specifier cannot be instantiated with a null build name");
     }
     if (buildName == string.Empty)
     {
         throw new CruiseControlException("Build Specifier cannot be instantiated with an empty build name");
     }
     this.projectSpecifier = projectSpecifier;
     this.buildName = buildName;
 }
开发者ID:vardars,项目名称:ci-factory,代码行数:17,代码来源:DefaultBuildSpecifier.cs

示例10: IsDisplayedForProject

        public bool IsDisplayedForProject(IProjectSpecifier project)
        {
            string projectName = project.ProjectName;

            if (includedProjects.Count > 0)
            {
                return includedProjects.Contains(project.ProjectName);
            }
            else if (excludedProjects.Count > 0)
            {
                return !excludedProjects.Contains(projectName);
            }
            else
            {
                return true;
            }
        }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:17,代码来源:ProjectConfigurableBuildPlugin.cs

示例11: BuildRecentBuildsTable

        // ToDo - use concatenatable views here, not strings
        // ToDo - something better for errors
        public string BuildRecentBuildsTable(IProjectSpecifier projectSpecifier)
        {
            Hashtable primaryContext = new Hashtable();
            Hashtable secondaryContext = new Hashtable();

            try
            {
                secondaryContext["links"] = linkListFactory.CreateStyledBuildLinkList(farmService.GetMostRecentBuildSpecifiers(projectSpecifier, 10), BuildReportBuildPlugin.ACTION_NAME);
                primaryContext["buildRows"] = velocityTransformer.Transform(@"BuildRows.vm", secondaryContext);
                primaryContext["allBuildsLink"] = linkFactory.CreateProjectLink(projectSpecifier, "", ViewAllBuildsProjectPlugin.ACTION_NAME);

                return velocityTransformer.Transform(@"RecentBuilds.vm", primaryContext);
            }
            catch (Exception)
            {
                // Assume exception also caught where we care about (i.e. by action)
                return "";
            }
        }
开发者ID:vardars,项目名称:ci-factory,代码行数:21,代码来源:RecentBuildLister.cs

示例12: CreateRSSLink

        public static GeneralAbsoluteLink CreateRSSLink(ILinkFactory linkFactory, IProjectSpecifier projectSpecifier)
        {
            string MachineName;

            if (System.Web.HttpContext.Current == null ) 
            {
                MachineName = "localhost";
            }
            else
            {
                MachineName = System.Web.HttpContext.Current.Request.Url.Host;
                if (!System.Web.HttpContext.Current.Request.Url.IsDefaultPort)
                    MachineName = MachineName + ":" + System.Web.HttpContext.Current.Request.Url.Port;
            }

            return  new GeneralAbsoluteLink("RSS",string.Format(System.Globalization.CultureInfo.CurrentCulture,"http://{0}{1}",
                         MachineName,  
                         linkFactory.CreateProjectLink(projectSpecifier, WebDashboard.Plugins.RSS.RSSFeed.ACTION_NAME).Url));
       }
开发者ID:kascomp,项目名称:CruiseControl.NET,代码行数:19,代码来源:RSSLinkBuilder.cs

示例13: GetCruiseManager

        private CruiseServerClientBase GetCruiseManager(IProjectSpecifier projectSpecifier, string sessionToken)
		{
            return GetCruiseManager(projectSpecifier.ServerSpecifier, sessionToken);
		}
开发者ID:nickdevore,项目名称:CruiseControl.NET,代码行数:4,代码来源:ServerAggregatingCruiseManagerWrapper.cs

示例14: BuildRecentBuildsTable

 // ToDo - use concatenatable views here, not strings
 // ToDo - something better for errors
 public string BuildRecentBuildsTable(IProjectSpecifier projectSpecifier, string sessionToken)
 {
     return BuildRecentBuildsTable(projectSpecifier, null, sessionToken);
 }
开发者ID:derrills1,项目名称:ccnet_gitmode,代码行数:6,代码来源:RecentBuildLister.cs

示例15: Setup

		public void Setup()
		{
			urlBuilderMock = new DynamicMock(typeof (IUrlBuilder));
			serverSpecifier = new DefaultServerSpecifier("myserver");
			projectSpecifier = new DefaultProjectSpecifier(serverSpecifier, "myproject");
			buildSpecifier = new DefaultBuildSpecifier(projectSpecifier, "mybuild");
			cruiseUrlBuilder = new DefaultCruiseUrlBuilder((IUrlBuilder) urlBuilderMock.MockInstance);
		}
开发者ID:kascomp,项目名称:CruiseControl.NET,代码行数:8,代码来源:DefaultCruiseUrlBuilderTest.cs


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