package com.yutou.tools.utils;

import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * 服务启动后执行
 */
@Component
public class ApplicationInit implements ApplicationRunner {
    @Resource
    MusicTools musicTools;
    @Override
    public void run(ApplicationArguments args) throws Exception {
        musicTools.init();//初始化音乐库
    }
}
