Package ru.tinkoff.kora.common
Annotation Interface Tag
Русский: Указывает что проаннотированный компонент
English: Indicates that the annotated component
Пример / Example:
Component имеет определенный тег
и будет внедрен как зависимость именно там где требуется такой же тег.
English: Indicates that the annotated component
Component has a specific tag
and will be implemented as a dependency exactly where the same tag is required.
Пример / Example:
@KoraApp
public interface Application {
@Tag(String.class)
default Supplier<String> tagStrSupplier() {
return () -> "1";
}
default Supplier<String> myStr(@Tag(String.class) Supplier<String> tagStr) {
return s -> tagStr.get() + "2";
}
}
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classРусский: Специальный тип тега который означает что тэг подходит под любое условие внедрения зависимости, то есть соответствует любому тэгу. -
Required Element Summary
Required Elements
-
Element Details
-
value
Class<?>[] value
-