Home
Recent Q&A
Java
Cloud
JavaScript
Python
SQL
PHP
HTML
C++
Data Science
DBMS
Devops
Hadoop
Machine Learning
Azure
Blockchain
Devops
Ask a Question
Which of the following is true when using @Autowired on a setter method?
Home
Spring
Which of the following is true when using @Autowired on a setter method?
0
votes
asked
Nov 14
in
Spring
by
rajeshsharma
Which of the following is true when using @Autowired on a setter method?
a) The setter method becomes optional
b) The related property can't be injected using XML
c) The setter method can have any name
d) The setter method can have multiple parameters
autowired
Please
log in
or
register
to answer this question.
1
Answer
0
votes
answered
Nov 14
by
rajeshsharma
c) The setter method can have any name
Explanation:
While traditionally, setter methods follow the setPropertyName pattern, when using @Autowired, the method name does not have to follow this convention.
...