Exam4Training

When injecting scalar/literal values into Spring beans, which of the following statements is true? (select one)

When injecting scalar/literal values into Spring beans, which of the following statements is true? (select one)
A . Scalar values cannot be injected into setters or constructors with primitive type parameters
B . Spring performs automatic type conversion for certain data types, such as String to int
C . In XML Spring configuration, you can inject scalar values using the ref attribute of the <property /> tag
D . All of the above

Answer: B

Exit mobile version