Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.apache.maven.continuum.management.util;
 
 /*
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
  * distributed with this work for additional information
  * regarding copyright ownership.  The ASF licenses this file
  * to you under the Apache License, Version 2.0 (the
  * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *   http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing,
 * software distributed under the License is distributed on an
 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
 * KIND, either express or implied.  See the License for the
 * specific language governing permissions and limitations
 * under the License.
 */
import  org.codehaus.plexus.spring.PlexusBeanDefinitionDocumentReader;
import  org.codehaus.plexus.spring.PlexusConfigurationPropertyEditor;
import  org.codehaus.plexus.spring.PlexusContainerAdapter;
import  org.codehaus.plexus.spring.PlexusLifecycleBeanPostProcessor;
import  org.codehaus.plexus.spring.editors.CollectionPropertyEditor;
import  org.codehaus.plexus.spring.editors.MapPropertyEditor;
import  org.codehaus.plexus.spring.editors.PropertiesPropertyEditor;
import  org.slf4j.Logger;
import  org.slf4j.LoggerFactory;
import  org.springframework.beans.BeansException;
import  org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
import  org.springframework.beans.factory.xml.XmlBeanDefinitionReader;
import  org.springframework.context.ApplicationContext;
{
    
Logger used by this class.
    protected Logger logger = LoggerFactory.getLogger( getClass() );
    private PlexusLifecycleBeanPostProcessor lifecycleBeanPostProcessor;

    

See also:
org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(org.springframework.beans.factory.xml.XmlBeanDefinitionReader)
    protected void loadBeanDefinitions( XmlBeanDefinitionReader reader )
        throws BeansException, IOException
    {
        .info( "Registering Plexus to Spring XML translation" );
        reader.setDocumentReaderClass( PlexusBeanDefinitionDocumentReader.class );
    }

    

See also:
org.springframework.context.support.AbstractApplicationContext.postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory)
    protected void postProcessBeanFactory( ConfigurableListableBeanFactory beanFactory, ApplicationContext context )
    {
        // Register a PlexusContainerAdapter bean to allow context lookups using plexus API
        PlexusContainerAdapter plexus = new PlexusContainerAdapter();
        plexus.setApplicationContext( context );
        beanFactory.registerSingleton( "plexusContainer"plexus );
        // Register a beanPostProcessor to handle plexus interface-based lifecycle management
         = new PlexusLifecycleBeanPostProcessor();
        .setBeanFactory( context );
        beanFactory.addBeanPostProcessor(  );
        // Register a PropertyEditor to support plexus XML <configuration> set as CDATA in
        // a spring context XML file.
        beanFactory.addPropertyEditorRegistrar( new PlexusConfigurationPropertyEditor() );
        beanFactory.addPropertyEditorRegistrar( new PropertiesPropertyEditor() );
        beanFactory.addPropertyEditorRegistrar( new CollectionPropertyEditor( List.classArrayList.class ) );
        beanFactory.addPropertyEditorRegistrar( new CollectionPropertyEditor( Set.classHashSet.class ) );
        beanFactory.addPropertyEditorRegistrar( new MapPropertyEditor( Map.classHashMap.class ) );
    }

    

See also:
org.springframework.context.support.AbstractApplicationContext.doClose()
    protected void doClose()
    {
        try
        {
            .destroy();
        }
        catch ( Throwable ex )
        {
            .error( "Exception thrown from PlexusLifecycleBeanPostProcessor handling ContextClosedEvent"ex );
        }
    }
New to GrepCode? Check out our FAQ X