ExamGecko
Question list
Search
Search

Question 46 - 2V0-72.22 discussion

Report
Export

Which statement describes the @AfterReturning advice type? (Choose the best answer.)

A.
The advice is invoked only if the method returns successfully but not if it throws an exception.
Answers
A.
The advice is invoked only if the method returns successfully but not if it throws an exception.
B.
The @AfterReturning advice allows behavior to be added after a method returns even if it throws an exception.
Answers
B.
The @AfterReturning advice allows behavior to be added after a method returns even if it throws an exception.
C.
The advice has complete control over the method invocation; it could even prevent the method from being called at all.
Answers
C.
The advice has complete control over the method invocation; it could even prevent the method from being called at all.
D.
Typically used to prevent any exception, thrown by the advised method, from propagating up the call-stack.
Answers
D.
Typically used to prevent any exception, thrown by the advised method, from propagating up the call-stack.
Suggested answer: A

Explanation:

Reference: https://www.amitph.com/spring-aop-afterreturning-advice

asked 16/09/2024
Knowledge Mathebula
35 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first