public \Joomla\CMS\Toolbar\Button\StandardButton
save2copy
(string $task, string $text = 'JTOOLBAR_SAVE_AS_COPY')
/**
* Writes a save as copy button for a given option.
* Save as copy operation leads to a save after clearing the key,
* then returns user to edit mode with new key.
*
* @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 save2copy(string $task, string $text = 'JTOOLBAR_SAVE_AS_COPY') : StandardButton
{
return $this->standardButton('save-copy', $text)->task($task)->formValidation(true);
}