class BootstrapMarkup

Class BootstrapMarkup provides methods for using Bootstrap specific HTML markups.

Public Class Methods

new() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 4
def initialize
  @str = ''
end

Public Instance Methods

bigcell_begin() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 52
def bigcell_begin
  @str << '<td colspan="3"><h5>'
end
bigcell_end() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 56
def bigcell_end
  @str << '</h5></td>'
end
cell_begin() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 44
def cell_begin
  @str << '<td>'
end
cell_content(str) click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 60
def cell_content(str)
  @str << str
end
cell_end() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 48
def cell_end
  @str << '</td>'
end
header_begin() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 24
def header_begin
  @str << '<th>'
end
header_content(str) click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 32
def header_content(str)
  @str << str unless str.nil?
end
header_end() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 28
def header_end
  @str << '</th>'
end
headers_begin() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 16
def headers_begin
  @str << '<thead><tr>'
end
headers_end() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 20
def headers_end
  @str << '</tr></thead>'
end
render() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 64
def render
  @str
end
row_begin() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 36
def row_begin
  @str << '<tr>'
end
row_end() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 40
def row_end
  @str << '</tr>'
end
table_begin(css_class = 'table-condensed') click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 8
def table_begin(css_class = 'table-condensed')
  @str << "<table class=\"table x #{css_class}\">"
end
table_end() click to toggle source
# File lib/coursegen/course/helpers/bootstrap_markup.rb, line 12
def table_end
  @str << '</table>'
end