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

io.quarkiverse.ironjacamar.ResourceAdapterKind Maven / Gradle / Ivy

There is a newer version: 1.5.0
Show newest version
package io.quarkiverse.ironjacamar;

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

import jakarta.enterprise.util.AnnotationLiteral;
import jakarta.inject.Qualifier;

/**
 * A Qualifier for resource adapters. This is used to identify the resource adapter to be used.
 */
@Qualifier
@Documented
@Retention(RetentionPolicy.RUNTIME)
public @interface ResourceAdapterKind {
    /**
     * The kind of resource adapter.
     */
    String value();

    // Literal for this CDI qualifier
    class Literal extends AnnotationLiteral implements ResourceAdapterKind {
        private final String value;

        public static Literal of(String value) {
            return new Literal(value);
        }

        public Literal(String value) {
            this.value = value;
        }

        @Override
        public String value() {
            return value;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy