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

com.github.panchitoboy.common.ecb.helper.ClassHelper Maven / Gradle / Ivy

There is a newer version: 1.0.4
Show newest version
package com.github.panchitoboy.common.ecb.helper;

import java.lang.reflect.ParameterizedType;
import javax.enterprise.inject.spi.InjectionPoint;
import javax.inject.Inject;

public class ClassHelper {

    private final Class injectionClass;

    @Inject
    public ClassHelper(InjectionPoint ip) {
        ParameterizedType type = (ParameterizedType) ip.getType();
        Class clazz = (Class) type.getActualTypeArguments()[0];
        this.injectionClass = clazz;
    }

    public Class getInjectionClass() {
        return injectionClass;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy