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

org.switchyard.test.MixInDependencies Maven / Gradle / Ivy

package org.switchyard.test;

import java.lang.annotation.Documented;
import java.lang.annotation.Retention;
import java.lang.annotation.Target;


import static java.lang.annotation.ElementType.TYPE;
import static java.lang.annotation.RetentionPolicy.RUNTIME;

/**
 * An annotation to indicate MixIn dependencies.
 * 
 * @author Tomohisa Igarashi
 *
 */
@Target({TYPE})
@Retention(RUNTIME)
@Documented
public @interface MixInDependencies {

    /**
     * A list of mixins which must be initialized before the annotated mixin does.
     * These mixins will be instantiated by SwitchYardTestKit even if they are not on the
     * mixins list of {@link SwitchYardTestCaseConfig} annotation.
     */
    Class[] required() default SwitchYardTestKit.NullMixIns.class;
    
    /**
     * A list of mixins which should be initialized before the annotated mixin does
     * if they will be used. These mixins will not be instantiated unless they are on the
     * mixins list of {@link SwitchYardTestCaseConfig} annotation.
     * This option can be used to handle the case like that - the MixInA doesn't always need
     * MixInB, but when we use MixInA and MixInB together, MixInB should be initialized first.
     * In this case the MixInA should have a optional dependency on MixInB.
     */
    Class[] optional() default SwitchYardTestKit.NullMixIns.class;
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy