并行的RPC框架 Yar
- 授权协议: PHP license
- 开发语言: C/C++ PHP
- 操作系统: 跨平台
- 软件首页: https://github.com/laruence/yar
- 软件文档: http://www.laruence.com/2012/09/15/2779.html
软件介绍
Yar 是一个支持多种打包协议的, 并行的RPC框架.
它基于HTTP协议, 在libcurl基础上开发而成
简单的Server:
- class API {
- /**
- * the doc info will be generated automatically into service info page.
- * @params
- * @return
- */
- public function api($parameter, $option = "foo") {
- }
- protected function client_can_not_see() {
- }
- }
- $service = new Yar_Server(new API());
- $service->handle();
- ?>
简单调用:
- $client = new Yar_Client("http://host/api/");
- $result = $client->api("parameter);
- ?>
并行调用:
- function callback($retval, $callinfo) {
- var_dump($retval);
- }
- Yar_Concurrent_Client::call("http://host/api/", "api", array("parameters"), "callback");
- Yar_Concurrent_Client::call("http://host/api/", "api", array("parameters"), "callback");
- Yar_Concurrent_Client::call("http://host/api/", "api", array("parameters"), "callback");
- Yar_Concurrent_Client::call("http://host/api/", "api", array("parameters"), "callback");
- Yar_Concurrent_Client::loop(); //send
- ?>
更多信息参看: Yar at Github
Ruby语言入门
Yugui / 丁明、吕嘉 / 东南大学出版社 / 2010 年4月 / 32.00元
《Ruby 语言入门(中文版)》为具有一定其他语言的编程经验的读者介绍Ruby的特征、Ruby中的编程方法和编程习惯。这些内容都是为了让读者能够边阅读Ruby的资料边进行实践性的学习所必须具备的基础知识。《Ruby 语言入门(中文版)》对Ruby的基础部分和元类、块语句这样独特的概念,以及由此产生的特有的文化进行了说明,以使读者能够了解到Ruby独特的思考方式。读完《Ruby 语言入门(中文版)》......一起来看看 《Ruby语言入门》 这本书的介绍吧!
