https://github.com/ganzerli/backend_framework
a backend framework in C inspired from modern frameworks
https://github.com/ganzerli/backend_framework
Last synced: 10 months ago
JSON representation
a backend framework in C inspired from modern frameworks
- Host: GitHub
- URL: https://github.com/ganzerli/backend_framework
- Owner: ganzerli
- Created: 2023-10-15T19:48:37.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-11-27T22:28:15.000Z (about 1 year ago)
- Last Synced: 2025-01-17T13:28:49.298Z (12 months ago)
- Language: C
- Size: 330 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# backend_framework
After that you received the request in your C socket server,
count = recv( descriptor , buffer , size , 0);
just call the function backend_framework(); will return the size of the response and fill the buffer with the response.
size = backend_framework( buffer , count );
In backend_framework.c -> get("route" , controller) , post("/",ctrl) you can define wich routes your server has, and which controller to call, like the modern frameworks.
In controllers you can send pictures(binary), html files(text), add response headers, and get the request body, like the modern frameworks.
(request and response are global and have the buffer than tecnically you can always all)
But like this is like modern frameworks. in few Kilobytes