/**
 * Writes a cancel button and invokes a cancel operation (eg a checkin).
 *
 * @param   string  $task  The task name of this button.
 * @param   string  $text  The text of this button.
 *
 * @return  StandardButton
 *
 * @since   4.0.0
 */
public function cancel(string $task, string $text = 'JTOOLBAR_CLOSE') : StandardButton
{
    return $this->standardButton('cancel', $text)->task($task);
}