/** * {@inheritDoc} */ public TypeDescription.Generic getReceiverType() { if (isStatic()) { return TypeDescription.Generic.UNDEFINED; } else if (isConstructor()) { TypeDescription declaringType = getDeclaringType(), enclosingDeclaringType = getDeclaringType().getEnclosingType(); if (enclosingDeclaringType == null) { return TypeDescription.Generic.OfParameterizedType.ForGenerifiedErasure.of(declaringType); } else { return declaringType.isStatic() ? enclosingDeclaringType.asGenericType() : TypeDescription.Generic.OfParameterizedType.ForGenerifiedErasure.of(enclosingDeclaringType); } } else { return TypeDescription.Generic.OfParameterizedType.ForGenerifiedErasure.of(getDeclaringType()); } } }
/** * {@inheritDoc} */ public TypeDescription.Generic getReceiverType() { return receiverType == null ? super.getReceiverType() : receiverType.accept(TypeDescription.Generic.Visitor.Substitutor.ForAttachment.of(this)); }
/** * {@inheritDoc} */ public TypeDescription.Generic getReceiverType() { TypeDescription.Generic receiverType = TypeDescription.Generic.AnnotationReader.DISPATCHER.resolveReceiverType(constructor); return receiverType == null ? super.getReceiverType() : receiverType; }
/** * {@inheritDoc} */ public TypeDescription.Generic getReceiverType() { if (TypeDescription.AbstractBase.RAW_TYPES) { return super.getReceiverType(); } TypeDescription.Generic receiverType = TypeDescription.Generic.AnnotationReader.DISPATCHER.resolveReceiverType(method); return receiverType == null ? super.getReceiverType() : receiverType; }