Download the PHP package vanthink/hprose-swoole-fork without Composer
On this page you can find all versions of the php package vanthink/hprose-swoole-fork. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download vanthink/hprose-swoole-fork
More information about vanthink/hprose-swoole-fork
Files in vanthink/hprose-swoole-fork
Package hprose-swoole-fork
Short Description Hprose asynchronous client & standalone server based on swoole
License MIT
Homepage http://vanthink.com/
Informations about the package hprose-swoole-fork
Hprose for Swoole
Introduction
Hprose is a High Performance Remote Object Service Engine.
It is a modern, lightweight, cross-language, cross-platform, object-oriented, high performance, remote dynamic communication middleware. It is not only easy to use, but powerful. You just need a little time to learn, then you can use it to easily construct cross language cross platform distributed application system.
Hprose supports many programming languages, for example:
- AAuto Quicker
- ActionScript
- ASP
- C++
- Dart
- Delphi/Free Pascal
- dotNET(C#, Visual Basic...)
- Golang
- Java
- JavaScript
- Node.js
- Objective-C
- Perl
- PHP
- Python
- Ruby
- ...
Through Hprose, You can conveniently and efficiently intercommunicate between those programming languages.
This project is the implementation of Hprose for PHP based on swoole.
More Documents for Hprose 2.0: https://github.com/hprose/hprose-php/wiki
Installation
Download Source Code
install by composer
Usage
You need to install swoole first. The minimum version of swoole been supported is 1.8.8.
You also need to install hprose-pecl 1.6.5+.
Server
Hprose for PHP is very easy to use.
You can create a standalone hprose http server like this:
http_server.php
tcp_server.php
unix_server.php
websocket_server.php
The websocket server is also a http server.
Client
Then you can create a hprose client to invoke it like this:
http_client.php
tcp_client.php
The result of invoking is a promise object, you can also specify the callback function after the arguments, the callback function supports 0 - 3 parameters:
params | comments |
---|---|
result | The result is the server returned, if no result, its value is null. |
arguments | It is an array of arguments. if no argument, it is an empty array. |
error | It is an object of Exception, if no error, its value is null. |
All versions of hprose-swoole-fork with dependencies
vanthink/hprose-php-fork Version >2.0.35
ext-swoole Version >=1.8.8
ext-hprose Version >=1.6.5