emit to database
765513
def emit(self, message):
        
        # handle vaping data that arrives in a list
        if isinstance(message.get("data"), list):
            for row in message.get("data"):


                # format filename from data
                filename = self.format_filename(message, row)

                # create database file if it does not exist yet
                if not os.path.exists(filename):
                    self.create(filename)

                # update database
                self.log.debug("storing time:%d, %s:%.5f in %s" % (
                    message.get("ts"), self.field, row.get(self.field), filename))
                self.update(filename, message.get("ts"), row.get(self.field))
763268
def emit(self, string, match, pattern, **_):
        """"""
        return grammar.Token(name=pattern.name, value=string,
                             start=match.start(), end=match.end())
1097988
def emit(event, *data)
      sync_exclusive do
        [event.type].each do |hook_type|
          any_state_or_event = HookEvent.any_state_or_event(hook_type)
          [any_state_or_event, event.name].each do |event_name|
            hooks[hook_type][event_name].each do |hook|
              handle_callback(hook, event, *data)
              off(hook_type, event_name, &hook) if hook.is_a?(Once)
            end
          end
        end
      end
    end
782261
function emit (msg, done) {
    var raw_data = [
      {source: 'demo-plugin', payload: {val: 1, tag: 'foo'}},
      {val: 2, tag: 'foo'}
    ]

    done(null, raw_data)
  }
1031925
def emit(self, record):
        """"""
        if self.triggerLevelNo is not None and record.levelno>=self.triggerLevelNo:
            self.triggered = True
        logging.handlers.BufferingHandler.emit(self,record)
401385
def emit(self):
        """"""

        self.count += 1

        # event_name = 'on_{0}'.format(self.context.subcategory.lower())
        event_name = self.context.subcategory
        if hasattr(self.handler, event_name):
            getattr(self.handler, event_name)(self.context)
        elif hasattr(self.handler, 'default'):
            self.handler.default(self.context)
931211
def emit(self, rule='pass', stage=None, data={}, delay=None,
             optional=False):
        """"""
        if stage is None:
            stage = self.stage.handlers.get(rule)
        if optional and stage is None:
            return
        if stage is None or stage not in self.crawler.stages:
            self.log.info("No next stage: %s (%s)" % (stage, rule))
            return
        state = self.dump_state()
        delay = delay or self.crawler.delay
        Queue.queue(stage, state, data, delay)
653188
function createListener(db, e, object) {
  function listener(err) {
    if (object.listeners(e).length > 0) {
      object.emit(e, err, db);

      // Emit on all associated db's if available
      for (let i = 0; i < db.s.children.length; i++) {
        db.s.children[i].emit(e, err, db.s.children[i]);
      }
    }
  }
  return listener;
}
271157
function emit (route) {
    var matched = match(route)

    var args = new Array(arguments.length)
    args[0] = matched.params
    for (var i = 1; i < args.length; i++) {
      args[i] = arguments[i]
    }

    return matched.cb.apply(matched.cb, args)
  }
461629
@Override
    public void emit(Sink sink, DataType dataType, String header) {
    	logger.fine("Generating data type " + dataType.name + ".");
        sink.write(header);
        sink.write(ASTPrinter.print(dataType));
        sink.write("\n*/\n");

        sink.write(ASTPrinter.printComments("", commentProcessor.leftAlign(dataType.comments)));
        for (Annotation annotation : dataType.annotations) {
            sink.write(ASTPrinter.print(annotation));
            sink.write("\n");
        }
        if (dataType.constructors.size() == 1) {
            emitSingleConstructor(sink, dataType, header);
            
        } else {
            emitMultipleConstructor(sink, dataType, header);
        }
    }
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;
    }
  }
}
1086899
function emitStart(name, attrs) {
  this.emit('data', '<' + name);
  for (var attr in attrs) if (__own.call(attrs, attr)) {
    this.emit('data', ' ' + attr + '="' + escape(attrs[attr]) + '"');
  }
  this.emit('data', '>');
}
379220
public function execute()
    {
        $this->label = str_replace(array(
            '#dbName#',
            '#nbQueries#',
            '#totalDuration#'
        ), array(
            $this->dbName,
            count($this->payload) - 1,
            round($this->totalDuration, 2)
        ), $this->label);
        
        $this->firephp->fb(array(
            $this->label,
            $this->payload
        ), \FirePHP::TABLE);
    }
1264866
def emit( self, record ):
        
        msg   = self._formatter.format(record)
        align = self._splash.textAlignment()
        fg    = self._splash.textColor()
        
        self._splash.showMessage(msg, align, fg)
1234717
def emit(self, action, event, **kwargs):
        
        for listener in self._listeners:
            listener.put_nowait((action, event, kwargs))
1173628
def emit(self, sound, exclude=set()):
        """"""
        nearby = self.nearby()
        try:
            exclude = set(exclude)
        except TypeError:
            exclude = set([exclude])
        exclude.add(self.entity)
        listeners = nearby - exclude
        for listener in listeners:
            listener.tell(sound)
1074197
function(site, env) {

    app.status('Pushing database.');

    // Make sure remote db is up
    return terminus.wakeSite(site, env)

    // Grab binding info
    .then(function() {
      return terminus.connectionInfo(site, env);
    })

    // Push our DB up to pantheon
    .then(function(bindings) {
      return commands.exportDB(bindings.mysql_command);
    });

  }