You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
![webserver using libuv](https://cdn-ak-scissors.b.st-hatena.com/image/square/1ef26f6cb4349557952890dbe3e567f7f98dc151/height=288;version=1;width=512/https%3A%2F%2Fgithub.githubassets.com%2Fassets%2Fgist-og-image-54fd7dc0713e.png)
An Introduction to libuv Table of Contents Contents :: Introduction » Table of Contents¶ Introduction Who this book is for Background Code Basics of libuv Event loops Hello World Error handling Handles and Requests Filesystem Reading/Writing files Filesystem operations Buffers and Streams File change events Networking TCP UDP Querying DNS Network interfaces Threads Core thread operations Synchron
C言語の構造体をラップする方法が分からなかった(rubyでいうData_Wrap_Structが見当たらなかった)のでissueに書いたら僕と名前の良く似た方matzさんが音速で入れてくれた。 ただrubyの時の様にalloc_funcが無いのでinitializeでメンバに放り込んでる。 まぁしょうがないか。 #include <mruby.h> #include <mruby/proc.h> #include <mruby/data.h> #include <compile.h> #include <variable.h> #include <uv.h> typedef struct { mrb_state* mrb; mrb_value proc; void* data; } mrb_uv_data; static void uv_handle_free(mrb_state *mrb
気分転換プロジェクトとして、libuvのPerlバインディングを書いている。 typester/p5-UV - GitHub 現状、timerとtcp周りを一通り実装したところ。 実装は愚直にlibuvの関数とperlの関数を1:1に(uv_tcp_init(...)をUV::tcp_init(...)というような形で)マッピングしている。 この実装はlow level APIと位置づけ、その上に使いやすい高レベルなインタフェースをPerl上で用意したいつもり。 このlow level APIをつかったTCP echo serverはこんな感じになる: use strict; use warnings; use UV; my $server = UV::tcp_init(); UV::tcp_bind($server, '0.0.0.0', 3000) && die 'bind error
VLCってたしかYouTube動画の再生に対応してたよなーと思いだして試してみたけど、 現在の最新バージョンの2.0.5でも今のYouTubeの仕様に対応できてないのか、YouTube動画の URL を開こうとしてもエラーになってしまう。 ためしにナイトリービルドでためしてみたらOKだった。 けど、ナイトリービルドを常用するのも嫌だ。しかし、このYouTubeのハンドリングはどうもluaの拡張でやっているだけみたいなので、 その拡張ファイルだけバックポートするだけでいけそうだということで、やってみたらちゃんと動いた。 具体的には、 VLC.app/Contents/MacOS/share/lua/playlist/youtube.luacVLC.app/Contents/MacOS/share/lua/playlist/youtube_homepage.luac の2ファイルを上書きしてあ
node.jsのスライドを見てて、プラットフォームの違いを吸収するnode.jsの核でもある非同期通信ライブラリuvを今日知ったので試してみた。 joyent/libuv - GitHub platform layer for node.js https://github.com/joyent/libuv libev/libeventをwindowsでもちゃんと使いたいという所から出てきたライブラリ。 #include <iostream> #include <uv/uv.h> int main() { int r; uv_tcp_t tcp; struct sockaddr_in server_addr; server_addr = uv_ip4_addr("127.0.0.1", 80); r = uv_tcp_init(uv_default_loop(), &tcp); uv_con
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く