ProcessorUtils

interface ProcessorUtils

Types

Context
Link copied to clipboard
interface Context
SimpleContext
Link copied to clipboard
class SimpleContext(logPrefix: String, env: ProcessingEnvironment) : ProcessorUtils.Context

Functions

asKotlinClassName
Link copied to clipboard
open fun TypeName.asKotlinClassName(): String
open fun Element.asKotlinClassName(): String
open fun String.asKotlinClassName(): String
asRawKotlinClassName
Link copied to clipboard
open fun ParameterizedTypeName.asRawKotlinClassName(): String
asTypeName
Link copied to clipboard
open fun Element.asTypeName(): TypeName
blacklist
Link copied to clipboard
open fun <T : Element> List<T>.blacklist(blacklist: List<String>): List<T>
Blacklists all types, where the fqn starts with any entry of the given blacklist
defaultBlacklist
Link copied to clipboard
open fun <T : Element> List<T>.defaultBlacklist(): List<T>
Applies a default black list.
equals
Link copied to clipboard
open operator fun equals(other: Any?): Boolean
findAllTypesWithAnnotation
Link copied to clipboard
open fun <T : Annotation> RoundEnvironment.findAllTypesWithAnnotation(cls: KClass<T>): List<TypeElement>
Finds all TypeElements that carry the given annotation
getAllEnclosedTypes
Link copied to clipboard
open fun TypeElement.getAllEnclosedTypes(filter: (TypeElement) -> Boolean = { true }): List<TypeElement>
Returns all enclosed type (direct and indirect) to the list of TypeElements
getAllSuperTypes
Link copied to clipboard
open fun TypeElement.getAllSuperTypes(): List<TypeElement>
Returns all supertypes (direct and indirect) of the TypeElement recursively
getReferencedTypes
Link copied to clipboard
open fun TypeMirror.getReferencedTypes(): Set<TypeMirror>
Get all types that are directly referenced by the given type
getReferencedTypesRecursive
Link copied to clipboard
open fun Element.getReferencedTypesRecursive(): Set<TypeMirror>
Get all types, that are directly or recursively used within the given Element
hasAnnotation
Link copied to clipboard
open fun <T : Annotation> Element.hasAnnotation(cls: KClass<T>): Boolean
hashCode
Link copied to clipboard
open fun hashCode(): Int
hasPublicGetterFor
Link copied to clipboard
open fun TypeElement.hasPublicGetterFor(v: VariableElement): Boolean
logError
Link copied to clipboard
open fun logError(str: String)
logMandatoryWarning
Link copied to clipboard
open fun logMandatoryWarning(str: String)
logNote
Link copied to clipboard
open fun logNote(str: String)
logOther
Link copied to clipboard
open fun logOther(str: String)
logWarning
Link copied to clipboard
open fun logWarning(str: String)
plusAllEnclosedTypes
Link copied to clipboard
open fun List<TypeElement>.plusAllEnclosedTypes(filter: (TypeElement) -> Boolean = { true }): List<TypeElement>
Adds all enclosed type (direct and indirect) to the list of TypeElements
plusAllSuperTypes
Link copied to clipboard
open fun List<TypeElement>.plusAllSuperTypes(): List<TypeElement>
Adds all supertypes (direct and indirect) to the list of TypeElements
plusReferencedTypesRecursive
Link copied to clipboard
open fun List<TypeElement>.plusReferencedTypesRecursive(): List<TypeElement>
Adds all referenced TypeElements by walking through all members recursively
toString
Link copied to clipboard
open fun toString(): String

Properties

ctx
Link copied to clipboard
abstract val ctx: ProcessorUtils.Context
defaultPackageBlackList
Link copied to clipboard
open val defaultPackageBlackList: List<String>
elementUtils
Link copied to clipboard
open val elementUtils: Elements
env
Link copied to clipboard
open val env: ProcessingEnvironment
filer
Link copied to clipboard
open val filer: Filer
fqn
Link copied to clipboard
open val TypeName.fqn: String
fqn
Link copied to clipboard
open val TypeMirror.fqn: String
fqn
Link copied to clipboard
open val Element.fqn: String
isAnyType
Link copied to clipboard
open val String.isAnyType: Boolean
isAnyType
Link copied to clipboard
open val TypeName.isAnyType: Boolean
isBlackListed
Link copied to clipboard
open val TypeMirror.isBlackListed: Boolean
isBlackListed
Link copied to clipboard
open val TypeName.isBlackListed: Boolean
isEnum
Link copied to clipboard
open val TypeName.isEnum: Boolean
isNullable
Link copied to clipboard
open val Element.isNullable: Boolean
isPrimitiveType
Link copied to clipboard
open val String.isPrimitiveType: Boolean
isPrimitiveType
Link copied to clipboard
open val TypeName.isPrimitiveType: Boolean
isPrimitiveType
Link copied to clipboard
open val Element.isPrimitiveType: Boolean
isStringType
Link copied to clipboard
open val String.isStringType: Boolean
isStringType
Link copied to clipboard
open val TypeName.isStringType: Boolean
isStringType
Link copied to clipboard
open val Element.isStringType: Boolean
locale
Link copied to clipboard
open val locale: Locale
messager
Link copied to clipboard
open val messager: Messager
methods
Link copied to clipboard
open val TypeElement.methods: List<ExecutableElement>
options
Link copied to clipboard
open val options: Map<String, String>
packageName
Link copied to clipboard
open val TypeName.packageName: String
sourceVersion
Link copied to clipboard
open val sourceVersion: SourceVersion
typeUtils
Link copied to clipboard
open val typeUtils: Types
variables
Link copied to clipboard
open val TypeElement.variables: List<VariableElement>
Get all variables of a type element

Inheritors

GenericUsages
Link copied to clipboard
KotlinProcessor
Link copied to clipboard
MBase
Link copied to clipboard
Model
Link copied to clipboard

Extensions

model
Link copied to clipboard
fun ProcessorUtils.model(types: List<TypeElement>): Model