class Fictium::ApiBlueprintExporter::FooterFormatter
Public Instance Methods
format(document)
click to toggle source
Calls superclass method
Fictium::ApiBlueprintExporter::BaseFormatter#format
# File lib/fictium/exporters/api_blueprint_exporter/footer_formatter.rb, line 9 def format(document) list = super(document) list.present? ? "# #{api_blueprint.footer_header}\n\n#{list}" : '' end
Protected Instance Methods
format_sections(_document)
click to toggle source
# File lib/fictium/exporters/api_blueprint_exporter/footer_formatter.rb, line 16 def format_sections(_document) [ api_version_reference, terms_of_service_reference, license_reference ] end
Private Instance Methods
api_version_reference()
click to toggle source
# File lib/fictium/exporters/api_blueprint_exporter/footer_formatter.rb, line 26 def api_version_reference return '' if info.version.blank? api_version_formatter.call(info.version) end
license_reference()
click to toggle source
# File lib/fictium/exporters/api_blueprint_exporter/footer_formatter.rb, line 38 def license_reference info.license.present? ? license_formatter.call(info.license) : '' end
terms_of_service_reference()
click to toggle source
# File lib/fictium/exporters/api_blueprint_exporter/footer_formatter.rb, line 32 def terms_of_service_reference return '' if info.terms_of_service.blank? terms_of_service_formatter.call(info.terms_of_service) end