Writing an Emcast Handler by David Helder Copyright (C) 2001 Regents of the University of Michigan ============================================================ libemcast internals ------------------- When libemcast is told to join or create a URL in the form of ":something", it launches the program -emcast and communicates with it using stdin and stdout as specified below. The program must be in the user's path. The launched program is called the "handler". Handler programs may optionally use emcast-protocol.h, part of libemcast, which provides an event loop that parses the protocol and calls callbacks provided by the programmer. Writing a handler in C ---------------------- Either parse the protocol yourself (see emcast-protocol.txt) or use the functions in emcast-protocol.h. The later option requires writing callbacks for some or all of the messages. See star/star-emcast.c for an example. Writing a handler in Perl ------------------------- Use Emcast::Handler in the perl directory. See irc/irc-emcast for an example. Create versus join ------------------ DISCUSS.