package com.brframework.commoncms.web;

import com.brframework.commoncms.utils.SelectorManager;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * @author 揭光智
 * @date 2019/02/21
 */
@Configuration
public class CmsApplicationRunner implements ApplicationRunner {

    @Override
    public void run(ApplicationArguments args) throws Exception {
        configManager().init();
    }

    @Bean
    public SelectorManager configManager() {
        return new SelectorManager();
    }
}
