c-websocket-server

所属分类:Websocket编程
开发工具:C++
文件大小:0KB
下载次数:2
上传日期:2022-03-18 14:18:24
上 传 者sh-1993
说明:  c-websocket-服务器,,
(c-websocket-server,,)

文件列表:
core/ (0, 2022-03-18)
core/example_websocket.cpp (1879, 2022-03-18)
core/websocket_client.cpp (2795, 2022-03-18)
test/ (0, 2022-03-18)
test/test_thread (34720, 2022-03-18)
test/test_thread.cpp (448, 2022-03-18)

# Simple C++ Websocket Server > This github repository documents my education of websocket programming with C++ This repository documents my journey with socket programming. ## Installation OS X & Linux: ```sh git clone git@github.com:d3vk1tty/c-websocket-server.git ```

(back to top)

## Usage example This can be used to establish a connection and exchange information through TCP using the boost library. Compile and execute [example_websocket.cpp](https://github.com/d3vk1tty/c-websocket-server/blob/main/example_websocket.cpp) ```sh > g++ -I /usr/include/boost/ -pthread example_websocket.cpp -o websocket > g++ -I /usr/include/boost/ -pthread websocket_client.cpp -o websocket_client > ./websocket > ./websocket_client 127.0.0.1 8085 "client message" socket accepted #connection opened client message #server echo client message Operation canceled #connection closed ```

(back to top)

## Roadmap - [ ] Implement [example_websocket.cpp](https://github.com/d3vk1tty/c-websocket-server/blob/main/example_websocket.cpp) and [websocket_client.cpp](https://github.com/d3vk1tty/c-websocket-server/blob/main/websocket_client.cpp) into a lightweight reusable class - [x] Add back to top links See the [open issues](https://github.com/othneildrew/Best-README-Template/issues) for a full list of proposed features (and known issues).

(back to top)

## Development setup Describe how to install all development dependencies and how to run an automated test-suite of some kind. Potentially do this for multiple platforms. ```sh sudo apt install libboost-all-dev ``` For convenience use the plugin Simple Websocket Client for [Chrome](https://chrome.google.com/webstore/detail/simple-websocket-client/pfdhoblngboilpfeibdedpjgfnlcodoo) or [Firefox](https://addons.mozilla.org/en-US/firefox/addon/simple-websocket-client/)

(back to top)

## Release History * 0.0.1 * Work in progress

(back to top)

## Meta Dev Kitty :3 – [@d3vk1tty](https://twitter.com/d3vk1tty) – admin@devkitty.org Distributed under the MIT license. See ``LICENSE`` for more information. [https://github.com/d3vk1tty/c-websocket-server](https://github.com/d3vk1tty/)

(back to top)

## Contributing 1. Fork it () 2. Create your feature branch (`git checkout -b feature/fooBar`) 3. Commit your changes (`git commit -am 'Add some fooBar'`) 4. Push to the branch (`git push origin feature/fooBar`) 5. Create a new Pull Request

(back to top)


近期下载者

相关文件


收藏者