I have a class that takes a java.time.Clock object as a constructor argument. I am having problems defining this as a bean in the applicationContext.xml file:
TimeTracker.java
public class TimeTracker{ public final Clock clock; public TimeTracker(Clock clock){ this.clock = clock; } applicationContext.xml
<bean id="timeTracker" class="com.tracker.TimeTracker"> <constructor-arg type="java.time.Clock" value=""/> </bean> The error I am having is: Ambiguous constructor argument types - did you specify the correct bean references as constructor arguments?