I'm trying to copy the "server example" from http://live.gnome.org/Vala/GIONetworkingSample.
But when I try to compile, I have the following error :
./src/server/Anais.vala:51.4-51.34: error: 2 missing arguments for `ssize_t GLib.OutputStream.write (void* buffer, size_t count, GLib.Cancellable? cancellable = null)'
output.write( header.str.data );
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
./src/server/Anais.vala:52.4-52.31: error: 2 missing arguments for `ssize_t GLib.OutputStream.write (void* buffer, size_t count, GLib.Cancellable? cancellable = null)'
output.write( content.data );
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Compilation failed: 2 error(s), 0 warning(s)
make: *** [build-server] Erreur 1
I tryed to understand, what the error message means. So I looked at the documentation : http://www.valadoc.org/references/gio-2.0/0.11.5/GLib.OutputStream.write.html
But as I'm not used to use glib and/or any library for client/server, I don't understand what I should do.
Could someone say to me how to use the OutputStream with Vala ?
NB : For information, I'm using valac 0.10.0