How to embed java.util.properties in spring bean?



How to embed java.util.properties in spring bean?..

Answer / Kapil Agari

You can embed a java.util.Properties object in a Spring bean by defining the Properties object as a field in your bean class, and annotating that field with @Value or @PropertySource.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Spring Framework Interview Questions

What is spring api?

1 Answers  


Differentiate between singleton and prototype bean?

1 Answers  


What is webapplicationcontext?

1 Answers  


Does spring boot require tomcat? : Spring Boot

1 Answers  


What is spring?

1 Answers  


What is proxy in spring aop?

1 Answers  


What is the use of @service annotation in spring?

1 Answers  


What is servlet initializer in spring boot? : Spring Boot

1 Answers  


What are the annotation used in spring?

1 Answers  


Discuss the benefit of spring framework?

1 Answers  


What are different ways to achieve spring ioc?

1 Answers  


What is aop in spring with example?

1 Answers  


Categories