Coder Social home page Coder Social logo

toy-http-application's Introduction

toy-html-application

一个简易的 http 应用开发框架,基于 libhv 封装。

基本概念

框架的设计非常简单,**类似 MVC 模式,将业务代码划分为三个部分,分别是:

  • Controller 控制器,用于实现 HTTP 请求的处理逻辑,这部分需要进行路由配置、请求参数校验和结果返回等代码的编写。
  • Model 模型,用于实现具体的业务逻辑和数据持久化,这部分需要接受控制器传来的参数,对数据库进行相应的操作或请求其他的模型和服务完成复合的操作,然后返回结果给到控制器。
  • Service 服务,用于实现通用的工具服务或业务逻辑,例如缓存服务,数据库连接服务和权限认证服务等。

用法

TODO

使用方法参考 examples 目录。

编译环境和要求

编译器需要支持 C++20 标准。

编译环境需要能够联网,以下载第三方库 libhv。

需要提前安装至少 1.78 版本的 boost。

经过测试的可用环境

系统 架构 编译器
Ubuntu 22.10 x86_64 clang 15.0.7

toy-http-application's People

Contributors

zjlian avatar

Stargazers

winily avatar innoyiya avatar

Watchers

 avatar winily avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.