Class: RubyToBlock::Block::Null
- Defined in:
- app/models/concerns/ruby_to_block/block/null.rb
Overview
Null(何もない)ブロックを表現する
Constant Summary
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
#fields, #parent, #prev_sibling, #sibling, #statements, #values
Instance Method Summary collapse
Methods inherited from Base
#[], #add_statement, #add_value, blocknize, indent?, #indent_level, inherited, #initialize, inline?, #inline?, priority, process_else, process_end, process_match_data, process_value_string, regexp, statement?, type, #type, value?
Constructor Details
This class inherits a constructor from RubyToBlock::Block::Base
Instance Method Details
#null? ⇒ Boolean
12 13 14 |
# File 'app/models/concerns/ruby_to_block/block/null.rb', line 12 def null? !@sibling end |
#to_xml(parent) ⇒ Object
6 7 8 9 10 |
# File 'app/models/concerns/ruby_to_block/block/null.rb', line 6 def to_xml(parent) return nil unless @sibling @sibling.to_xml(parent) end |