epoxy-processor / com.airbnb.epoxy.processor / javax.lang.model.element.Element

Extensions for javax.lang.model.element.Element

annotationMirrorsThreadSafe

val Element.annotationMirrorsThreadSafe: List<AnnotationMirror>

enclosedElementsThreadSafe

val Element.enclosedElementsThreadSafe: List<Element>

getAnnotation

fun <A : Annotation> Element.getAnnotation(): A?

getAnnotationThreadSafe

fun <A : Annotation> Element.getAnnotationThreadSafe(annotationClass: Class<A>): A?

hasAnyAnnotation

fun Element.hasAnyAnnotation(annotationClasses: List<KClass<out Annotation>>): Boolean

iterateClassHierarchy

tailrec fun Element.iterateClassHierarchy(types: Types, classCallback: (classElement: TypeElement) -> Unit): Unit

Return each of the classes in the class hierarchy, starting with the initial receiver and working upwards until Any.

iterateSuperClasses

fun Element.iterateSuperClasses(types: Types, classCallback: (classElement: TypeElement) -> Unit): Unit

Iterate each super class of the receiver, starting with the initial super class and going until Any.

modifiersThreadSafe

val Element.modifiersThreadSafe: Set<Modifier>