Last active
April 15, 2018 12:43
-
-
Save Ozsie/4e1762ba8cc27f76689ae070c2cb29e0 to your computer and use it in GitHub Desktop.
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
package com.github.ozsie.webfluxtest | |
import com.github.ozsie.webfluxtest.handlers.ItemHandler | |
import com.github.ozsie.webfluxtest.routers.router | |
import org.springframework.context.ApplicationContextInitializer | |
import org.springframework.context.support.GenericApplicationContext | |
import org.springframework.context.support.beans | |
// See application.properties context.initializer.classes entry | |
class Beans : ApplicationContextInitializer<GenericApplicationContext> { | |
override fun initialize(context: GenericApplicationContext) = beans { | |
bean { ItemHandler(ref()) } | |
bean { router(ref()) } | |
bean { init(ref()) } | |
}.initialize(context) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment