All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.noear.solon.annotation.Configuration Maven / Gradle / Ivy

package org.noear.solon.annotation;

import java.lang.annotation.*;

/**
 * 配置器(主要为了动态构建组件 或 适配些接口)
 *
 * 

 * //或构建一些组件
 * @Configuration
 * public class Config{
 *     @Bean
 *     public DataSource db1(@Inject("${db1}") HikariDataSource ds){
 *         return ds;
 *     }
 * }
 *
 * //或完成一些适配
 * @Configuration
 * public class ServletConfig implements ServletContainerInitializer {
 *     @Override
 *     public void onStartup(Set> set, ServletContext sc) throws ServletException {
 *
 *     }
 * }
 * 
* * @author noear * @since 1.0 * */ @Target({ElementType.TYPE}) @Retention(RetentionPolicy.RUNTIME) @Documented public @interface Configuration { }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy