Run the tasks as a part of the start up process.

With the current implementation, the Runnables will be executed
just before starting the server.

@param callback
@return this, for chaining
321821
public Jawn onStartup(Runnable callback) {
        Objects.requireNonNull(callback);
        bootstrapper.onStartup(callback);
        return this;
    }
1194431
def start(self, build_requests=None, callback=None):
        
        if callback:
            self.callback = callback
        if build_requests:
            self.build_requests = build_requests

        # spin off requester thread
        self.sw = threading.Thread(target=self.run)
        self.sw.start()
1130525
public static Callable<Object> callable(Runnable task) {
        if (task == null)
            throw new NullPointerException();
        return new RunnableAdapter<Object>(task, null);
    }
289514
public void addCallback(final ClientTransport.PingCallback callback, Executor executor) {
    Runnable runnable;
    synchronized (this) {
      if (!completed) {
        callbacks.put(callback, executor);
        return;
      }
      // otherwise, invoke callback immediately (but not while holding lock)
      runnable = this.failureCause != null ? asRunnable(callback, failureCause)
                                           : asRunnable(callback, roundTripTimeNanos);
    }
    doExecute(executor, runnable);
  }
1065882
@Override
    public final void run() {
        for (; ; ) {
            final BaasHandler<?> curr = suspendableHandler.get();
            // at this stage we are in the callback thread of execution
            // we get the current handler and choose the state to reach
            if (curr == Signal.COMMITTED) {
                //the callback has already run
                // really we don't have to make any work
                return;
            }

            final BaasHandler<?> target;
            if (curr == Signal.SUSPENDED || curr == Signal.DELIVERED) {
                //if the current state is SUSPENDED the target state
                //to reach is DELIVERED
                //handlers in DELIVERED state won't change and remain the same
                //so for both the cases the target state would be
                // DELIVERED and there would be no more work to do
                target = Signal.DELIVERED;
            } else {
                // we have a real handler to execute
                // and we need to commit the execution
                target = Signal.COMMITTED;
            }

            if (suspendableHandler.compareAndSet(curr, target)) {
                //at this point the transition is completed
                //if the target we reached is COMMITTED than we have
                //to execute the callback and cleanup the dispatcher
                if (target == Signal.COMMITTED) {
                    if (curr != null) {
                        ((BaasHandler<R>) curr).handle(result);
                    }
                    finish();
                }
                return;
            }
        }
    }
1243606
public CallbackList<T> add(Callback<T> callback) {
    checkState();
    callbacks.add(callback);
    return this;
  }
1088624
function(options){
    this.triggerMethod("initialize:before", options);
    this._initCallbacks.run(options, this);
    this.triggerMethod("initialize:after", options);

    this.triggerMethod("start", options);
  }
1034124
def _run_atstart():
    ''''''
    global _atstart
    for callback, args, kwargs in _atstart:
        callback(*args, **kwargs)
    del _atstart[:]
1159163
public final void start(final Command command, final Callback callback) {
        this.start = System.currentTimeMillis();
        this.conditionSatisfied = false;
        command.execute();
        new Async().whilst(new KeepGoing(), new Finish(callback), checker(), 500);
    }
846889
private Runnable createProcessRunner(final BlockingQueue<FlowletProcessEntry<?>> processQueue,
                                       final List<FlowletProcessEntry<?>> processList,
                                       final ClassLoader classLoader) {
    return new Runnable() {
      @Override
      public void run() {
        Thread.currentThread().setContextClassLoader(classLoader);
        for (FlowletProcessEntry<?> entry : processList) {
          if (!handleProcessEntry(entry, processQueue)) {
            processQueue.offer(entry);
          }
        }
      }
    };
  }
550656
function doRun() {
    if (Module['calledRun']) return; // run may have just been called while the async setStatus time below was happening
    Module['calledRun'] = true;

    if (ABORT) return;

    ensureInitRuntime();

    preMain();


    if (Module['onRuntimeInitialized']) Module['onRuntimeInitialized']();

    if (Module['_main'] && shouldRunNow) Module['callMain'](args);

    postRun();
  }
537548
@Override public void start(Set<File> files, Consumer<Set<File>> callback) {
        if (isStarted()) {
            throw new IllegalStateException("start() should not be called more than once");
        }
        Set<File> filesCopy = ImmutableSet.copyOf(files);
        Preconditions.checkArgument(filesCopy.size() > 0, "must specify at least 1 file to watch for changes");
        this.callback = requireNonNull(callback);
        watchedFiles = filesCopy;
        executorService = MoreExecutors.listeningDecorator(Executors.newScheduledThreadPool(1));
        future = executorService.scheduleAtFixedRate(
            this::scanFilesForChanges,
            initialDelay,
            interval,
            timeUnit);
    }
463242
def start(dispatcher, future, *, loop=None, skip_updates=None,
          on_startup=None, on_shutdown=None):
    
    executor = Executor(dispatcher, skip_updates=skip_updates, loop=loop)
    _setup_callbacks(executor, on_startup, on_shutdown)

    return executor.start(future)
1205009
protected function runProcess($callback = null)
    {
        $process = $this->processBuilder
            ->setArguments(
                $this->prepareArguments()
            )
            ->getProcess();

        // exit code
        $result = $process->run($callback);

        // text-mode
        if (null === $callback) {
            $result = $process->getOutput();

            if (false === $process->isSuccessful()) {
                $process->getErrorOutput();
            }
        }

        return $result;
    }
528031
@Override
    public void run() {
        try {
            if (this.isDone()) {
                return;
            }
            ExpeditedFutureTask<V> futureTask = new ExpeditedFutureTask<V>(this.m_callable);
            this.m_defaultFuture = futureTask;
            this.m_executor.execute(futureTask);
            this.m_scheduledExecutorQueue.remove(this);
        } catch (Exception e) {
            this.m_pendingException = new RuntimeException(e);
            return;
        } finally {
            // Let blocked ScheduleFuture methods thru now.
            this.m_coordinationLatch.countDown();
        }
    }
807431
public static <Result> TaskBuilder<Result> create(TaskCallback<Result> callback) {
        return new TaskBuilder<Result>().callback(callback);
    }
998909
function run_callbacks (object, key) {
  var callbacks = object[key];
  var callback;
  // Mark the module is ready
  // `delete module.c` is not safe
  // #135
  // Android 2.2 might treat `null` as [object Global] and equal it to true,
  // So, never confuse `null` and `false`
  object[key] = FALSE;
  while(callback = callbacks.pop()){
    callback();
  }
}