/*
 * Copyright (C) 2008 feilong (venusdrogon@163.com)
 *
 * Licensed 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.
 */
package com.feilong.spring.jdbc.datasource;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * <h3>使用方式:</h3>
 * 
 * <blockquote>
 * <p>
 * 在业务类 manager或者方法上,使用 {@code @MultipleGroupDataSource("exampleDatabase")}来标识
 * </p>
 * </blockquote>.
 *
 * @author <a href="mailto:venusdrogon@163.com">feilong</a>
 * @version 1.1.0 2014-6-25 16:28:08
 * @since 1.1.0
 */
// 表示产生文档，比如通过javadoc产生文档, 将此注解包含在 javadoc 中, 这个Annotation可以被写入javadoc
@Documented
// 在jvm加载class时候有效, VM将在运行期也保留注释，因此可以通过反射机制读取注解的信息
@Retention(RetentionPolicy.RUNTIME)
@Target({ ElementType.TYPE, ElementType.METHOD })
@Inherited
public @interface MultipleGroupDataSource{

    /**
     * 数据库组名.
     *
     * @return the string
     */
    String value() default MultipleGroupReadWriteUtil.DEFAULT_GROUP_NAME;

}

/*
 * Copyright (C) 2008 feilong (venusdrogon@163.com)
 *
 * Licensed 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.
 */
package com.feilong.spring.jdbc.datasource;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Inherited;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * 多数据源注解.
 * 
 * <h3>使用方式:</h3>
 * 
 * <blockquote>
 * <p>
 * 在业务类 manager或者方法上,使用 {@code @MultipleGroupDataSource("exampleDatabase")}来标识.
 * </p>
 * </blockquote>
 *
 * @author <a href="mailto:venusdrogon@163.com">feilong</a>
 * @version 1.1.0 2014-6-25 16:28:08
 * @since 1.1.0
 */
// 表示产生文档，比如通过javadoc产生文档, 将此注解包含在 javadoc 中, 这个Annotation可以被写入javadoc
@Documented
// 在jvm加载class时候有效, VM将在运行期也保留注释，因此可以通过反射机制读取注解的信息
@Retention(RetentionPolicy.RUNTIME)
@Target({ ElementType.TYPE, ElementType.METHOD })
@Inherited
public @interface MultipleGroupDataSource{

    /**
     * 数据库组名.
     *
     * @return the string
     */
    String value() default MultipleGroupReadWriteUtil.DEFAULT_GROUP_NAME;
}

update javadoc