Fix sample code in WebFlux chapter

This commit is contained in:
Kazuki Shimizu 2017-05-08 00:52:22 +09:00 committed by Rossen Stoyanchev
parent 94618c4f37
commit 1412c2c577
1 changed files with 2 additions and 1 deletions

View File

@ -327,9 +327,10 @@ For the **functional programming model** bootstrap as follows:
[source,java,indent=0]
[subs="verbatim,quotes"]
----
ApplicationContext context = new AnnotationConfigApplicationContext(); // (1)
AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(); // (1)
context.registerBean(FooBean.class, () -> new FooBeanImpl()); // (2)
context.registerBean(BarBean.class); // (3)
context.refresh();
HttpHandler handler = WebHttpHandlerBuilder
.webHandler(RouterFunctions.toHttpHandler(...))