Last active
July 27, 2019 22:03
-
-
Save beyondxscratch/c3342ffd5dc5b3fee3f1beda87ec7638 to your computer and use it in GitHub Desktop.
Example of a boilerplate bean factory
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Configuration | |
public class DomainConfiguration { | |
@Bean | |
public RetrieveSanitaryGrades retrieveSanitaryGrades() { | |
return new RetrieveSanitaryGrades(); | |
} | |
@Bean | |
public SearchRestaurants restaurantsFinder(Restaurants restaurants, | |
OpeningHours openingHours, | |
RetrieveSanitaryGrades retrieveSanitaryGrades) { | |
return new RestaurantsFinder(restaurants, openingHours, retrieveSanitaryGrades); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment