Class AjProblemReporter
java.lang.Object
org.aspectj.org.eclipse.jdt.internal.compiler.problem.ProblemHandler
org.aspectj.org.eclipse.jdt.internal.compiler.problem.ProblemReporter
org.aspectj.ajdt.internal.compiler.problem.AjProblemReporter
Extends problem reporter to support compiler-side implementation of declare soft. Also overrides error reporting for the need to
implement abstract methods to account for inter-type declarations and pointcut declarations. This second job might be better done
directly in the SourceTypeBinding/ClassScope classes.
- Author:
- Jim Hugunin
-
Field Summary
Fields inherited from class org.aspectj.org.eclipse.jdt.internal.compiler.problem.ProblemReporter
referenceContext
Fields inherited from class org.aspectj.org.eclipse.jdt.internal.compiler.problem.ProblemHandler
NoArgument, options, policy, problemFactory, suppressTagging
-
Constructor Summary
ConstructorDescriptionAjProblemReporter(IErrorHandlingPolicy policy, CompilerOptions options, IProblemFactory problemFactory)
-
Method Summary
Modifier and TypeMethodDescriptionvoid
abstractMethodCannotBeOverridden(SourceTypeBinding type, MethodBinding concreteMethod)
void
abstractMethodInAbstractClass(SourceTypeBinding type, AbstractMethodDeclaration methodDecl)
void
void
abstractMethodMustBeImplemented(SourceTypeBinding type, MethodBinding abstractMethod)
void
caseExpressionMustBeConstant(Expression expression)
createProblem(char[] fileName, int problemId, String[] problemArguments, String[] messageArguments, int severity, int problemStartPosition, int problemEndPosition, int lineNumber)
All problems end up routed through here at some point...void
disallowedTargetForAnnotation(Annotation annotation)
void
duplicateInheritedMethods(SourceTypeBinding type, MethodBinding inheritedMethod1, MethodBinding inheritedMethod2, boolean isJava8)
The method verifier is a bit 'keen' and doesn't cope well with ITDMs which are of course to be considered a 'default' implementation if the target type doesn't supply one.void
duplicateMethodInType(AbstractMethodDeclaration methodDecl, boolean equalParameters, int severity)
void
finalMethodCannotBeOverridden(MethodBinding currentMethod, MethodBinding inheritedMethod)
A side-effect of the way that we handle itds on default methods on top-most implementors of interfaces is that a class acquiring a final default ITD will erroneously report that it can't override its own member.void
handle(int problemId, String[] problemArguments, String[] messageArguments, int severity, int problemStartPosition, int problemEndPosition, ReferenceContext referenceContext, CompilationResult unitResult)
void
inheritedMethodReducesVisibility(SourceTypeBinding type, MethodBinding concreteMethod, MethodBinding[] abstractMethods)
void
itdMethodMustOverride(AbstractMethodDeclaration method, MethodBinding binding)
Called when there is an ITD marked @override that doesn't override a supertypes method.void
javadocMissingParamTag(char[] name, int sourceStart, int sourceEnd, int modifiers)
void
methodMustOverride(AbstractMethodDeclaration method, long complianceLevel)
Overrides the implementation in ProblemReporter and is ITD aware.void
missingValueForAnnotationMember(Annotation annotation, char[] memberName)
void
overridesPackageDefaultMethod(MethodBinding localMethod, MethodBinding inheritedMethod)
void
parseErrorInsertAfterToken(int start, int end, int currentKind, char[] errorTokenSource, String errorTokenName, String expectedToken)
void
staticAndInstanceConflict(MethodBinding currentMethod, MethodBinding inheritedMethod)
void
unhandledException(TypeBinding exceptionType, ASTNode location)
void
unhandledExceptionFromAutoClose(TypeBinding exceptionType, ASTNode location)
void
uninitializedLocalVariable(LocalVariableBinding binding, ASTNode location, Scope scope)
void
unusedArgument(LocalDeclaration localDecl)
void
unusedPrivateField(FieldDeclaration fieldDecl)
void
unusedPrivateMethod(AbstractMethodDeclaration methodDecl)
void
unusedPrivateType(TypeDeclaration typeDecl)
void
visibilityConflict(MethodBinding currentMethod, MethodBinding inheritedMethod)
Methods inherited from class org.aspectj.org.eclipse.jdt.internal.compiler.problem.ProblemReporter
abortDueToInternalError, abortDueToInternalError, abortDueToPreviewEnablingNotAllowed, abstractMethodMustBeImplemented, abstractMethodNeedingNoBody, alreadyDefinedLabel, annotationCannotOverrideMethod, annotationCircularity, annotationMembersCannotHaveParameters, annotationMembersCannotHaveTypeParameters, annotationTypeDeclarationCannotHaveConstructor, annotationTypeDeclarationCannotHaveSuperclass, annotationTypeDeclarationCannotHaveSuperinterfaces, annotationTypeUsedAsSuperinterface, annotationValueMustBeAnnotation, annotationValueMustBeArrayInitializer, annotationValueMustBeClassLiteral, annotationValueMustBeConstant, anonymousClassCannotExtendFinalClass, anonymousDiamondWithNonDenotableTypeArguments, argumentTypeCannotBeVoid, argumentTypeCannotBeVoidArray, arrayConstantsOnlyInArrayInitializers, arrayReferencePotentialNullReference, arrowInCaseStatementsNotSupported, assignmentHasNoEffect, assignmentHasNoEffect, attemptToReturnNonVoidExpression, attemptToReturnVoidValue, autoboxing, autoManagedResourcesNotBelow17, autoManagedVariableResourcesNotBelow9, autoModuleWithUnstableName, boundCannotBeArray, boundMustBeAnInterface, bytecodeExceeds64KLimit, bytecodeExceeds64KLimit, bytecodeExceeds64KLimit, bytecodeExceeds64KLimit, bytecodeExceeds64KLimit, cannotAllocateVoidArray, cannotAssignToFinalField, cannotAssignToFinalLocal, cannotAssignToFinalOuterLocal, cannotDefineDimensionsAndInitializer, cannotDireclyInvokeAbstractMethod, cannotExtendEnum, cannotImplementIncompatibleNullness, cannotImportPackage, cannotInferElidedTypes, cannotInstantiate, cannotInvokeSuperConstructorInEnum, cannotReadSource, cannotRedefineTypeArgumentNullity, cannotReferToNonEffectivelyFinalOuterLocal, cannotReferToNonFinalField, cannotReferToNonFinalLocalInGuard, cannotReferToNonFinalOuterLocal, cannotReturnInInitializer, cannotThrowNull, cannotThrowType, cannotUseQualifiedEnumConstantInCaseLabel, cannotUseSuperInCodeSnippet, cannotUseSuperInJavaLangObject, classExtendFinalClass, codeSnippetMissingClass, codeSnippetMissingMethod, comparingIdenticalExpressions, computeSeverity, conditionalArgumentsIncompatibleTypes, conflictingImport, conflictingInheritedNullAnnotations, conflictingNullAnnotations, conflictingPackageInModules, conflictingPackagesFromModules, conflictingPackagesFromModules, conflictingPackagesFromOtherModules, constantOutOfRange, constructedArrayIncompatible, containerAnnotationTypeHasNonDefaultMembers, containerAnnotationTypeHasShorterRetention, containerAnnotationTypeHasWrongValueType, containerAnnotationTypeMustHaveValue, contradictoryNullAnnotations, contradictoryNullAnnotations, contradictoryNullAnnotations, contradictoryNullAnnotationsInferred, contradictoryNullAnnotationsInferred, contradictoryNullAnnotationsOnBounds, corruptedSignature, cyclicModuleDependency, danglingReference, defaultMethodOverridesObjectMethod, defaultMethodsNotBelow18, defaultModifierIllegallySpecified, deprecatedField, deprecatedMethod, deprecatedModule, deprecatedType, deprecatedType, dereferencingNullableExpression, dereferencingNullableExpression, descriptorHasInvisibleType, diamondNotBelow17, diamondNotBelow17, diamondNotWithAnoymousClasses, diamondNotWithExplicitTypeArguments, disallowedTargetForContainerAnnotation, disallowedThisParameter, discouragedValueBasedTypeToSynchronize, duplicateAnnotation, duplicateAnnotationValue, duplicateBoundInIntersectionCast, duplicateBounds, duplicateCase, duplicateDefaultCase, duplicateEnumSpecialMethod, duplicateFieldInType, duplicateImport, duplicateInitializationOfBlankFinalField, duplicateInitializationOfFinalLocal, duplicateModifierForField, duplicateModifierForMethod, duplicateModifierForType, duplicateModifierForVariable, duplicateModuleReference, duplicateNestedType, duplicateResourceReference, duplicateSuperinterface, duplicateTargetInTargetAnnotation, duplicateTotalPattern, duplicateTypeParameterInType, duplicateTypeReference, duplicateTypeReference, duplicateTypes, emptyControlFlowStatement, enhancedSwitchMissingDefaultCase, enumAbstractMethodMustBeImplemented, enumConstantMustImplementAbstractMethod, enumConstantsCannotBeSurroundedByParenthesis, enumStaticFieldUsedDuringInitialization, enumSwitchCannotTargetField, errorNoMethodFor, errorNoMethodFor, errorNoSuperInInterface, errorThisSuperInStatic, explicitlyClosedAutoCloseable, exportingForeignPackage, expressionNonNullComparison, expressionNullReference, expressionPotentialNullReference, expressionShouldBeAVariable, fakeReachable, fieldFreeTypeVariableReference, fieldHiding, fieldsOrThisBeforeConstructorInvocation, finallyMustCompleteNormally, finalVariableBound, forbiddenReference, forbiddenReference, forbiddenReference, forwardReference, forwardTypeVariableReference, genericInferenceError, genericInferenceProblem, genericTypeCannotExtendThrowable, getIrritant, getProblemCategory, handleUntagged, hiddenCatchBlock, hierarchyCircularity, hierarchyCircularity, hierarchyHasProblems, illegalAbstractModifierCombinationForMethod, illegalAbstractModifierCombinationForMethod, illegalAccessFromTypeVariable, illegalAnnotationForBaseType, illegalAnnotationForBaseType, illegalArrayOfUnionType, illegalArrayTypeInIntersectionCast, illegalClassLiteralForTypeVariable, illegalExtendedDimensions, illegalExtendedDimensions, IllegalFallThroughToPattern, illegalGenericArray, illegalInstanceOfGenericType, illegalLocalTypeDeclaration, illegalModifierCombinationFinalAbstractForClass, illegalModifierCombinationFinalVolatileForField, illegalModifierCombinationForInterfaceMethod, illegalModifierCombinationForPrivateInterfaceMethod, illegalModifierForAnnotationField, illegalModifierForAnnotationMember, illegalModifierForAnnotationMemberType, illegalModifierForAnnotationType, illegalModifierForClass, illegalModifierForEnum, illegalModifierForEnumConstant, illegalModifierForEnumConstructor, illegalModifierForField, illegalModifierForInnerRecord, illegalModifierForInterface, illegalModifierForInterfaceField, illegalModifierForInterfaceMethod, illegalModifierForLocalClass, illegalModifierForLocalEnumDeclaration, illegalModifierForLocalRecord, illegalModifierForMemberClass, illegalModifierForMemberEnum, illegalModifierForMemberInterface, illegalModifierForMethod, illegalModifierForModule, illegalModifierForRecord, illegalModifierForVariable, illegalModifiers, illegalModifiersForElidedType, illegalParameterRedefinition, illegalPrimitiveOrArrayTypeForEnclosingInstance, illegalQualifiedParameterizedTypeAllocation, illegalQualifierForExplicitThis, illegalQualifierForExplicitThis2, illegalRedeclarationOfPatternVar, illegalRedefinitionToNonNullParameter, illegalReturnRedefinition, illegalReturnRedefinition, illegalSourceLevelForThis, illegalStaticModifierForMemberType, illegalSuperAccess, illegalSuperCallBypassingOverride, illegalThis, illegalThisDeclaration, illegalTotalPatternWithDefault, illegalTypeAnnotationsInStaticMemberAccess, illegalTypeForExplicitThis, illegalUsageOfQualifiedTypeReference, illegalUsageOfTypeAnnotations, illegalUsageOfWildcard, illegalUseOfUnderscoreAsAnIdentifier, illegalVararg, illegalVarargInLambda, illegalVisibilityModifierCombinationForField, illegalVisibilityModifierCombinationForMemberType, illegalVisibilityModifierCombinationForMethod, illegalVisibilityModifierForInterfaceMemberType, illegalVoidExpression, illFormedParameterizationOfFunctionalInterface, implicitObjectBoundNoNullDefault, importProblem, incompatibleExceptionInThrowsClause, incompatibleReturnType, incompatibleReturnType, incorrectArityForParameterizedType, incorrectArityForParameterizedType, incorrectLocationForNonEmptyDimension, incorrectSwitchType, indirectAccessToStaticField, indirectAccessToStaticMethod, inheritedDefaultMethodConflictsWithOtherInherited, inheritedMethodReducesVisibility, inheritedMethodsHaveIncompatibleReturnTypes, inheritedMethodsHaveIncompatibleReturnTypes, inheritedMethodsHaveNameClash, inheritedParameterLackingNonnullAnnotation, initializerMustCompleteNormally, innerTypesCannotDeclareStaticInitializers, interfaceCannotHaveConstructors, interfaceCannotHaveInitializers, interfaceSuperInvocationNotBelow18, intersectionCastNotBelow18, invalidAnnotationMemberType, invalidArrayConstructorReference, invalidBreak, invalidConstructor, invalidContinue, invalidEnclosingType, invalidExplicitConstructorCall, invalidExpressionAsStatement, invalidField, invalidField, invalidField, invalidFileNameForPackageAnnotations, invalidMethod, invalidModule, invalidNullToSynchronize, invalidOpensStatement, invalidOperator, invalidOperator, invalidOperator, invalidPackageReference, invalidParameterizedExceptionType, invalidParenthesizedExpression, invalidServiceRef, invalidType, invalidTypeArguments, invalidTypeForCollection, invalidTypeForCollectionTarget14, invalidTypeToSynchronize, invalidTypeVariableAsException, invalidUnaryExpression, invalidUsageOfAnnotation, invalidUsageOfAnnotationDeclarations, invalidUsageOfEnumDeclarations, invalidUsageOfForeachStatements, invalidUsageOfStaticImports, invalidUsageOfTypeAnnotations, invalidUsageOfTypeArguments, invalidUsageOfTypeParameters, invalidUsageOfTypeParametersForAnnotationDeclaration, invalidUsageOfTypeParametersForEnumDeclaration, invalidUsageOfVarargs, isClassPathCorrect, javadocAmbiguousMethodReference, javadocDeprecatedField, javadocDeprecatedMethod, javadocDeprecatedType, javadocDeprecatedType, javadocDuplicatedParamTag, javadocDuplicatedProvidesTag, javadocDuplicatedReturnTag, javadocDuplicatedTag, javadocDuplicatedThrowsClassName, javadocDuplicatedUsesTag, javadocEmptyReturnTag, javadocErrorNoMethodFor, javadocHiddenReference, javadocInvalidConstructor, javadocInvalidField, javadocInvalidMemberTypeQualification, javadocInvalidMethod, javadocInvalidModuleQualification, javadocInvalidParamTagName, javadocInvalidParamTypeParameter, javadocInvalidProvidesClass, javadocInvalidProvidesClassName, javadocInvalidReference, javadocInvalidSeeHref, javadocInvalidSeeReferenceArgs, javadocInvalidSeeUrlReference, javadocInvalidTag, javadocInvalidThrowsClass, javadocInvalidThrowsClassName, javadocInvalidType, javadocInvalidUsesClass, javadocInvalidUsesClassName, javadocInvalidValueReference, javadocMalformedSeeReference, javadocMissing, javadocMissing, javadocMissingHashCharacter, javadocMissingIdentifier, javadocMissingParamName, javadocMissingProvidesClassName, javadocMissingProvidesTag, javadocMissingReference, javadocMissingReturnTag, javadocMissingTagDescription, javadocMissingTagDescriptionAfterReference, javadocMissingThrowsClassName, javadocMissingThrowsTag, javadocMissingUsesClassName, javadocMissingUsesTag, javadocModuleMissing, javadocUndeclaredParamTagName, javadocUnexpectedTag, javadocUnexpectedText, javadocUnterminatedInlineTag, lambdaExpressionCannotImplementGenericMethod, lambdaExpressionsNotBelow18, lambdaParameterTypeMismatched, lambdaRedeclaresArgument, lambdaRedeclaresLocal, lambdaSignatureMismatched, localStaticsIllegalVisibilityModifierForInterfaceLocalType, localVariableFreeTypeVariableReference, localVariableHiding, localVariableNonNullComparedToNull, localVariableNullComparedToNonNull, localVariableNullInstanceof, localVariableNullReference, localVariablePotentialNullReference, localVariableRedundantCheckOnNonNull, localVariableRedundantCheckOnNull, localVariableRedundantNullAssignment, messageSendPotentialNullReference, messageSendRedundantCheckOnNonNull, methodCanBeDeclaredStatic, methodCanBePotentiallyDeclaredStatic, methodMustBeAccessedStatically, methodMustBeAccessedWithInstance, methodNameClash, methodNameClashHidden, methodNeedBody, methodNeedingNoBody, methodReferenceSwingsBothWays, methodReturnTypeFreeTypeVariableReference, methodWithConstructorName, misplacedTypeAnnotations, missingDefaultCase, missingDeprecatedAnnotationForField, missingDeprecatedAnnotationForMethod, missingDeprecatedAnnotationForType, missingEnumConstantCase, missingEnumConstantCase, missingModuleAddReads, missingNonNullByDefaultAnnotation, missingOverrideAnnotation, missingOverrideAnnotationForInterfaceMethodImplementation, missingRequiresTransitiveForTypeInAPI, missingReturnType, missingSemiColon, missingSerialVersion, missingSynchronizedOnInheritedMethod, missingTypeInConstructor, missingTypeInLambda, missingTypeInMethod, missingValueFromLambda, multiCatchNotBelow17, multiConstantCaseLabelsNotSupported, mustDefineDimensionsOrInitializer, mustUseAStaticMethod, nativeMethodsCannotBeStrictfp, needImplementation, needToEmulateFieldAccess, needToEmulateMethodAccess, noAdditionalBoundAfterTypeVariable, noMoreAvailableSpaceForArgument, noMoreAvailableSpaceForConstant, noMoreAvailableSpaceForLocal, noMoreAvailableSpaceInConstantPool, nonExternalizedStringLiteral, nonGenericTypeCannotBeParameterized, nonNullTypeVariableInUnannotatedBinary, nonPublicTypeInAPI, nonStaticAccessToStaticField, nonStaticAccessToStaticField, nonStaticAccessToStaticMethod, nonStaticContextForEnumMemberType, nonStaticOrAlienTypeReceiver, noSuchEnclosingInstance, notAFunctionalInterface, notAnnotationType, notCompatibleTypesError, notCompatibleTypesError, notCompatibleTypesErrorInForeach, notExportedTypeInAPI, nullableFieldDereference, nullAnnotationAtQualifyingType, nullAnnotationIsRedundant, nullAnnotationIsRedundant, nullAnnotationUnsupportedLocation, nullAnnotationUnsupportedLocation, nullDefaultAnnotationIsRedundant, nullityMismatch, nullityMismatchingTypeAnnotation, nullityMismatchIsNull, nullityMismatchIsUnknown, nullityMismatchPotentiallyNull, nullityMismatchSpecdNullable, nullityMismatchTypeArgument, nullityMismatchVariableIsFreeTypeVariable, nullUnboxing, objectCannotBeGeneric, objectCannotHaveSuperTypes, objectMustBeClass, onlyReferenceTypesInIntersectionCast, operatorOnlyValidOnNumericType, overridesDeprecatedMethod, overridesMethodWithoutSuperInvocation, packageCollidesWithType, packageIsNotExpectedPackage, parameterAssignment, parameterizedMemberTypeMissingArguments, parameterLackingNonnullAnnotation, parameterLackingNullableAnnotation, parseError, parseErrorDeleteToken, parseErrorDeleteTokens, parseErrorInsertBeforeToken, parseErrorInsertToComplete, parseErrorInsertToCompletePhrase, parseErrorInsertToCompleteScope, parseErrorInvalidToken, parseErrorMergeTokens, parseErrorMisplacedConstruct, parseErrorNoSuggestion, parseErrorNoSuggestionForTokens, parseErrorReplaceToken, parseErrorReplaceTokens, parseErrorUnexpectedEnd, patternCannotBeSubtypeOfExpression, patternDominatedByAnother, polymorphicMethodNotBelow17, possibleAccidentalBooleanAssignment, possibleFallThroughCase, possibleHeapPollutionFromVararg, potentiallyUnclosedCloseable, potentialNullUnboxing, previewAPIUsed, previewFeatureUsed, problemNotAnalysed, publicClassMustMatchFileName, rawConstructorReferenceNotWithExplicitTypeArguments, rawMemberTypeCannotBeParameterized, rawTypeReference, recordAccessorMethodHasThrowsClause, recordAccessorMethodShouldBePublic, recordAccessorMethodShouldNotBeGeneric, recordAccessorMethodShouldNotBeStatic, recordCannotExtendRecord, recordCanonicalConstructorHasExplicitConstructorCall, recordCanonicalConstructorHasReturnStatement, recordCanonicalConstructorHasThrowsClause, recordCanonicalConstructorShouldNotBeGeneric, recordCanonicalConstructorVisibilityReduced, recordCompactConstructorHasExplicitConstructorCall, recordCompactConstructorHasReturnStatement, recordComponentCannotBeVoid, recordComponentsCannotHaveModifiers, recordDuplicateComponent, recordIllegalAccessorReturnType, recordIllegalComponentNameInRecord, recordIllegalExplicitFinalFieldAssignInCompactConstructor, recordIllegalExtendedDimensionsForRecordComponent, recordIllegalNativeModifierInRecord, recordIllegalParameterNameInCanonicalConstructor, recordIllegalStaticModifierForLocalClassOrInterface, recordIllegalVararg, recordInstanceInitializerBlockInRecord, recordMissingExplicitConstructorCallInNonCanonicalConstructor, recordNestedRecordInherentlyStatic, recordNonStaticFieldDeclarationInRecord, recordStaticReferenceToOuterLocalVariable, recursiveConstructorInvocation, redefineArgument, redefineLocal, redundantSpecificationOfTypeArguments, redundantSuperInterface, referenceExpressionArgumentNullityMismatch, referenceExpressionsNotBelow18, referenceMustBeArrayTypeAt, repeatableAnnotationTypeIsDocumented, repeatableAnnotationTypeIsInherited, repeatableAnnotationTypeTargetMismatch, repeatableAnnotationWithRepeatingContainer, repeatedAnnotationWithContainer, reset, resourceHasToImplementAutoCloseable, restrictedTypeName, safeVarargsOnFixedArityMethod, safeVarargsOnNonFinalInstanceMethod, safeVarargsOnOnSyntheticRecordAccessor, scannerError, sealedAnonymousClassCannotExtendSealedType, sealedDisAllowedNonSealedModifierInClass, sealedDisAllowedNonSealedModifierInInterface, sealedDuplicateTypeInPermits, sealedInterfaceIsSealedAndNonSealed, sealedLocalDirectSuperTypeSealed, sealedMissingClassModifier, sealedMissingInterfaceModifier, sealedMissingSealedModifier, sealedNotDirectSuperClass, sealedNotDirectSuperInterface, sealedPermittedTypeOutsideOfModule, sealedPermittedTypeOutsideOfModule, sealedPermittedTypeOutsideOfPackage, sealedSealedTypeMissingPermits, sealedSuperClassDisallowed, sealedSuperClassDoesNotPermit, sealedSuperClassInDifferentPackage, sealedSuperInterfaceDisallowed, sealedSuperInterfaceDoesNotPermit, sealedSuperInterfaceInDifferentPackage, sealedSuperTypeDisallowed, sealedSuperTypeInDifferentPackage, shouldImplementHashcode, shouldReturn, signalError, signalNoImplicitStringConversionForCharArrayExpression, staticFieldAccessToNonStaticVariable, staticInheritedMethodConflicts, staticInterfaceMethodsNotBelow18, staticMemberOfParameterizedType, StrictfpNotRequired, stringConstantIsExceedingUtf8Limit, superclassMustBeAClass, superfluousSemicolon, superinterfaceMustBeAnInterface, superinterfacesCollide, superTypeCannotUseWildcard, swallowedException, switchExpressionBreakNotAllowed, switchExpressionEmptySwitchBlock, switchExpressionIllegalLastStatement, switchExpressionIncompatibleResultExpressions, switchExpressionLastStatementCompletesNormally, switchExpressionMixedCase, switchExpressionNoResultExpressions, switchExpressionsBreakOutOfSwitchExpression, switchExpressionsContinueOutOfSwitchExpression, switchExpressionsNotSupported, switchExpressionsReturnWithinSwitchExpression, switchExpressionSwitchLabeledBlockCompletesNormally, switchExpressionsYieldIllegalStatement, switchExpressionsYieldOutsideSwitchExpression, switchExpressionsYieldRestrictedGeneralWarning, switchExpressionsYieldTypeDeclarationError, switchExpressionsYieldTypeDeclarationWarning, switchExpressionsYieldUnqualifiedMethodError, switchExpressionsYieldUnqualifiedMethodWarning, switchExpressionTrailingSwitchLabels, switchPatternBothNullAndNonTypePatternNotAllowed, switchPatternBothPatternAndDefaultCaseLabelsNotAllowed, switchPatternOnlyOnePatternCaseLabelAllowed, targetTypeIsNotAFunctionalInterface, task, tooManyDimensions, tooManyFields, tooManyMethods, tooManyParametersForSyntheticMethod, typeAnnotationAtQualifiedName, typeCastError, typeCollidesWithEnclosingType, typeCollidesWithPackage, typeHiding, typeHiding, typeHiding, typeMismatchError, typeMismatchError, unclosedCloseable, undefinedAnnotationValue, undefinedLabel, undefinedTypeVariableSignature, undocumentedEmptyBlock, unexpectedStaticModifierForField, unexpectedStaticModifierForMethod, unexpectedTypeinSwitchPattern, unhandledException, unhandledWarningToken, uninitializedBlankFinalField, uninitializedNonNullField, uninternedIdentityComparison, unlikelyArgumentType, unmatchedBracket, unnamedPackageInNamedModule, unnecessaryCast, unnecessaryElse, unnecessaryEnclosingInstanceSpecification, unnecessaryInstanceof, unnecessaryNLSTags, unnecessaryNullCaseInSwitchOverNonNull, unnecessaryTypeArgumentsForMethodInvocation, unqualifiedFieldAccess, unreachableCatchBlock, unreachableCode, unresolvableReference, unsafeCast, unsafeCastInInstanceof, unsafeElementTypeConversion, unsafeGenericArrayForVarargs, unsafeNullnessCast, unsafeRawFieldAssignment, unsafeRawGenericMethodInvocation, unsafeRawInvocation, unsafeReturnTypeOverride, unsafeTypeConversion, unusedDeclaredThrownException, unusedExceptionParameter, unusedImport, unusedLabel, unusedLocalVariable, unusedObjectAllocation, unusedPrivateConstructor, unusedTypeParameter, unusedWarningToken, useAssertAsAnIdentifier, useEnumAsAnIdentifier, validateJavaFeatureSupport, validateRestrictedKeywords, validateRestrictedKeywords, varargsArgumentNeedCast, varargsConflict, varCannotBeMixedWithNonVarParams, variableTypeCannotBeVoid, variableTypeCannotBeVoidArray, varIsNotAllowedHere, varIsReservedTypeName, varIsReservedTypeNameInFuture, varLocalCannotBeArray, varLocalCannotBeArrayInitalizers, varLocalCannotBeLambda, varLocalCannotBeMethodReference, varLocalInitializedToNull, varLocalInitializedToVoid, varLocalMultipleDeclarators, varLocalReferencesItself, varLocalWithoutInitizalier, wildcardAssignment, wildcardInvocation, wrongSequenceOfExceptionTypes, wrongSequenceOfExceptionTypesError
Methods inherited from class org.aspectj.org.eclipse.jdt.internal.compiler.problem.ProblemHandler
createProblem, createProblem, handle, handle, record, resumeTempErrorHandlingPolicy, suspendTempErrorHandlingPolicy, switchErrorHandlingPolicy
-
Field Details
-
factory
-
-
Constructor Details
-
AjProblemReporter
public AjProblemReporter(IErrorHandlingPolicy policy, CompilerOptions options, IProblemFactory problemFactory)
-
-
Method Details
-
unhandledException
- Overrides:
unhandledException
in classProblemReporter
-
unhandledExceptionFromAutoClose
- Overrides:
unhandledExceptionFromAutoClose
in classProblemReporter
-
abstractMethodCannotBeOverridden
- Overrides:
abstractMethodCannotBeOverridden
in classProblemReporter
-
inheritedMethodReducesVisibility
public void inheritedMethodReducesVisibility(SourceTypeBinding type, MethodBinding concreteMethod, MethodBinding[] abstractMethods)- Overrides:
inheritedMethodReducesVisibility
in classProblemReporter
-
staticAndInstanceConflict
- Overrides:
staticAndInstanceConflict
in classProblemReporter
-
abstractMethodMustBeImplemented
- Overrides:
abstractMethodMustBeImplemented
in classProblemReporter
-
disallowedTargetForAnnotation
- Overrides:
disallowedTargetForAnnotation
in classProblemReporter
-
overridesPackageDefaultMethod
public void overridesPackageDefaultMethod(MethodBinding localMethod, MethodBinding inheritedMethod)- Overrides:
overridesPackageDefaultMethod
in classProblemReporter
-
handle
public void handle(int problemId, String[] problemArguments, String[] messageArguments, int severity, int problemStartPosition, int problemEndPosition, ReferenceContext referenceContext, CompilationResult unitResult) -
javadocMissingParamTag
public void javadocMissingParamTag(char[] name, int sourceStart, int sourceEnd, int modifiers)- Overrides:
javadocMissingParamTag
in classProblemReporter
-
abstractMethodInAbstractClass
public void abstractMethodInAbstractClass(SourceTypeBinding type, AbstractMethodDeclaration methodDecl)- Overrides:
abstractMethodInAbstractClass
in classProblemReporter
-
itdMethodMustOverride
Called when there is an ITD marked @override that doesn't override a supertypes method. The method and the binding are passed - some information is useful from each. The 'method' knows about source offsets for the message, the 'binding' has the signature of what the ITD is trying to be in the target class. -
methodMustOverride
Overrides the implementation in ProblemReporter and is ITD aware. To report a *real* problem with an ITD marked @override, the other methodMustOverride() method is used.- Overrides:
methodMustOverride
in classProblemReporter
-
visibilityConflict
- Overrides:
visibilityConflict
in classProblemReporter
-
unusedPrivateType
- Overrides:
unusedPrivateType
in classProblemReporter
-
uninitializedLocalVariable
public void uninitializedLocalVariable(LocalVariableBinding binding, ASTNode location, Scope scope)- Overrides:
uninitializedLocalVariable
in classProblemReporter
-
abstractMethodInConcreteClass
- Overrides:
abstractMethodInConcreteClass
in classProblemReporter
-
unusedPrivateField
- Overrides:
unusedPrivateField
in classProblemReporter
-
unusedPrivateMethod
- Overrides:
unusedPrivateMethod
in classProblemReporter
-
caseExpressionMustBeConstant
- Overrides:
caseExpressionMustBeConstant
in classProblemReporter
-
unusedArgument
- Overrides:
unusedArgument
in classProblemReporter
-
finalMethodCannotBeOverridden
public void finalMethodCannotBeOverridden(MethodBinding currentMethod, MethodBinding inheritedMethod)A side-effect of the way that we handle itds on default methods on top-most implementors of interfaces is that a class acquiring a final default ITD will erroneously report that it can't override its own member. This method detects that situation.- Overrides:
finalMethodCannotBeOverridden
in classProblemReporter
-
duplicateInheritedMethods
public void duplicateInheritedMethods(SourceTypeBinding type, MethodBinding inheritedMethod1, MethodBinding inheritedMethod2, boolean isJava8)The method verifier is a bit 'keen' and doesn't cope well with ITDMs which are of course to be considered a 'default' implementation if the target type doesn't supply one. This test may not be complete - it is possible that it should read if *either* is an ITD...but I dont have a testcase that shows that is required. yet. (pr115788)- Overrides:
duplicateInheritedMethods
in classProblemReporter
-
createProblem
public IProblem createProblem(char[] fileName, int problemId, String[] problemArguments, String[] messageArguments, int severity, int problemStartPosition, int problemEndPosition, int lineNumber)All problems end up routed through here at some point... -
duplicateMethodInType
public void duplicateMethodInType(AbstractMethodDeclaration methodDecl, boolean equalParameters, int severity)- Overrides:
duplicateMethodInType
in classProblemReporter
-
parseErrorInsertAfterToken
public void parseErrorInsertAfterToken(int start, int end, int currentKind, char[] errorTokenSource, String errorTokenName, String expectedToken)- Overrides:
parseErrorInsertAfterToken
in classProblemReporter
-
missingValueForAnnotationMember
- Overrides:
missingValueForAnnotationMember
in classProblemReporter
-