nerdexam
Broadcom-VMware

2V0-72.22PSE · Question #71

Refer to the exhibit. How can a Spring Bean be created from this LegacySingleton class?

Sign in or unlock 2V0-72.22PSE to reveal the answer and full explanation for question #71. The question stem and answer options stay visible for context.

Core Spring

Question

Refer to the exhibit. How can a Spring Bean be created from this LegacySingleton class?

Exhibit

2V0-72.22PSE question #71 exhibit

Options

  • ACall LegacySingleton.getInstance() from within a @Bean method and return the instance.
  • BReturn an instance of LegacySingleton using the new keyword from a @Bean method.
  • CIt is not possible without modifying the LegacySingleton class, the constructor must be public.
  • DModify the LegacySingleton class by adding the @Autowired annotation to the instance variable.

Unlock 2V0-72.22PSE to see the answer

You've previewed enough free 2V0-72.22PSE questions. Unlock 2V0-72.22PSE for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.

Topics

#Bean Creation#@Bean Methods#Factory Pattern#Legacy Integration
Full 2V0-72.22PSE Practice