Class: Table

Inherits:
Array
  • Object
show all
Includes:
XX::HTML4::Strict, XX::XHTML::Strict, XX::XML
Defined in:
lib/xx.rb,
lib/xx-0.1.0.rb

Constant Summary

Constants included from XX::Markup

XX::Markup::XX_MARKUP_RECURSIVE_INCLUSION_PROC

Instance Method Summary collapse

Methods included from XX::XML

#xml_

Methods included from XX::Markup

included

Methods included from XX::Markup::ClassMethods

#xx_ancestors, #xx_config, #xx_config_for, #xx_configure, #xx_define_tag_method, #xx_define_tmp_method, #xx_remove_tag_method, #xx_tag_method_name

Methods included from XX::Markup::InstanceMethods

#method_missing, #xx_ancestors, #xx_any_, #xx_cdata_, #xx_class, #xx_config, #xx_config_for, #xx_configure, #xx_define_tag_method, #xx_define_tmp_method, #xx_doc, #xx_markup_, #xx_parse_attributes, #xx_parse_yaml_attributes, #xx_remove_tag_method, #xx_tag_, #xx_tag_method_name, #xx_text_, #xx_which, #xx_with_doc_in_effect

Methods included from XX::HTML4::Strict

#html4_

Methods included from XX::HTML4

#html4_

Methods included from XX::XHTML::Strict

#xhtml_

Methods included from XX::XHTML

#xhtml_

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class XX::Markup::InstanceMethods

Instance Method Details

#docObject



684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
# File 'lib/xx.rb', line 684

def doc 
  html_{
    head_{ title_{ "xhtml/html4/xml demo" } }

    div_{
      h_{ "< malformed html & un-escaped symbols" }
    }

    t_{ "escaped & text > <" }

    x_{ "<any_valid> xml </any_valid>" }

    div_(:style => :sweet){ 
      em_ "this is a table"

      table_(:width => 42, :height => 42){
        each{|row| tr_{ row.each{|cell| td_ cell } } }
      }
    }

    script_(:type => :dangerous){ cdata_{ "javascript" } }
  }
end

#to_html4Object



710
711
712
# File 'lib/xx.rb', line 710

def to_html4
  html4_{ doc }
end

#to_xhtmlObject



707
708
709
# File 'lib/xx.rb', line 707

def to_xhtml
  xhtml_{ doc }
end

#to_xmlObject



713
714
715
# File 'lib/xx.rb', line 713

def to_xml
  xml_{ doc }
end