code: public void sendMessage(View view) {
      ((InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE))
          .hideSoftInputFromWindow(hostEdit.getWindowToken(), 0);
      sendButton.setEnabled(false);
      resultText.setText("");
      new GrpcTask(this, cache)
          .execute(
              hostEdit.getText().toString(),
              messageEdit.getText().toString(),
              portEdit.getText().toString(),
              getCheckBox.isChecked(),
              noCacheCheckBox.isChecked(),
              onlyIfCachedCheckBox.isChecked());
    }
docs: Sends RPC. Invoked when app button is pressed.