Skip to content
Sharp

Reflection API · interview question

Which of the following best describes the use of an Annotation Processor in Java?

Multiple choiceHardchapter-16-curatedpremiumreflection-apidynamic-class-loading
Choose one answer
Answer and explanation

Correct answer

C. It processes annotations at compile-time to generate additional source files or resources.

Why

An Annotation Processor examines and processes annotations at compile-time, often generating additional source code or resources based on the metadata provided by the annotations.

Test yourself on Reflection API

A free test with instant, explained results. No account needed.

Start free test
All Reflection API questions →