GithubHelp home page GithubHelp logo

brzuchal / event-loop Goto Github PK

View Code? Open in Web Editor NEW

This project forked from async-interop/event-loop

0.0 3.0 0.0 120 KB

An event loop interface for interoperability in PHP.

License: MIT License

PHP 100.00%

event-loop's Introduction

Event Loop Interopability

The purpose of this specification is to provide a common interface for event loop implementations. This allows libraries and components from different vendors to operate in an event driven architecture, sharing a common event loop.

Why Bother?

Some programming languages, such as Javascript, have an event loop that is native to the execution environment. This allows package vendors to easily create asynchronous software that uses this native event loop. Although PHP is historically a synchronous programming environment, it is still possible to use asynchronous programming techniques. Using these techniques, package vendors have created event loop implementations that have seen success.

However, as these event loop implementations are from package vendors, it is not yet possible to create event driven software components that are independent of the underlying event loop implementation. By creating a common interface for an event loop, interoperability of this nature will be possible.

Goals

The functionality exposed by this interface should include the ability to:

  • Watch input streams for available data
  • Watch output streams for the ability to perform non-blocking write operations
  • Run single and periodic timers
  • Listen for signals
  • Defer the execution of callables

Implementations

You can find available implementations on Packagist.

Compatible Packages

You can find compatible packages on Packagist.

Contributors

event-loop's People

Contributors

kelunik avatar bwoebi avatar andrewcarteruk avatar trowski avatar wyrihaximus avatar joshdifabio avatar joelwurtz avatar

Watchers

James Cloos avatar Michał Marcin Brzuchalski avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.