Introduced:
It is an open source (Apache License) mini-web framework in Java with minimal dependencies and a fast learning curve.
The goal of the project is to create an easy-to-use and cracked mini-web framework in Java.
Get the project source code, project explanation, knowledge sharing, learning communication, then join the small series of Java Learning Exchange Group it!
616 959 444
The code is as follows:
Route method
First, we have to create an application and add some routes:
Where to contact is a simple pojo:
The second step is to choose your favorite server, template engine and content type engine.
For example, I will select
Jetty as a template engine for server Freemarker, Jackson as a JSON engine and jaxbxml engine. My maven pom.xml looks like this:
The final step is to start Pippo with your application as a parameter:
Pippo starts the embedded Web server (located in your classpath) and makes the application available for Port 8338 (the default).
Controller method
Define the controller:
To add a controller to your application:
Don't forget this.
Get the project source code, project explanation, knowledge sharing, learning communication, then join the small series of Java Learning Exchange Group it!
616 959 444
Of course, not to forget this
Controller
The concept is included in the Pippo-controller module, so you must add this module to your project as a dependency.
God-class Java programmer to teach you basic development, the simplest Micro Java web framework