Learn Java for Web Development

(Tina Meador) #1

370 CHAPTER 8: Play with Java and Scala


You can go through the code on your own and improve the application.


Helloworld Scala Application with Play 2

As mentioned earlier, Play 2 allows you to create both Java- and Scala-based web applications. The
procedure for generating a Scala-based application is the same as generating the Java application.
You can create a helloworld-scala application as illustrated in Figure 8-18.


Figure 8-18. Creating the helloworld-scala application


Figure 8-17. Running the sample helloworld application

Free download pdf