/ \copydoc Plop::HandlerAbstract::emit().
420963
protected function emit(\Plop\RecordInterface $record)
    {
        if (!file_exists($this->baseFilename)) {
            $stats      = null;
            $changed    = true;
        } else {
            $stats = stat($this->baseFilename);
            $changed = (
                ($stat['dev'] != $this->dev) ||
                ($stat['ino'] != $this->ino)
            );
        }

        if ($changed && $this->stream !== false) {
            if (is_resource($this->stream)) {
                fflush($this->stream);
                fclose($this->stream);
            }
            $this->open();
            if (!$stats) {
                $stats = stat($this->baseFilename);
            }
            $this->dev = $stats['dev'];
            $this->ino = $stats['ino'];
        }
        parent::emit($record);
    }
1002070
public function handle(\Plop\RecordInterface $record)
    {
        $rv = $this->format($record);
        if ($rv) {
            $this->emit($record);
        }
        return $this;
    }
301591
public function emit(string $event, ...$args)
    {
        if ($this->_events[$event] ?? false) {

            foreach ($this->_events[$event] as $handler) {

                $handler(...$args);
            }
        }

        return $this;
    }
805769
function emit(eventName, data, parent) {
    if (!this.__listeners || !this.__listeners[eventName]) {
        return;
    }

    let self = this,
        event = new Event(eventName, data, this, parent);

    this
        .getListeners(eventName)
        .forEach((config) => {
            if (config.once === true) {
                self.off(eventName, config.fn, config.context, config.args, config.once);
            }
            execute(event, config);
        });
}
512715
function emit(string $event, ...$arguments) {
        $errorEmpty = ($event === 'error');
        
        if(!empty($this->listeners[$event])) {
            $errorEmpty = false;
            
            foreach($this->listeners[$event] as $listener) {
                $listener(...$arguments);
            }
        }
        
        if(!empty($this->onceListeners[$event])) {
            $errorEmpty = false;
            
            $listeners = $this->onceListeners[$event];
            unset($this->onceListeners[$event]);
            
            foreach($listeners as $listener) {
                $listener(...$arguments);
            }
        }
        
        if($errorEmpty) {
            throw new \CharlotteDunois\Events\UnhandledErrorException('Unhandled error event', 0, (($arguments[0] ?? null) instanceof \Throwable ? $arguments[0] : null));
        }
    }
1213962
protected function emit(string $chunk): void
    {
        echo $chunk;

        $this->flush(Closure::fromCallable('ob_flush'));
        $this->flush(Closure::fromCallable('flush'));
    }
1268512
def emit(self, record):
        """"""
        try:
            self._callback(self.prepare(record))
        except Exception:
            self.handleError(record)
740942
def emit(self, event, data=None, room=None, skip_sid=None, namespace=None,
             callback=None):
        
        return self.server.emit(event, data=data, room=room, skip_sid=skip_sid,
                                namespace=namespace or self.namespace,
                                callback=callback)
1088483
public function createSubscription($channels, Closure $callback, $method = 'subscribe')
    {
        $loop = $this->pubSubLoop();

        call_user_func_array([$loop, $method], (array) $channels);

        foreach ($loop as $message) {
            if ($message->kind === 'message' || $message->kind === 'pmessage') {
                call_user_func($callback, $message->payload, $message->channel);
            }
        }

        unset($loop);
    }
931263
function emitContext (env, scope, context) {
    var shared = env.shared
    var CONTEXT = shared.context

    var contextEnter = env.scope()

    Object.keys(context).forEach(function (name) {
      scope.save(CONTEXT, '.' + name)
      var defn = context[name]
      contextEnter(CONTEXT, '.', name, '=', defn.append(env, scope), ';')
    })

    scope(contextEnter)
  }
907075
function emit(event /* , args... */) {
  this._events = this._events || {};
  // NOTE: copy array so that removing listeners in listeners (once etc)
  // NOTE: does not affect the iteration
  var list = (this._events[event] || []).slice(0);
  for(var i = 0; i < list.length; i++) {
    list[i].apply(this, Array.prototype.slice.call(arguments, 1))
  }
  return list.length > 0;
}
1333772
function emitLine(line, isEnd) {
  if (this.filters.every(function(fn) { return fn(line) }))
    emit.call(this, 'data', line, !!isEnd);
}
1309440
function emit(name, args, thisArg, delay) {
        var list = eventHandlers[name];
        if ( list ) {
            thisArg || (thisArg = this);
            if ( args ) {
                args = args.slice(); // make a copy
                args.unshift(name);
            }
            else {
                args = [name];
            }
            _.each(list, function (hdl, idx) {
                // var _args = args.slice();
                delay > -1
                    ? setTimeout(function () {
                        hdl.apply(thisArg, args);
                      }, delay)
                    : hdl.apply(thisArg, args)
                ;
            });
        }
        return this;
    }
763268
def emit(self, string, match, pattern, **_):
        """"""
        return grammar.Token(name=pattern.name, value=string,
                             start=match.start(), end=match.end())
1317248
protected function emit(\Plop\RecordInterface $record)
    {
        $msg = $this->format($record);
        $msg = sprintf(
            static::LOG_FORMAT_STRING,
            $this->encodePriority(
                $this->facility,
                $this->mapPriority($record['levelname'])
            ),
            $msg
        );

        for ($written = 0; $written < strlen($msg); $written += $fwrite) {
            $fwrite = @fwrite($this->socket, substr($msg, $written));
            if ($fwrite === false) {
                $this->handleError(
                    $record,
                    new \Plop\Exception('Connection lost')
                );
                break;
            }
        }
    }
1282709
function emit() {
  if (arguments.length) this.emitted.push(arguments);
  while (!this.paused && this.emitted.length && this.readable) {
    var emitArgs = this.emitted.shift();
    this.emit.apply(this, emitArgs);
    if (emitArgs[0] == 'end') {
      this.readable = false;
    }
  }
}
1199283
function emit_destructor_code($out, PHP_ParserGenerator_Symbol $sp, &$lineno)
//    FILE *out;
//    struct symbol *sp;
//    struct lemon *lemp;
//    int *lineno;
    {
        $cp = 0;
        
        $linecnt = 0;
        if ($sp->type == PHP_ParserGenerator_Symbol::TERMINAL) {
            $cp = $this->tokendest;
            if ($cp === 0) {
                return;
            }
            $this->tplt_linedir($out, $this->tokendestln, $this->filename);
            fwrite($out, "{");
        } elseif ($sp->destructor) {
            $cp = $sp->destructor;
            $this->tplt_linedir($out, $sp->destructorln, $this->filename);
            fwrite($out, "{");
        } elseif ($this->vardest) {
            $cp = $this->vardest;
            if ($cp === 0) {
                return;
            }
            $this->tplt_linedir($out, $this->vardestln, $this->filename);
            fwrite($out, "{");
        } else {
            throw new Exception('emit_destructor'); /* Cannot happen */
        }
        for ($i = 0; $i < strlen($cp); $i++) {
            if ($cp[$i]=='$' && $cp[$i + 1]=='$' ) {
                fprintf($out, "(yypminor->yy%d)", $sp->dtnum);
                $i++;
                continue;
            }
            if ($cp[$i] == "\n") {
                $linecnt++;
            }
            fwrite($out, $cp[$i]);
        }
        $lineno += 3 + $linecnt;
        fwrite($out, "}\n");
        $this->tplt_linedir($out, $lineno, $this->outname);
    }