Download the PHP package jeffreyroberts/phergie-irc-client-react without Composer

On this page you can find all versions of the php package jeffreyroberts/phergie-irc-client-react. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package phergie-irc-client-react

phergie/phergie-irc-client-react

A bare-bones PHP-based IRC client library built on React.

Build Status Coverage Status Code Climate

Install

The recommended method of installation is through composer.

Design goals

Usage

This example makes the bot greet other users as they join any of the channels in which the bot is present.

  1. Create and configure an instance of the connection class, \Phergie\Irc\Connection, for each server the bot will connect to. See phergie-irc-connection documentation for more information on configuring connection objects.
  2. Create an instance of the client class, \Phergie\Irc\Client\React\Client.
  3. Call the client object's on() method any number of times, each time specifying an event to monitor and a callback that will be executed whenever that event is received from the server.
  4. Call the client object's run() method with a connection object or array of multiple connection objects created in step #1.

Client Events

Below are the events supported by the client. Its on() method can be used to add callbacks for them.

connect.before.all

Emitted before any connections are established.

Parameters

Example

connect.after.all

Emitted after all connections are established.

Parameters

Note that if a connection attempt failed, the value in $writes for that connection will be null.

Example

connect.before.each

Emitted before each connection is established.

Parameters

Example

connect.after.each

Emitted after each connection is established.

One potentially useful application of this is to institute a delay between connections in cases where the client is attempting to establish multiple connections to the same server and that server throttles connection attempts by origin to prevent abuse, DDoS attacks, etc.

Parameters

Note that if the connection attempt failed, $write will be null.

Example

connect.error

Emitted when an error is encountered on a connection.

Parameters

Example

connect.end

Emitted when a connection is terminated.

This can be useful for re-establishing a connection if it is unexpectedly terminated.

Parameters

Example

irc.received

Emitted when an IRC event is received from the server.

Parameters

Example

irc.sent

Emitted when an IRC event is sent by the client to the server.

Parameters

Example

irc.tick

Emitted periodically on each connection to allow events to be sent asynchronously versus in response to received or sent events. The interval between invocations is specified in seconds and set using the client's setTickInterval() method.

Parameters

Example

Timers

In some cases, it's desirable to execute a callback on a specified interval rather than in response to a specific event.

One-Time Callbacks

To add one-time callbacks that execute after a specified amount of time (in seconds):

The above example will execute the specified callback at least 5 seconds after it's added.

Recurring Callbacks

To add recurring callbacks that execute on a specified interval (in seconds):

The above example will execute the specified callback at least every 5 seconds after it's added.

Connection Options

force-ip4

Connection sockets will use IPv6 by default where available. If you need to force usage of IPv4, set this option to true.

allow-self-signed

By default all ssl connections only accept officially signed certificates. Sometimes you need to connect to a irc server that uses a self signed certificate. If you need to allow connections to servers using a self signed certificate, set this option to true.

transport

By default, a standard TCP socket is used. For IRC servers that support TLS or SSL, specify an appropriate transport.

Tests

To run the unit test suite:

License

Released under the BSD License. See LICENSE.

Community

Check out #phergie on irc.freenode.net.


All versions of phergie-irc-client-react with dependencies

PHP Build Version
Package Version
Requires php Version >=5.5
phergie/phergie-irc-parser Version ~2.0
phergie/phergie-irc-generator Version ~1.5
phergie/phergie-irc-connection Version ~2.0
react/event-loop Version ^1.0 || ^0.5
react/stream Version ^1.0 || ^0.7 || ^0.6 || ^0.5 || ^0.4
react/socket Version ^1.0 || ^0.8 || ^0.7
react/dns Version ~0.4.0
react/promise Version ~2.0
psr/log Version ~1.0
monolog/monolog Version ~1.6
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package jeffreyroberts/phergie-irc-client-react contains the following files

Loading the files please wait ....