    # File lib/yard/i18n/text.rb, line 52
          def translate(locale)
            translated_text = ""
            parse do |part|
              case part[:type]
              when :markup
                translated_text << part[:line]
              when :attribute
                prefix = "#{part[:prefix]}#{part[:name]}#{part[:infix]}"
                value = locale.translate(part[:value])
                suffix = part[:suffix]
                translated_text << "#{prefix}#{value}#{suffix}"
              when :paragraph
                translated_text << locale.translate(part[:paragraph])
              when :empty_line
                translated_text << part[:line]
              else
                raise "should not reach here: unexpected type: #{type}"
              end
            end
            translated_text
          end