Skip to content

kevinveld2001/JXpress

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JXpress

JXpress is a java based http web server build from scratch. It makes use of the built-in java ServerSocket to communicate with the browser. The request will be parsed to a request object. It will be passed into the callback that is defined for that route. The response returned using the response callback will be sent to the browser.

Getting started

Below is a small example to get you started. In the example folder are more examples that show more features.

App app = new App();

app.addRoute(Method.GET, "/", req -> new Response().setHTML("Hallo World"));

app.listen(80);

Features

  • Routing

  • Header parsing

  • Params parsing

  • XForm parsing

  • Getting raw request body

  • JSON parsing

  • Global & local middleware

  • Text response

  • HTML response

  • JSON stringify response

  • Response Status codes

  • Response headers

Unit tests

Junit is used to make unit test. Most features have unit tests. If you like to contribute to this project and make code changes make sure to run the unit test before making a PR. Unit tests can be found in the test folder.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages