if (! pickBuffer(4+4+complete_app_name.length)) return false; writeApp(COMPLETE_APP_FORMAT, complete_app_name);
buffer_length = 4 + 4 + complete_app_name.length; padding = complete_app_name.length % 4; if (padding != 0) { buffer_length += 4 + 4 + padding; } if (! pickBuffer(buffer_length)) return false; writeApp(COMPLETE_APP_FORMAT, complete_app_name, padding);
  private boolean processCallbacksFromConsumer()   {    if (notifyAppRunComplete) {      if (! pickBuffer(4+4+4+4+complete_app_run_name.length)) return false;      writeAppRun(COMPLETE_APP_RUN_FORMAT, complete_app_run, complete_app_run_name);      notifyAppRunComplete = false; complete_app_run = -1; complete_app_run_name = null;      updateBufferIndex();    }    if (notifyAppRunStart) {      if (! pickBuffer(4+4+4+4+   start_app_run_name.length)) return false;      writeAppRun(START_APP_RUN_FORMAT, start_app_run, start_app_run_name);      notifyAppRunStart = false;      start_app_run = -1;     start_app_run_name = null;      updateBufferIndex();    }    if (notifyAppComplete) {      if (! pickBuffer(4+4+complete_app_name.length)) return false;      writeApp(COMPLETE_APP_FORMAT, complete_app_name);      notifyAppComplete = false;                               complete_app_name = null;      updateBufferIndex();    }    if (notifyAppStart) {      if (! pickBuffer(4+4+   start_app_name.length)) return false;      writeApp(START_APP_FORMAT, start_app_name);      notifyAppStart = false;                                     start_app_name = null;      updateBufferIndex();    }    return true;  }