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


Java NoBannerLogger类代码示例

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


NoBannerLogger类属于org.apache.tools.ant包,在下文中一共展示了NoBannerLogger类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createProject

import org.apache.tools.ant.NoBannerLogger; //导入依赖的package包/类
/**
 * @return Factory method to create new Project instances
 */
protected static Project createProject() {
    final Project project = new Project();

    final ProjectHelper helper = ProjectHelper.getProjectHelper();
    project.addReference(ProjectHelper.PROJECTHELPER_REFERENCE, helper);
    helper.getImportStack().addElement("AntBuilder"); // import checks that stack is not empty 

    final BuildLogger logger = new NoBannerLogger();

    logger.setMessageOutputLevel(org.apache.tools.ant.Project.MSG_INFO);
    logger.setOutputPrintStream(System.out);
    logger.setErrorPrintStream(System.err);

    project.addBuildListener(logger);

    project.init();
    project.getBaseDir();
    return project;
}
 
开发者ID:apache,项目名称:groovy,代码行数:23,代码来源:AntBuilder.java

示例2: createProject

import org.apache.tools.ant.NoBannerLogger; //导入依赖的package包/类
/**
 * Creates and configures Ant project for Java task.
 * 
 * @return Ant project for Java task
 */
protected Project createProject()
{
    final Project result = new Project();

    final ProjectHelper helper = ProjectHelper.getProjectHelper();
    result.addReference( ProjectHelper.PROJECTHELPER_REFERENCE, helper );
    helper.getImportStack().addElement( "AntBuilder" ); // import checks that stack is not empty

    final BuildLogger logger = new NoBannerLogger();

    logger.setMessageOutputLevel( Project.MSG_INFO );
    logger.setOutputPrintStream( System.out );
    logger.setErrorPrintStream( System.err );

    result.addBuildListener( logger );

    result.init();
    result.setDefaultInputStream( System.in ); // for interactive commands, like "shell", needs more work!
    return result;
}
 
开发者ID:sbtrun-maven-plugin,项目名称:sbtrun-maven-plugin,代码行数:26,代码来源:AbstractAntJavaBasedMojo.java

示例3: createProject

import org.apache.tools.ant.NoBannerLogger; //导入依赖的package包/类
protected Project createProject()
{
    final Project project = new Project();

    final ProjectHelper helper = ProjectHelper.getProjectHelper();
    project.addReference( ProjectHelper.PROJECTHELPER_REFERENCE, helper );
    helper.getImportStack().addElement( "AntBuilder" ); // import checks that stack is not empty

    final BuildLogger logger = new NoBannerLogger();

    logger.setMessageOutputLevel( Project.MSG_INFO );
    logger.setOutputPrintStream( System.out );
    logger.setErrorPrintStream( System.err );

    project.addBuildListener( logger );

    project.init();
    project.getBaseDir();
    return project;
}
 
开发者ID:play1-maven-plugin,项目名称:play1-maven-plugin,代码行数:21,代码来源:AbstractAntJavaBasedPlayMojo.java


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