Package org.apache.avalon.framework.logger

Examples of org.apache.avalon.framework.logger.ConsoleLogger


    private void generalTest( Instrument[] instruments, Instrumentable[] children )
        throws Exception
    {
        AbstractLogEnabledInstrumentableImpl impl =
            new AbstractLogEnabledInstrumentableImpl( "base" );
        impl.enableLogging( new ConsoleLogger() );
       
        // Set the name
        impl.setInstrumentableName( "test" );
       
        // Add the instruments
View Full Code Here


        FortressConfig config = new FortressConfig( FortressConfig.createDefaultConfig() );
        config.setContainerConfiguration( "resource://org/apache/avalon/fortress/test/data/test1.xconf" );
        config.setLoggerManagerConfiguration( "resource://org/apache/avalon/fortress/test/data/test1.xlog" );

        m_instrManager = new DefaultInstrumentManager();
        ContainerUtil.enableLogging(m_instrManager, new ConsoleLogger());
        ContainerUtil.initialize(m_instrManager);
        config.setInstrumentManager(m_instrManager);

        m_manager = new ContextManager( config.getContext(), new ConsoleLogger() );
        m_manager.initialize();
    }
View Full Code Here

        //  warning or error messages.  However in most cases, the debug
        //  information should not be displayed, so turn it off by default.
        //  Unfortunately, there is not a very good place to make this settable.
        if ( m_logger == null )
        {
            m_primordialLogger = new ConsoleLogger( ConsoleLogger.LEVEL_INFO );
        }
        else
        {
            m_primordialLogger = null;
        }
View Full Code Here

    }

    public void setUp() throws Exception
    {
        FortressRoleManager roles = new FortressRoleManager( null, this.getClass().getClassLoader() );
        roles.enableLogging( new ConsoleLogger( ConsoleLogger.LEVEL_INFO ) );
        roles.initialize();
        m_manager = new Role2MetaInfoManager( roles );
    }
View Full Code Here

     */
    public void DONTtestShorthandReturnValues()
        throws Exception
    {
        FortressRoleManager roles = new FortressRoleManager( null, this.getClass().getClassLoader() );
        roles.enableLogging( new ConsoleLogger( ConsoleLogger.LEVEL_INFO ) );
        roles.initialize();

        checkRole( roles,
            "jdbc-datasource",
            "org.apache.avalon.excalibur.datasource.DataSourceComponent",
View Full Code Here

    public void testShorthandReturnValues()
            throws Exception
    {
        DefaultConfigurationBuilder builder = new DefaultConfigurationBuilder();
        ConfigurableRoleManager roles = new ConfigurableRoleManager( null, this.getClass().getClassLoader() );
        roles.enableLogging( new ConsoleLogger( ConsoleLogger.LEVEL_INFO ) );
        roles.configure( builder.build( this.getClass().getClassLoader()
                .getResourceAsStream( "org/apache/avalon/fortress/impl/role/test/ConfigManager.roles" ) ) );

        checkRole( roles,
                "component1",
View Full Code Here

    /**
     * Constructor
     */
    public ConsoleLoggerManager()
    {
        m_logger = new ConsoleLogger();
    }
View Full Code Here

    private Configuration containerConfiguration;

    /** Constructor */
    public ServiceContainerConfiguration()
    {
        this.logger = new ConsoleLogger();
        this.containerFlavour = ServiceConstants.AVALON_CONTAINER_YAAFI;
        this.serviceContainerClazzName = ServiceConstants.CLAZZ_NAME;
        this.componentRolesLocation = ServiceConstants.COMPONENT_ROLE_VALUE;
        this.isComponentRolesEncrypted = "false";
        this.componentConfigurationLocation = ServiceConstants.COMPONENT_CONFIG_VALUE;
View Full Code Here

     * Constructor
     */
    public Container()
    {
        // org.apache.log4j.BasicConfigurator.configure();
        this.enableLogging( new ConsoleLogger( ConsoleLogger.LEVEL_DEBUG ) );
        this.config = new ServiceContainerConfiguration();
    }
View Full Code Here

        getLogger().debug("Starting container...");

        this.config.setComponentConfigurationLocation( configFileName );
        this.config.setComponentRolesLocation( roleFileName );
        this.config.setParametersLocation( parametersFileName );
        this.config.setLogger( new ConsoleLogger( ConsoleLogger.LEVEL_DEBUG ) );

        File configFile = new File(configFileName);

        if (!configFile.exists())
        {
View Full Code Here

TOP

Related Classes of org.apache.avalon.framework.logger.ConsoleLogger

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.