001// Copyright 2009 by Basil Vandegriend. All rights reserved. 002 003package com.basilv.examples.spring.explicit; 004 005import org.springframework.config.java.annotation.*; 006 007import com.basilv.examples.spring.*; 008 009@Configuration 010public class ExplicitConfig 011{ 012 @Bean 013 public ResumeRepository resumeRepository() { 014 return new HardcodedResumeRepository(); 015 } 016 017 @Bean 018 public CalculatorService calculatorService() { 019 return new CalculatorServiceImpl( 020 resumeRepository()); // Inject dependency 021 } 022}