NAME
IO::Mux::HTTP - HTTP protocol on IO::Mux
INHERITANCE
IO::Mux::HTTP
is a IO::Mux::Net::TCP
is a IO::Mux::Handler::Read
is a IO::Mux::Handler
IO::Mux::Net::TCP also extends IO::Mux::Handler::Write
is a IO::Mux::Handler::Write
is a IO::Mux::Handler
IO::Mux::HTTP is extended by
IO::Mux::HTTP::Client
IO::Mux::HTTP::Service
SYNOPSIS
# base-class for IO::Mux::HTTP::Service or Client
METHODS
Constructors
- IO::Mux::HTTP->new(OPTIONS)
-
-Option --Defined in --Default add_headers [] fh IO::Mux::Handler <required> name IO::Mux::Handler 'tcp $host:$port' read_size IO::Mux::Handler::Read 32768 socket IO::Mux::Net::TCP <required> write_size IO::Mux::Handler::Write 4096
- IO::Mux::HTTP->open(MODE, WHAT, OPTIONS) See "Constructors" in IO::Mux::Handler
- IO::Mux::HTTP->open(MODE, WHAT, OPTIONS) See "Constructors" in IO::Mux::Handler
Accessors
- $obj->fh See "Accessors" in IO::Mux::Handler
- $obj->fh See "Accessors" in IO::Mux::Handler
- $obj->fileno See "Accessors" in IO::Mux::Handler
- $obj->fileno See "Accessors" in IO::Mux::Handler
- $obj->mux See "Accessors" in IO::Mux::Handler
- $obj->mux See "Accessors" in IO::Mux::Handler
- $obj->name See "Accessors" in IO::Mux::Handler
- $obj->name See "Accessors" in IO::Mux::Handler
- $obj->readSize([INTEGER]) See "Accessors" in IO::Mux::Handler::Read
- $obj->socket See "Accessors" in IO::Mux::Net::TCP
- $obj->startTime
-
Returns a HASH with some basic information about the client, not the socket itself.
- $obj->usesSSL See "Accessors" in IO::Mux::Handler
- $obj->usesSSL See "Accessors" in IO::Mux::Handler
- $obj->writeSize([INTEGER]) See "Accessors" in IO::Mux::Handler::Write
User interface
Connection
- $obj->close([CALLBACK]) See "Connection" in IO::Mux::Handler
- $obj->close([CALLBACK]) See "Connection" in IO::Mux::Handler
- $obj->shutdown((0|1|2)) See "Connection" in IO::Mux::Net::TCP
- $obj->timeout([TIMEOUT]) See "Connection" in IO::Mux::Handler
- $obj->timeout([TIMEOUT]) See "Connection" in IO::Mux::Handler
Reading
- $obj->readline(CALLBACK) See "Reading" in IO::Mux::Handler::Read
- $obj->slurp(CALLBACK) See "Reading" in IO::Mux::Handler::Read
Writing
- $obj->print(STRING|SCALAR|LIST|ARRAY) See "Writing" in IO::Mux::Handler::Write
- $obj->printf(FORMAT, PARAMS) See "Writing" in IO::Mux::Handler::Write
- $obj->say(STRING|SCALAR|LIST|ARRAY) See "Writing" in IO::Mux::Handler::Write
- $obj->write(SCALAR, [MORE]) See "Writing" in IO::Mux::Handler::Write
Multiplexer
Connection
- $obj->mux_init(MUX, [HANDLER]) See "Connection" in IO::Mux::Handler
- $obj->mux_init(MUX, [HANDLER]) See "Connection" in IO::Mux::Handler
- $obj->mux_remove See "Connection" in IO::Mux::Handler
- $obj->mux_remove See "Connection" in IO::Mux::Handler
- $obj->mux_timeout See "Connection" in IO::Mux::Handler
- $obj->mux_timeout See "Connection" in IO::Mux::Handler
Reading
- $obj->mux_eof See "Multiplexer" in IO::Mux::Net::TCP
- $obj->mux_except_flagged(FILENO) See "Reading" in IO::Mux::Handler
- $obj->mux_except_flagged(FILENO) See "Reading" in IO::Mux::Handler
- $obj->mux_input(BUFFER) See "Reading" in IO::Mux::Handler::Read
- $obj->mux_read_flagged(FILENO) See "Reading" in IO::Mux::Handler
- $obj->mux_read_flagged(FILENO) See "Reading" in IO::Mux::Handler
Writing
- $obj->mux_outbuffer_empty See "Writing" in IO::Mux::Handler::Write
- $obj->mux_output_waiting See "Writing" in IO::Mux::Handler::Write
- $obj->mux_write_flagged(FILENO) See "Writing" in IO::Mux::Handler
- $obj->mux_write_flagged(FILENO) See "Writing" in IO::Mux::Handler
Service
Helpers
- $obj->extractSocket(HASH)
- IO::Mux::HTTP->extractSocket(HASH) See "Helpers" in IO::Mux::Handler
- $obj->extractSocket(HASH)
- IO::Mux::HTTP->extractSocket(HASH) See "Helpers" in IO::Mux::Handler
- $obj->fdset(STATE, READ, WRITE, ERROR) See "Helpers" in IO::Mux::Handler
- $obj->fdset(STATE, READ, WRITE, ERROR) See "Helpers" in IO::Mux::Handler
- $obj->show See "Helpers" in IO::Mux::Handler
- $obj->show See "Helpers" in IO::Mux::Handler
HTTP protocol
- $obj->closeConnection
- $obj->sendMessage(MESSAGE, CALLBACK)
-
Used by
sendRequest()
(client) andsendResponse()
(server) to send a MESSAGE. When the message has arrived, the CALLBACK will we called.
SEE ALSO
This module is part of IO-Mux-HTTP distribution version 0.10, built on January 26, 2011. Website: http://perl.overmeer.net/ All modules in this suite: "Any::Daemon", "IO::Mux", and "IO::Mux::HTTP".
Please post questions or ideas to perl@overmeer.net
LICENSE
Copyrights 2011 by Mark Overmeer. For other contributors see ChangeLog.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See http://www.perl.com/perl/misc/Artistic.html