public function process_final_element(base_final_element $final)
 {
     // Send full tag to xml_writer and annotations (only if has value)
     if ($final->is_set()) {
         $attrarr = array();
         foreach ($final->get_attributes() as $attribute) {
             $attrarr[$attribute->get_name()] = $attribute->get_value();
         }
         $this->writer->full_tag($final->get_name(), $final->get_value(), $attrarr);
         if ($this->progress) {
             $this->progress->progress();
         }
         // Annotate current value if configured to do so
         $final->annotate($this->get_var(backup::VAR_BACKUPID));
     }
 }
 public function to_string($showvalue = false)
 {
     $output = parent::to_string($showvalue);
     if (!empty($this->final_elements)) {
         foreach ($this->final_elements as $final_element) {
             $output .= PHP_EOL . $final_element->to_string($showvalue);
         }
     }
     if (!empty($this->children)) {
         foreach ($this->children as $child) {
             $output .= PHP_EOL . $child->to_string($showvalue);
         }
     }
     if (!empty($this->optigroup)) {
         $output .= PHP_EOL . $this->optigroup->to_string($showvalue);
     }
     return $output;
 }