public class ProcessorUtils extends Object
Constructor and Description |
---|
ProcessorUtils() |
Modifier and Type | Method and Description |
---|---|
static <T> T |
getAnnotationParameter(javax.lang.model.util.Elements elements,
javax.lang.model.element.Element element,
Class<?> annotationType,
String parameterName,
Class<? extends T> expectedReturnType)
Gets an annotation parameter from an annotation.
|
static String |
getPackageName(String qualifiedName) |
static String |
getPackageName(TypeName typeName) |
static void |
validate(SpecModel specModel,
EnumSet<RunMode> runMode)
Creates printable exceptions for the validation errors found while running the annotation
processor for the given specmodel and throws a
MultiPrintableException if any such
errors are found. |
public static <T> T getAnnotationParameter(javax.lang.model.util.Elements elements, javax.lang.model.element.Element element, Class<?> annotationType, String parameterName, Class<? extends T> expectedReturnType)
Class
it doesn't work, because javac doesn't
load classes in the normal manner.public static final void validate(SpecModel specModel, EnumSet<RunMode> runMode)
MultiPrintableException
if any such
errors are found.public static String getPackageName(TypeName typeName)