Top Description Constructors Methods
io.vertx.codegen

pack-priv Class TypeValidator

extends Object
Class Inheritance
Imports
io.vertx.codegen.type.ClassKind, .DataObjectInfo, .ParameterizedTypeInfo, .TypeInfo, .TypeVariableInfo, javax.lang.model.element.Element, .ElementKind, .ExecutableElement, .TypeParameterElement, .VariableElement, javax.lang.model.type.TypeMirror, javax.lang.model.util.Types, java.util.List, .Map, .Set

Validates codegen types.

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
private static boolean
isValidCallbackValueType(Element elem, TypeInfo type, boolean allowAnyJavaType)

private static boolean
private static boolean
isValidContainer(Element elem, TypeInfo type, boolean allowAnyJavaType)

private static boolean
isValidContainerComponent(Element elem, TypeInfo arg, boolean allowAnyJavaType)

private static boolean
private static boolean
isValidFunctionType(Element elem, TypeInfo typeInfo, boolean allowAnyJavaType)

private static boolean
isValidFutureType(Element elem, TypeInfo type, boolean allowAnyJavaType)

private static boolean
isValidHandlerType(Element elem, TypeInfo type, boolean allowAnyJavaType)

private static boolean

Returns:

check whether constantElt type is an inner type of the same class of the constant declaration
isValidKotlinCompanionObject
(Types typeUtils, VariableElement constantElt)

private static boolean
isValidNonCallableType(Element elem, TypeInfo type, boolean isParam, boolean isReturn, boolean allowParameterized, boolean allowAnyJavaType)

private static boolean
isValidOtherType(TypeInfo type, boolean allowAnyJavaType)

private static boolean
isValidVertxGenInterface(Element elem, TypeInfo type, boolean allowParameterized, boolean allowAnyJavaType)

private static boolean
isValidVertxGenTypeArgument(Element elem, TypeInfo arg, boolean allowAnyJavaType)

private static boolean
rawTypeIs(TypeInfo type, Class<?>... classes)

pack-priv static void
validateConstantType(Types typeUtils, VariableElement elem, TypeInfo type, TypeMirror typeMirror, boolean allowAnyJavaType)

pack-priv static void
validateParamType(ExecutableElement elem, TypeInfo typeInfo, boolean allowAnyJavaType)

pack-priv static void
validateReturnType(ExecutableElement elem, TypeInfo type, boolean allowAnyJavaType)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

TypeValidatorback to summary
pack-priv TypeValidator()

Method Detail

isValidCallbackValueTypeback to summary
private static boolean isValidCallbackValueType(Element elem, TypeInfo type, boolean allowAnyJavaType)
isValidClassTypeParamback to summary
private static boolean isValidClassTypeParam(ExecutableElement elem, TypeInfo type)
isValidContainerback to summary
private static boolean isValidContainer(Element elem, TypeInfo type, boolean allowAnyJavaType)
isValidContainerComponentback to summary
private static boolean isValidContainerComponent(Element elem, TypeInfo arg, boolean allowAnyJavaType)
isValidEnumback to summary
private static boolean isValidEnum(TypeInfo info)
isValidFunctionTypeback to summary
private static boolean isValidFunctionType(Element elem, TypeInfo typeInfo, boolean allowAnyJavaType)
isValidFutureTypeback to summary
private static boolean isValidFutureType(Element elem, TypeInfo type, boolean allowAnyJavaType)
isValidHandlerTypeback to summary
private static boolean isValidHandlerType(Element elem, TypeInfo type, boolean allowAnyJavaType)
isValidKotlinCompanionObjectback to summary
private static boolean isValidKotlinCompanionObject(Types typeUtils, VariableElement constantElt)
Returns:boolean

check whether constantElt type is an inner type of the same class of the constant declaration

isValidNonCallableTypeback to summary
private static boolean isValidNonCallableType(Element elem, TypeInfo type, boolean isParam, boolean isReturn, boolean allowParameterized, boolean allowAnyJavaType)
isValidOtherTypeback to summary
private static boolean isValidOtherType(TypeInfo type, boolean allowAnyJavaType)
isValidVertxGenInterfaceback to summary
private static boolean isValidVertxGenInterface(Element elem, TypeInfo type, boolean allowParameterized, boolean allowAnyJavaType)
isValidVertxGenTypeArgumentback to summary
private static boolean isValidVertxGenTypeArgument(Element elem, TypeInfo arg, boolean allowAnyJavaType)
rawTypeIsback to summary
private static boolean rawTypeIs(TypeInfo type, Class<?>... classes)
validateConstantTypeback to summary
pack-priv static void validateConstantType(Types typeUtils, VariableElement elem, TypeInfo type, TypeMirror typeMirror, boolean allowAnyJavaType)
validateParamTypeback to summary
pack-priv static void validateParamType(ExecutableElement elem, TypeInfo typeInfo, boolean allowAnyJavaType)
validateReturnTypeback to summary
pack-priv static void validateReturnType(ExecutableElement elem, TypeInfo type, boolean allowAnyJavaType)