org.apache.maven.continuum.model.project.Project.addBuildDefinition()方法的使用及代码示例

x33g5p2x  于2022-01-26 转载在 其他  
字(3.9k)|赞(0)|评价(0)|浏览(93)

本文整理了Java中org.apache.maven.continuum.model.project.Project.addBuildDefinition()方法的一些代码示例,展示了Project.addBuildDefinition()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Project.addBuildDefinition()方法的具体详情如下:
包路径:org.apache.maven.continuum.model.project.Project
类名称:Project
方法名:addBuildDefinition

Project.addBuildDefinition介绍

[英]Method addBuildDefinition
[中]方法addBuildDefinition

代码示例

代码示例来源:origin: org.apache.maven.continuum/continuum-core

resolveDefaultBuildDefinitionsForProject( buildDefinition, project );
  project.addBuildDefinition( buildDefinition );
resolveDefaultBuildDefinitionsForProject( buildDefinition, project );
project.addBuildDefinition( buildDefinition );

代码示例来源:origin: org.apache.maven.continuum/continuum-test

public static Project makeStubShellProject( String name, String script )
{
  Project project = new Project();
  makeProject( project, name, "1.0" );
  project.setExecutorId( ContinuumBuildExecutorConstants.SHELL_BUILD_EXECUTOR );
  BuildDefinition def = new BuildDefinition();
  def.setBuildFile( script );
  project.addBuildDefinition( def );
  return project;
}

代码示例来源:origin: org.apache.maven.continuum/continuum-model

project.addBuildDefinition( parseBuildDefinition( "buildDefinition", xmlStreamReader, strict, encoding ) );

代码示例来源:origin: org.apache.continuum/continuum-test

public static Project makeStubShellProject( String name, String script )
{
  Project project = new Project();
  makeProject( project, name, "1.0" );
  project.setExecutorId( ContinuumBuildExecutorConstants.SHELL_BUILD_EXECUTOR );
  BuildDefinition def = new BuildDefinition();
  def.setBuildFile( script );
  project.addBuildDefinition( def );
  return project;
}

代码示例来源:origin: org.apache.maven.continuum/continuum-core

public void addTemplateInProject( int buildDefinitionTemplateId, Project project )
  throws BuildDefinitionServiceException
{
  try
  {
    BuildDefinitionTemplate template = getBuildDefinitionTemplate( buildDefinitionTemplateId );
    if ( template.getBuildDefinitions().isEmpty() )
    {
      return;
    }
    project = store.getProjectWithBuildDetails( project.getId() );
    List<BuildDefinition> buildDefs = new ArrayList<BuildDefinition>();
    for ( Iterator<BuildDefinition> iterator = template.getBuildDefinitions().iterator(); iterator.hasNext(); )
    {
      BuildDefinition bd = iterator.next();
      bd = cloneBuildDefinition( bd );
      bd.setTemplate( false );
      bd = store.addBuildDefinition( bd );
      project.addBuildDefinition( bd );
    }
    store.updateProject( project );
  }
  catch ( ContinuumStoreException e )
  {
    throw new BuildDefinitionServiceException( e.getMessage(), e );
  }
}

代码示例来源:origin: org.apache.continuum/continuum-core

project.addBuildDefinition( buildDefinition );
resolveDefaultBuildDefinitionsForProject( buildDefinition, project );
project.addBuildDefinition( buildDefinition );

代码示例来源:origin: org.apache.continuum/continuum-core

continuumProject.addBuildDefinition( projectBuildDef );

代码示例来源:origin: org.apache.continuum/continuum-model

project.addBuildDefinition( parseBuildDefinition( "buildDefinition", xmlStreamReader, strict, encoding ) );

代码示例来源:origin: org.apache.continuum/continuum-core

public void addTemplateInProject( int buildDefinitionTemplateId, Project project )
  throws BuildDefinitionServiceException
{
  try
  {
    BuildDefinitionTemplate template = getBuildDefinitionTemplate( buildDefinitionTemplateId );
    if ( template.getBuildDefinitions().isEmpty() )
    {
      return;
    }
    project = projectDao.getProjectWithBuildDetails( project.getId() );
    for ( BuildDefinition bd : (List<BuildDefinition>) template.getBuildDefinitions() )
    {
      bd = cloneBuildDefinition( bd );
      bd.setTemplate( false );
      bd = buildDefinitionDao.addBuildDefinition( bd );
      project.addBuildDefinition( bd );
    }
    projectDao.updateProject( project );
  }
  catch ( ContinuumStoreException e )
  {
    throw new BuildDefinitionServiceException( e.getMessage(), e );
  }
}

代码示例来源:origin: org.apache.maven.continuum/continuum-core

.hasNext(); )
project.addBuildDefinition( iterator.next() );

代码示例来源:origin: org.apache.continuum/continuum-core

project.addBuildDefinition( cloneBuildDefinition );

代码示例来源:origin: org.apache.maven.continuum/continuum-core

project.addBuildDefinition( buildDefinitionService.addBuildDefinition( cloned ) );

相关文章

Project类方法